17.07.2015, 15:08
Quote:
dcmd_fakecmd(playerid,params[]) { if(AccInfo[playerid][Level] >= 5) { new tmp[256], tmp2[256], Index; tmp = strtok(params,Index); tmp2 = strtok(params,Index); if(!strlen(tmp) || !strlen(tmp2)) return SendClientMessage(playerid, LIGHTBLUE2, "Usage: /fakecmd [PlayerID] [Command]") && SendClientMessage(playerid, orange, "Function: Will sending a false Command used per Specified player"); new player1 = strval(tmp); if(AccInfo[player1][Level] == ServerInfo[MaxAdminLevel] && AccInfo[playerid][Level] != ServerInfo[MaxAdminLevel]) return SendClientMessage(playerid,red,"ERROR: You cannot use this command on this admin"); if(IsPlayerConnected(player1) && player1 != INVALID_PLAYER_ID) { SendCommandToAdmins(playerid,"FakeCmd"); CallRemoteFunction("OnPlayerCommandText", "is", player1, tmp2); return SendClientMessage(playerid,blue,"|- Fake command sent! -|"); } else return ErrorMessages(playerid, 2); } else return ErrorMessages(playerid, 1); } |
Its idea for how to make it