truck0 = AddStaticVehicle(455,-1839.8022,-12.6983,15.5544,270.1398,254,135); //truck
public OnPlayerEnterVehicle(playerid, vehicleid, ispassenger)
{
if(vehicleid == truck0)
{
if(pInfo[playerid][job] == 1)
{
SetPlayerCheckpoint(playerid,-1872.4550,1417.2936,7.1805,5);
SendClientMessage(playerid,COLOR_OLIVE,"Fahre zum Roten Punkt und Tippe /stuff get ein.");
GetPlayerVehicleID(playerid);
}
else
{
SendClientMessage(playerid,COLOR_RED,"Du bist kein Trucker!");
SendClientMessage(playerid,COLOR_RED,"Falls du noch gefreezt bist /unfreeze.");
TogglePlayerControllable(playerid, false);
}
return 1;
}
public OnPlayerCommandText(playerid, cmdtext[])
{
if(strcmp(cmd, "/stuff", true) == 0)
{
if (pInfo[playerid][job] == 1)
{
if(vehicleid == truck0)
{
if(PlayerToPoint(50.0,playerid,-1872.1891,1418.8207,7.1805))
{
SendClientMessage(playerid,COLOR_OLIVE,"Fahre zum Roten Punkt und Tippe /deliver ein.");
SendClientMessage(playerid,COLOR_OLIVE,"Die Produkte haben dich 500$ gekostet.");
SetPlayerCheckpoint(playerid,-1020.9528,-678.2216,31.9035,5);
GivePlayerMoney(playerid,-500);
pInfo[playerid][truckprods] = 5;
}
}
}
return 1;
}
des mim einsteigen geht, aber des /stuff geht net =(
an den koordinaten kanns net liegen shcon überprüft...