Hello everyone,
I would like to ask, is there any way to provide collision between two nodes? I added two objects as ".node"(FBX) file and tried to set collider on them.But unfortunately I couldn't check any collision is available between them.According to this collision I would like to give some effect like explosions on objects.
simply,
Unigine::NodePtr node1;
Unigine::NodePtr node2;
then I initialize node objects for them which is available in Unigine editor,mReference represent parent node(everything works and I can show them in Unigine engine(these two objects are available on the screen))
node1 = Util::Search::getNodeRecursive("Body", mReference->getNode());
node2 = Util::Search::getNodeRecursive("Turret", mReference->getNode());
then,
I set collider for second object and first object,
node1.setCollider(1);
node2.setCollider(1);
then,
I move node1 to the node 2 object in for loop.
node1.setPosition(Vec3) // it starts to move second object
But unfortunately I don't know how to check they touch each other or not.Simply node1 passes node2 and goes away.(There is no tutorials for Node collision)
Any help would be appreciated.