Started by
Adi_MC
on
Topic category: Help with Minecraft modding (Java Edition)
Like, glow in the dark, not the enchant glint. I want to make a sword, which I already have a model for, that it's blade is glowing. Similar to glowing mushrooms from the Random Things mod (not a mcreator mod)
How did U make the glowing blade?
optifine?
This is what I'm thinking:
Create an invisible block that emits light, and set the min x y z and max x y z of the block to zero so that the player cannot mine the invisible block. The block material would be air, and the rest would be up to you.
After that, you would create a procedure that is added onto that block. The event that runs the procedure should be "On Update tick" for the block. The procedure would remove the block in order to prevent unnecessary block placements.
Now, the final step...
Add another procedure that would be for your sword that would place the invisible glowing block at the player position if there's air at the player's location. Edit your item by adding that procedure to the event called "When tool/item in hand tick".
If I'm correct, while the item is in the player's hand, it should emit light. I hope I was of assistance!
;)
Thank you GBG, however, I don't think that works in any occasions
1 this method would cause the existing blocks in the world to be easily be overwritten (become that light block) because of location inaccuracies.
2 placing a block every tick and removing the previous block every tick is not good for movements, whether swimming, walking, sneaking, jumping, sprinting, or crawling as the block placement axis depending on the player axis is usually inexact.
3 The lights are emitted and removed constantly so it will look wrong.
4 If you are underwater, then I think it would be a disaster cuz block placements remove water and fluid blocks.
It's deprecated and causes many more problems.
There is no way,
but here's a little something https://github.com/sp614x/optifine/issues/182
to let you know that even optifine's dynamic lighting does not support this
isnt the vanilla torch a glow item now?