Function positioning
#1

Hi, where i need to put

Код:
if(IsTrailerAttachedToVehicle(GetPlayerVehicleID(playerid)))
     		{
     		    new rand = (1+locatiitir[playerid]+random(sizeof(tirlocatii)-1))%sizeof(tirlocatii);
				locatiitir[playerid] = rand;
				SetPlayerCheckpoint(playerid,tirlocatii[rand][0],tirlocatii[rand][1],tirlocatii[rand][2],3);

			}
	return 1;
to set checkpoint when the truck pickup the attach
Reply
#2

OnPlayerUpdate??
Reply
#3

how to change my instructions to execute only once in onplayerupdate?
Reply
#4

This code requires a trigger. What that trigger is, is totally up to you. It could be a command, entering a checkpoint, pressing a key, ... OnPlayerUpdate isn't the right spot for this.
Reply
#5

i resolve with trigger
Reply


Forum Jump:


Users browsing this thread: 1 Guest(s)