Posted March 30, 201312 yr Hello. i have problems with detecting the stacksize. Everytime i start a world the game crashes (not internal server shut down) Here the source of the TileEntity https://github.com/Speiger/DynamicTools/blob/master/spmod_common/speiger/src/tinychest/common/tileentity/TileEntityAdvancedTinyChest.java
March 30, 201312 yr Author Something what is not a normal kind of error. Something like that: BlockID = 0 BlockID <= -1 And some errors about my OneSlotTinyChest (Advanced) And he links to the (my link i postet) public void updateEntity() { if(worldObj.isRemote) { for(int i = 0; i < getSizeInventory(); i++) { if(advTinyChest.stackSize >= this.getInventoryStackLimit()) { isFull = true; } else if(advTinyChest.stackSize < this.getInventoryStackLimit() && advTinyChest.stackSize == advTinyChest.getMaxStackSize()) { isFull = true; } else { isFull = false; } if(advTinyChest == null) { isEmpty = true; } else { isEmpty = false; } } } } Please look into my source
March 31, 201312 yr Something what is not a normal kind of error. Something like that: BlockID = 0 BlockID <= -1 And some errors about my OneSlotTinyChest (Advanced) And he links to the (my link i postet) public void updateEntity() { if(worldObj.isRemote) { for(int i = 0; i < getSizeInventory(); i++) { if(advTinyChest.stackSize >= this.getInventoryStackLimit()) { isFull = true; } else if(advTinyChest.stackSize < this.getInventoryStackLimit() && advTinyChest.stackSize == advTinyChest.getMaxStackSize()) { isFull = true; } else { isFull = false; } if(advTinyChest == null) { isEmpty = true; } else { isEmpty = false; } } } } Please look into my source I know how to read code but my brain doesn't compile java code to check what the error is, need the error log.
March 31, 201312 yr Author ok. But how can i detect the stacksize in a inventory? I mean is the stacksize greater than null or is the stacksize null or is the stacksize max? How can i detect that?
Join the conversation
You can post now and register later. If you have an account, sign in now to post with your account.
Note: Your post will require moderator approval before it will be visible.