#Make a new block that inherits properties of another block
30 messages · Page 1 of 1 (latest)
Once your ticket has been resolved, please close it with </ticket close:1054771505520717835> command!
Or register an item with a modded class
Bumping as I have the same question/issue. Trying to inherit the properties of a Caverns and Chasms brazier so I can add one with custom fire.
Models or textures are generally not inherited using a class, when you do this you usually do it to copy the bahvioir of an item. E.g. hammers that mine in a 3x3 area
https://github.com/team-abnormals/caverns-and-chasms/blob/1.20.x/src%2Fmain%2Fjava%2Fcom%2Fteamabnormals%2Fcaverns_and_chasms%2Fcommon%2Fblock%2FBrazierBlock.java
This is the class for the brazier
You'd want to load that and it seems like you just use the function Brazier Block with the new keyword
Though I'm no expert on this
?
you mean like a texture/model mimic?
I messed with datapack/texturepack stuff. You can define a model to use specific textures (its basic but you need EMF/CIT to do more advance stuff). You can have a model call a pre-existing texture added by a resourcepack or in the game from a mod
ive done something like this using a custom model to pull a texture from another mod if present for a modded item (bucket with fluid render from its source block for example)
I'm talking like a full block mimic, I was able to approximate most of the properties but I'm still missing some things. The current code that I got from another helpful person was this:
Paste version of block_registry_2.js from @inner pollen
But with this I'm noticing like, the block sounds aren't correct, it doesn't drop when mined by any tool and there's no preferred tool set.
Which I'm sure I just need to set up in BlockProperties but I'm still working on finding the syntax for that
like here you can see it's working, we've got the appropriate block model and textures even if they aren't cutout like they're supposed to be
To set the preferred tool add the correct block tags iirc
Drops are related to that tag missing probab
Yeah I assumed so, I'm just not sure why the block sounds are incorrect as well
Like it's just default block
You would need to set the sound type as well, though I don't know how to do this for a block created like this
You can try like it's documented on the wiki
Idk if that will work though
I tried using the cutout rending method from the wiki and it crashed me so I'm not hopeful
And for the cutout you just need to set the render type which might or might not be the same as on the eiki
Oh it did? What was the error it gave?