Whats wrong with this racecp?
#1

Same thing happens with regular cp

pawn Код:
public OnPlayerEnterDynamicRaceCP(playerid, checkpointid)
{
    if(checkpointid == buscp1[playerid])
    {
        DestroyDynamicRaceCP(buscp1[playerid]);
        buscp2[playerid] = CreateDynamicRaceCP(0, 393.8065,-1770.1382,5.3697, 850.7170,-1329.2406,13.4902, 2, -1, -1, playerid, 1000000);
    }
   
    else if(checkpointid == buscp2[playerid])
    {
        DestroyDynamicRaceCP(buscp2[playerid]);
        buscp3[playerid] = CreateDynamicRaceCP(0, 850.7170,-1329.2406,13.4902, 1206.4131,-1328.0035,13.3984, 2, -1, -1, playerid, 1000000);
    }
    return 1;
}
The second racecp does not get destroyed, it just "respawns" where it was
Reply
#2

pawn Код:
public OnPlayerEnterDynamicRaceCP(playerid, checkpointid)
{
    if(checkpointid == buscp1[playerid])
    {
        DestroyDynamicRaceCP(buscp1[playerid]);
        buscp2[playerid] = CreateDynamicRaceCP(0, 393.8065,-1770.1382,5.3697, 850.7170,-1329.2406,13.4902, 2, -1, -1, playerid, 1000000);
    }
   
    if(checkpointid == buscp2[playerid])
    {
        DestroyDynamicRaceCP(buscp2[playerid]);
        buscp3[playerid] = CreateDynamicRaceCP(0, 850.7170,-1329.2406,13.4902, 1206.4131,-1328.0035,13.3984, 2, -1, -1, playerid, 1000000);
    }
    return 1;
}
Try with this, i remove the else of the second function
Reply


Forum Jump:


Users browsing this thread: 1 Guest(s)