I’m trying to make a number of objects move around on uneven terrain, but I’m having trouble getting them to collide with the ground. I made the terrain in 3d Studio Max and added a Collide tag to the egg file so that it reads
environment {
“Scene Root” {
ground_collide {
ground_collide {polyset keep}
ground_collide.verts {
…
and I set the geometry in my loadModels function as
self.env = loader.loadModel("ground")
self.ground = self.env.find("**/ground_collide")
self.ground.reparentTo(render)
self.ground.node().setIntoCollideMask(BitMask32(0x4))
with the models’ CollisionRay collide-into masks set as allOff() and collide-from masks as 0x4.
I can attach CollisionSolids to the ground model within Panda and the objects will respond to that, but they ignore the collision geometry that I set in the egg file. Does it seem like the problem is in the way I handle the models in my code, or the way I set the tag in the egg file? I read the egg syntax documentation but as far as I can tell I have the right line added to the egg file.