Blender Export Script for Scorched3d models!

Post new topic Reply to topic  [ 121 posts ]  Go to page Previous  1 ... 4, 5, 6, 7, 8, 9  Next
Author Message
 Post subject:
PostPosted: Tue Nov 21, 2006 1:56 am 
User avatar
Desintigrated

Current Scorched3D Rank: Unranked






Joined: Sat Jun 12, 2004 12:53 am
Posts: 2884
Location: _____________________________ Current Scorched3d Rank: 1 _____________________________ *clink*
Good stuff, thanks. :)

I'll likely do another release soon - there's a couple other imporovements I'm thinking about first though.

Cheers

cbx
To be honest, I don't fully understand that page, but it sounds like it provides the answers you need. - Deathstryker

She doesn't stimulate me mentally or physically... I need at least one of those - Anonymous

Who wrote this crap? - G. Camp


Top
 Profile  
 
 Post subject:
PostPosted: Mon Jan 29, 2007 10:50 pm 
User avatar
Desintigrated

Current Scorched3D Rank: Unranked






Joined: Sat Jun 12, 2004 12:53 am
Posts: 2884
Location: _____________________________ Current Scorched3d Rank: 1 _____________________________ *clink*
I've released a new version, 1.5. See the uppermost post for download and release information.

Cheers,

cbx
To be honest, I don't fully understand that page, but it sounds like it provides the answers you need. - Deathstryker

She doesn't stimulate me mentally or physically... I need at least one of those - Anonymous

Who wrote this crap? - G. Camp


Top
 Profile  
 
 Post subject:
PostPosted: Tue Aug 07, 2007 12:42 am 
User avatar
Obliterated

Current Scorched3D Rank: Unranked



Joined: Wed Jun 14, 2006 11:18 pm
Posts: 1480
Location: United Kingdom
I know next to nothing about Blender, but I think they stopped including mesh_tri2quad from 2.43 on?

Nice script. (I like it when things work : )

I'm having trouble with smoothing groups. Everything I export from Blender ends up completely smooth. (The acsii files are also a lot bigger than those exported from Milkshape (maybe part of the same issue?)).

Is there any way to fix that? (Milkshape's next to useless for any serious models and doesn't seem to export smoothing groups at all).

I'm having to manually combine Milkshape/Blender .txt files at the moment.

Image

(Be cool if someone could write a Milkshape export script for 3DS Max).


Top
 Profile  
 
 Post subject:
PostPosted: Tue Aug 07, 2007 3:57 am 
User avatar
Desintigrated

Current Scorched3D Rank: Unranked






Joined: Sat Jun 12, 2004 12:53 am
Posts: 2884
Location: _____________________________ Current Scorched3d Rank: 1 _____________________________ *clink*
I'll have a look at the smoothing groups prob this week if I get a chance.

Don't have time to look at it right now, but something tells me I may have messed that up in a change a while back such that it now only looks at vertex normals and not face normals.

Thanks for the feedback, and give the topic a bump if I forget about it. ;)

cbx
To be honest, I don't fully understand that page, but it sounds like it provides the answers you need. - Deathstryker

She doesn't stimulate me mentally or physically... I need at least one of those - Anonymous

Who wrote this crap? - G. Camp


Top
 Profile  
 
 Post subject:
PostPosted: Fri Sep 21, 2007 8:06 am 
User avatar
Charred
Not Signed Up For Stats

Joined: Sun Aug 21, 2005 9:23 pm
Posts: 106
Location: Hungary
CBX I have a big problem, my machine crashed, so I loosed the belnder 2.42 installer, and your script dont work with the newest version of blender, please aid me thx.
"For the Emperor!!!!"

Top
 Profile  
 
 Post subject:
PostPosted: Fri Sep 21, 2007 8:19 am 
User avatar
Desintigrated

Current Scorched3D Rank: Unranked



Joined: Sat Dec 18, 2004 7:20 pm
Posts: 2015
Location: USA
Berem wrote:
CBX I have a big problem, my machine crashed, so I loosed the belnder 2.42 installer, and your script dont work with the newest version of blender, please aid me thx.


Just goto the blender site and redownload it. They should still have a copy of it to be downloaded.
Beware the VOID

When in doubt on why your mod broke...
it's all Bobirov's fault.


Top
 Profile  
 
 Post subject:
PostPosted: Fri Sep 21, 2007 1:46 pm 
User avatar
Charred
Not Signed Up For Stats

Joined: Sun Aug 21, 2005 9:23 pm
Posts: 106
Location: Hungary
Ohhh I dont find first, but I never thought that day should keep oldest versions from it, I searched with google on it, and I found it thx Jdog.
"For the Emperor!!!!"

Top
 Profile  
 
 Post subject:
PostPosted: Sun Sep 30, 2007 12:58 am 
User avatar
Desintigrated

Current Scorched3D Rank: Unranked






Joined: Sat Jun 12, 2004 12:53 am
Posts: 2884
Location: _____________________________ Current Scorched3d Rank: 1 _____________________________ *clink*
I updated to Blender 2.45 last night, and the script works (for me) without problems.
*** EDIT: Not true, sorry, I was only on 2.44 ***
Any more info on the issue would be helpful.

Laptop's Daddy wrote:
I know next to nothing about Blender, but I think they stopped including mesh_tri2quad from 2.43 on?

Not sure - I'm not actually using it (it never really worked as documented, in my experience), so if it's any problem, just delete that line.
To be honest, I don't fully understand that page, but it sounds like it provides the answers you need. - Deathstryker

She doesn't stimulate me mentally or physically... I need at least one of those - Anonymous

Who wrote this crap? - G. Camp


Top
 Profile  
 
 Post subject:
PostPosted: Sun Sep 30, 2007 3:53 pm 
User avatar
Desintigrated

Current Scorched3D Rank: Unranked






Joined: Sat Jun 12, 2004 12:53 am
Posts: 2884
Location: _____________________________ Current Scorched3d Rank: 1 _____________________________ *clink*
Fixed.

I've added a new release (1.5.1) - https://sourceforge.net/project/showfil ... _id=206650

cbx
To be honest, I don't fully understand that page, but it sounds like it provides the answers you need. - Deathstryker

She doesn't stimulate me mentally or physically... I need at least one of those - Anonymous

Who wrote this crap? - G. Camp


Top
 Profile  
 
 Post subject:
PostPosted: Tue Oct 23, 2007 10:04 am 
User avatar
Obliterated

Current Scorched3D Rank: Unranked



Joined: Wed Jun 14, 2006 11:18 pm
Posts: 1480
Location: United Kingdom
Ok, I need some help.

Script works perfectly (in that it doesn’t fail or crash and provides a usable ascii file), but I'm stuck with smoothing groups.

I've certainly hit the limit with Milkshape functionality.

If I'm going to take any Scorched mod (contest : ) to the next level, I must have smoothing groups.

Blender screenshot (half solid/half smooth sphere as exported):
Image

Scorched screenshot (with blenders export having been imported into Milkshape and re-exported to ascii):
Image


Any advice would be greatly appreciated.

Thanks


Ps:
Cbx, I'm assuming that smoothing groups are supported by Scorched? You're not just being accidentally very clever with your normals are you?

Thanks for the hard work; I know you're not obligated.


Top
 Profile  
 
 Post subject:
PostPosted: Tue Oct 23, 2007 1:56 pm 
User avatar
Site Admin
Not Signed Up For Stats

Joined: Mon Aug 04, 2003 4:09 pm
Posts: 4771
Location: Scotland
Quote:
Cbx, I'm assuming that smoothing groups are supported by Scorched?


They are not supported, the normals used are the normals in the file. If the file has the vertex normals correct then it will look ok in game.


Top
 Profile  
 
 Post subject:
PostPosted: Tue Oct 23, 2007 3:05 pm 
User avatar
Obliterated

Current Scorched3D Rank: Unranked



Joined: Wed Jun 14, 2006 11:18 pm
Posts: 1480
Location: United Kingdom
edited to allay confusion

laptops daddy wrote (this posts original contents, not as quote):


Quote:
ok, i think i see. i'm a little out of my depth. are you saying that there's a distinction between smoothing groups and vertex normals? and that scorched only uses the latter? so smoothing groups are(/should be) translated to normals at export, but aren't actually supported by the game per se?


gcamp (i guess) wrote:
(must have used special site access or something. possibly distracted? : )


Exactly right. The smooting groups are used to generate the normals.

So long as the exported normals are correct, everthing should be cool. However, I've just checked the Milkshape export format and the smoothing groups do apear to be in the milkshape file as well. So scorched could also change the normals based on these groups (which it currently doesn't do).

So I guess this could be fixed in scorched too.


Last edited by Laptops Daddy on Wed Oct 24, 2007 9:01 pm, edited 2 times in total.

Top
 Profile  
 
 Post subject:
PostPosted: Wed Oct 24, 2007 4:12 am 
User avatar
Desintigrated

Current Scorched3D Rank: Unranked






Joined: Sat Jun 12, 2004 12:53 am
Posts: 2884
Location: _____________________________ Current Scorched3d Rank: 1 _____________________________ *clink*
Laptops Daddy wrote:
Quote:
ok, i think i see. i'm a little out of my depth. are you saying that there's a distinction between smoothing groups and vertex normals? and that scorched only uses the latter? so smoothing groups are(/should be) translated to normals at export, but aren't actually supported by the game per se?


Exactly right. The smooting groups are used to generate the normals.

I'm a bit confused as to where that quote came from, but anyway..... ;)

Whomever the quote was from was exactly right - the smoothing groups *should* be translated to normals at export. The way the export script works now is that it uses vertex normals, always. I thought this was the correct behavior, in that I thought that Blender would adjust the vertex normals if it is using smoothing, and just use the face normals if not using smoothing.
I have never noticed anything wrong, but given the number of comments on this, I'm thinking perhaps my assumption was wrong. ;)
I will check.

Laptop: Any reason you imported into MilkShape after exporting from Blender? (I mostly ask because if there's a reason to do so, I may be able to remove that reason)

Quote:
So long as the exported normals are correct, everthing should be cool. However, I've just checked the Milkshape export format and the smoothing groups do apear to be in the milkshape file as well. So scorched could also change the normals based on these groups (which it currently doesn't do).

I disagree - I don't think Scorched should ever change normals - they should be as the modeller intended them to be.... I might be misunderstanding something here however.

So I guess this could be fixed in scorched too.[/quote]
To be honest, I don't fully understand that page, but it sounds like it provides the answers you need. - Deathstryker

She doesn't stimulate me mentally or physically... I need at least one of those - Anonymous

Who wrote this crap? - G. Camp


Top
 Profile  
 
 Post subject:
PostPosted: Wed Oct 24, 2007 8:16 am 
User avatar
Obliterated

Current Scorched3D Rank: Unranked



Joined: Wed Jun 14, 2006 11:18 pm
Posts: 1480
Location: United Kingdom
cbx550f wrote:
I'm a bit confused as to where that quote came from, but anyway..... ;)

: ) all very strange phantom quote. let me see if I can edit it…

Laptops Daddy wrote:
ok, i think i see. i'm a little out of my depth. are you saying that there's a distinction between smoothing groups and vertex normals? and that scorched only uses the latter? so smoothing groups are(/should be) translated to normals at export, but aren't actually supported by the game per se?

gcamp? (pretending to be lt daddy with special website powers) wrote:
Exactly right. The smooting groups are used to generate the normals...

that make more sense?

cbx550f wrote:
Laptop: Any reason you imported into MilkShape after exporting from Blender? (I mostly ask because if there's a reason to do so, I may be able to remove that reason)

really just to demonstrate the milkshape default behaviour. but if you're implying blender can export animated models, do it please?

cbx550f wrote:
I don't think Scorched should ever change normals - they should be as the modeller intended them to be...

i think the idea is scorched could potentially use the smoothing group information to extrapolate normals, i guess this is the intended milkshape behaviour. i suppose milkshape should really dictate how its ascii file is structured : )

on the other hand, scorched is way bigger than milkshape (maybe i'm biased). maybe it's time there was an s3d ascii format. (i.e. milkshape ascii, but with smoothing groups translated into normals?)

i had a look at the script. (barely speak a word of python, but)... could you do something like:

Code:
#normals
if blender ses it's solid:
   file.write('\n' + str(round(mesh.faces[i].no[0],4))) etc#use faces
else:#i.e. if it's smooth
   file.write('\n' + str(round(-mesh.faces[i].v[faceVerts-fv-1].no[0],4))) etc#use verts

?


Top
 Profile  
 
 Post subject:
PostPosted: Thu Oct 25, 2007 1:00 am 
User avatar
Obliterated

Current Scorched3D Rank: Unranked



Joined: Wed Jun 14, 2006 11:18 pm
Posts: 1480
Location: United Kingdom
cbx550f wrote:
I have never noticed anything wrong, but given the number of comments on this, I'm thinking perhaps my assumption was wrong. ;)

i think the comments may be all me (except for the one that wasn't), but please don't let that stop you, i'm at least two people

i can't be the only person who needs smoothing groups.

tank barrels are smooth


Top
 Profile  
 
Display posts from previous:  Sort by  
Post new topic Reply to topic  [ 121 posts ]  Go to page Previous  1 ... 4, 5, 6, 7, 8, 9  Next


Who is online

Users browsing this forum: Google [Bot] and 0 guests


You cannot post new topics in this forum
You cannot reply to topics in this forum
You cannot edit your posts in this forum
You cannot delete your posts in this forum
You cannot post attachments in this forum

Search for:
Jump to:  
cron
Powered by phpBB © 2000, 2002, 2005, 2007 phpBB Group