Everything posted by Draco18s
-
[SOLVED][1.12.2]Lose durability on my axe when making wood planks
Touche.
-
[SOLVED][1.12.2]Lose durability on my axe when making wood planks
if(item instanceof ItemAxe) { //now it works for mod axes too
-
[SOLVED] [1.12] NoSuchMethodError for getSlotFor
>> No code posted > Help not available
-
Help with registering item renders
Oh jesus fucking christ on a crutch. Use item.getRegistryName() instead of all of this garbage Also, you have a NullPointerException, which none of the above suggestions will fix. Your problem is here: @EventHandler public void preInit(FMLPreInitializationEvent event) { Utils.getLogger().info("Pre Initialization"); Utils.getLogger().info("Loading Proxies..."); proxy.registerRenders(); } @EventHandler public void Init(FMLInitializationEvent event) { ModItems.init(); ModItems.register(); Utils.getLogger().info("Initialization"); } You're registering your renderers before you ever create your item. Fuck. How are you people this incompetent? Of course you got a NPE, this wasn't even a hard problem to figure out. All you had to do was look at the order in which you were doing things and realize that they were WRONG. On top of that, you should be using the Registry events anyway!
-
Is the entity a horse?
logger.info("Is debug enabled? " + mc.gameSettings.showDebugInfo);
-
Is the entity a horse?
Does it work?
-
Help with registering item renders
1) What is the error? 2) What version of Minecraft are you modding for? 3) Where do you call registerRenders()?
-
[SOLVED][1.12.2] How to remove vanilla recipes?
Yes
-
[SOLVED][1.12.2] How to remove vanilla recipes?
Instead of adding a dummy recipe, add a new recipe.
-
[1.12.2]NBT Packet
Oh gosh, leaving an exercise to the reader about writing in the length of the string first! The horror!
-
[1.12.2]NBT Packet
The ByteBufUtils are awesome, and definitely a better choice. But in terms of "here's what's in front of me, how can I solve this problem?" I could do it.
-
[1.12.2]NBT Packet
Knowing two things: 1) How to use my IDE 2) That strings are characters and characters are bytes I worked this out on my own: buf.writeBytes(("this is a string").getBytes());
-
1.12.2 adventuring time advancement
You'd have to track them yourself. My suggestion would be to create a new advancement that uses the same system as Adventuring Time, but which has ALL the biomes in it.
-
code problem in 1.12
Your original code had you trying to register an item named logo. In this code you're trying to register a block named Block1 (which doesn't exist).
-
Texture wont display 1.11
(I'll point out that Minecraft practices were better than what I was doing before because I was never taught any sort of organizational schema...)
-
TileEntity with inventory and GUI
Actually, its the items that are 16 pixels. An actual slot graphic is 18x18. The 1 pixel border that gives the slot some "depth" extends beyond the 16x16 bounds. But otherwise you're correct.
-
How to create a new world?
Here's a hint. You're working in a language that has access to the file system.
-
net.minecraftforge:Mercurius:1.12
http://files.minecraftforge.net/ is not currently responding
-
Forums Migration/Upgrade
- code problem in 1.12
You're doing everything wrong. You need to use the Registry events. http://mcforge.readthedocs.io/en/latest/concepts/registries/#registering-things- [SOLVED] [1.11.2] Plant Crop on Custom Modded Block
Define "not working."- Null pointer exception during setting Model Resource Location?
https://github.com/linkisheroic/minestuckarsenal/blob/master/src/main/java/com/natura/minestuckarsenal/item/MinestuckArsenalItems.java#L99-L100 You've made your registration event handler static. Because you are creating a new instance and registering that instance with the event bus, your method needs to be non-static.- [SOLVED][1.11.2] Ore generation per biome
Wrong. It should be Biome. Your advice is like saying "when you get a block, you want the variable to be Blocks." Biome is the object, Biomes is where the game holds a reference to each biome.- [1.12.2] Mod Loading options
Don't do that. Register the block, if an ore exists during init, then make it show up in the world, be craftable, whatever. But always always register all blocks and items.- [1.12] Blockstates for versions of item in inventory?
My ItemRawOre is not a block, it is an item. This is so my ores can be subject to Fortune enchantments (among others). 4 is Incorrect. I have one blockstate file. https://github.com/Draco18s/ReasonableRealism/blob/1.12.1/src/main/resources/assets/harderores/blockstates/orechunks.json Each ore block also has a blockstate file, but the ore items themselves only have 1. The two do not have a relationship with each other. You don't. Here is my block json: https://github.com/Draco18s/ReasonableRealism/blob/1.12.1/src/main/resources/assets/harderores/blockstates/ore_hardiron.json Here's where I register it: https://github.com/Draco18s/ReasonableRealism/blob/1.12.1/src/main/java/com/draco18s/ores/OresBase.java#L181 The easy registry is a mess because of the way I want to handle things in my main mod class (as a single function call). But here's a break down of what it does: 1) register and item the block with the game 2) get all valid states for the block and register an item model: https://github.com/Draco18s/ReasonableRealism/blob/1.11.2/src/main/java/com/draco18s/hardlib/client/ClientEasyRegistry.java#L46-L55 3) That involves calling ModelLoader.setCustomModelResourceLocation for each variant from the block's state: https://github.com/Draco18s/ReasonableRealism/blob/1.11.2/src/main/java/com/draco18s/hardlib/client/ClientEasyRegistry.java#L162-L169 My 1.12 code makes a hash of that process because it has to cache the object to register and then wait for the ModelRegistryEvent, but it still does just that: https://github.com/Draco18s/ReasonableRealism/blob/1.12.1/src/main/java/com/draco18s/hardlib/client/ClientEasyRegistry.java#L197-L199 - code problem in 1.12
IPS spam blocked by CleanTalk.
Important Information
By using this site, you agree to our Terms of Use.