Not a member of Pastebin yet?
Sign Up,
it unlocks many cool features!
- command(checkinactivehouses, playerid, params[])
- {
- new string[128], Day, Month, Year;
- if(sscanf(params, "ddd", Day, Month, Year))
- {
- if(Player[playerid][AdminLevel] >= 6)
- {
- SendClientMessage(playerid, WHITE, "SYNTAX: /checkinactivehouses [day] [month] [year]");
- }
- }
- else
- {
- if(Player[playerid][AdminLevel] >= 6)
- {
- SCM(playerid, COLOR_ORANGE, ".: Inactive Houses :.");
- new CheckDate;
- format(CheckDate, sizeof(CheckDate), "%02d/%02d/%d", Day, Month, Year);
- new FileName[128];
- for(new i = 0; i < MAX_HOUSES; i++)
- {
- format(FileName, sizeof(FileName), "Houses/House_%d.ini", i);
- if(fexist(FileName))
- {
- Houses[i][OwnerLastLogin] = dini_Int(FileName, "OwnerLastLogin");
- if(CheckDate < Houses[i][OwnerLastLogin])
- {
- format(string, sizeof(string), "House id: %d", i);
- SCM(playerid, SERVERCOLOR, string);
- }
- }
- }
- SCM(playerid, ADMINBLUE, "Use /asellproperty [id], to asell them, use /autoasell to sell them all.");
- }
- }
- return 1;
- }
Advertisement
Add Comment
Please, Sign In to add comment