When I have a node () in a .egg with a name and with " { Polyset keep descend }", the node’s name is removed and instead applied to the generated CollisionNode. Here is a simple example demonstrating the issue:
minimalCollideTest.egg
<CoordinateSystem> { Z-up }
<Comment> { "Egg laid by Chicken for Blender, version R91" }
<Group> ThisIsMyNodeName {
<Transform> {
<Matrix4> {
1.000000 0.000000 0.000000 0.000000
0.000000 1.000000 0.000000 0.000000
0.000000 0.000000 1.000000 0.000000
0.000000 0.000000 -5.000000 1.000000
}
}
<Collide> { Polyset keep descend }
<VertexPool> Plane {
<Vertex> 0 {
1.0 0.999999940395 -5.0
}
<Vertex> 1 {
-0.999999642372 1.00000035763 -5.0
}
<Vertex> 2 {
-1.00000011921 -0.999999821186 -5.0
}
<Vertex> 3 {
1.0 -1.0 -5.0
}
}
<Polygon> {
<Normal> { 0.000000 -0.000000 1.000000
}
<VertexRef> { 0 1 2 3 <Ref> { Plane } }
}
}
nodeNameTest.py
import direct.directbase.DirectStart
from pandac.PandaModules import *
from direct.gui.OnscreenText import OnscreenText
level = loader.loadModel('minimalCollideTest.egg')
level.reparentTo(render)
level.ls()
Here’s the output generated by the above example:
DirectStart: Starting the game.
Known pipe types:
glxGraphicsPipe
(all display modules loaded.)
ModelRoot minimalCollideTest.egg
PandaNode
PandaNode T:m(pos 0 0 -5)
CollisionNode ThisIsMyNodeName (1 solids) (hidden)
GeomNode (1 geoms)
Is there any way to attach a name to the innermost PandaNode in the tree above, instead of having the name stolen by the CollisionNode?