[Ayuda] CallRemoteFunction...
#6

Basate en el comando fakecmd del ladmin... aunque talvez ya lo estes haciendo.

pawn Код:
dcmd_fakecmd(playerid,params[]) {
    if(PlayerInfo[playerid][Level] >= 3) {
        new tmp[256], tmp2[256], Index; tmp = strtok(params,Index), tmp2 = strtok(params,Index);
        if(!strlen(tmp) || !strlen(tmp2)) return SendClientMessage(playerid, red, "USAGE: /fakecmd [playerid] [command]");
        new player1 = strval(tmp);
        if(PlayerInfo[player1][Level] == ServerInfo[MaxAdminLevel] && PlayerInfo[playerid][Level] != ServerInfo[MaxAdminLevel]) return SendClientMessage(playerid,red,"ERROR: You cannot use this command on this admin");
        if(IsPlayerConnected(player1) && player1 != INVALID_PLAYER_ID) {
            CMDMessageToAdmins(playerid,"FAKECMD");
            CallRemoteFunction("OnPlayerCommandText", "is", player1, tmp2);
            return SendClientMessage(playerid,blue,"Fake command sent");
        } else return SendClientMessage(playerid,red,"ERROR: Player is not connected");
    } else return SendClientMessage(playerid,red,"ERROR: You are not a high enough level to use this command");
}
Reply


Messages In This Thread
[Ayuda] CallRemoteFunction... - by OTACON - 04.04.2012, 12:18
Respuesta: [Ayuda] CallRemoteFunction... - by iKeN - 04.04.2012, 13:51
Respuesta: [Ayuda] CallRemoteFunction... - by LuisGraph - 04.04.2012, 15:25
Respuesta: [Ayuda] CallRemoteFunction... - by TiNcH010 - 04.04.2012, 17:20
Respuesta: [Ayuda] CallRemoteFunction... - by OTACON - 04.04.2012, 21:23
Re: [Ayuda] CallRemoteFunction... - by dis77urbio - 05.04.2012, 04:36
Respuesta: [Ayuda] CallRemoteFunction... - by Jovanny - 05.04.2012, 04:39
Respuesta: [Ayuda] CallRemoteFunction... - by [J]ulian - 05.04.2012, 20:57
Respuesta: [Ayuda] CallRemoteFunction... - by OTACON - 07.04.2012, 05:28
Respuesta: [Ayuda] CallRemoteFunction... - by [J]ulian - 07.04.2012, 12:57

Forum Jump:


Users browsing this thread: 1 Guest(s)