/help command for player
#4

Quote:
Originally Posted by detter
Посмотреть сообщение
This is onley if you are using sscanaf and zcmd...

PHP код:
CMD:help(playerid ,params[])
{
    new 
msg[128] ,pname[MAX_PLAYER_NAME];
   
GetPlayerName(playeridpnamesizeof(pname));
    if (!
sscanf(params ,"s[128]" ,msg )
    {
        if(
IsPlayerConnected(playerid))
        {
            
format(msg ,sizeof(msg) ,"[HELP] %s [ID:%i]: %s" ,pname ,playerid ,msg);
            
SendClinetMessage(playerid ,COLOR ,"You have sent your message to the admins!");
            
// HERE you can throw in your custom admin check func. or you can just stick with this
            
for(new 0MAX_PLAYERS i++)
            {
                
// change your variable name if its diffrent
                 
if(playerInfo[i][admin] >= 1)
                 {
                      
SendClientMessage(,COLOR ,msg);
                 }
            }
        }
        else return 
SCM(playerid ,COLOR ,"You must login!");
    }
    else return 
SCM(playerid ,COLOR ,"USAGE: /help [text]");
    return 
1;

Thanks for your reply. But

OMG! I have tons of warning like Total War: Shogun!

My gamemode is using zcmd and sscanf. And I think I need to add every variables and other stuff (I forgot) My problem is that I'm using Luxadmin that it not compatible with zcmd and sscanf, I can only use dcmd for that.. What should I do?
Reply


Messages In This Thread
/help command for player - by kbalor - 26.08.2012, 15:57
Re: /help command for player - by detter - 26.08.2012, 16:12
Re: /help command for player - by Jarnu - 26.08.2012, 16:18
Re: /help command for player - by kbalor - 26.08.2012, 16:51
Re: /help command for player - by kbalor - 26.08.2012, 16:59

Forum Jump:


Users browsing this thread: 1 Guest(s)