PHP Code:
function onTimeout() {
for (i = 0; i <= this.itemid; i++) {
temp.itemx = InventoryControl.x + ("InventoryItem_" @ i).x;
temp.itemy = InventoryControl.y + ("InventoryItem_" @ i).y;
if (mousescreenx in |temp.itemx, temp.itemx + 32| && mousescreeny in |temp.itemy, temp.itemy + 32|) {
new GuiTextCtrl("ItemText") {
profile = GuiBlueTextProfile;
/*useownprofile = true;
profile.fontcolor = {255, 255, 255};
profile.fillcolor = {0, 0, 0};
profile.opaque = true;*/
x = mousescreenx;
y = mousescreeny;
height = 10;
text = "Item";
}
}
else {
if (ItemText != NULL) ItemText.destroy();
}
}
setTimer(0.05);
}
This is a strange problem. Instead of the mouse pointer being detected over the items, it's being detected in the top right of the GUI Control. However, when using echo()s and what not, it detects where the mouse is just fine.
Very strange indeed.