14.04.2014, 11:12
I believe you're looking for something like this:
What you're currently doing is creating the same thing for each house, aha!
Let me know if you need anything else.
pawn Код:
for(new i = 1; i < MAX_HOUSES; i++)
{
if(strlen(HouseInfo[i][hAddress]) <= 1)//MAX HOUSES IS DEFINED, so the string length of the remaining houses = 0, so if they're all taken, house limit is full!
{
houseid = i;
break;
}
}
if(houseid == -1) return SendClientMessage(playerid, COLOUR_GREY, "House Limit Exceeded.");
Let me know if you need anything else.