Checkpoint help
#1

pawn Код:
CMD:house(playerid, params[])
{
    if(pInfo[playerid][Admin]==3)
    {
        //new Float:x,Float:y,Float:z;
        //GetPlayerPos(playerid,x,y,z);
        //house = CreateDynamicCP(x,y,z,1,GetPlayerVirtualWorld(playerid),GetPlayerInterior(playerid),5);
    }
    return 1;
}

public OnPlayerEnterDynamicCP(playerid,checkpointid)
{
    if(checkpointid == house)
    {
        SendClientMessage(playerid,COLOR_GRAY,"/enter to enter house");
                // If player does command /enter?
    }
    return 1;
}
Reply
#2

Few questions/points.

1. Do you have a PLAYER VARIABLE that states which house ID is saved to the player.
2. You should change "house" to "house[MAX_PLAYERS]" and have each one for each individual player, this is more optimal and makes it much less buggy in the end.
3. Make /enter a seperate command, checking the player's location then comparing it to the house pickups or co-ordinates you are using.
4. You don't want to get the Player position then create the checkpoint on top of them.

Answer/correct these and I will help further.
Reply
#3

PHP код:
(530) : error 033: array must be indexed (variable "house")
(
547) : error 033: array must be indexed (variable "house")
(
556) : error 033: array must be indexed (variable "house"
pawn Код:
if(checkpointid == house)
Reply


Forum Jump:


Users browsing this thread: 1 Guest(s)