Jump to content

[1.2-1.7] Blender (2.83+) .mu import/export addon


Recommended Posts

  • 1 month later...

Quick note before I start: After using this addon for so many years, I have to say it's been invaluable and I literally wouldn't be able to create the stuff I do now without it. 

 

There are a few bugs with the addon, most of which can be solved fairly easily - AirplanePlus cockpits have the monoprop resource commented out incorrectly, and the importer throws an error; to fix it, simply comment out all of that bit of code, and it imports fine. Some parts, like certain landing gear (or the BDA ej200, which is a scaled jet engine) don't import correctly. Honestly, for those issues, having the importer just import what's left and skipping the offending part, rather than just throwing an error.

However the one mod I know of that absolutely refuses to import correctly, or sometimes at all, is pwings. Procedural wings import as the default blocks, and procedural panels, for whatever reason, flat-out refuse to import at all. Having functionality where pwings could be scaled correctly, and procpanels imported correctly, would be a massive boon for competitions like runway project, where pwings are a small part; or FJRT, where pwings are basically integral to the competition. In combination with @Halban's ksp -> blender vessel tracer, we could recreate a dogfight in blender to get those sweet, sweet cinematic camera angles.

Tl;DR: feature request for @taniwha: have the importer skip offending parts on import, rather than throwing an error and refusing to import it at all; and possibly add support for pwing scaling, so complicated builds, such as gigantic ships, don't have to be re-built in blender?

Link to comment
Share on other sites

  • 4 months later...
  • 1 month later...
10 hours ago, kspbutitscursed said:

its not working in blender 4.1?

Pretty sure it hasn't been updated since back when blender 3 came out. So any fundamental change in 4.1 might break it.

Link to comment
Share on other sites

14 hours ago, ColdJ said:

Pretty sure it hasn't been updated since back when blender 3 came out. So any fundamental change in 4.1 might break it.

yeah its fixed now 

i downgraded to 3.9 and its now fixed lol

Link to comment
Share on other sites

When I try to import a craft file I get this error

Blender 2.83.20 windows x64

Traceback (most recent call last):
  File "C:\Users\bienc\AppData\Roaming\Blender Foundation\Blender\2.83\scripts\addons\io_object_mu-master\import_craft\import_craft.py", line 106, in execute
    return import_craft_op(self, context, **keywords)
  File "C:\Users\bienc\AppData\Roaming\Blender Foundation\Blender\2.83\scripts\addons\io_object_mu-master\import_craft\import_craft.py", line 80, in import_craft_op
    obj = import_craft(filepath)
  File "C:\Users\bienc\AppData\Roaming\Blender Foundation\Blender\2.83\scripts\addons\io_object_mu-master\import_craft\import_craft.py", line 44, in import_craft
    gamedata = GameData(Preferences().GameData)
  File "C:\Users\bienc\AppData\Roaming\Blender Foundation\Blender\2.83\scripts\addons\io_object_mu-master\import_craft\gamedata.py", line 146, in __init__
    self.create_db()
  File "C:\Users\bienc\AppData\Roaming\Blender Foundation\Blender\2.83\scripts\addons\io_object_mu-master\import_craft\gamedata.py", line 129, in create_db
    recurse_tree(self.root, self.build_db)
  File "C:\Users\bienc\AppData\Roaming\Blender Foundation\Blender\2.83\scripts\addons\io_object_mu-master\import_craft\gamedata.py", line 36, in recurse_tree
    recurse_tree(p, func)
  File "C:\Users\bienc\AppData\Roaming\Blender Foundation\Blender\2.83\scripts\addons\io_object_mu-master\import_craft\gamedata.py", line 36, in recurse_tree
    recurse_tree(p, func)
  File "C:\Users\bienc\AppData\Roaming\Blender Foundation\Blender\2.83\scripts\addons\io_object_mu-master\import_craft\gamedata.py", line 36, in recurse_tree
    recurse_tree(p, func)
  File "C:\Users\bienc\AppData\Roaming\Blender Foundation\Blender\2.83\scripts\addons\io_object_mu-master\import_craft\gamedata.py", line 38, in recurse_tree
    func(p)
  File "C:\Users\bienc\AppData\Roaming\Blender Foundation\Blender\2.83\scripts\addons\io_object_mu-master\import_craft\gamedata.py", line 102, in build_db
    self.process_cfg(path)
  File "C:\Users\bienc\AppData\Roaming\Blender Foundation\Blender\2.83\scripts\addons\io_object_mu-master\import_craft\gamedata.py", line 97, in process_cfg
    self.process_cfgnode(gdpath, node)
  File "C:\Users\bienc\AppData\Roaming\Blender Foundation\Blender\2.83\scripts\addons\io_object_mu-master\import_craft\gamedata.py", line 73, in process_cfgnode
    internal = Internal(path, node)
  File "C:\Users\bienc\AppData\Roaming\Blender Foundation\Blender\2.83\scripts\addons\io_object_mu-master\import_craft\part.py", line 58, in __init__
    self.scale = parse_float(cfg.GetValue("scale"))
  File "C:\Users\bienc\AppData\Roaming\Blender Foundation\Blender\2.83\scripts\addons\io_object_mu-master\cfgnode\parser.py", line 121, in parse_float
    return float(string)
ValueError: could not convert string to float: '1,1,1'

location: <unknown location>:-1

bpy.ops.import_object.ksp_craft(filepath="C:\\BlenderStuff\\Blender\\abcde.craft")

Link to comment
Share on other sites

Join the conversation

You can post now and register later. If you have an account, sign in now to post with your account.
Note: Your post will require moderator approval before it will be visible.

Guest
Reply to this topic...

×   Pasted as rich text.   Paste as plain text instead

  Only 75 emoji are allowed.

×   Your link has been automatically embedded.   Display as a link instead

×   Your previous content has been restored.   Clear editor

×   You cannot paste images directly. Upload or insert images from URL.

×
×
  • Create New...