-
Posts
16559 -
Joined
-
Last visited
-
Days Won
156
Everything posted by Draco18s
-
[1.16] Block texture resonds to sky light not block light
Draco18s replied to NovaMachina's topic in Modder Support
I wonder what combinedLight is. https://github.com/NovaMachina-Mods/ExNihiloSequentia/blob/1.16/src/main/java/novamachina/exnihilosequentia/client/render/SieveRender.java#L34 -
The error is caused by registering the event to the wrong bus. Change the bus, error goes away.
-
can someone help with server crashing
Draco18s replied to IRONDALEK's topic in Support & Bug Reports
Surprise, accessing the client thread from the server thread isn't possible. Bitch at the author of wonderfulenchantments. -
[1.16.5] Help with custom container (error when put a item in an slot)
Draco18s replied to Luis_ST's topic in Modder Support
A custom one. -
How can i rotate models around z axis in blockstates?
Draco18s replied to Drachenbauer's topic in Modder Support
The game does not recognize a Z axis for rotation because the game world does not distinguish between "north/south" and "east/west" as being unique for the purpose of rendering things (that is, models should be compass orientation agnostic). -
Having actually benchmarked this, not really. Scanning a whole chunk from 0 to 64 takes 600,000 nanos provided you're doing virtually nothing else (e.g. don't find a matching block). Adding a position to a list is going to be pretty small as well (my benchmarking involved more complicated stuff, which included setting block states, and even for a bunch of matching blocks I never exceeded 1,200,000 nanos for a single chunk). For a full 11x11 chunk area around the player and the full chunk height you're looking at 290ms +/- 15%. It's still not a great idea, but the actual time on checking blocks is tiny.
-
[1.16.5] Help with custom container (error when put a item in an slot)
Draco18s replied to Luis_ST's topic in Modder Support
Post your code. -
Minecraft keeps crashing with a few mods
Draco18s replied to Litice's topic in Support & Bug Reports
Bitch at the creator of this mod. -
https://lmgtfy.app/?q=java+tutorial+for+beginners&iie=1
-
How would you put nameplates on TileEntities? (1.16)
Draco18s replied to Caseofgames's topic in Modder Support
I'm hesitant to share this code, as it is fucking ancient (I wrote it for 1.6.4 and someone else updated it to 1.7; yeah it's that old), but still might be helpful. (The block had 1 inventory slot and it would render that item's name on the "front" of the block). https://github.com/Draco18s/Artifacts/blob/master/main/java/com/draco18s/artifacts/client/PedestalRenderer.java#L57 -
How does regular sand do it?
-
Why do certain Minecraft classes have really weird method names?
Draco18s replied to woofer's topic in Modder Support
Look at their contents and make deductions. -
Those function names are called SRG names. They're the semi-reliable automated decompilation names (instead of a.a() you get Block.func_12345_c()). It is then up to the community to figure out what that function does and supply a human-readable name.
-
How would I auto smelt items when broken by a specific pickaxe?
Draco18s replied to YamiAtem's topic in Modder Support
Yeah I literally wrote the code for autosmelt already. Things've changed a bit, but it was one of the "someone is going to want this, so my system better support it" test mod examples. https://github.com/MinecraftForge/MinecraftForge/blob/1.16.x/src/test/java/net/minecraftforge/debug/gameplay/loot/GlobalLootModifiersTest.java#L146-L178 -
https://ericlippert.com/2008/09/10/vexing-exceptions/ File handling is exogenous. If an exception occurs, clean up what you can (eg. if you successfully opened a file, close it), then die with a fatal exception. Currently you're catching the exception, logging it, and continuing as if nothing bad happened (and thus, generally make things worse).
-
I have a NullPointerException but I don’t know where
Draco18s replied to TokiiWalkie's topic in Modder Support
Line 28 of PlatformIndicatorBlock. -
-
Look at the Screen class. In general, guis haven't changed much since 1.10 The missing page has been missing for a while.
-
If you're using nested CompoundNBT and ListNBT and all that, then what are you doing with JSON? JSON is a serialization format. NBT is a serialization format. They are not the same thing even if they do the same job.