Everything posted by Draco18s
-
[1.16.4] How do data generators work with loot tables?
Feel free to submit a pull request to update the docs https://github.com/MinecraftForge/Documentation
-
[1.16.4] Copying Enchantment Data when Smelting
Not with vanilla systems, no.
-
[1.15.2] How do I make it so you need a tool for logs?
...if the player isn't holding an axe...cancel the event...
-
[1.16.4] 3-block tall Door
Correct.
-
[1.16.4] HandleCommand on PlayerWakeUpEvent crashing with java.lang.StackOverflowError
Rather than trying to fake executing a command, just do the things that the command does. i.e. instead of telling the server "the player typed /teleport, run the teleport command" just...teleport the player by changing their position.
-
[1.16.4] How to zoom out?
Vanilla. The FOVUpdateEvent (Forge) might help you find the right areas to start looking at though.
-
[1.16.4] How to zoom out?
You'll have to dig into the code yourself and find what you need.
-
[1.16.4] How to zoom out?
Move the camera further away from the player.
-
Is there a way to Render a JSON onto a player?
JSON is just data. You are looking for how to render a model.
-
How do I detect if a player rightclicks using an item
If you are trying to learn how to mod without knowing how to program (Java preferred, but any language), then you are going to have a lot of trouble.
-
How do I detect if a player rightclicks using an item
Look at the available methods to override in the Item class and IForgeItem interface.
-
[1.15.2] Unlocalized names
Unlocalized names are for display purposes. The registry name is what identifies the item with the game. Which one makes more sense to be the primary key?
-
multi block with gaps
Create your own invisible, replacable, isAir block that gets placed in the air spaces.
-
multi block with gaps
Every block that is part of your structure should know where in that structure it is, relative to the center, and when it breaks, it should notify the center. https://github.com/Draco18s/ReasonableRealism/blob/1.14.4/src/main/java/com/draco18s/harderores/block/WindvaneBlock.java#L72
-
1.16.4 AutoSmelt Enchant
You need to register the serializer and add the json data as well (including adding your serializer to the forge loot_modifier.json).
-
Can't get custom item in ItemStack
Do not use item IDs. You do not need to know what they are or interact with them in any way. Your class extends Item Your method is an instance method new ItemStack(this)
-
Error when running Client
Errors are pretty self explanatory. You have a NoClassDefFound error, meaning a class was not found, the name of the class that wasn't found, and the line of code that called it.
-
Failure message: Missing License Information in file Mod File
Good thing the documentation I linked tells you where it goes so you can create it.
-
Failure message: Missing License Information in file Mod File
Dude, it's a Forge feature, Forge doesn't have to "update to automatically include it," it is Forge. Check your resources folder. https://mcforge.readthedocs.io/en/1.15.x/gettingstarted/structuring/#the-modstoml-file
-
[1.16.3] How to calcule line in 3D
That's not a line, that's a sphere. You want to look up how to calculate a Slerp (spherical linear interpolation).
-
[1.16.4] Damage ItemStack through Json Shaped/Shapeless craft?
You don't need to implement IForgeItem directly, Item already does that. You just need to override the method.
-
Break blocks around a breaked block
Derp yeah. I thought it did. Nevermind then.
-
Break blocks around a breaked block
Stream implements IEnumerable, so you don't need to convert it to a List
-
Break blocks around a breaked block
BlockPos.getAllInBox(...) would be a much, much better way of handling that loop. Or hell, using three nested loops for x, y, and z...
-
[1.16.1]Block Properties
What happens if the entity isn't a player? What happens if the entity is null?
IPS spam blocked by CleanTalk.