Particle System staying at the tip of my weapon during animations

Hi everyone,

I’m trying to get a particle system to stay at the tip of my characters wand. If googled and looked around and a lot of people say “just drag it in the hierachy on to the bone and it will follow”. Well I did that and positioned the ps on the right place and it follows my characters but it’s not really following exactly.

So now if put a small sphere in blender3d at the tip and it follows nicely when I play the different animations.

My idea was that I could write a script that gets the position from the small sphere which is an extra object and child of my char in unity and use it to apply it in update to the particle system.

Can anyone confirm that this way would be possible or what would be the best practice for something like that?

I’ve tried to script it but I’m just starting to try scripting my self so I have no Idea if it’s just not possible or I just suck at scripting :wink:

If you make your particle object a child ob any other object (like, say, the weapon), it will always stay at the same exact relative to it’s parent. For a weapon muzzle flash, I would just make it a child of the weapon, and move it to the weapon object’s model’s muzzle and rotate it the right way. You can do this via script with

muzzleflashObject.transform.parent = weaponObject.transform

I don’t understand you alternative approach, you never explain what the “small sphere” is or what it’s supposed to do.