27.10.2010, 08:07
(
Последний раз редактировалось Haydz; 27.10.2010 в 09:13.
)
Alright, so i'v made this /airstrike command and need it to be available when a player reaches a kill streak of 5 and they can only use it once.
my code, i'v got the explosion done and it works nicely, now i just need to make it so a player can only use it once, and once they get a +5 kill streak.
If possible could you add a //and what the lines do so i can learn/remember this for later, thank you.
my code, i'v got the explosion done and it works nicely, now i just need to make it so a player can only use it once, and once they get a +5 kill streak.
If possible could you add a //and what the lines do so i can learn/remember this for later, thank you.
Код:
if (strcmp("/airstrike", cmdtext, true, 5) == 0) { new Float:x, Float:y, Float:z ; GetPlayerPos( playerid, Float:x, Float:y, Float:z ); CreateExplosion(Float:x+10, Float:y, Float:z, 8,10.0); CreateExplosion(Float:x-10, Float:y, Float:z, 8,10.0); CreateExplosion(Float:x, Float:y+10, Float:z, 8,10.0); CreateExplosion(Float:x, Float:y-10, Float:z, 8,10.0); CreateExplosion(Float:x+10, Float:y+10, Float:z, 8,10.0); CreateExplosion(Float:x-10, Float:y+10, Float:z, 8,10.0); return CreateExplosion(Float:x-10, Float:y-10, Float:z, 8,10.0); }