Jump to content

[1.16.4] Particle which doesn't face the player.


Hendoor64

Recommended Posts

Hi! I wanted to create a rotating circle visual which hovers in the air, and I figured a particle would have less overhead than an entity. By default, particles rotate their quad to face the player automatically, but I want mine to face straight up regardless of the player's position. How can I tell the particle (or whatever renders it) not to face the player?

 

P.S.

I'm also struggling to rotate my particle, there doesn't seem to be a field for its orientation, only its position. Any ideas?

 

Thanks!

Link to comment
Share on other sites

Howdy

Have a look in TexturedParticle::renderParticle.  You will need to understand some vector rotation math (Quaternions) but with a bit of experimentation you should be able to figure it out.

 

Some more information on particles here in case you need it:

https://github.com/TheGreyGhost/MinecraftByExample/tree/master/src/main/java/minecraftbyexample/mbe50_particle

 

Cheers

  TGG

 

 

Link to comment
Share on other sites

Join the conversation

You can post now and register later. If you have an account, sign in now to post with your account.
Note: Your post will require moderator approval before it will be visible.

Guest
Unfortunately, your content contains terms that we do not allow. Please edit your content to remove the highlighted words below.
Reply to this topic...

×   Pasted as rich text.   Restore formatting

  Only 75 emoji are allowed.

×   Your link has been automatically embedded.   Display as a link instead

×   Your previous content has been restored.   Clear editor

×   You cannot paste images directly. Upload or insert images from URL.

Announcements



×
×
  • Create New...

Important Information

By using this site, you agree to our Terms of Use.