Blender 2.69 Runtime error - Traceback, most recent call last

Hi guys, I enabled the addon of “Save game as runtime”. And when I´m going to export, I get a traceback (most recent call last) error


(I don´t know how to scale this little crap)

So, I´ve been looking and a lot of people had this problem. I found a solution but it is for blender 2.68.
And it is different (The script game_engine_save_as_runtime is not the same in 2.68 and 2.69)

I really need to get this thing working, please!

I appreciate your kindness! :slight_smile:

Cheers

This was mentioned a few months ago, the exporter is trying to put add a .blend to a filepath after its called. To fix you must open your scripts/addons/ game_engine_save_as_runtime.py file…In it you will see a section that looks like this starting at line 107



    
    # Create a tmp blend file (Blenderplayer doesn't like compressed blends)
    tempdir = tempfile.mkdtemp()
    blend_path = os.path.join(tempdir, bpy.path.clean_name(output_path))
    bpy.ops.wm.save_as_mainfile(filepath=blend_path,
                                relative_remap=False,
                                compress=False,
                                copy=True,
                                )
    blend_path += '.blend'


The blend_path +=’.blend’ must be moved to before the bpy.ops.wm… so that it looks like this


# Create a tmp blend file (Blenderplayer doesn't like compressed blends)
    tempdir = tempfile.mkdtemp()
    blend_path = os.path.join(tempdir, bpy.path.clean_name(output_path))
    blend_path += '.blend'  ##MOVED HERE
    bpy.ops.wm.save_as_mainfile(filepath=blend_path,
                                relative_remap=False,
                                compress=False,
                                copy=True,
                                )

that will fix it

Thanks a lot!!!

i’m also in a bit of trouble im trying to addlink with 3dcoat and ive watched the tutorial from 3dcoat website but this keeps on poping out traceback and im stuck so please can someone help me. thanks