How to create checkpoints inside interior using streamer? - 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: How to create checkpoints inside interior using streamer? (
/showthread.php?tid=662474)
How to create checkpoints inside interior using streamer? -
beastmaster - 02.01.2019
hi , as the title say's i am trying to create an checkpoint inside an interior but it is not showing up and here is my script(this is my first thread so please be kind (
Код:
new pizza1cp;
public OnGameModeInit()
{
SetGameModeText("Freeroam RP Cops Race");
DisableInteriorEnterExits();
UsePlayerPedAnims();
AddPlayerClass(270, 1682.7000,-2244.8999,13.5454,178.9000,0,0,0,0,0,0);
//CHECKPOINTS FOR INTERIORS
pizza1cp = CreateDynamicCP(373.9403,-119.2545,1001.4922, 3, -1, -1, -1, 100.0);
return 1;
}
public OnPlayerEnterDynamicCP(playerid, checkpointid)
{
if(checkpointid == pizza1cp)
{
ShowInfoBox(playerid, 0x00000099, 10, "Welcome to Well Staced Pizza Co. WE ARE OUT OF STOCK!");
}
return 1;
}
Re: How to create checkpoints inside interior using streamer? -
AhmedMohamed - 02.01.2019
Check this thread:
https://forum.sa-mp.com/showthread.p...48#post2482048
Quote:
Originally Posted by DaTa[X]
use this plugin/include : https://sampforum.blast.hk/showthread.php?tid=102865
and make a cp like this
pawn Код:
new CP1; new CP2; new CP3; public OnGameModeInit() { CP1 = CreateDynamicCP(220.5612,1423.4796,10.5859,3, -1,-1,-1,100.0); CP2 = CreateDynamicCP(599.6351,1247.6184,11.7188,3, -1,-1,-1,100.0); CP3 = CreateDynamicCP(14.6718,1549.8481,12.7672,3,-1,-1,-1,100.0); }
[/pawn]
and dont forget the callbacks
pawn Код:
public OnPlayerEnterDynamicCP(playerid, checkpointid) { if(checkpointid == CP1) { SendClientMessage(playerid,-1," CP1"); } if(checkpointid == CP2) { SendClientMessage(playerid,-1,"CP2"); } if(checkpointid == CP3) { SendClientMessage(playerid,-1,"CP3"); } } public OnPlayerLeaveDynamicCP(playerid, checkpointid) { if(checkpointid == CP1) { SendClientMessage(playerid,-1,"you left checkpoint CP1"); } if(checkpointid == CP2) { SendClientMessage(playerid,-1,"you left checkpoint CP2"); } if(checkpointid == CP3) { SendClientMessage(playerid,-1,"you left checkpoint CP3"); } }
|
pawn Код:
CreateDynamicCP(Float:x, Float:y, Float:z, Float:size, worldid, interiorid, playerid, Float:distance);
pizza1cp = CreateDynamicCP(373.9403,-119.2545,1001.4922, 3, -1, -1, -1, 100.0);
//just make it like below:
pizza1cp = CreateDynamicCP(373.9403,-119.2545,1001.4922, 3, -1, {your desired interior id}, -1, 100.0);
Re: How to create checkpoints inside interior using streamer? -
beastmaster - 03.01.2019
Код:
CreateDynamicCP(Float:x, Float:y, Float:z, Float:size, worldid, interiorid, playerid, Float:distance);
pizza1cp = CreateDynamicCP(373.9403,-119.2545,1001.4922, 3, -1, -1, -1, 100.0);
//just make it like below:
pizza1cp = CreateDynamicCP(373.9403,-119.2545,1001.4922, 3, -1, {your desired interior id}, -1, 100.0);
Thanks but I already know about this thread and I tried that but still it's not working somehow.
Re: How to create checkpoints inside interior using streamer? -
beastmaster - 03.01.2019
Anyone can help me?
Re: How to create checkpoints inside interior using streamer? -
BOyka1 - 03.01.2019
Deleted