Jump to content
Search In
  • More options...
Find results that contain...
Find results in...


Forge Modder
  • Content Count

  • Joined

  • Last visited

Community Reputation

5 Neutral

About p455w0rd

  • Rank
    Stone Miner


  • Gender
  • URL
  • Personal Text

Recent Profile Visitors

The recent visitors block is disabled and is not being shown to other users.

  1. My shield extends the vanilla shield and I use this: @SubscribeEvent public void attackEvent(LivingAttackEvent e) { float damage = e.getAmount(); ItemStack activeItemStack; EntityPlayer player; if (!(e.getEntityLiving() instanceof EntityPlayer)) { return; } player = (EntityPlayer) e.getEntityLiving(); if (player.getActiveItemStack() == null) { return; } activeItemStack = player.getActiveItemStack(); if (damage > 0.0F && activeItemStack != null && activeItemStack.getItem() instanceof ItemShield) { int i = 1 + MathHelper.floor_float(damage); activeItemS
  2. Updated GuiCompressor to have actual dimensions set (xSize is 176): https://github.com/p455w0rd/p455w0rds1.9Things/blob/master/src/java/p455w0rd/p455w0rdsthings/client/gui/GuiCompressor.java Also all other code related to compressor machine is now using IItemHandler: ContainerCompressor: https://github.com/p455w0rd/p455w0rds1.9Things/blob/master/src/java/p455w0rd/p455w0rdsthings/container/ContainerCompressor.java TileEntityCompressor: https://github.com/p455w0rd/p455w0rds1.9Things/blob/master/src/java/p455w0rd/p455w0rdsthings/blocks/tileentities/TileEntityCompressor.java I
  3. it depends on how you're making your model..if you're using a JSON model (ala Crayfish's Model Creator or the like), then yes
  4. We're dissuaded from teaching basic Java things here, but you need to reference an item in the list..you're trying to use the entire list..so if you're wanting the first item returned, you'd need to use get(), so: ItemStack copper = OreDictionary.getOres("ingotCopper").get(0); but you'd really need to encase this whole functionality with a check for if there is even anything in the list of ingotCopper
  5. you'd need to load the list of items registered as ingotCopper and use one of the results.. So for copper ingots, to get the list you'd use OreDictionary.getOres("ingotCopper") ..this returns an ArrayList you can go through and set preference or w/e or just return first result..
  6. While I had forgotten to do that, it isn't the problem. I tried using the default texture/sizes from GuiContainer and I tried using custom xSize/ySize (set in constructor) to no avail.
  7. Okay, so I converted to IItemHandler (via Choonster's Examples)..same thing persists. (And I figured as much would be the case). So I'm stumped still. I've tried all sorts of combinations of ordering the slots in the container with the only positive result being that when I add hotbar slots, followed by the 27 player inv slots, followed by the 2 custom slots, the player inv slots function correctly..still can't pick up hotbar items and when I click either of the 2 custom slots, it acts as if I'm clicking slots 0/1 on the hotbar. I am able to successfully insert items via a hopper. Updates
  8. Well, my TE implements ISidedInventory which extends IInventory which is a separate inventory from InventoryPlayer, no? Are these not two different inventories?
  9. In my Wireless Crafting Terminal mod, as well as my /dank/null item and BedrockMiner's tutorial on the subject @ http://bedrockminer.jimdo.com/modding-tutorials/advanced-modding/gui-container/ , there are multiple slots assigned with same ID's and they work perfectly. (slots 0-8 in BRM's tutorial are assigned IDs 0-8..slots 36-44 are also assigned ID's of 0-...I'm lost...
  10. check out https://github.com/p455w0rd/p455w0rds1.9Things/blob/master/src/java/p455w0rd/p455w0rdsthings/client/render/TESRCompressor.java#L145-L182 ..it doesn't "bob", but that would be simple enough to implement.
  11. I wish this were true, but those id's are setting the ID of the referenced inventory (TileEntity in this case), where the player inventory is a separate inventory with it's own set of IDs. The slot number of the container is set as slots are added (via the inventorySlots list in net.minecraft.inventory.Container).
  12. gif of what is happening: I had this working in 1.9 and somewhere along the way after updating to 1.9.4 it started doing this stuff. I'm assuming this is due to my lack of knowledge of TileEntities as I have no issues when I do this using a normal IInventory. I have been racking my brain for over a week on this. I don't know where I'm going wrong. ContainerCompressor public class ContainerCompressor extends Container { public TileEntityCompressor tileEntity; private final InventoryPlayer inventoryPlayer; public ContainerCompressor(InventoryPlayer inventoryPlayer, TileEn
  13. I'm trying to create a wrench function for my blocks. I'm trying to retrieve the tile's NBT via getTileData(). getTileData() always returns an empty tag. The tile retains the NBT data so long as the block is placed. I can verify this because the block is a solar panel that generates RF. It retains the RF data through logging out and restarting the client. I have implemented packet handling to send the server data to the client as well. Following are the relevant methods: BlockSolarPanel#onBlockActivated public boolean onBlockActivated(World worldIn, BlockPos pos, IBlockState state, E
  14. look into Block#getSubBlocks & blockstates/metadata, register using GameRegistry#register ..also Choonster's TestMod 3 is an amazing resource for learning 1.9+ stuff (I believe he has updated to 1.9.4 now)
  15. There is still a console log which could only help. Post (within BBCode CODE tags) each of the relevant class codes. (Main mod file, proxy classes, item class, etc)
  • Create New...

Important Information

By using this site, you agree to our Privacy Policy.