Well, I'm setting up an Inventory on Maloria, and there's obviously an area there with the slots for the item icons. It's a 4x6 grid, basically, and there' up/down page buttons. So I have this function to show the items for the page:
PHP Code:
function loadPage() {
this.itemssize = clientr.items.size()-((this.page-1)*24);
temp.base = {218, 53};
temp.i = 1;
with (Inv) {
for (h=0; h<6; h++) {
for (w=0; w<4; w++) {
with (new GuiShowImgCtrl("ItemIcon_" @ temp.i)) {
resize(temp.base[0]+(32*w),temp.base[1]+(32*h),32,32);
image = "block.png";
Inv.addControl(this);
}
player.chat = h;
if (temp.i <= this.itemssize)
temp.i++;
else
break;
}
}
}
}
But, for whatever reason, when it gets the point where it's setting player.chat to h, h equals 5...that means it seems to be waiting until the end of the first for loop before going on the the next for loop. o.0
Help. :<