SuperTuxKart Exporter Tools/Scripts For Blender 2.80+

SuperTuxKart Exporter Tools/Scripts For Blender 2.80+

Postby Worldblender » 02 Oct 2020, 23:35

I've spent the last two months porting the existing exporter scripts to work with Blender 2.80 and later. This will hopefully allow us to eventually migrate to using newer Blender versions for producing STK assets. Along the way, I spent a considerable amount of effort to reorganize the layout and workings of every script. Today, the scripts are ready for testing! :D

Download at https://github.com/RQWorldblender/stk-blender <-- :cool:

Give them a try; they need all the testing possible before becoming official. To help with converting existing assets, there is an extra conversion script to aid in migration, as there barely exist any assets to test with.
User avatar
Worldblender
 
Posts: 99
Joined: 15 Aug 2014, 18:46
Location: Houston, Texas, United States

Re: SuperTuxKart Exporter Tools/Scripts For Blender 2.80+

Postby GeekPenguinBR » 03 Oct 2020, 00:04

Downloaded! This exporter will help us a lot.
"Making cool harmless games makes the world a better place".
User avatar
GeekPenguinBR
 
Posts: 466
Joined: 22 Mar 2014, 00:41
Location: Rio de Janeiro

Re: SuperTuxKart Exporter Tools/Scripts For Blender 2.80+

Postby Kitetsu » 10 Oct 2020, 13:04

Hello,

i tried your addons with Blender v2.81.16 but I always get issues exporting my track.

Here is the Log:

{l Code}: {l Select All Code}
Traceback (most recent call last):
  File "C:\Users\darkf\Desktop\blender-2.81a-windows64\blender-2.81a-windows64\2.81\scripts\addons\io_antarctica_scene\stk_track.py", line 1282, in invoke
    return self.execute(context)
  File "C:\Users\darkf\Desktop\blender-2.81a-windows64\blender-2.81a-windows64\2.81\scripts\addons\io_antarctica_scene\stk_track.py", line 1296, in execute
    savescene_callback(self, self.filepath, exportImages, self.exportDrivelines, self.exportScene, self.exportMaterials)
  File "C:\Users\darkf\Desktop\blender-2.81a-windows64\blender-2.81a-windows64\2.81\scripts\addons\io_antarctica_scene\stk_track.py", line 1221, in savescene_callback
    TrackExport(self, sFilePath, exportImages, exportDrivelines and stk_utils.getSceneProperty(bpy.data.scenes[0], 'is_stk_node', 'false') != 'true', exportScene, exportMaterials)
  File "C:\Users\darkf\Desktop\blender-2.81a-windows64\blender-2.81a-windows64\2.81\scripts\addons\io_antarctica_scene\stk_track.py", line 1128, in __init__
    if exporter.processObject(obj, stktype):
  File "C:\Users\darkf\Desktop\blender-2.81a-windows64\blender-2.81a-windows64\2.81\scripts\addons\io_antarctica_scene\stk_track_utils.py", line 687, in processObject
    self.lDrivelines.insert(0, Driveline(obj, 1))
  File "C:\Users\darkf\Desktop\blender-2.81a-windows64\blender-2.81a-windows64\2.81\scripts\addons\io_antarctica_scene\stk_track_utils.py", line 1236, in __init__
    self.convertToLists()
  File "C:\Users\darkf\Desktop\blender-2.81a-windows64\blender-2.81a-windows64\2.81\scripts\addons\io_antarctica_scene\stk_track_utils.py", line 1562, in convertToLists
    self.log.report({'WARNING'}, "Warning, driveline '%s' appears to be broken in separate sections. Vertex at %f %f %f is not connected with the rest" % \
AttributeError: 'Driveline' object has no attribute 'log'

location: <unknown location>:-1



Maybe you can tell me, whats wrong. Or it helps.

I actually don't know what i've could done wrong.

I just build a round course to try and learn a little bit in building tracks.

just let me know, if you need something more. It's my first try to build a track :)

Greetings
Kitetsu
User avatar
Kitetsu
 
Posts: 3
Joined: 10 Oct 2020, 12:59
Location: Germany

Re: SuperTuxKart Exporter Tools/Scripts For Blender 2.80+

Postby Worldblender » 11 Oct 2020, 22:07

Kitetsu {l Wrote}:Hello,

i tried your addons with Blender v2.81.16 but I always get issues exporting my track.

Here is the Log:

{l Code}: {l Select All Code}
Traceback (most recent call last):
  File "C:\Users\darkf\Desktop\blender-2.81a-windows64\blender-2.81a-windows64\2.81\scripts\addons\io_antarctica_scene\stk_track.py", line 1282, in invoke
    return self.execute(context)
  File "C:\Users\darkf\Desktop\blender-2.81a-windows64\blender-2.81a-windows64\2.81\scripts\addons\io_antarctica_scene\stk_track.py", line 1296, in execute
    savescene_callback(self, self.filepath, exportImages, self.exportDrivelines, self.exportScene, self.exportMaterials)
  File "C:\Users\darkf\Desktop\blender-2.81a-windows64\blender-2.81a-windows64\2.81\scripts\addons\io_antarctica_scene\stk_track.py", line 1221, in savescene_callback
    TrackExport(self, sFilePath, exportImages, exportDrivelines and stk_utils.getSceneProperty(bpy.data.scenes[0], 'is_stk_node', 'false') != 'true', exportScene, exportMaterials)
  File "C:\Users\darkf\Desktop\blender-2.81a-windows64\blender-2.81a-windows64\2.81\scripts\addons\io_antarctica_scene\stk_track.py", line 1128, in __init__
    if exporter.processObject(obj, stktype):
  File "C:\Users\darkf\Desktop\blender-2.81a-windows64\blender-2.81a-windows64\2.81\scripts\addons\io_antarctica_scene\stk_track_utils.py", line 687, in processObject
    self.lDrivelines.insert(0, Driveline(obj, 1))
  File "C:\Users\darkf\Desktop\blender-2.81a-windows64\blender-2.81a-windows64\2.81\scripts\addons\io_antarctica_scene\stk_track_utils.py", line 1236, in __init__
    self.convertToLists()
  File "C:\Users\darkf\Desktop\blender-2.81a-windows64\blender-2.81a-windows64\2.81\scripts\addons\io_antarctica_scene\stk_track_utils.py", line 1562, in convertToLists
    self.log.report({'WARNING'}, "Warning, driveline '%s' appears to be broken in separate sections. Vertex at %f %f %f is not connected with the rest" % \
AttributeError: 'Driveline' object has no attribute 'log'

location: <unknown location>:-1



Maybe you can tell me, whats wrong. Or it helps.

I actually don't know what i've could done wrong.

I just build a round course to try and learn a little bit in building tracks.

just let me know, if you need something more. It's my first try to build a track :)

Greetings
Kitetsu

That's most likely an oversight during my porting. I was trying to remove the built-in log as part of my porting effort. In place of this, I would be using the built-in Blender log facility. It looks like I didn't catch every usage of log usage, so I may need to go back to check it.
You might also want to upgrade to a more recent Blender version; 2.83 LTS is a good place to start if you don't want to go all the way to 2.90 (the scripts should still work on that version, but it's untested).

Update: I fixed the issue now with commit https://github.com/RQWorldblender/stk-blender/commit/c400020a62513be0d723d01f819d53a2c40bc745. Check out the latest update and try again what you were doing. You can reload scripts from the menu by clicking the Blender icon at the top-left -> system -> reload scripts.
User avatar
Worldblender
 
Posts: 99
Joined: 15 Aug 2014, 18:46
Location: Houston, Texas, United States

Re: SuperTuxKart Exporter Tools/Scripts For Blender 2.80+

Postby tempAnon093 » 09 Nov 2020, 03:50

Thank you for this! I've just started using it now and my basic test track is exporting perfectly. :)

(The only issue I had was when a badly-made driveline (forgot to use merge on the array) didn't throw an error and just exported a driveline with no quads, which segfaults STK. Again, it was a broken driveline so not really an issue)
aka. GumballForAPenny
User avatar
tempAnon093
 
Posts: 416
Joined: 02 Feb 2019, 12:09

Re: SuperTuxKart Exporter Tools/Scripts For Blender 2.80+

Postby McRavenINDo » 07 Dec 2020, 15:45

This tool works perfectly in Blender 2.91 for making Kart. Already test on Pepper and Revamped Gnu. :)
I am Blender User also the Gamer(average). I live in Indonesia.

The name is "ZAQraven99" forever.
https://www.artstation.com/zaqraven99


Youtube
https://www.youtube.com/channel/UCPJJph8bsXJc8HFohHLFAVQ
User avatar
McRavenINDo
 
Posts: 25
Joined: 09 Jul 2020, 15:15
Location: Indonesia

Re: SuperTuxKart Exporter Tools/Scripts For Blender 2.80+

Postby Worldblender » 20 Dec 2020, 04:05

Today I made a commit that enables hiding objects while still being able to export them: https://github.com/RQWorldblender/stk-b ... 12ef4f18f8
This consists of collecting all hidden objects and unhiding them, performing the export as usual by selecting individual objects, and then hiding those objects again. All of this happens in the background and users won't see objects being revealed during the export process, so it will look almost the same as from before the export process.

This is part of me trying to restore part of the old workflow from Blender workflow, but without having to stay on old Blender versions.
User avatar
Worldblender
 
Posts: 99
Joined: 15 Aug 2014, 18:46
Location: Houston, Texas, United States

Re: SuperTuxKart Exporter Tools/Scripts For Blender 2.80+

Postby Worldblender » 01 Feb 2021, 20:43

Today, my version of the Blender 2.80+ scripts have become an official part of STK. They can now be found at https://github.com/supertuxkart/stk-blender, in addition to my original repository. I will be updating the main website to include information about them.
User avatar
Worldblender
 
Posts: 99
Joined: 15 Aug 2014, 18:46
Location: Houston, Texas, United States

Re: SuperTuxKart Exporter Tools/Scripts For Blender 2.80+

Postby tempAnon093 » 01 Feb 2021, 21:29

Worldblender {l Wrote}:Today, my version of the Blender 2.80+ scripts have become an official part of STK. They can now be found at https://github.com/supertuxkart/stk-blender, in addition to my original repository. I will be updating the main website to include information about them.

Nice work! Thank you. :)
aka. GumballForAPenny
User avatar
tempAnon093
 
Posts: 416
Joined: 02 Feb 2019, 12:09

Re: SuperTuxKart Exporter Tools/Scripts For Blender 2.80+

Postby GeekPenguinBR » 02 Feb 2021, 02:49

Worldblender {l Wrote}:Today, my version of the Blender 2.80+ scripts have become an official part of STK. They can now be found at https://github.com/supertuxkart/stk-blender, in addition to my original repository. I will be updating the main website to include information about them.


Great job! Congrats and be sure your work will be very useful for us.
"Making cool harmless games makes the world a better place".
User avatar
GeekPenguinBR
 
Posts: 466
Joined: 22 Mar 2014, 00:41
Location: Rio de Janeiro

Who is online

Users browsing this forum: No registered users and 1 guest