20.04.2014, 12:01
its my idea , use like this
but you must have a database for your user ranks
example dini or y_ini to get rank value and to show it
and this setrank cmd for vip.
you must work hard with your data bases ...
if i knew what is your plan and whatare you using , i would tell you a better way ...
but you must have a database for your user ranks
example dini or y_ini to get rank value and to show it
Код:
#define COLOR_WHITE 0xFFFFFFFF public OnPlayerText(playerid, text[]) { new rank,Player[64],pName[MAX_PLAYER_NAME],string[128]; GetPlayerName(playerid, pName, sizeof(pName)); // This get's the player name with the name length format(Player, sizeof(Player),"/Accounts/%s.txt",pName); // Formatting file format(string,sizeof(string),"%s <%d>(%d): %s",pName,rank,playerid,text); printf(string); SendClientMessageToAll(COLOR_WHITE,string); }
you must work hard with your data bases ...
Код:
CMD:setrank(playerid,params[]) { if(playerlevel[playerid]==1) //playerlevel[playerid] == 1 (is player vip) { new rnk; sscanf(params,"d",rnk); playerinfo[playerid][rank] = rnk; } return 1; }