Jump to content

FirstOrderKylo

Members
  • Posts

    4
  • Joined

  • Last visited

Converted

  • Gender
    Male
  • URL
    http://tierxgaming.net/
  • Location
    Starkiller Base
  • Personal Text
    Hello!

FirstOrderKylo's Achievements

Tree Puncher

Tree Puncher (2/8)

0

Reputation

  1. Hello, So in short, I'm trying to animate a model in one of 2 ways, way 1 is preferred but if not possible, 2 would be just as good. Currently I have an item of a drill, it has a model and texture and all that wonderful stuff, however when I right click with the item, I'd like the drill bit at the end to start rotating (like it's powered up) if this is not possible then I'd be more than happy to accept it always look 'powered on' but the right click version is proffered.
  2. I got it to work. getBlockInSlot is used in this bit of code (composition is a string called in another class to write on the gui): if (te.getBlockInSlot(0) == Blocks.nether_brick) Composition = "it worked"; for anyone who comes along later, this is the code bit I used in replacement of: if (te.getBlockInSlot(0) == Blocks.nether_brick) Composition = "it worked"; new, working code: if (Block.getBlockFromItem(te.getStackInSlot(0).getItem())== Blocks.bedrock) Composition = "it worked";
  3. Hello, so I'm trying to create a method in my TileEntity class to get the block in a specific slot so it can be used like "getBlockInSlot(index)" Currently I have: private ItemStack[] inventory; private Block[] inventory2; @Override public ItemStack getStackInSlot(int index) { if (index < 0 || index >= this.getSizeInventory()) return null; return this.inventory[index]; } public Block getBlockInSlot(int index) { if (index < 0 || index >= this.getSizeInventory()) return null; return this.inventory2[index]; } which is a copy of the getStackInSlot method with a different return type and location to return to and that one works, but getBlockInSlot gives this crash report when an item goes into the TileEntitySlot specified with getBlockInSlot() [p]Report:[/p]
×
×
  • Create New...

Important Information

By using this site, you agree to our Terms of Use.