coolAlias Posted February 8, 2014 Posted February 8, 2014 EDIT: Yep, MC doesn't seem to have any way to automatically notify other clients of particles. Too bad, but no big deal. Writing a custom packet or two solves the problem just as easily. Ok, I know I can send packets to spawn the particles (though Packet63WorldParticles doesn't seem to have a usable constructor?), but my question is why is it that particles told to spawn on the server don't show up for clients? Looking at the method: public void spawnParticle(String par1Str, double par2, double par4, double par6, double par8, double par10, double par12) { for (int i = 0; i < this.worldAccesses.size(); ++i) { ((IWorldAccess)this.worldAccesses.get(i)).spawnParticle(par1Str, par2, par4, par6, par8, par10, par12); } } It looks like it should run through all the client worlds to spawn the particles, no? For example, if I have spawned an entity, such as an arrow, everyone can see particles that it generates. But if I run a method from onItemRightClick that spawns particles, only the player clicking the item can see them, even though the method runs on both sides. I understand that a shell entity is spawned on every client, so that's obviously how those particles are visible, but I'm wondering if there isn't a good method already available for informing other clients of particles spawned, or if I must write it myself. Cheers. Quote http://i.imgur.com/NdrFdld.png[/img]
TheGreyGhost Posted February 8, 2014 Posted February 8, 2014 Hi spawnParticle does nothing on the server WorldManager:: public void spawnParticle(String par1Str, double par2, double par4, double par6, double par8, double par10, double par12) {} I'm pretty sure that particle effects are always triggered on the client in response to something else, and there is no packet to say "draw particle effects". Packet63 appears to be unused anywhere in the vanilla. I think you're probably stuck with writing your own "spawn particles here" packet from the server to client. -TGG Quote
coolAlias Posted February 8, 2014 Author Posted February 8, 2014 Well, nothing else for it then Thanks for confirming my suspicions. Quote http://i.imgur.com/NdrFdld.png[/img]
Recommended Posts
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.