Chicken, an Egg exporter for Blender 2.49 and lower

UPDATE 12-30-2006:
The final (or so I hope) 1.0 release is out. It fixes all the known issues, especially those regarding Linux. It also adds support for exporting Empty objects for use as markers in Panda. You can also tag these just like you can tag Mesh objects.
If you happen to find an issue with this release you’re still welcome to report it, although I urge you to do it through the SourceForge bug tracker.

We’ll be focusing on a new version of Chicken now with new features as the primary objective, so we also encourage you to place your feature requests in the SourceForge feature request tracker.

Check out the script’s new site at

hey, thanks :smiley:

I did a basic test of exporting a few meshes and it looks ok. Previous blender exporters i used so far didn’t feel like handling my mesh names, but now it’s perfect.

The ‘export BAM file’ and ‘pview’ options are also real timesavers.

Just one question: In future i can see myself making a more or less large terrain with some trees, houses,… Can you add a ‘select all’ button?

I can, but for now you can just select all meshes before launching the exporter. How about instead of a button I just implement the ‘A’ key to do the same thing as in the rest of Blender?

Oh, i didn’t know that i could do it that way. Good enough for me.

(btw hooray for the chicken/egg references :smiley: )

Just bumping this up a bit :slight_smile:

Oh, and I forgot to say here that if anyone finds any bugs or has any feature requests, I’d be happy to address them.

I’m especially interested in someone with Linux trying it out, because I haven’t had a chance to test it there yet.

got it working fine under linux. with the latest blender and fedora5. thought one model’s texture wont get exported properly…all other models are fine… guess i made something weired in blender =) thx for your work

You’re welcome :slight_smile:

Would it be possible for you to try this same blend file on Windows to see if the problem is platform specific? If you can’t I wouldn’t mind trying it out (you can send it to my e-mail, it’s on the exporter’s page).

nah… i dont think its a platformspecific problem (i cant test it on windows since i dont have a win install nearby)… i think i messed something up. since it works with the rest.(and i tried a lot of stuff with this one so dont worry) it’s just a wrong texture-name after all.

Okay, that’s good to hear then. How about the export to BAM options, and pview launching? Is that working well on Linux as well? That’s probably the most platform-specific part.

havent tested them so fat… i’ll have a look at it tomorrow or so. stay tuned =)
i’ll edit this post and submit the results

ups^^ i mistook your exporter with the one from chris holland.
exporting a simple textured box worked fine. my models however did not. the console output:

Got export name of /HD2/Modellstuff/Modells/char-001-05.egg
Traceback (most recent call last):
  File "<string>", line 338, in gui
  File "<string>", line 302, in buildExportables
  File "<string>", line 1173, in doExport
  File "<string>", line 575, in ExportMesh
  File "<string>", line 600, in AddTex
AttributeError: 'NoneType' object has no attribute 'name'

exporting to bam file didnt work either. opening in pview option worked and pview opend but the model wasnt loaded

:egg(error): Unable to open “/HD2/Modellstuff/Modells/box.egg”

well the name and path above is ok. might be something else.
well animation dosent seem to work. when parenting a armature to a mesh it’s seems to be no longer exportable(also isnt shown in the exporter overview anymore).
to execute tha egg2bam converter under linux you can use
os.system("egg2bam “+inputfile+” "+outputfile)
same with pview
os.system("pview "+filename)

well unanimated and textured models usualy are exported fine to egg.
basicaly works =)

Hmm, the fact that it crashed on line 600 suggests that your object has material indices with no materials assigned to them, is that correct?

Also thanks for the input on the export to BAM and pview options, I think it might be the quotes on the paths of the parameters. I know about the os.system way of doing it, but that doesn’t allow me to check for the return code. That would mean you’d have to check the console yourself to see if it executed correctly or not.

As for the animation, I know it doesn’t export when you parent to armature. I did that on purpose because that is an obsolete way to animate things. If you don’t parent the object to the armature, and use the armature modifier instead it should work with no problems.

if thats whats happening when you assign a material and delete it again… then it is possible :smiley:

bdw. are animations supposed to be exported?

Yes, that’s exactly what happens :slight_smile: I forgot to consider that case. I’ll fix that up.
About the animations, I already answered that in my previous post. You must use the armature modifier, not parenting to armature. Supporting both ways would’ve been a mess so I decided to only use the current official way which is the modifier.

oh …thx for telling me twice :slight_smile: armature modifier worked… but it seems the rotation of the bones is a little bit wrong. instead of bending my object its twisting it :unamused: looks somewhat strange.

Check that object-level transforms are cleared on both the object and the armature (Alt-G, Alt-R, Alt-S to clear translation, rotation and scaling respectively). Sometimes they can be weird like that. As far as I’ve tested, eggX has the same problem, and it’s sometimes much worse.

oh… ok… the standart cube in blender is rotated by 90° … everything clear =) thx again

No problem, but please check out the script’s help as well, since it addresses most of these questions.

I’ll upload a fix for the material issue you found earlier as soon as my host lets me upload files again (they’re having some ftp problems it seems).

EDIT: Okay, I uploaded an updated version which fixes the material indices without materials issues, and hopefully fixes egg2bam and pview invocation under Linux. I couldn’t try it in Linux cause I only have a live CD and no space to install it, but I did try Python’s invocation functions and their quirks so it should work.

hm… well i just tried the new version…
material is still strange. it still seems to use the texture name of the deleted material’s texture instead the one from the UV-editor.
bam export doesnt work (still same error)
pview opens but still no model loaded. (the “egg unable to open…” error disappeared :unamused:)
no real changes… well…at least you got one errormessage less :slight_smile:
i guess bam and pview aren’t so important. but it would be nice if the material stuff can be fixed since blender is using the uv-editor’s image as preview. atm it’s like… assign a texture and you’r doomed :wink:. you dont need to hurry because of me. use the nights to get sleep, dont fall for the bits, they b(i/y)te :open_mouth:

Could you send me a blend file that produces the error? Perhaps I misunderstood the problem. I fixed something, but perhaps it wasn’t what you wanted.
I guess I’ll have to wait until I have a working Linux install to really fix the egg2bam/pview issue, but this other one doesn’t seem to have anything to do with Linux.