04.12.2013, 15:45
Hey guys, as the title says my /hnext is bugged, or it's not scripted how I want it.
If I place a house, which is not bought yet and do /hnext it still says the same as the previous one.
But when someone buys the house, it goes one further.
Is it possible to make when you place one, /hedit exterior (nexthouseid) to get at /hnext the next one?
here's my current code
If I place a house, which is not bought yet and do /hnext it still says the same as the previous one.
But when someone buys the house, it goes one further.
Is it possible to make when you place one, /hedit exterior (nexthouseid) to get at /hnext the next one?
here's my current code
Quote:
CMD:hnext(playerid, params[]) { if(PlayerInfo[playerid][pAdmin] >= 4 || PlayerInfo[playerid][pShopTech] == 1) { SendClientMessageEx(playerid, COLOR_RED, "* Listing next available house..."); for(new x;x<MAX_HOUSES;x++) { if(HouseInfo[x][hOwned] == 0) { new string[128]; format(string, sizeof(string), "%d is available to use.", x); SendClientMessageEx(playerid, COLOR_WHITE, string); break; } } } else { SendClientMessageEx(playerid, COLOR_GRAD2, "You are not authorized to use that command!"); return 1; } return 1; } |