stock IsPlayerOG
#1

Hi!

I need your help again! I want to create a stock!
That means, this kind of stock:

PHP код:
stock IsPlayerOG(playerid)
{
IsPlayerOG(playerid)

I know it's very incomplete! I already got an OG command:

PHP код:
CMD:og(playeridparams[])
{
    new
        
glevel[32], id;
    if(
PlayerInfo[playerid][pAdmin] >= 5)
    {
        if(
sscanf(params"us[32]"idglevel)) return SendClientMessage(playeridCOLOR_RED"USAGE: /og [id] [gangster level]");
        if(
id == INVALID_PLAYER_ID) return SendClientMessage(playeridCOLOR_RED"System: Invalid ID");
        new
            
str[128];
        
format(str128"System: %s [ID %d] has set %s [ID %d] gangsterlevel to %s."PlayerName(playerid), playeridPlayerName(id), idglevel);
        
SendClientMessage(playeridCOLOR_YELLOWstr);
        if(
INI_Open(getINI(playerid)))
        {
            
INI_WriteString("GangsterLvl"glevel);
            new
                
pts INI_ReadInt("RespectPts");
            if(
pts <= 90)
            {
                
INI_WriteInt("RespectPts"pts 10);
            }
            else
            {
                
INI_WriteInt("RespectPts"100);
            }
            
INI_Save();
            
INI_Close();
        }
        return 
1;
    }
    else return 
SendClientMessage(playerid,COLOR_RED,"  You are not allowed to use this command!");

So, any ideas how to do this kind of stock?
Reply


Messages In This Thread
stock IsPlayerOG - by samtey - 05.09.2011, 10:51
Re: stock IsPlayerOG - by =WoR=Varth - 05.09.2011, 10:54
AW: stock IsPlayerOG - by samtey - 05.09.2011, 10:56
Re: stock IsPlayerOG - by PrawkC - 05.09.2011, 11:01
Re: AW: stock IsPlayerOG - by =WoR=Varth - 05.09.2011, 11:01
AW: stock IsPlayerOG - by samtey - 05.09.2011, 11:07
Re: AW: stock IsPlayerOG - by =WoR=Varth - 05.09.2011, 11:12
Re: stock IsPlayerOG - by =WoR=Varth - 05.09.2011, 11:36
Re: stock IsPlayerOG - by Basicz - 05.09.2011, 13:21
Re: stock IsPlayerOG - by Kingunit - 05.09.2011, 13:35

Forum Jump:


Users browsing this thread: 1 Guest(s)