Hi guys,
currently have a lovely inventory system working; however at the moment it generates the items name/number on each icon; i’d like to remove this but every time i do i end up not being able to compile and don’t fully understand what the issue is:
Code:
public void InventoryWindow(int id)
{
int cnt = 0;
for(int y = 0; y < Inventory_Rows; y++){
for(int x = 0; x < Inventory_Columns; x++){
if(cnt < Inventory._Inventory.Count)
{
GUI.Button(new Rect(10.5f + (x * Button_Width), 50 + (y * Button_Height), -2.5f + Button_Width, -2.5f + Button_Height), Inventory._Inventory[cnt].Name);
}
else
{
GUI.Label(new Rect(10.5f + (x * Button_Width), 50 + (y * Button_Height), -2.5f + Button_Width, -2.5f + Button_Height), (x + y * Inventory_Columns).ToString(), "Inventory Slot Empty"); // Inventory BOX SLOTS HERE
}
cnt++;
}
}
}
Help would be greatly appreciated.
Cheers.
David