checkpoint - 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: checkpoint (
/showthread.php?tid=224723)
checkpoint -
omer5198 - 12.02.2011
how can i create a checkpoint that will teleport you somewhere or open a dialog or something?
Re: checkpoint - Unknown123 - 12.02.2011
Something like this should work.
You will maybe get an error, just download the "
Streamer Plugin v2.5.2" and install it..
pawn Код:
new GiveGuns[MAX_PLAYERS];
public OnGameModeInit()
{
GiveGuns = CreateDynamicCP(-103.7533, -22.6790, 1000.7188, 3.0, -1, -1, -1);
return 1;
}
public OnPlayerEnterCheckPoint(playerid)
{
if(GiveGuns)
{
GivePlayerWeapon(...);
return 1;
}
}
Re : checkpoint -
[WTF]Godfather - 19.02.2011
That wat i was looking for thanks Unkown
Re: checkpoint -
Adnan Pasic - 19.02.2011
// In this example the player's checkpoint will be set when they spawn.
// On entering the checkpoint they will receive $1000 and the checkpoint will be disabled.
public OnPlayerSpawn(playerid)
{
SetPlayerCheckpoint(playerid,x,y,z,size of the checkpoint [example 3.0]);
return 1;
}
public OnPlayerEnterCheckpoint(playerid)
{
GivePlayerMoney(playerid, 1000);
DisablePlayerCheckpoint(playerid);
return 1;
}
If you need that.
Re: checkpoint -
Adnan Pasic - 19.02.2011
Sry for the duble post
if you need the teleport you need to change this:
public OnPlayerEnterCheckpoint(playerid)
{
SetPlayerPos(x,z,y);
DisablePlayerCheckpoint(playerid);
return 1;
}