Aeodyn
Last Activity:
Jul 3, 2012
Joined:
Apr 10, 2011
Messages:
37
Likes Received:
0
Trophy Points:
0
Gender:
Male

Share This Page

Aeodyn

Member, Male

Working on a mod to allow for "Golems", "mobs" made out of blocks. May 29, 2011

Aeodyn was last seen:
Jul 3, 2012
    1. OblivionBR
      OblivionBR
      Hi there Aeodyn,
      This message is about your BlockDispenser Mod
      I dont know if was your intention to pack the source in your .jar file, but I couldnt resist looking at it.
      While using the mod Ive found the stack bug (the one the stack disapear):
      BlockDispenserBlockListener.java (line 137)
      dispenser.getInventory().removeItem(item);
      There you remove all the stack instead of removing just 1 item.
      1. OblivionBR
        OblivionBR
        Solution follows:

        dispenser.getInventory().removeItem(item);
        ItemStack itemToAdd = item;
        if (item.getAmount()-1 >0){
        itemToAdd.setAmount(item.getAmount()-1);
        dispenser.getInventory().addItem(itemToAdd);}

        Ive tested it with some blocks and seens to be working. Of course, more testing should be done.
        Sorry again for modifing your code without authorization, Ive not published it, just wanted to help ;)
        Jan 12, 2012
    2. Aeodyn
      Aeodyn
      Working on a mod to allow for "Golems", "mobs" made out of blocks.
  • Loading...
  • Loading...
  • About

    Gender:
    Male