20.07.2015, 16:22
http://pastebin.com/bfUMhDex
i have this plugin.
i give vip to player and after i restart server, vip don t save..
i have this plugin.
i give vip to player and after i restart server, vip don t save..
public OnPlayerConnect(playerid) { new string[200]; format(string, sizeof(string), " Welcome Back %s Your Vip Level is: %d", PlayerName(playerid), Vip[playerid] ); SendClientMessage(playerid ,COLOR_RED, string); tune[playerid] = 0; asked1[playerid] = 0; asked[playerid] = 0; ship[playerid] = 0; SendClientMessage(playerid,-1,"RPG.KRONDZ.COM"); INI_ParseFile(UserPath(playerid), "LoadUser_%s", .bExtra = true, .extra = playerid); new INI:File = INI_Open(UserPath(playerid)); INI_SetTag(File,"data"); INI_WriteInt(File,"VIP",0); INI_Close(File); return 1; }
public OnPlayerConnect(playerid) { new string[128]; format(string, sizeof(string), " Welcome Back %s Your Vip Level is: %d", PlayerName(playerid), Vip[playerid]); SendClientMessage(playerid ,COLOR_RED, string); tune[playerid] = 0; asked1[playerid] = 0; asked[playerid] = 0; ship[playerid] = 0; SendClientMessage(playerid,-1,"RPG.KRONDZ.COM"); if(!fexist(UserPath(playerid)) { new INI:File = INI_Open(UserPath(playerid)); INI_SetTag(File,"data"); INI_WriteInt(File, "VIP", 0); INI_Close(File); } else INI_ParseFile(UserPath(playerid), "LoadUser_%s", .bExtra = true, .extra = playerid); return 1; }
// along with all other variables; new vipchecker[MAX_PLAYERS]; public OnPlayerConnect(playerid) { vipchecker[playerid] = -1; vipchecker[playerid] = SetTimerEx("VipCheckMessage", 2000, false, "i", playerid); if(!fexist(UserPath(playerid)) { new INI:File = INI_Open(UserPath(playerid)); INI_SetTag(File,"data"); INI_WriteInt(File, "VIP", 0); INI_Close(File); } else INI_ParseFile(UserPath(playerid), "LoadUser_%s", .bExtra = true, .extra = playerid); return 1; } forward VipCheckMessge(playerid); public VipCheckMessage(playerid) { if(IsPlayerConnected(playerid) && Vip[playerid] > 0) { new string[90]; format(string, sizeof(string), " Welcome back, %s. Your V.I.P. level is: %d", PlayerName(playerid), Vip[playerid]); SendClientMessage(playerid ,COLOR_RED, string); } else return 1; return 1; }