#Custom Projectile Trail (1.21)

1 messages · Page 1 of 1 (latest)

forest zenith
#

I have an idea to make a spiralling particle trail that will following projectiles fired by players, but due to how projectiles don't face the direction they are moving, using ^ ^ ^ doesn't give the proper result I'm looking for. What else could I do?

forest zenith
#

Custom Projectile Trail (1.21)

buoyant granite
#

You could have a marker ride the projectile and every tick turn and place a particle ^ ^ ^.2

#

Though that doesn't take the direction of the projectiles travel into account...

#

Ig I would solve this with a bunch of math but that likely isnt the best way. If no one else answers this for a while, ping me and I'll send a solution

forest zenith
#

I have given your marker idea a try but I'm not too sure if it would be the best idea in a multiplayer setting with players throwing tridents everywhere. Using math would at least have less extra entities spawn, I think, so multiplayer wise I would prefer to handle it without spawning any extra entities.

What's your solution? @buoyant granite

buoyant granite
#

So I would stick with that

#

So you grab the tridents rotation and normalize it. Each trident has a time since it was thrown that you have to keep track of. Make a display entity with one of its left or right rotation set using the angle axis option. The angle is the normalized trident motion and the axis is some multiple of the tridents lifetime. Now the display entity contains a quaternion in that position representing a rotation about that axis. Conjugate a point that you know, I would go for (0,0,1,0) which is directly above the trident, by the quaternion. That will give you the relative coordinates to the trident to place a point

#

Use Wikipedia to fill in what you don't know