29.03.2015, 18:27
edit:
new vehicleid;
vehicleid= GetPlayerVehicleID(playerid);
if(GetVehicleModel(vehicleid) == 415)
fixed it got what i wanted done from this line getvehiclemodel thanks for the help
Код:
if(strcmp("/vs", cmdtext,true, 10) == 0) { if(PlayerToPoint(3.0,playerid,2490.0757,-1662.8297,13.1110)) // 723.6520, -1890.7867, -0.0164 are the coord from your PirateShip(X,Y,Z) and 5.0 is the range between ship and player. { new vehicleid; vehicleid= GetPlayerVehicleID(playerid); if(GetVehicleModel(vehicleid) == 415) // { DestroyVehicle(vehicleid); SendClientMessage(playerid, -1, "You have recieved $5000"); GameTextForPlayer(playerid, "VEHICLE SOLD", 3000, 5); GivePlayerMoney(playerid, 5000); DisablePlayerCheckpoint(playerid); RemovePlayerMapIcon(playerid, 12); } } if(PlayerToPoint(3.0,playerid,2490.0757,-1662.8297,13.1110)) // 723.6520, -1890.7867, -0.0164 are the coord from your PirateShip(X,Y,Z) and 5.0 is the range between ship and player. { if(IsPlayerInVehicle(playerid, bullet)) { new vehicleid; vehicleid= GetPlayerVehicleID(playerid); if(vehicleid == bullet) DestroyVehicle(vehicleid); SendClientMessage(playerid, -1, "You have recieved $3000"); GameTextForPlayer(playerid, "VEHICLE SOLD", 3000, 5); GivePlayerMoney(playerid, 3000); DisablePlayerCheckpoint(playerid); RemovePlayerMapIcon(playerid, 12); } } else SendClientMessage(playerid, -1,"You're not near the Crane."); return 1; }
vehicleid= GetPlayerVehicleID(playerid);
if(GetVehicleModel(vehicleid) == 415)
fixed it got what i wanted done from this line getvehiclemodel thanks for the help