SA-MP Forums Archive
Walking out of a pickup? - Printable Version

+- SA-MP Forums Archive (https://sampforum.blast.hk)
+-- Forum: SA-MP Scripting and Plugins (https://sampforum.blast.hk/forumdisplay.php?fid=8)
+--- Forum: Scripting Help (https://sampforum.blast.hk/forumdisplay.php?fid=12)
+--- Thread: Walking out of a pickup? (/showthread.php?tid=344892)



Walking out of a pickup? - 2KY - 23.05.2012

How would I detect that without using a timer?

I have..

pawn Code:
public OnPlayerPickUpPickup(playerid, pickupid)
{
    if( pickupid == hospital )
    {
        TextDrawShowForPlayer( playerid, EnterTD );
    }
    return 1;
}
How would I detect if they leave that pickup without using a timer to cross reference their position?


Re: Walking out of a pickup? - iGetty - 23.05.2012

I don't think that's possible, to be totally honest.

It's a timer I'm afraid.


Re: Walking out of a pickup? - 2KY - 23.05.2012

God dammit, lol. Too bad. Alright, thanks anyhow Getty.


Re: Walking out of a pickup? - iGetty - 23.05.2012

No problem 2KY


Re: Walking out of a pickup? - Jonny5 - 23.05.2012

if you used a checkpoint you could use
IsPlayerInCheckpoint in the OnPlayerUpdate callback to see if they are still in that position,
if your not using it for anything else it might be an option.

a checkpoint is not the only way to go, im just not sure on the performance of it.,