Jump to content


- - - - -

Blender Import/Export Scripts for .wso


26 replies to this topic

#1 Ceixari

    Rookie


  • 9 posts

Posted 23 May 2010 - 05:29 PM

Some of you may recognise me from MTS where I'm writing the Blender Object (S3ASC) Import/Export Scripts for the S3ObjTool exports.

As we now have the .wso specifications I've started writing the import script. I am now able to import objects (without the bones). I could load the import script for testing if people want, else I'll only do it once I've tested quite a few objects and of course added in the bones as well.

I'll keep updating this thread with my progress and if people have questions (or problems later) this would be the place to ask them. :)

#2 Murano

    TSR Support Staff


  • 982 posts
  • LocationSwitzerland

Posted 23 May 2010 - 07:17 PM

I'm very grateful for your effort to make a free tool environment around Workshop a reality. :--)

Good luck with the remaining scripting!

#3 pommes

    TSR Wizard Keeper


  • 101 posts

Posted 24 May 2010 - 07:44 AM

This is wonderful news!

As im kind of responsible for the workshop I´d gladly test the script or answer any question that you might have regarding the import/export procedure.

/micke

#4 johan-TSR

    TSR Technical Admin


  • 21 posts

Posted 24 May 2010 - 07:49 AM

Hello Ceixari!

It's really nice to see that you're working on Blender support for .wso :)
If you need any help with .wso/workshop related things please let us know and we'll do our best to help out.

When you feel ready i'd love to try it out (not very familiar with blender but what the heck) and help you test it!

#5 Ceixari

    Rookie


  • 9 posts

Posted 25 May 2010 - 08:50 PM

Thanks for the support. :nw:

I'm setting up a SourceForge project as I write this, so I can maintain a central repository of all my Blender 3D / Sims 3 scripts. It's at http://blender3dsims3.sourceforge.net and should have the relevant scripts available in the next day or so.

#6 Ceixari

    Rookie


  • 9 posts

Posted 26 May 2010 - 07:39 PM

I underestimated the complexities of the SourceForge process so have moved it to something a lot simpler: http://sites.google....pts4sims3tools/

Apologies for the swift change of mind.

#7 djehmli

    Team Mascot


  • 57 posts

Posted 26 May 2010 - 07:49 PM

Ceixari,

Thank you so much again for working on this.
My Patterns and other things
My current families: Thyme, Shui, Zamora, Drew, Jarlson and Myzer

#8 johan-TSR

    TSR Technical Admin


  • 21 posts

Posted 27 May 2010 - 09:33 AM

It's looking good! I've successfully imported a .wso to blender but i don't have a clue about how blender works :)

#9 Ceixari

    Rookie


  • 9 posts

Posted 28 May 2010 - 10:00 PM

I've updated the import script with the bones now, it doesn't make a lot of difference, since it looks like it's just there for reference.

http://sites.google..../blender-3d-wso

It does mean I can now start on the export script and since we have a bank holiday this weekend, I might have it done by then. :)

#10 Adri_M

    Just Registered


  • 1 posts

Posted 30 May 2010 - 01:03 PM

I can not say how grateful I am someone's doing this =). I came on with the intention of looking for an old forum to see if I could find any news. I've had blender for quite a long time though I admit I've hardly gotten a chance to master it but I'm more comfortable with it so what you are doing is just fantastic! Thank you so much! :D

#11 Ceixari

    Rookie


  • 9 posts

Posted 13 June 2010 - 12:23 PM

Quick update to say that I'm still working on this. I have been able to export a .wso and import it back into the Workshop and although the mesh looks fine the UV is off, so back to a bit of debugging.

#12 Ceixari

    Rookie


  • 9 posts

Posted 13 June 2010 - 05:01 PM

I've uploaded an initial export script, plus an update to the import script.

http://sites.google..../blender-3d-wso

I'm still fiddling with the UV, but I'm guessing if people change the mesh, they'll have to update the UVs as well as the textures, so might not be a biggie, but I'd like to get it working better for where people will rely on the existing UV and texture if the change is just a small fix/change.

Also please consider the scripts for more ideal when there is only a single bones as most objects do. Things like beds will not go down well.

#13 weirdchars

    Just Registered


  • 1 posts

Posted 21 June 2010 - 10:11 PM

There seems to be some issue with the import script. Specifically with the UV importing. If I comment out the following code and just work without original UVs it appears to work fine.

for i in xrange(0, len(meshData.faces)):
face = meshData.faces[i]
uv_verts0 = list_uv[face.verts[0].index]
uv_verts1 = list_uv[face.verts[1].index]
face.uv = [Vector(uv_verts0), Vector(uv_verts1)]

Throws the error "TypeError:Size of Vertex and UV sequences differ" in the Blender console and refuses to load. It fails on first iteration of loop where i = 0. This occurs regardless of the model/mesh you're loading. I tried several to be sure. Hope that is helpful.

Edit: I forgot to tell you, the specific line that throws error is
face.uv = [Vector(uv_verts0), Vector(uv_verts1)]

#14 Ceixari

    Rookie


  • 9 posts

Posted 23 June 2010 - 08:58 PM

Thanks for the report.

Could you also tell me which object you worked with so I can try to fix the problem?

Thanks again

#15 Vlana

    Just Registered


  • 4 posts

Posted 26 June 2010 - 10:52 AM

Hi !

I'm completly new to 3d, blender and so on, but I'm really exited to learn and try.

I have downloaded and installed Blender version 2.49b, then Python 2.6.5. I copied the wso import/export files to the .blender\scripts directory. I started Blender then tried to import a .wso file. I've had an error message. So, I tried with another .wso file, but had the same error message. You can see it in the jpg file I have attached to this post.

As I'm new to all this, I may do something wrong. Anyway, I would be happy to have some help. ;)

Attached Files



#16 pip218

    Just Registered


  • 1 posts

Posted 03 July 2010 - 09:51 AM

Hi I'm french so my English is the translation.
To begin, thank you, I try the export WSO with his hair but said script error.

#17 MandySA3

    Rookie


  • 12 posts

Posted 28 July 2010 - 06:08 AM

Hi. I am new to Blender and still trying to learn my way around but where do we put these import and export scripts for WSO? I have just installed the 2.53 Beta version of Blender (the stable version wasn't downloading properly for some reason). I can't find a 'scripts' directory anywhere on 2.53.

#18 Murano

    TSR Support Staff


  • 982 posts
  • LocationSwitzerland

Posted 28 July 2010 - 08:31 AM

I think these plug-ins only work with the stable version?

#19 MandySA3

    Rookie


  • 12 posts

Posted 02 August 2010 - 06:18 AM

I have the stable version of Blender 2.49 and python 2.6.4 and am still getting the error message weirdchars mentioned when trying to import. I have tried to import the cheerleader outfit and also the chef's outfit mesh 1.

#20 Kookas

    Just Registered


  • 1 posts

Posted 08 August 2010 - 07:05 PM

Hey Ceixari,

I have a couple of major issues with your scripts, both import and export. Import, unless the UV Mapping section is commented out, will report "TypeError: Size of Vertex and UV sequences differ". When I am exporting, I get this:

http://j.imagehost.o...tupidErrors.png (click to view image)





1 user(s) are reading this topic

0 members, 1 guests, 0 anonymous users