STEAM GROUP
Blender Source Tools BleST
STEAM GROUP
Blender Source Tools BleST
307
IN-GAME
1,904
ONLINE
Founded
8 November, 2013
All Discussions > Help > Topic Details
Two Python traceback errors
Not sure what to do, receiving python errors when exporting one mesh+one armature as .DMX binary 9 model 22.

Both using BST 3.2.5.

On blender 2.93.9:
Python: Traceback (most recent call last): File "C:\Users\admin\AppData\Roaming\Blender Foundation\Blender\2.93\scripts\addons\io_scene_valvesource\export_smd.py", line 215, in execute self.exportId(context, exportable.item) File "C:\Users\admin\AppData\Roaming\Blender Foundation\Blender\2.93\scripts\addons\io_scene_valvesource\export_smd.py", line 551, in exportId self.files_exported += write_func(id, bake_results, self.sanitiseFilename(export_name), path) File "C:\Users\admin\AppData\Roaming\Blender Foundation\Blender\2.93\scripts\addons\io_scene_valvesource\export_smd.py", line 1971, in writeDMX anim_len = animationLength(ad) File "C:\Users\admin\AppData\Roaming\Blender Foundation\Blender\2.93\scripts\addons\io_scene_valvesource\utils.py", line 312, in animationLength if ad.action: AttributeError: 'NoneType' object has no attribute 'action' location: <unknown location>:-1

On Blender 3.3 or 3.4.1:
Python: Traceback (most recent call last): File "C:\Users\admin\AppData\Roaming\Blender Foundation\Blender\3.3\scripts\addons\io_scene_valvesource\export_smd.py", line 214, in execute for exportable in getSelectedExportables(): File "C:\Users\admin\AppData\Roaming\Blender Foundation\Blender\3.3\scripts\addons\io_scene_valvesource\utils.py", line 514, in getSelectedExportables for exportable in getExportablesForObject(ob): File "C:\Users\admin\AppData\Roaming\Blender Foundation\Blender\3.3\scripts\addons\io_scene_valvesource\utils.py", line 498, in getExportablesForObject item_name = exportable.item.name AttributeError: 'NoneType' object has no attribute 'name'

100% totally fresh installs each time I tried
< >
Showing 1-15 of 16 comments
GoopedUpGaming 31 Dec, 2022 @ 11:29am 
Add-on was properly installed each time, and I gave blender a restart after installing, before trying to export, each time.
Artfunkel 1 Jan, 2023 @ 6:13am 
Please upload your blend file.
ErlGrey 1 Jan, 2023 @ 9:00am 
You need to create a keyframe animation for your armature. Press ctrl+tab with your armature selected and press i > Location, Rotation and scale. Hope it helps, it worked for me
ErlGrey 1 Jan, 2023 @ 9:02am 
^ Then export everything (you can later delete this animation). I recommend to use proportion trick for any of your custom humanoid armatures if they are about using playermodel native anims
Last edited by ErlGrey; 1 Jan, 2023 @ 9:02am
ErlGrey 1 Jan, 2023 @ 9:04am 
One keyframe is enough
GoopedUpGaming 1 Jan, 2023 @ 10:17am 
Originally posted by Artfunkel:
Please upload your blend file.

ErlGrey's answer worked for me but here's the blend if you want to search for other problems.
I was attempting to only export the head mesh and armature.
https://www100.zippyshare.com/v/AsAIv7Lv/file.html
GoopedUpGaming 1 Jan, 2023 @ 11:45am 
Originally posted by Artfunkel:
Please upload your blend file.

**UNMARKED AS SOLVED**
ErlGrey's answer allows the .dmx to export but once imported to Source 2 modeldoc, it is stuck facing one direction no matter how it's rotated before export. It seems like a sorta working hacky fix but isn't fully viable at least in my attempt
ErlGrey 1 Jan, 2023 @ 1:56pm 
Works for source one (Gmod atleast). Have you tried modifing $origin in qc file?
Artfunkel 21 Jan, 2023 @ 6:52am 
I can't download your file and can't reproduce the issue locally, so I don't really know what caused this. But I was able to put some checks into the code to handle things being unexpectedly null.
GoopedUpGaming 23 Jan, 2023 @ 10:53am 
Thank you! Not sure why you can't download the file, maybe zippyshare limitation? I'll give this export another shot
Artfunkel 23 Jan, 2023 @ 10:54am 
The changes haven't left my computer yet. Please try to upload your file to another site so that I can test whether I've actually fixed the issue.
Coyc 20 Apr, 2024 @ 9:42am 
Python: Traceback (most recent call last):
File "C:\Users\Марк\AppData\Roaming\Blender Foundation\Blender\4.1\scripts\addons\io_scene_valvesource\export_smd.py", line 209, in execute
self.exportId(context, id)
File "C:\Users\Марк\AppData\Roaming\Blender Foundation\Blender\4.1\scripts\addons\io_scene_valvesource\export_smd.py", line 551, in exportId
self.files_exported += write_func(id, bake_results, self.sanitiseFilename(export_name), path)
^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^
File "C:\Users\Марк\AppData\Roaming\Blender Foundation\Blender\4.1\scripts\addons\io_scene_valvesource\export_smd.py", line 1028, in writeSMD
anim_len = animationLength(ad) + 1 # frame 0 is a frame too...
^^^^^^^^^^^^^^^^^^^
File "C:\Users\Марк\AppData\Roaming\Blender Foundation\Blender\4.1\scripts\addons\io_scene_valvesource\utils.py", line 311, in animationLength
if ad.action:
^^^^^^^^^
AttributeError: 'NoneType' object has no attribute 'action'

wtf
ErlGrey 22 Apr, 2024 @ 12:36am 
Blender 4.1 has broken sharp edges, so use 4.0 or below.
Blue 29 May, 2024 @ 9:28pm 
Originally posted by ErlGrey:
Blender 4.1 has broken sharp edges, so use 4.0 or below.

not technically broken, just moved. the auto smoothing has been replaced with a modifier called "smooth by angle" or something.
< >
Showing 1-15 of 16 comments
Per page: 1530 50

All Discussions > Help > Topic Details