Sunday, July 3, 2022
HomeGame DevelopmentSet particles to mannequin anchor level - Cocos Creator

Set particles to mannequin anchor level – Cocos Creator


Hello All,

I’ve been making an attempt to connect a particle system to the anchor level of a mannequin inside a node. I’ve tried one thing like this (this.node being the mannequin with the anchor level):

replace(deltaTime: quantity) {
  this.particle.node.setPosition(this.node.getChildByName("ModelWithAnchor").getPosition());
}

It appears to behave unusually, it strikes the particles to a special place however then it doesn’t transfer with the mannequin.

Anybody have any concepts?

Thanks,
-iDev


Seems:

replace(deltaTime: quantity) {
  this.particle.node.setPosition(this.node.getChildByName("ModelWithAnchor").getWorldPosition());
}

Did the trick.

RELATED ARTICLES

LEAVE A REPLY

Please enter your comment!
Please enter your name here

- Advertisment -
Google search engine

Most Popular

Recent Comments