PDA

View Full Version : checkpointid problem.


the.et
31/12/2011, 03:16 PM
i am following the tutorial here: http://forum.sa-mp.com/showthread.php?t=194471

I want to make a enter building check point here's my script:

new LVPD_enter;


public OnGameModeInit()
{
LVPD_enter = CreateDynamicCP(2290.0059,2431.4236,10.8203, 4.0 , -1, -1, -1, 100);
return 1;
}

public OnPlayerEnterDynamicCP(playerid)
{
if(checkpointid == LVPD_enter){
if(!IsPlayerInVehicle(playerid))
{
RemovePlayerFromVehicle(playerid);
SetPlayerInterior(playerid, 3);
}
return 1;
}
return 1;
}


I kept on getting this error:
error 017: undefined symbol "checkpointid"

Please , anyone where's my problem .

P/S i included streamer by Incognito Streamer
#include <streamer> on top of my script.

Ash.
31/12/2011, 03:18 PM
You need ", checkpointid" after the "playerid" variable in your OnPlayerEnterDynamicCP callback header.

Stigg
31/12/2011, 03:20 PM
public OnPlayerEnterDynamicRaceCP(playerid)
Should be:
public OnPlayerEnterDynamicRaceCP(playerid, checkpointid)
Edit: to slow.

the.et
31/12/2011, 03:23 PM
oh thankss