07.01.2012, 16:19
Well I am making command Signal which will add a signal next to you. I found object and everything needed as I wanted, but I have problem now. I want to set a timer 5 seconds, which will after 5 seconds delete the object, but I don't get it what's the problem with this.
When I added the timer the script just stopped working. Please help me. Without the timer it was working normaly but still I want the timer with it.
Bump: I never worked with these timers before.
When I added the timer the script just stopped working. Please help me. Without the timer it was working normaly but still I want the timer with it.
Код:
if (strcmp("/signal", cmdtext, true) == 0) { new Float:x, Float:y, Float:z; GetPlayerPos(playerid, x, y, z); new Signal; Signal = CreateObject(18674,x,y,z, 0.0, 0.0, 96.0); CreateObject(Signal,x,y,z, 0.0, 0.0, 96.0); { SetTimer("Signal", 5000, false); } DestroyObject(Signal); return 1; }