• Which the release of FS2020 we see an explosition of activity on the forun and of course we are very happy to see this. But having all questions about FS2020 in one forum becomes a bit messy. So therefore we would like to ask you all to use the following guidelines when posting your questions:

    • Tag FS2020 specific questions with the MSFS2020 tag.
    • Questions about making 3D assets can be posted in the 3D asset design forum. Either post them in the subforum of the modelling tool you use or in the general forum if they are general.
    • Questions about aircraft design can be posted in the Aircraft design forum
    • Questions about airport design can be posted in the FS2020 airport design forum. Once airport development tools have been updated for FS2020 you can post tool speciifc questions in the subforums of those tools as well of course.
    • Questions about terrain design can be posted in the FS2020 terrain design forum.
    • Questions about SimConnect can be posted in the SimConnect forum.

    Any other question that is not specific to an aspect of development or tool can be posted in the General chat forum.

    By following these guidelines we make sure that the forums remain easy to read for everybody and also that the right people can find your post to answer it.

Python error: Location -1?

F747fly

Resource contributor
Messages
1,713
Country
netherlands
Hi t

here,

I just tried to export my blender made model to .x and received the following error, which I through some googling already found is python error:

Traceback (most recent call last):
File "...\Blender\2.73\scripts\addons\io_scene_fsx\__init__.py", line 138, in execute
Exporter = export_fsx.FSXExporter(self, context)
File "...\Blender\2.73\scripts\addons\io_scene_fsx\export_fsx.py", line 164, in __init__
AnimationGenerators = self._GatherAnimationGenerators()
File "...\Blender\2.73\scripts\addons\io_scene_fsx\export_fsx.py", line 721, in __GatherAnimationGenerators
None, Object, self.modeldefTree))
File "...\Blender\2.73\scripts\addons\io_scene_fsx\export_fsx.py", line 1739, iin _GenerateKeys
for fcu in FCurves:
TypeError: 'NoneType' object is not iterable\

location: (unknown location): -1

location: (unknown location): -1



Anyone know how to solve this?
 
You either have an object which is tagged with an Animation Tag but not animated, or the other way round (animated object without a Tag).
 
You either have an object which is tagged with an Animation Tag but not animated, or the other way round (animated object without a Tag).

Thank you! I feel very silli now I know it was right in front of me the whole time :) Thank you again!
 
Is it possible... Within the python script to notify the user in such a case?
 
Could be... The toolset is still in a kind of beta shape. I'd illustrate the way I handle these things normally:

- My T.5 model takes ages to export to .mdl. Not strange, because of the (still dirty) hi-poly VC.
- During this process, Blender flips on the "Not responding" mode. Might be alarming at first, but no worries, it will return to normal mode.
- If the exporter discovers a problem, it quits the process earlier than normal. For my D.21 it's almost immediately after hitting the Export button, for my T.5 it takes a bit longer.
- To check the export process (ie. if it went all right), I have two options:
a: Go to Blender a few times during export, to see if it's still in "Not responding" mode. If it works again too early, something went wrong.
b: After the estimated export time, go to Blender and view the Info window whether it shows red lines or not. If so, something went wrong.

I had the error that the OP came up with numerous times of course. I now immediately tag an animated object or the other way round. In most cases, I move the objects I'm working on, to a seperate layer. Selecting all layers but excluding that one, then select all objects, excludes this in-work object from the export (since I might have forgotten to assign a material or tag it or anything else).

For the time being, we should still apply the human-in-the-loop approach ;)

@capt_x: I found out that selected objects in hidden layers are still taken along on the export (they ARE selected, but their layer ISN'T). Is that true? Not that's it a problem, I just observed :)

Cheerio!
 
@capt_x: I found out that selected objects in hidden layers are still taken along on the export (they ARE selected, but their layer ISN'T). Is that true? Not that's it a problem, I just observed :)

Cheerio!

Hi Daan, that should not actually happen. When I tested it, the behavior was different. Only objects from selected layers should be exported. That being said, I'm still on 2.72, so that might have changed in the later versions of Blender, although I couldn't think of a good reason why...:scratchch I'll switch to the latest version of Blender and report.

Cheers :)
 
Back
Top