05.09.2011, 10:51
Hi!
I need your help again! I want to create a stock!
That means, this kind of stock:
I know it's very incomplete! I already got an OG command:
So, any ideas how to do this kind of stock?
I need your help again! I want to create a stock!
That means, this kind of stock:
PHP код:
stock IsPlayerOG(playerid)
{
IsPlayerOG(playerid)
}
PHP код:
CMD:og(playerid, params[])
{
new
glevel[32], id;
if(PlayerInfo[playerid][pAdmin] >= 5)
{
if(sscanf(params, "us[32]", id, glevel)) return SendClientMessage(playerid, COLOR_RED, "USAGE: /og [id] [gangster level]");
if(id == INVALID_PLAYER_ID) return SendClientMessage(playerid, COLOR_RED, "System: Invalid ID");
new
str[128];
format(str, 128, "System: %s [ID %d] has set %s [ID %d] gangsterlevel to %s.", PlayerName(playerid), playerid, PlayerName(id), id, glevel);
SendClientMessage(playerid, COLOR_YELLOW, str);
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!");
}