23.01.2016, 12:05
Hello, I have problem with Dynamic checkpoint from Streamer, it`s won`t show up, here is the code.
Screen
pawn Код:
hook OnPlayerKeyStateChange(playerid, newkeys, oldkeys)
{
if(newkeys == KEY_SUBMISSION)
{
if(GetPlayerState(playerid) != PLAYER_STATE_DRIVER) return SendDebug(playerid, "Check: 1");
new model = GetVehicleModel(GetPlayerVehicleID(playerid));
if(model != 431 && model != 437) return SendDebug(playerid, "Check: 2");
if(IsValidDynamicCP(pJobCP[playerid])) return SendDebug(playerid, "Check: 3");
new RandomCpID = random(sizeof(BusJobCP));
pJobCP[playerid] = CreateDynamicCP(BusJobCP[RandomCpID][PosX], BusJobCP[RandomCpID][PosY], BusJobCP[RandomCpID][PosZ],2.0, -1, -1, playerid, 1000.0);
SendDebug(playerid,"PosX: %f, PosY: %f, PosZ: %f", BusJobCP[RandomCpID][PosX], BusJobCP[RandomCpID][PosY], BusJobCP[RandomCpID][PosZ]);
}
return 1;
}