02.01.2009, 13:17
Do you Just need a vehicle spawner? If so, here's a nice simple one for you:
pawn Код:
if(strcmp(cmdtext, "/veh", true, 4) == 0)
{
new pos = strfind(cmdtext, " ", true);
strdel(cmdtext, 0, pos + 1);
if(IsPlayerInAnyVehicle(playerid) == 1) return SendClientMessage(playerid, 0xFF0000AA, "You can not spawn vehicles when in a vehicle");
if(strval(cmdtext) < 400 || strval(cmdtext) > 611) return SendClientMessage(playerid, 0xFF0000AA, "Vehicle IDs go from 400 to 611");
new Float:X, Float:Y, Float:Z, Float:A;
GetPlayerPos(playerid, X, Y, Z);
GetPlayerFacingAngle(playerid, A);
X += (5 * floatsin(-A, degrees));
Y += (5 * floatcos(-A, degrees));
CreateVehicle(strval(cmdtext), X, Y, Z, A + 90, -1, -1, -1);
return 1;
}