Need Help With Admin Cmds -
Salsa - 28.09.2011
How i make this command of admins only?
Код:
if(strcmp(cmd, "/adminjetpack", true) == 0)
{
new Float:X, Float:Y, Float:Z;
GetPlayerPos(playerid, X, Y, Z);
CreatePickup(370, 3, X, Y, Z);
SendClientMessage(playerid, COLOR_GREEN, "Jet Pack Created.");
return 1;
}
Re : Need Help With Admin Cmds -
Naruto_Emilio - 28.09.2011
pawn Код:
if(strcmp(cmd, "/adminjetpack", true) == 0)
{
if(IsPlayerAdmin(playerid))
{
new Float:X, Float:Y, Float:Z;
GetPlayerPos(playerid, X, Y, Z);
CreatePickup(370, 3, X, Y, Z);
SendClientMessage(playerid, COLOR_GREEN, "Jet Pack Created.");
}
return 1;
}
Re: Need Help With Admin Cmds -
FireCat - 28.09.2011
pawn Код:
if(strcmp(cmd, "/adminjetpack", true) == 0)
{
if(!IsPlayerAdmin(playerid)) return 0;
new Float:X, Float:Y, Float:Z;
GetPlayerPos(playerid, X, Y, Z);
CreatePickup(370, 3, X, Y, Z);
SendClientMessage(playerid, COLOR_GREEN, "Jet Pack Created.");
return 1;
}
@ Naruto:
If the player is admin return the message?
Check the signs! (:
Re: Need Help With Admin Cmds -
Salsa - 28.09.2011
FireCat Thats Working But Only Rcon Admin Can get /AdminJetpack not anyadmin can get it can u do it for 3 level admin
Re : Need Help With Admin Cmds -
Naruto_Emilio - 28.09.2011
give us the pInfo your using.
Re: Need Help With Admin Cmds - [L3th4l] - 28.09.2011
How are you defining player's admin level?
Re: Need Help With Admin Cmds -
Kingunit - 28.09.2011
// Wrong thread.
Re : Re: Need Help With Admin Cmds -
Naruto_Emilio - 28.09.2011
Quote:
Originally Posted by Kingunit
pawn Код:
CMD:goto(playerid, params[]) { if(PlayerInfo[playerid][Adminlevel] < 1) return SendClientMessage(playerid, 0xFFFFFFFF,".:: You are not authorized to use this command ::."); // Own Vars new targetid, string[128]; if(sscanf(params, "u", targetid)) return SendClientMessage(playerid, 0xFFFFFFFF, "[PlayerID/PartOfName]"); if(!IsPlayerConnected(targetid)) return SendClientMessage(playerid, 0xFFFFFFFF, " Player not connected!"); else { new pName[24]; GetPlayerName(targetid,pName,128); format(string, sizeof(string), "[ADMIN] You succesfully teleported to [%d] %s.",targetid, pName); SendClientMessage(playerid, 0xFFFFFFFF,string); SetPlayerInterior(playerid,GetPlayerInterior(targetid)); new Float:TPX, Float:TPY, Float:TPZ; GetPlayerPos(targetid, TPX, TPY, TPZ); SetPlayerPos(playerid, TPX, TPY, TPZ+1); } return 1; }
|
Read the topic again please.
Re: Re : Re: Need Help With Admin Cmds -
Kingunit - 28.09.2011
Quote:
Originally Posted by Naruto_Emilio
Read the topic again please.
|
Yes? What's the problem.
// Sorry, posted the command in the wrong thread.
Re: Re : Re: Need Help With Admin Cmds -
FireCat - 28.09.2011
Quote:
Originally Posted by Kingunit
Yes? What's the problem.
// Sorry, posted the command in the wrong thread.
|
Jetpack not goto.