Car problem
#3

pawn Код:
CMD:veh(playerid, params[])
{
    if(!IsCnRAdmin(playerid)) return SendClientMessage(playerid, COLOR_RED, "You Must Be An Admin To Spawn This Vehicle.");
    if(isDead[playerid] == 1) return SendClientMessage(playerid, COLOR_RED, "You Cannot Use This Command When Dead.");
    if(GetPlayerInterior(playerid) != 0) return SendClientMessage(playerid, COLOR_RED, "You Cannot Use This Command In An Interior.");
    new carName[32];
    if(sscanf(params, "s[32]", carName)) return SendClientMessage(playerid, COLOR_RED, "USAGE: /veh (Vehicle Name)");
    if(BlockVeh == 1) return  SendClientMessage(playerid, COLOR_RED, "This Command Is DISABLED.");
    if(IsPlayerInAnyVehicle(playerid)) return SendClientMessage(playerid, COLOR_RED, "You Are Already In A Vehicle.");
    if(ReturnVehicleID(carName) == INVALID_VEHICLE_ID) return SendClientMessage(playerid, COLOR_RED, "Invalid Vehicle Model.");
    if(IsVehicleForbidden(ReturnVehicleID(carName))) return SendClientMessage(playerid, COLOR_RED, "You Must Be An Admin To Spawn This Vehicle.");
    new Float:pPos[4], vid;
    GetPlayerPos(playerid, pPos[0], pPos[1], pPos[2]);
    GetPlayerFacingAngle(playerid, pPos[3]);
    vid = CreateVehicle(ReturnVehicleID(carName), pPos[0], pPos[1], pPos[2] + 1.00, pPos[3], 0, 0, 60);
    PutPlayerInVehicle(playerid, vid, 0);
    return 1;
}
Reply


Messages In This Thread
Car problem - by [..MonTaNa..] - 07.04.2013, 18:13
Re: Car problem - by SomebodyAndMe - 07.04.2013, 18:17
Re: Car problem - by Windrush - 07.04.2013, 18:18
Re: Car problem - by [..MonTaNa..] - 07.04.2013, 18:25
Re: Car problem - by [..MonTaNa..] - 07.04.2013, 18:39
Re: Car problem - by [..MonTaNa..] - 08.04.2013, 01:18
Re: Car problem - by [..MonTaNa..] - 08.04.2013, 02:41

Forum Jump:


Users browsing this thread: 1 Guest(s)