Started by
2Cool4u
on
Topic category: Help with Minecraft modding (Java Edition)
I have finished my Model, Texture, and GUI for my cannon, but I can't seem to figure out how to make it work. No matter which direction I place the cannon in, it fires in only one direction, north. Even the particles always shoot north, even if the cannon is facing east, south, or west. Help please!!!!
That's a problem because you only have it shooting north. In the procedure for it firing, have four If statements, with If Get direction of block at X Y Z = North/South/East/West, then duplicate the firing code and change the directions. X is east/west, and Z is north/south.
That is perfect, thank you so much, the cannon now works. Also how would I add a custom projectile? Like a cannonball that, when collides with entity or block, explodes?
You can do it with a custom ranged item (just make it unobtainable) that explodes when it hits a block/entity.
I'll try that out, thank you!!!
Actually I don't know how to make the block shoot the entity. May I have some help on that