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

WH-Reaper

Members
  • Posts

    34
  • Joined

  • Last visited

Converted

  • Gender
    Male
  • Personal Text
    I am new!

WH-Reaper's Achievements

Tree Puncher

Tree Puncher (2/8)

-1

Reputation

  1. Hello and thanks for your guide! Okay, I fixed all problems thanks to TheGreyGhost's examples, thank you a lot But I have one question - is it possible to render block in hand in the same way as block placed down, when it is set to render with specialRenderer? I.e. if I create new model and assign it to block via TileEntityRenderer, can I make it so the model is rendered when in hand, too?
  2. I had the same problem with 1.7.10. CleanCache fixed the issue. But then I updated to 1.8 and the issue was back. I tried cleanCache several times, but no luck. I hope someone here knows what went wrong, as I'm not able to build any mod for 1.8 right now. EDIT: Okay, I managed to get it built by running cleanCache command and then build command (no SetupDecompWorkspace in between). I wish there was better solution, though.
  3. Hello, I would like to ask if it is possible to access info stored in packets which are sent each time player moves from client. I.e. can I create event handler which is fired when client recieves packet which holds info about coordinates of other players? If so, what event should I look for? I took a look at list of forge events, but with no success. Thanks in advance
  4. There are methods in IInventory in Forge 10.12.0.1024 int getSizeInventory(); ItemStack getStackInSlot(int var1); ItemStack decrStackSize(int var1, int var2); ItemStack getStackInSlotOnClosing(int var1); void setInventorySlotContents(int var1, ItemStack var2); String getInventoryName(); boolean hasCustomInventoryName(); int getInventoryStackLimit(); void markDirty(); boolean isUseableByPlayer(EntityPlayer var1); void openInventory(); void closeInventory(); boolean isItemValidForSlot(int var1, ItemStack var2); And from what I have understand, markDirty does something different. Maybe it got back in newest (1025) update? I haven't had time to update yet.
  5. Thanks for the tips for the events. I still have problems with my lang file, though. This is my lang file: tile.CocoaLeaves.name=Cocoa Leaves tile.CocoaWood.name=Cocoa Wood tile.CocoaSapling.name=Cocoa Sapling tile.Coffee.name=Coffee Plant item.Mug.name=Mug item.MugMilk.name=Milk item.MugCocoa.name=Cocoa item.MugWater.name=Water item.MugCoffee.name=Coffee item.CoffeeSeeds.name=Coffee Seeds item.RoastedCoffeeSeeds.name=Roasted Coffee Seeds And here is part of my preInit method mug = new ItemMug().setUnlocalizedName("Mug").setCreativeTab(CreativeTabs.tabMisc); mugMilk = new ItemMugMilk().setUnlocalizedName("MugMilk").setCreativeTab(CreativeTabs.tabFood); Still, "item.Mug.name" appears in game instead of "Mug"
  6. Thanks! Works fine now Btw. is there a list (or way to tell) which event is registered in which bus? I would specifically need events that were in connection handler. Also, any help to the lang file, please?
  7. No, it is removed. There is no deobfuscated method in IInventory and no other method that could replace it.
  8. Hello, I used method onInventoryChanged() from IInventory in 1.6.4. Unfortunatelly, this method was removed in 1.7.2. Any idea what to use instead? I used the method to send packet about update, so the tileEntity updates on clients without activating the block.
  9. Oh sorry, I mistakenly posted the declaration of Crafting handler twice, instead of the code in preInit. Anyway, main post corrected. So the code in preInit is this: MinecraftForge.EVENT_BUS.register(craftHandler);
  10. Hello, I'm having problems with two things in Forge 1.7.2. First, the usual way to add names was completely scrapped, so we are forced to use the lang file. I created my lang file according to this tutorial http://www.minecraftforge.net/wiki/Localizing And pasted it to src/main/resources/assets/mymodid/lang/en_US.lang but I still cannot see the names (textures in src/main/resources/assets/mymodid/textures work fine though). Any advice where should it be located or where might be the problem? The coding of the file is set to UTF-8. Second, I used custom CraftingHandler for adding achievement when player crafted certain item. This was scrapped too, insted we should use Forge event bus. Now I have instance of my crafting handler private static CraftingHandler craftHandler = new CraftingHandler(); and in preInit method, I have MinecraftForge.EVENT_BUS.register(craftHandler); and here is the crafting handler class public class CraftingHandler { /** * Adds Coffee achievement after crafting mug of coffee */ @SubscribeEvent public void onCrafting(ItemCraftedEvent event) { System.out.println("event launched"); if (event.crafting.getItem() == CocoaCraft.mugCoffee) { event.player.addStat(CocoaCraft.coffeeAchievement, 1); } } } Yet I don't get the achievement, nor see "event launched" in console. Any help would be appreciated
  11. Well, the problem is, as I mentioned I HAVE them installed and path variable set. If I wouldn't, typing javac in command line (and not being in java folder) wouldn't launch the java exe
  12. Hello, I run into problem with installation of Forge using gradlew.bat. I always get recompForge error, and as suggestion that I should check if I have JDK installed and added to environment path. I have JDK installed and added to environment path correctly(launching java via command line works fine). I tried it several times, cleaned the cache, refreshed dependencies, but nothing helps. I even tried to change the path variable to point to 32bit Java instead of 64bit, but with the same result. Here is error output, as obtained after using this command: gradlew.bat setupDecompWorkspace --refresh-dependencies 2> out.txt Thanks in advance for any help
×
×
  • Create New...

Important Information

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