22.12.2017, 06:44
Good day!
I'm using RedRex Freeroam Build 2, and there's a VIP System their I guess. My question is where are those VIP Commands for it's VIP System or even advantages of a VIP ?
Also, how to save it's stats ? Because everytime I spawn, my money returns to $0
Thank you for fast reply
I'm using RedRex Freeroam Build 2, and there's a VIP System their I guess. My question is where are those VIP Commands for it's VIP System or even advantages of a VIP ?
Код:
CMD:setvip(playerid, params[]) { //check if the player is a admin LevelCheck(playerid, 5); new target, level; if(sscanf(params, "ui", target, level)) return SendClientMessage(playerid, COLOR_THISTLE, "USAGE: /setvip [player] [level]"); if(! IsPlayerConnected(target)) return SendClientMessage(playerid, COLOR_FIREBRICK, "ERROR: The specified player is not conected."); if(GetPlayerGAdminLevel(playerid) < GetPlayerGAdminLevel(target)) return SendClientMessage(playerid, COLOR_FIREBRICK, "ERROR: You cannot use this command on higher level admin."); if(level < 0 || level > MAX_VIP_LEVELS) return SendClientMessage(playerid, COLOR_FIREBRICK, "ERROR: Invalid level, mus be b/w 0-"#MAX_VIP_LEVELS"."); if(level == GetPlayerGVipLevel(target)) return SendClientMessage(playerid, COLOR_FIREBRICK, "ERROR: Player is already of that level."); new string[144]; if(GetPlayerGVipLevel(playerid) < level) { GameTextForPlayer(target, "~g~~h~~h~~h~Premium", 5000, 1); format(string, sizeof(string), "You have been given VIP level %i by %s[%i], Congratulation.", level, ReturnPlayerName(playerid), playerid); SendClientMessage(target, COLOR_DODGER_BLUE, string); format(string, sizeof(string), "You have given %s[%i] VIP level of %i.", ReturnPlayerName(target), target, level); SendClientMessage(playerid, COLOR_DODGER_BLUE, string); } else if(GetPlayerGAdminLevel(playerid) > level) { GameTextForPlayer(target, "~r~~h~~h~~h~Demoted", 5000, 1); format(string, sizeof(string), "Your VIP level havs been taken and reseted to level %i by %s[%i], Sorry.", level, ReturnPlayerName(playerid), playerid); SendClientMessage(target, COLOR_DODGER_BLUE, string); format(string, sizeof(string), "You have taken %s[%i]'s VIP level and reseted it to level %i.", ReturnPlayerName(target), target, level); SendClientMessage(playerid, COLOR_DODGER_BLUE, string); } PlayerPlaySound(target, 1057, 0.0, 0.0, 0.0); PlayerPlaySound(playerid, 1057, 0.0, 0.0, 0.0); new userid = BUD::GetNameUID(ReturnPlayerName(playerid)); BUD::SetIntEntry(userid, "vip", level); gUser[target][u_vip] = level; return 1; }
Thank you for fast reply