• We have updated our Community Code of Conduct. Please read through the new rules for the forum that are an integral part of Paradox Interactive’s User Agreement.

Shelltoe

First Lieutenant
Apr 4, 2015
235
63
couldn't upload it here for some reason. it's a zip with a 800cmx800cm cube exported from c4d without root node as 2010.0 ascii fbx and a converted to 2013.3 ascii.

and just made sure both import nicely for me
 
Last edited:

thomthom

Sergeant
8 Badges
Apr 11, 2015
50
6
www.thomthom.net
  • Cities: Skylines
  • Cities: Skylines - After Dark
  • Cities: Skylines - Snowfall
  • Surviving Mars
  • Surviving Mars: Digital Deluxe Edition
  • Surviving Mars: First Colony Edition
  • Surviving Mars: First Colony Edition
  • Cities: Skylines Deluxe Edition
The crash at game exit which I'm seeing seems to be related to the texture for the asset. When I removed the texture the game did not crash upon exit.
Originally my test texture (1024x2014) was a PNG. I thought it might be something with the format and converted it to JPEG. But still I get a crash.

Anyone got a sample texture that works for them?

(Oh, and that FBX cube - I diffed it to a similar cube from SketchUp and I see that SU inject two levels of nodes. CS seem to accept one extra level though.)
 

thomthom

Sergeant
8 Badges
Apr 11, 2015
50
6
www.thomthom.net
  • Cities: Skylines
  • Cities: Skylines - After Dark
  • Cities: Skylines - Snowfall
  • Surviving Mars
  • Surviving Mars: Digital Deluxe Edition
  • Surviving Mars: First Colony Edition
  • Surviving Mars: First Colony Edition
  • Cities: Skylines Deluxe Edition
1024x2014?? 1024x1024 typo? o_O
Indeed! Fat fingers towards the end of the day... o_O

Tried your texture - I still get a Stopped Working message upon exit. That's with my own FBX and textures, but also with that 800x800cm FBX and this smaller 256x256 texture map.

za9vp.png


2yl93b9.png


Now - it only happens during Exit - so it's not a show stopper. And I'm not sure if I see this message because I have Visual Studio installed and normal users might not see anything. Though the programmer in me is not liking this.
 

Shelltoe

First Lieutenant
Apr 4, 2015
235
63
as a programmer check your logs ;)

i'll check the cube with my texture. i'm on mac os x though and probably won't be able to boot windows today.

EDIT: No Error in Unity Debug Console or System logs. besides telling me intel hd 4600 isn't exactly a gaming gpu
 
Last edited:

Mr Maison

Colonel
13 Badges
May 9, 2013
866
706
  • Cities: Skylines
  • Cities: Skylines - After Dark
  • Cities: Skylines - Snowfall
  • Cities: Skylines - Mass Transit
  • Surviving Mars
  • Cities: Skylines - Green Cities
  • Surviving Mars: Digital Deluxe Edition
  • Cities: Skylines - Parklife
  • Surviving Mars: First Colony Edition
  • Cities: Skylines Industries
  • Surviving Mars: First Colony Edition
  • Cities: Skylines - Campus
  • Cities: Skylines Deluxe Edition
It happens to me all the time especially when quitting straight to desktop. I just ignore it for now as it doesn't seem to do any damage. But thanks for that thread. I missed that info.

ThomThom you are a godsend to us Sketchup users for this game. Seems your script will make the Sketchup route the easiest and quickest of all 3D SW options if it works as intended.
 
Last edited:

thomthom

Sergeant
8 Badges
Apr 11, 2015
50
6
www.thomthom.net
  • Cities: Skylines
  • Cities: Skylines - After Dark
  • Cities: Skylines - Snowfall
  • Surviving Mars
  • Surviving Mars: Digital Deluxe Edition
  • Surviving Mars: First Colony Edition
  • Surviving Mars: First Colony Edition
  • Cities: Skylines Deluxe Edition
Seems your script will make the Sketchup route the easiest and quickest of all 3D SW options if it works as intended.
Well, since the FBX exporter in SketchUp is Pro it somewhat limits the users. I'd think a good number of modders are Make users. I wonder if there are FBX console utilities out there - where one could then as a workaround export to collada and then convert to FBX. I dunno - that's one for later.
 

Shelltoe

First Lieutenant
Apr 4, 2015
235
63
http://download.autodesk.com/us/fbx...74-BD41-546EFA372706.htm,topicNumber=d30e3370

as there are no collada export options in SU you'll want to scale it during or before conversion

EDIT:
- export from SU to collada
- run FBXCONVERTER collada_file fbx_file /v /l /-e /f201300 /ascii
the converter seems to create a "take" but CSL shouldn't care about it

still requires 2.54 ingame scale as all floatpoints are in inch and CSL seemingly does not care about the colladascale
Code:
<unit meter="0.0254000" name="inch" />

<float_array id="ID8" count="174">157.4803150 157.4803150 0.0000000 -157.4803150 -157.4803150 0.0000000 ....

it doesn't seem to care about hardly anything besides the float_arrays
 
Last edited:

thomthom

Sergeant
8 Badges
Apr 11, 2015
50
6
www.thomthom.net
  • Cities: Skylines
  • Cities: Skylines - After Dark
  • Cities: Skylines - Snowfall
  • Surviving Mars
  • Surviving Mars: Digital Deluxe Edition
  • Surviving Mars: First Colony Edition
  • Surviving Mars: First Colony Edition
  • Cities: Skylines Deluxe Edition
as there are no collada export options in SU you'll want to scale it during or before conversion
You mean unit options? There's a bunch of other options available:
qn8tpk.png


And it's the only (I think) exporter which have exposed the options to the API:
http://www.sketchup.com/intl/en/developer/docs/ourdoc/model#export

Not sure how the collada format is in terms of units - maybe it's all world units... maybe that's why we don't have the unit options for this format. Need to look into that.

- run FBXCONVERTER collada_file fbx_file /v /l /-e /f201300 /ascii
Excellent! That's great!

This is all looking very promising. :)
 

Mr Maison

Colonel
13 Badges
May 9, 2013
866
706
  • Cities: Skylines
  • Cities: Skylines - After Dark
  • Cities: Skylines - Snowfall
  • Cities: Skylines - Mass Transit
  • Surviving Mars
  • Cities: Skylines - Green Cities
  • Surviving Mars: Digital Deluxe Edition
  • Cities: Skylines - Parklife
  • Surviving Mars: First Colony Edition
  • Cities: Skylines Industries
  • Surviving Mars: First Colony Edition
  • Cities: Skylines - Campus
  • Cities: Skylines Deluxe Edition
Well, since the FBX exporter in SketchUp is Pro it somewhat limits the users. I'd think a good number of modders are Make users.
Yeah...you're right. You think Autodesk FBX converter would change anything if users exported via dae or obj? That may be make users best hope for now.
 

Shelltoe

First Lieutenant
Apr 4, 2015
235
63
You mean unit options? There's a bunch of other options available:


And it's the only (I think) exporter which have exposed the options to the API:
http://www.sketchup.com/intl/en/developer/docs/ourdoc/model#export

Not sure how the collada format is in terms of units - maybe it's all world units... maybe that's why we don't have the unit options for this format. Need to look into that.



Excellent! That's great!

This is all looking very promising. :)

yeah unit option was available with version 7. 8 removed it :( (tried v7 but didn't help)

as far as i can tell CSL doesn't care about anything but the actual point arrays. you can remove almost everything inside the fbx and CSL will load the file.
the geometry float array has to be scaled x2.54 and you have to do some matrix calc to rotate them
there is a fbx sdk which might help.

everything seems to import nicely if you put ingame scale to 2.54 and "rotate X" 3 times though
 

thomthom

Sergeant
8 Badges
Apr 11, 2015
50
6
www.thomthom.net
  • Cities: Skylines
  • Cities: Skylines - After Dark
  • Cities: Skylines - Snowfall
  • Surviving Mars
  • Surviving Mars: Digital Deluxe Edition
  • Surviving Mars: First Colony Edition
  • Surviving Mars: First Colony Edition
  • Cities: Skylines Deluxe Edition
I cobbled together a prototype export-patcher: https://github.com/thomthom/cities-skylines-sketchup-tools/releases/tag/0.1.0
It will try to patch the exported FBX to remove the extra nodes in the hierarchy - as well as automatically set the needed export options.

Require SketchUp Pro 2014 or newer, Window only - for now. Once tested that it appear to work ok I'll try to adjust it for wider compatibility. The lack of OSX compatibility is just that I haven't had time to dig up my mac and find where the preferences are yet. It will be done later.

Please note that this is just a test version for now - it might not succeed. If you find issues then please report them in the GitHub repository: https://github.com/thomthom/cities-skylines-sketchup-tools/issues

Once it seem to be stable I'll release it officially on Extension Warehouse.
 

thomthom

Sergeant
8 Badges
Apr 11, 2015
50
6
www.thomthom.net
  • Cities: Skylines
  • Cities: Skylines - After Dark
  • Cities: Skylines - Snowfall
  • Surviving Mars
  • Surviving Mars: Digital Deluxe Edition
  • Surviving Mars: First Colony Edition
  • Surviving Mars: First Colony Edition
  • Cities: Skylines Deluxe Edition
took a quick look at your code. would it be possible to rotate and scale the mesh inside sketchup before exporting to dae?
Yes, one could apply scaling and rotation transformation on the mesh before invoking the exporter - then reset afterwards.

Been testing the extension with real models today and it seems to be working ok. I wrote up a summary for the exporter extension: http://www.thomthom.net/thoughts/2015/04/export-from-sketchup-to-cities-skylines/

I'll see to adding OSX compatibility next then start looking at other improvements.
 

Shelltoe

First Lieutenant
Apr 4, 2015
235
63
yeah exactly.

the OS X "registry" path you might be looking for should be "/Users/<user>/Library/Preferences/com.sketchup.SketchUp.2015.plist"
 
  • 1
Reactions: