09.09.2017, 15:10
Код:
YCMD:createfactioncar(playerid, params[], help) {
if(help) {
SendClientMessage(playerid, X11_WHITE, "Creates a faction vehicle");
return 1;
}
new model, faction, c1, c2;
if(!sscanf(params, "dddd", faction, model, c1, c2)) {
if(!IsValidFaction(faction)) {
SendClientMessage(playerid, X11_TOMATO_2, "Invalid Faction!");
return 1;
}
if(model < 400 || model > 611) {
SendClientMessage(playerid, X11_TOMATO_2, "Invalid Model!");
return 1;
}
new Float:X, Float:Y, Float:Z, Float:A;
GetPlayerPos(playerid, X, Y, Z);
GetPlayerFacingAngle(playerid, A);
createFactionVehicle(faction, model, X, Y, Z, A, c1, c2);
} else {
SendClientMessage(playerid, X11_WHITE, "USAGE: /createfactioncar [factionid] [model] [c1] [c2]");
}
return 1;
}


