Everything posted by Draco18s
-
[1.12.2] [SOLVED] Is it okay to Subscribe to same event twice?
It'll work just fine.
-
Player's EntityData in LivingHurt and LivingUpdate events return different values?
My mistake.
-
Crash on constructor. Null Pointer on validateBlockstate
You can't set the default state to the default state: there is no default state yet. You want getBaseState()
-
Player's EntityData in LivingHurt and LivingUpdate events return different values?
Use Capabilities. And EntityData was never intended for mods to store their own data in anyway.
- [1.12.2] [SOLVED] A* JUnit Tests + Performance improvements
-
[1.12] Replace Vanilla recipes?
Did you mark your event with the correct annotation?
-
[1.11] Adding a potion effect to a player
Look for other uses of the method. Right click -> References -> Find in Workspace
-
[1.12.2] Arrays of TextComponents
The List Separator is always a comma, with the exception of listing numbers when the local's decimal separator is a comma, in which case, use a semicolon. https://stackoverflow.com/a/14925131/1663383 Note that you can translate this just fine with the lang files by having something like: list_separator=, And just doing a translate on that key when you need to combine things.
-
Smelting
https://github.com/leosavi25/Modding/blob/master/src/main/java/com/leosavi25/mod/FactoryCraft.java#L32-L33 ADD SMELTING FOR MY ITEMS. CREATE MY ITEMS. THIS IS DEFINITELY THE RIGHT ORDER.
-
Smelting
Oh it definitely is. Especially when it changes because "I forgot to call Blocks.Init()" and we have no idea what those snippets even look like now.
-
Smelting
"Doctor, it hurts. What's wrong with me?" Please describe the actual problem: what is the error you are getting, what is it that is not happening. Use your words. We aren't telepathic.
- Smelting
-
Vertex & OBJ [SOLVED]
Go into your 1.8 workspace, find addVertexWithUV where you are using it. Then
-
[1.12.2] Arrays of TextComponents
I think they mean if they wanted to list out all of the biomes at a block position. For most places, that will be 1. Along biome borders, that would be 2. Where two biomes meet up with a third, there would be 3. Conceivably there might even be 4. So you'd need to translate the "Biomes at this location: ..." text along with translating the biome's names, along with having list grammar ("A" "A and B" "A, B, and C").
-
[1.12.2] Add custom item to existing entity drop list?
You can, but you should use loot tables instead.
-
[1.12] [SOLVED] Custom Block has invisible bottom
False. I have a block that is Material.WOOD and it works just fine.
-
Vertex & OBJ [SOLVED]
Right click -> References -> Find in workspace
-
Vertex & OBJ [SOLVED]
Find a place the method was used in vanilla code. Locate that same place in 1.8.9 Figure it out yourself.
-
GuiIngameForge.renderFood = false not working
world#getWorldTime world#getTotalWorldTime And one other I can't remember the name of at the moment. One tells you the game's "date" (non-resetting value that increments by 1 tick per tick and is modified by the /time command) the other gets you the curernt "time" (midnight to midnight) and another gets you how long the world has existed (1 tick per tick, does not get modified by sleeping or /time).
-
World Changes Not Saving
You're wrong.
-
[1.12.2] Add custom item to existing entity drop list?
With difficulty. Here's how I modify the loot tables: https://github.com/Draco18s/ReasonableRealism/blob/1.12.1/src/main/java/com/draco18s/farming/FarmingEventHandler.java#L362 Note that this makes calls out to a library function, the important one is probably this one: https://github.com/Draco18s/ReasonableRealism/blob/1.12.1/src/main/java/com/draco18s/hardlib/util/LootUtils.java#L87
-
World Changes Not Saving
No, priority is what order event handlers (mod code) are executed. Without specifying (or specifying the same priority as another mod) means they go in the same order that the mods were loaded. Phase is whether the event is fired before the vanilla code executes or after the vanilla code executes.
-
World Changes Not Saving
Doing that requires packets. But you should not need packets for this. There are already events for the player that run server side.
-
GuiIngameForge.renderFood = false not working
Yes, it runs every frame, not every tick. Rendering must always happen every frame.
-
Smelting
That is not what D7 said. Do not create your items in a static initializer. He said nothing about having static fields. He said static initializer.
IPS spam blocked by CleanTalk.