15.04.2013, 00:36
Hi,
I Was looking how to make something like this
If anyone Could help i would appreciate it.
I Was looking how to make something like this
If anyone Could help i would appreciate it.
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);
}
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");
}
}
C:\Documents and Settings\Other Users\Desktop\Shanes Server\gamemodes\Server.pwn(103) : error 017: undefined symbol "CreateDynamicCP" C:\Documents and Settings\Other Users\Desktop\Shanes Server\gamemodes\Server.pwn(104) : error 017: undefined symbol "CreateDynamicCP" C:\Documents and Settings\Other Users\Desktop\Shanes Server\gamemodes\Server.pwn(105) : error 017: undefined symbol "CreateDynamicCP" C:\Documents and Settings\Other Users\Desktop\Shanes Server\gamemodes\Server.pwn(596) : warning 235: public function lacks forward declaration (symbol "OnPlayerEnterDynamicCP") C:\Documents and Settings\Other Users\Desktop\Shanes Server\gamemodes\Server.pwn(612) : warning 235: public function lacks forward declaration (symbol "OnPlayerLeaveDynamicCP") C:\Documents and Settings\Other Users\Desktop\Shanes Server\gamemodes\Server.pwn(618) : warning 217: loose indentation Pawn compiler 3.2.3664 Copyright © 1997-2006, ITB CompuPhase 3 Errors.
CP1 = CreateDynamicCP(2194.0273,1990.7640,11.9220,3, -1,-1,-1,100.0);//Line 103 CP2 = CreateDynamicCP(2196.2295,1676.3077,11.9922,3, -1,-1,-1,100.0);//Line 104 CP3 = CreateDynamicCP(14.6718,1549.8481,12.7672,3,-1,-1,-1,100.0);//Line 105
public OnPlayerEnterDynamicCP(playerid, checkpointid)//Line 596 { 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)//Line 612 { if(checkpointid == CP1) { SendClientMessage(playerid,-1,"you left checkpoint CP1"); } if(checkpointid == CP2)//Line 618 { SendClientMessage(playerid,-1,"you left checkpoint CP2"); } if(checkpointid == CP3) { SendClientMessage(playerid,-1,"you left checkpoint CP3"); } }