Problem with CMD
#1

I do this command in the server and just nothing happens.

PHP код:
CMD:apark(playeridparams[]) {
    if(
PlayerInfo[playerid][pAdmin] >= 3)
    {
        if(
AdminDuty[playerid] != && PlayerInfo[playerid][pAdmin] < 6)
        {
            
SendClientMessage(playerid,COLOR_WHITE"You're not on-duty as admin. To access your admin commands you must be on-duty. Type /aduty to go on-duty.");
            return 
1;
           }
        foreach(
Playerownerid)
        {
            for(new 
MAX_PLAYERVEHICLESd++)
            {
                if(
IsPlayerInVehicle(playeridPlayerVehicleInfo[ownerid][d][pvId]))
                {
                    if(
GetPlayerState(playerid) != PLAYER_STATE_DRIVER) return SendClientMessage(playeridCOLOR_GREY"You must be in the driver seat.");
                    new 
Float:xFloat:yFloat:zFloat:angleFloat:health;
                    if(
PlayerInfo[playerid][pLockCar] == GetPlayerVehicleID(playerid)) PlayerInfo[playerid][pLockCar] = INVALID_VEHICLE_ID;
                    if(
IsARC(GetPlayerVehicleID(playerid))) // RC Vehicles
                    
{
                        new 
Float:vehPos[3];
                        
GetVehiclePos(GetPlayerVehicleID(playerid),vehPos[0], vehPos[1], vehPos[2]);
                        
SetPlayerPos(playerid,vehPos[0], vehPos[1]+0.5vehPos[2]+0.5);
                    }
                    
GetVehicleHealth(PlayerVehicleInfo[ownerid][d][pvId], health);
                    
GetVehiclePos(PlayerVehicleInfo[ownerid][d][pvId], xyz);
                    
GetVehicleZAngle(PlayerVehicleInfo[ownerid][d][pvId], angle);
                    
SurfingCheck(GetPlayerVehicleID(playerid));
                    
UpdatePlayerVehicleParkPosition(owneriddxyzanglehealth);
                    
PutPlayerInVehicle(playeridGetPlayerVehicleID(playerid), 0);
                     
SetPlayerArmedWeapon(playerid0);
                     new 
szMessage[128];
                     
format(szMessagesizeof(szMessage),"You have parked %s's %s.",GetPlayerNameEx(ownerid), VehicleName[PlayerVehicleInfo[ownerid][d][pvModelId] - 400]);
                    
SendClientMessage(playeridCOLOR_WHITEszMessage);
                    
format(szMessagesizeof(szMessage), "Your %s has been parked at another location by an admin. Use /trackcar to find it."VehicleName[PlayerVehicleInfo[ownerid][d][pvModelId] - 400]);
                    
SendClientMessage(owneridCOLOR_WHITEszMessage);
                    return 
1;
                }
            }
        }
    }
    else
    {
        
SendClientMessage(playeridCOLOR_GRAD1"You're not authorized to use that command!");
    }
    return 
1;

Reply
#2

??
Reply


Forum Jump:


Users browsing this thread: 1 Guest(s)