I’ve actually managed to compile my game with py2exe , but when i tried the distribution version on another pc, the directory structure in the bam files where messed up. Seems to me when I use the egg2bam converter, it takes the full path to the textures and freezes that in the bam file.
ie. I had a texture in the same dir as the model pointed to as “texture.png”, now the bam file keeps looking in c:\panda3d\streetracer\models\course1\ for the texture. I also tried “./texture.png” but no luck.
Is there anyway to prevent this from happening?
Oh and if anyone is interested in compiling this stuff with py2exe, let me know and I’ll post a tutorial. My methode is rather messy though
Put the following in your Config.prc before you run egg2bam:
By default, the textures will be made relative to your model path before they are written to the bam file, so you want to write them relative to the current directory, then you need to have the current directory on your model-path.
Addendum: upon closer inspection, there might be a bug in there. If the above doesn’t work, try this instead:
This should result in just “texture.png” getting written to the bam file.
nope, still the same problem. I supose I could load the texture manualy, but this would be smoother. Thanks for the quick reply anyhow
did you already use the -pr option when converting?
If not, use it. It specifies references to textures and other files.
it would look something like:
egg2bam -pr /c/panda3d/streetcar/models/course1=**/ mymodel.egg mymodel.bam
when using the -pr option also look at the -pp option to specify other directory names to search for