SA-MP Forums Archive
Sending Message - 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)
+---- Forum: Help Archive (https://sampforum.blast.hk/forumdisplay.php?fid=89)
+---- Thread: Sending Message (/showthread.php?tid=173170)



Sending Message - Alex_Valde - 01.09.2010

How can I do script when player stands on pick up that he gets message..etc type /enter to come in this building?
And if that can be done with diferent styles??


Re: Sending Message - Voldemort - 01.09.2010

Make global timer and chack if IsPlayerInRangeOfPoint( if yes gametextfor player


Re: Sending Message - ||123|| - 01.09.2010

Quote:
Originally Posted by Voldemort
Посмотреть сообщение
Make global timer and chack if IsPlayerInRangeOfPoint( if yes gametextfor player
Why not just check the player pickupid on OnPickupPickup?


Re: Sending Message - Maxips2 - 01.09.2010

Create a new variable.
For example, i'll call it Var.
So, on top of the script, make a new variable.
pawn Код:
new Var;
Then go to public "OnGameModeInit()".
Then you do this:
pawn Код:
Var = CreatePickup(modelid, type, x, y, z)
then go to public "OnPlayerPickupPickup(playerid, pickupid)".
Then you do this:
pawn Код:
if(pickupid == Var)
{
    // Something
}
I hope you understand what I did here.


Re: Sending Message - Alex_Valde - 01.09.2010

Maxips2 Yeah I perfectly understand...I've done this into my "OnPlayerPickup"

Код:
if(pickupid == infopickup)
	{
	SendClientMessage(playerid, 0x1AFF00FF,"Type /enter if you want to go into building...");
	}
	return 1;
But heres the thing...Now when i stand in "i" outside I don't get any messages but when im in building and stand on "i" I get message..