Official Soldat Forums

Server Talk => Scripting Discussions and Help => Topic started by: Hubiq on December 13, 2016, 05:55:26 pm

Title: Simple script - need help
Post by: Hubiq on December 13, 2016, 05:55:26 pm
Hi, I created a simple script

Quote
procedure OnPlayerSpeak(ID: Byte; Text: string);
begin
   
  if (Text='!cmd') then begin
   WriteConsole(ID, '!balance !admins', $ffff33);
  end;
end;

I want to (after type !cmd) commands !balance and !admins was visible to everyone on server.

I give you an example:

- Random player use !cmd
- and commands (!balance !admins) are visible to everyone on my server. 

Someone help me?
Title: Re: Simple script - need help
Post by: Falcon` on December 13, 2016, 06:02:53 pm
replace your WriteConsole call with this and you're done:
WriteConsole(0, '!balance !admins', $ffff33);
Title: Re: Simple script - need help
Post by: Hubiq on December 14, 2016, 03:10:08 am
Thank you man!  :D