Command help
#1

Hello sa-mp scripters, i need help to a command i want to getvehicleid in zcmd, how i can get it?
CMD:work(playerid, cmdtext)
{
if(GetVehicleModel(vehicleid) == 515);
{
ShowPlayerDialog(playerid, 50, DIALOG_STYLE_LIST, "Choose any of those locations", "From --- to --- /*(listitem 0)*/ \nFrom --- to --- /*(listitem 1)*/ \nFrom --- to ---/*(listitem 2)*/", "Ok", "Cancel");
}
else
SendClientMessage(playerid, red, "Nu esti in tir");
return 1;
}
I want to make my gamemode from 0...
Reply
#2

In order to check the vehicle id you have to make sure that the player is in a vehicle by using IsPlayerInAnyVehicle or GetPlayerState , after that you can do vehicleid = GetPlayerVehicleID(playerid) and that is how you get the id of the vehicle. After that you can check model of the veh, pos , params, pretty much everything that required the vehicle id.
Reply
#3

Thanks for help
Reply


Forum Jump:


Users browsing this thread: 1 Guest(s)