|
export complete levels from blender
#208440
05/27/08 13:01
05/27/08 13:01
|
Joined: May 2002
Posts: 7,441
ventilator
OP
Senior Expert
|
OP
Senior Expert
Joined: May 2002
Posts: 7,441
|
export_gs_mdl7_static.pyexport_gs_$$m.pywith those scripts you can export whole levels from blender. it is an early version which needs cleanup, fool proofing, a gui and support for some more entity and surface flags but it already works. make your settings in export_gs_$$m.py here: scale = 32 mapcompiler = "d:/wwmp2wmb.exe" engine = "d:/acknex.exe" all selected objects with a name which starts with "__" will be exported as mesh, the other selected objects will be exported as model. features: - it supports two uv-sets for models (but the engine doesn't load the second uv-set yet) - it supports model instances - it supports modifiers without having to apply them (so you can use the edgesplit modifier to achieve correct smoothing for example) - it supports custom properties for skills, flags, action, material - it supports point lights notes: - creating mipmaps for mesh textures is slow with python (you could use dds textures which already have mipmaps but the map compiler seems to have a problem with dds at the moment)
|
|
|
Re: export complete levels from blender
[Re: ventilator]
#208472
05/27/08 16:20
05/27/08 16:20
|
Joined: Mar 2005
Posts: 969 ch
Loopix
User
|
User
Joined: Mar 2005
Posts: 969
ch
|
Hey vent...what have you done again!!! This sounds like a huge step foreward in leveling workflow...definately heaven for 3dgs-blendies. With "instancing" do you mean a "__model" object wich is copied and pasted in a blender scene will only "produce" a single mdl? Thanks for the great work...and definately keep working on it! You should get some money from conitec as this also makes 3dgs a lot more "leveler-friendly" thus first choice for many indies For me this takes away the last psycho-gui-hurden...let's learn Blender now!!!
|
|
|
Re: export complete levels from blender
[Re: Loopix]
#208476
05/27/08 16:33
05/27/08 16:33
|
Joined: May 2002
Posts: 7,441
ventilator
OP
Senior Expert
|
OP
Senior Expert
Joined: May 2002
Posts: 7,441
|
yes, instanced objects in blender (duplicated with alt-d) will produce only one mdl file. level geometry (object names with "__") won't use instancing of course since all level geometry is unique. (maybe i will think of a better solution than using "__" for specifying level geometry in the future.) i think there isn't much missing now to make blender a full alternative to wed.
|
|
|
Re: export complete levels from blender
[Re: Christian__A]
#208495
05/27/08 17:48
05/27/08 17:48
|
Joined: Oct 2007
Posts: 5,210 Ä°stanbul, Turkey
Quad
Senior Expert
|
Senior Expert
Joined: Oct 2007
Posts: 5,210
Ä°stanbul, Turkey
|
great, i started to learn Blender this week. This will make me more happy with it.
3333333333
|
|
|
Re: export complete levels from blender
[Re: Quad]
#208656
05/28/08 17:06
05/28/08 17:06
|
Joined: Jul 2002
Posts: 1,364 Minbar
MaxF
Serious User
|
Serious User
Joined: Jul 2002
Posts: 1,364
Minbar
|
Hi ventilator Do you what to build the same for Modo? They use Python and have a SDK for import/export Do you have Modo?
|
|
|
Re: export complete levels from blender
[Re: lostclimate]
#209125
06/01/08 07:15
06/01/08 07:15
|
Joined: May 2002
Posts: 7,441
ventilator
OP
Senior Expert
|
OP
Senior Expert
Joined: May 2002
Posts: 7,441
|
it would be great if duplicated objects, could all be saved as 1 mdl file that would be placed around the wmp. yes, that's what instancing does. objects which are linked to the same mesh data (which happens if you duplicate an object with alt-d) and which don't use modifiers which alter the mesh shape will only produce one mdl file. doesn't it work for you?
|
|
|
Re: export complete levels from blender
[Re: ventilator]
#209126
06/01/08 07:22
06/01/08 07:22
|
Joined: Oct 2005
Posts: 4,771 Bay City, MI
lostclimate
Expert
|
Expert
Joined: Oct 2005
Posts: 4,771
Bay City, MI
|
oh, i didnt check, just thought I'd throw that out.... thats awesome, never using wed except just to assign actions
Edit: actually nvm, seems thats already covered.
Edit: 2 what about animation?
Last edited by lostclimate; 06/01/08 07:35.
|
|
|
Re: export complete levels from blender
[Re: ventilator]
#209129
06/01/08 08:07
06/01/08 08:07
|
Joined: Oct 2005
Posts: 4,771 Bay City, MI
lostclimate
Expert
|
Expert
Joined: Oct 2005
Posts: 4,771
Bay City, MI
|
objects exported with animation would be good for swaying trees, windmills, etc, I think it would be very useful. for some reason instancing isnt working for me, im not sure why but heres a quick thing I made : http://rapidshare.com/files/119320806/testlevel.zip.htmlI want to edit the trees and add a shader to there material, but I dont want to go thru and do it to every tree.
Last edited by lostclimate; 06/01/08 14:28.
|
|
|
Re: export complete levels from blender
[Re: Nowherebrain]
#210192
06/08/08 20:26
06/08/08 20:26
|
Joined: May 2002
Posts: 7,441
ventilator
OP
Senior Expert
|
OP
Senior Expert
Joined: May 2002
Posts: 7,441
|
no, the engine doesn't draw into the blender window. i think this would only be possible if the engine used opengl too. the engine just gets started directly from blender. two small additions: - support for models which don't have any uv-coordinates and textures - blender curves get exported as gamestudio paths i will have to write some simple editor for setting path skills though because blender natively of course doesn't have this just like wed. export_gs_mdl7_static.pyexport_gs_map.py (i had to change the script name because with $ in it you can't import it from other scripts like i want to do later from the gui script.)
|
|
|
Re: export complete levels from blender
[Re: ventilator]
#210248
06/09/08 10:07
06/09/08 10:07
|
Joined: Jul 2005
Posts: 1,002 Trier, Deutschland
Nowherebrain
Serious User
|
Serious User
Joined: Jul 2005
Posts: 1,002
Trier, Deutschland
|
cool still, starting the engine is just as good!
"export_gs_map.py (i had to change the script name because with $ in it you can't import it from other scripts like i want to do later from"
-good forward thinking.
..is it my install or is there no more .blend folder for plugins?
EDIT: I created my own plugins dir.
Last edited by Nowherebrain; 06/09/08 11:21.
|
|
|
Re: export complete levels from blender
[Re: ventilator]
#210347
06/09/08 23:32
06/09/08 23:32
|
Joined: Jul 2005
Posts: 1,002 Trier, Deutschland
Nowherebrain
Serious User
|
Serious User
Joined: Jul 2005
Posts: 1,002
Trier, Deutschland
|
I have show hidden files on...so I possibly thinking myself in circles...sorry, I still don't have a .blend folder. I do have a plugin folder though so no issues....besides I have wasted enough thread space with my .blend file
Last edited by Nowherebrain; 06/09/08 23:35.
|
|
|
Re: export complete levels from blender
[Re: Nowherebrain]
#210401
06/10/08 11:44
06/10/08 11:44
|
Joined: May 2002
Posts: 7,441
ventilator
OP
Senior Expert
|
OP
Senior Expert
Joined: May 2002
Posts: 7,441
|
you could uninstall blender and download blender as zip and just extract that zip. that's what i always do. i never have installed blender. or you could ask jetpackmonkey. she had the same problem if i understood this correctly and she was able to choose the location of the .blender directory with the installer or so. do you use xp or vista? maybe you need to be administrator with vista? I have wasted enough thread space i have no problem with that! that's what forums are for. <edit> i came across this: http://blenderartists.org/forum/showthread.php?p=1136878#post1136878</edit>
|
|
|
Re: export complete levels from blender
[Re: ventilator]
#210494
06/11/08 00:01
06/11/08 00:01
|
Joined: Jul 2005
Posts: 1,002 Trier, Deutschland
Nowherebrain
Serious User
|
Serious User
Joined: Jul 2005
Posts: 1,002
Trier, Deutschland
|
yep..that's it, I change the file path on my most used programs to not be in "program files"....,but by setting my own plugins folder it is essentially the same...thanks though at least I know I am not crazy or have some strange virus. also check out the texture splatting video from the apricot build... texture slatting in blender RT. or save target/save target as..with RMB
Last edited by Nowherebrain; 06/11/08 00:03.
|
|
|
Re: export complete levels from blender
[Re: Nowherebrain]
#218763
07/30/08 13:08
07/30/08 13:08
|
Joined: May 2002
Posts: 7,441
ventilator
OP
Senior Expert
|
OP
Senior Expert
Joined: May 2002
Posts: 7,441
|
no, i didn't do any further work yet but it has proven to be very useful already for my projects. actually it does all i personally need at the moment. what do you think would be most important to add? by the way, in case you get problems because of spaces in your map compiler and engine paths you should change those lines (add the ' " '):
os.spawnl(os.P_WAIT, mapcompiler, '"'+mapcompiler+'"', name + ".$$m", "-pal", "palette.pcx", "-dialog")
os.spawnl(os.P_NOWAIT, engine, '"'+engine+'"', name + ".wmb")
|
|
|
Re: export complete levels from blender
[Re: ventilator]
#222492
08/19/08 17:08
08/19/08 17:08
|
Joined: Sep 2007
Posts: 3
Rednax
Guest
|
Guest
Joined: Sep 2007
Posts: 3
|
Hi to you all thanx to you ventilator for this good contribution to the community^^ but i have a problem to export the whole map^^ i just startet with a little plane and textur but when i try to export the map i ever get an error... here is a picture of the error^^ i have edit the export_gs_mdl7_static.py file with: scale = 32 mapcompiler = "C:\Program Files\GStudio7\wwmp2wmb.exe" engine = "C:\Program Files\GStudio7\acknex.exe" sunazimuth = 0 do i must add something more??? thx to you all... and pls help
|
|
|
Re: export complete levels from blender
[Re: ventilator]
#222497
08/19/08 17:23
08/19/08 17:23
|
Joined: Sep 2007
Posts: 3
Rednax
Guest
|
Guest
Joined: Sep 2007
Posts: 3
|
hmm the textur is in the same direction... not in the blend file just loaded as jpg...
but i dont know... maybe i done something wrong...
i downloaded the 2 files and placed it in the scripts folder then i added the line what i written before (maybe add more to the script?)
and then tryed to export...
Last edited by Rednax; 08/19/08 17:24.
|
|
|
Re: export complete levels from blender
[Re: Rednax]
#222507
08/19/08 17:59
08/19/08 17:59
|
Joined: May 2002
Posts: 7,441
ventilator
OP
Senior Expert
|
OP
Senior Expert
Joined: May 2002
Posts: 7,441
|
is the path of the image correct if you check it in the image editor? is it relative or absolute? could you provide your files so i can have a look? <edit> oh! jpg is no good since gamestudio doesn't support it for model textures i think but it shouldn't be the reason for the error. as a quick workaround you could add a # in front of the line which calls copyfile() in the write() method of the c_exporter() class in export_gs_mdl7_static.py. you have to to manually copy the textures to the target folder then. </edit>
|
|
|
Re: export complete levels from blender
[Re: ventilator]
#222525
08/19/08 19:46
08/19/08 19:46
|
Joined: Sep 2007
Posts: 3
Rednax
Guest
|
Guest
Joined: Sep 2007
Posts: 3
|
i think i found the mistake i made^^ first i used a jpg and not included it in the .blend file... so but the problem not ends sorry for annoy you with this problem... the map compiles with gamestudio but in the end there is another problem! not the whole map compiles only the model i selected^^ here is the error... just another picture...
|
|
|
Re: export complete levels from blender
[Re: Rednax]
#222529
08/19/08 19:59
08/19/08 19:59
|
Joined: May 2002
Posts: 7,441
ventilator
OP
Senior Expert
|
OP
Senior Expert
Joined: May 2002
Posts: 7,441
|
only selected objects will get exported. if you want to export the whole scene, you just have to select all objects by pressing [a] before exporting. a texture size of 2000x2000 is not ideal for gamestudio. better use 2048x2048. blender_level_exporter.zipmake sure you use this latest version. it can handle map compiler and engine paths with spaces in them. it sounds like this has caused your new error message.
|
|
|
Re: export complete levels from blender
[Re: ventilator]
#242481
12/23/08 13:21
12/23/08 13:21
|
Joined: Jan 2008
Posts: 20 On the right track
Rayn
Newbie
|
Newbie
Joined: Jan 2008
Posts: 20
On the right track
|
Yahoo, I solved it!
It works if I start by assigning an action-string to the Blender-mesh and then assign a material-string. I just didn't know that I couldn't have the material without an action-property also connected to the mesh.
Last edited by Rayn; 12/23/08 16:55.
|
|
|
Re: export complete levels from blender
[Re: Rayn]
#243918
01/01/09 17:50
01/01/09 17:50
|
Joined: Jul 2005
Posts: 1,002 Trier, Deutschland
Nowherebrain
Serious User
|
Serious User
Joined: Jul 2005
Posts: 1,002
Trier, Deutschland
|
I'm getting an unusual error with a traceback or path or some thing...I don't know if you can make any sense of this.
the last statements made in the cosole.....
filename: c:\Valiant Black\terrain\build01\water_bucket.mdl object "water_bucket": texture "barrel": 512x512 texture "barrel_water": 256x256 213 uvs 62 vertices 120 faces "barrel.bmp" copied to target folder "barrel_water.bmp" copied to target folder static mdl7 export done in 0.141971908946 seconds! static mdl7 export filename: c:\Valiant Black\terrain\build01\tree_swamp.mdl object "tree_swamp": texture "leaves": 512x512 texture "bark_03": 1024x1024 211 uvs 228 vertices Traceback (most recent call last): File "E:\Blender\.blender\scripts\export_gs_map.py", line 493, in export write(path, name) File "E:\Blender\.blender\scripts\export_gs_map.py", line 453, in write export_gs_mdl7_static.write(sys.join(path, mdlname), [o], scale) File "E:\Blender\.blender\scripts\export_gs_mdl7_static.py", line 562, in writ e exporter.write(filename) File "E:\Blender\.blender\scripts\export_gs_mdl7_static.py", line 474, in writ e self.exporttriangles(mesh, group) File "E:\Blender\.blender\scripts\export_gs_mdl7_static.py", line 536, in expo rttriangles if SS_TRIANGLE == 26: t.adduvset(uvs.index(fuv[1][2]), uvs.index(fuv[1][1]), uvs.index(fuv[1][0]), ti[1]) TypeError: 'NoneType' object is unsubscriptable
...... The odd thing is I can compile and run every object individually in the .blend by using your lvl exporter, but as a whole I get these errors.
EDIT: GOT IT! strange, it was a bad UV I guess...I looked at the console again and thought about it....for about 10 min. because I knew I had checked the uv's on my models...I added one model since and I guess it had a bad UV???? deleting and creating a new UV did the trick.
Last edited by Nowherebrain; 01/01/09 18:14.
|
|
|
Re: export complete levels from blender
[Re: Nowherebrain]
#256321
03/16/09 07:05
03/16/09 07:05
|
Joined: May 2002
Posts: 7,441
ventilator
OP
Senior Expert
|
OP
Senior Expert
Joined: May 2002
Posts: 7,441
|
http://www.conitec.net/beta/prog_mdlhmp.htmlthat's nice! jcl released the specifications of the wmb format. directly going to the wmb format would have many advantages. no need for going through the slow map compiler anymore, no need for letting the map compiler do ugly tesselation of the level geometry, export lightmapped level geometry directly from blender, the lite-c editions which don't come with wed and the map compiler can read wmb i think,... i don't use gamestudio much at the moment but probably i will work on a wmb version of this exporter nevertheless if i find some time. exporter writing is kind of fun.
|
|
|
Re: export complete levels from blender
[Re: ventilator]
#256640
03/17/09 21:51
03/17/09 21:51
|
Joined: Mar 2009
Posts: 112 Germany
KDuke
Member
|
Member
Joined: Mar 2009
Posts: 112
Germany
|
WHOOT! That would be freaking great! Do you have any idea how long this would take to complete ventilator? And thanks for your already existing exporter, as well as for at least already thinking about including lightmaps into the exporter ^^!
greetings KDuke
Using A7 Free Click and join the 3dgs irc community! Room: #3dgs
|
|
|
Re: export complete levels from blender
[Re: ventilator]
#256685
03/18/09 10:58
03/18/09 10:58
|
Joined: Oct 2007
Posts: 5,210 Ä°stanbul, Turkey
Quad
Senior Expert
|
Senior Expert
Joined: Oct 2007
Posts: 5,210
Ä°stanbul, Turkey
|
a fast and blunt, how to use tutorial (on a cube with a light and an entity?) would be cool too. then blender shall be the new level editör of Gamestudio.
3333333333
|
|
|
Re: export complete levels from blender
[Re: Quad]
#257195
03/21/09 11:43
03/21/09 11:43
|
Joined: Sep 2003
Posts: 5,900 Bielefeld, Germany
Pappenheimer
Senior Expert
|
Senior Expert
Joined: Sep 2003
Posts: 5,900
Bielefeld, Germany
|
Just tried to create a second skin in blender and got it! - yeah, I didn't find out before, didn't expect that it is that easy - and now I have to say: Go for it, ventilator! Maybe, it could be of use for me within the next days! :P Its, because my fish game shall get a background with an ocean 'landscape' yet! Never planned that. But I have to do it.
|
|
|
Re: export complete levels from blender
[Re: ventilator]
#257202
03/21/09 12:44
03/21/09 12:44
|
Joined: Sep 2003
Posts: 5,900 Bielefeld, Germany
Pappenheimer
Senior Expert
|
Senior Expert
Joined: Sep 2003
Posts: 5,900
Bielefeld, Germany
|
Okay, no problem! I wasn't aware that the exporter already exports two uv-sets. That is absolutely sufficient to me at the moment, because I don't use any collision anyway!
I wasn't aware that I can download your tutorials that you made with wink, too. I just downloaded the available parts of your tutorial. They are very helpful. Just found out that you gave some advices in the exporting part that I absolutely missed, although I already exported a lot of models from blender to 3DGS.
Any chance to get the other parts of it? Maybe, someone else could host them? Or, are they available at one of the blender forums?
|
|
|
Re: export complete levels from blender
[Re: Pappenheimer]
#257764
03/25/09 12:22
03/25/09 12:22
|
Joined: May 2002
Posts: 7,441
ventilator
OP
Senior Expert
|
OP
Senior Expert
Joined: May 2002
Posts: 7,441
|
i found a much faster way to generate the list of uvs. currently i do this in a very stupid way for python like: uvs = []
...
if uv not in uvs:
uvs.append(uv) and later when i write out the triangles i look up the uv indices like that: this scales very badly with objects that have ten thousands of vertices. if done with a set and dictionary like that:
uvs = set()
...
uvs.add(uv) and: # convert set to dictionary with indices
uvs = dict([(k, v) for v, k in enumerate(uvs)])
# index loopup
uvs[uv] an object with ten thousands of vertices takes the blink of an eye instead of minutes. :p probably i will upload a new corrected version soon. still didn't have time for the wmb version though.
|
|
|
Re: export complete levels from blender
[Re: ventilator]
#257820
03/25/09 18:20
03/25/09 18:20
|
Joined: Jun 2008
Posts: 151 Ukraine
XD1v0
Member
|
Member
Joined: Jun 2008
Posts: 151
Ukraine
|
Impressive, in 10 times faster that previous version i tested on this level(lot of textures and vertices)
Last edited by XD1v0; 03/25/09 18:25.
A7 Commercial Celeron 1700, GeForce 5500 FX 256mb, 1 Gb Ram
|
|
|
Re: export complete levels from blender
[Re: KiwiBoy]
#268622
05/30/09 10:23
05/30/09 10:23
|
Fear411
Unregistered
|
Fear411
Unregistered
|
you have to install phyton 2.5 not 3
|
|
|
Re: export complete levels from blender
[Re: ventilator]
#273501
06/23/09 09:01
06/23/09 09:01
|
Joined: Oct 2005
Posts: 4,771 Bay City, MI
lostclimate
Expert
|
Expert
Joined: Oct 2005
Posts: 4,771
Bay City, MI
|
the second uv set is in!, woot!. hey, since you seem to know the most out of everyone i know about blender, is there a way to get two seperate uv sets to work on a material, I want to be able to see my lightmaps in the viewport, but even with glsl on, i cant get seperate uvs on the textures.
|
|
|
Re: export complete levels from blender
[Re: lostclimate]
#273505
06/23/09 09:13
06/23/09 09:13
|
Joined: May 2002
Posts: 7,441
ventilator
OP
Senior Expert
|
OP
Senior Expert
Joined: May 2002
Posts: 7,441
|
yes, i think you just have to enter the proper uv-set in the "map input" panel of the material's textures. when i tried to display lightmaps in blender's viewports a while ago my problem was that i couldn't achieve a modulate2x like gamestudio uses for lightmaps. blender's multiply blending mode is the equivalent of direct3d's modulate. but i am no expert about blender's material system. i find it quite confusing. it's the area where i agree with all the blender gui criticism.
|
|
|
Re: export complete levels from blender
[Re: lostclimate]
#273511
06/23/09 09:34
06/23/09 09:34
|
Joined: Oct 2005
Posts: 4,771 Bay City, MI
lostclimate
Expert
|
Expert
Joined: Oct 2005
Posts: 4,771
Bay City, MI
|
ok, new question, since before as far as flags go you said only 1-8 and polygon were set up, so what do i do for passable objects?
edit: also im not sure how im going to get animated ents in the level now either....
Last edited by lostclimate; 06/23/09 09:44.
|
|
|
Re: export complete levels from blender
[Re: lostclimate]
#273516
06/23/09 09:47
06/23/09 09:47
|
Joined: May 2002
Posts: 7,441
ventilator
OP
Senior Expert
|
OP
Senior Expert
Joined: May 2002
Posts: 7,441
|
you have to add support for it in this function:
def customproperties(o):
f1=f2=f3=f4=f5=f6=f7=f8 = 0
polygon = 1
s1=s2=s3=s4=s5=s6=s7=s8=s9=s10=s11=s12=s13=s14=s15=s16=s17=s18=s19=s20 = 0
action = "ndef"
material = "ndef"
substitute = None
for p in o.getAllProperties():
if p.getType() == "BOOL":
if p.getName() == "flag1": f1 = p.getData()
if p.getName() == "flag2": f2 = p.getData()
if p.getName() == "flag3": f3 = p.getData()
if p.getName() == "flag4": f4 = p.getData()
if p.getName() == "flag5": f5 = p.getData()
if p.getName() == "flag6": f6 = p.getData()
if p.getName() == "flag7": f7 = p.getData()
if p.getName() == "flag8": f8 = p.getData()
if p.getName() == "polygon": polygon = p.getData()
if p.getType() == "FLOAT":
if p.getName() == "skill1": s1 = p.getData()
if p.getName() == "skill2": s2 = p.getData()
if p.getName() == "skill3": s3 = p.getData()
if p.getName() == "skill4": s4 = p.getData()
if p.getName() == "skill5": s5 = p.getData()
if p.getName() == "skill6": s6 = p.getData()
if p.getName() == "skill7": s7 = p.getData()
if p.getName() == "skill8": s8 = p.getData()
if p.getName() == "skill9": s9 = p.getData()
if p.getName() == "skill10": s10 = p.getData()
if p.getName() == "skill11": s11 = p.getData()
if p.getName() == "skill12": s12 = p.getData()
if p.getName() == "skill13": s13 = p.getData()
if p.getName() == "skill14": s14 = p.getData()
if p.getName() == "skill15": s15 = p.getData()
if p.getName() == "skill16": s16 = p.getData()
if p.getName() == "skill17": s17 = p.getData()
if p.getName() == "skill18": s18 = p.getData()
if p.getName() == "skill19": s19 = p.getData()
if p.getName() == "skill20": s20 = p.getData()
if p.getType() == "STRING":
if p.getName() == "action": action = p.getData()
if p.getName() == "material": material = p.getData()
if p.getName() == "substitute": substitute = p.getData()
skills = (s1,s2,s3,s4,s5,s6,s7,s8,s9,s10,s11,s12,s13,s14,s15,s16,s17,s18,s19,s20)
flags = (0,0,0,0,0,polygon,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,f1,f2,f3,f4,f5,f6,f7,f8)
return action, skills, flags, material, substitute
it's easy. the only problem is figuring out which of the zeros in flags = (...) is the passable flag and i don't have time for that now. you have to save some simple test $$m from wed.
|
|
|
Re: export complete levels from blender
[Re: LIGHTSPIKE]
#273946
06/25/09 03:45
06/25/09 03:45
|
Joined: May 2002
Posts: 7,441
ventilator
OP
Senior Expert
|
OP
Senior Expert
Joined: May 2002
Posts: 7,441
|
edit: also im not sure how im going to get animated ents in the level now either.... export the animated model separately with the other exporter. add the property "substitute" and specify the filename of the previously exported model. the object won't get exported then but only be referenced in the $$m file. hey ventilator the second link is broken you mean export_gs_$$m.py? i changed the filename to export_gs_map.py.
|
|
|
Re: export complete levels from blender
[Re: ventilator]
#273954
06/25/09 04:37
06/25/09 04:37
|
Joined: Oct 2005
Posts: 4,771 Bay City, MI
lostclimate
Expert
|
Expert
Joined: Oct 2005
Posts: 4,771
Bay City, MI
|
yikes, thats a little... inefficient you ever consider working with appended files?
EDIT: i feel like an asshole asking aobut all these free features and complaining, your work already is very appreciated.
Last edited by lostclimate; 06/25/09 04:38.
|
|
|
Re: export complete levels from blender
[Re: lostclimate]
#273957
06/25/09 04:52
06/25/09 04:52
|
Joined: May 2002
Posts: 7,441
ventilator
OP
Senior Expert
|
OP
Senior Expert
Joined: May 2002
Posts: 7,441
|
what do you mean with appended files? the "substitute" option did the trick for me. i am not sure how to solve the animation thing in a better way. i think if you have a level filled with different animated character models then always exporting all models and all animations could take a while. it would have to be cached somehow. the animations only exported again if something changed... i know that the exporter isn't really finished. after it did what i needed i lacked the motivation to polish it. polishing a program often is very boring and uninteresting work. ...and for myself it's no problem to add new features on the fly in case i need anything.
|
|
|
Re: export complete levels from blender
[Re: ventilator]
#273966
06/25/09 07:06
06/25/09 07:06
|
Joined: Oct 2005
Posts: 4,771 Bay City, MI
lostclimate
Expert
|
Expert
Joined: Oct 2005
Posts: 4,771
Bay City, MI
|
havent checked it yet, since all i was doing until I got a reply was making a default action to make the object passable.
thanks for looking into it. If i had money right now i'd donate since this is really an amazing contribution. cant wait until we can directly compile wmb's from blender, I wonder if its possible for pro users to manually set up a bsp system, in blender, using the structs predefined in the wmb description, not that I have pro, but it would be interesting to see.
|
|
|
Re: export complete levels from blender
[Re: Pappenheimer]
#276226
07/03/09 21:29
07/03/09 21:29
|
Joined: Sep 2003
Posts: 5,900 Bielefeld, Germany
Pappenheimer
Senior Expert
|
Senior Expert
Joined: Sep 2003
Posts: 5,900
Bielefeld, Germany
|
Guess what? I got it working! I have to save the blend file with the second skin, before I export it. Nonetheless, a further question: - Does it need a special material setting to see the combination of the skins ingame? At least, the preview in MED doesn't show both at once.
|
|
|
Re: export complete levels from blender
[Re: Pappenheimer]
#276336
07/04/09 15:12
07/04/09 15:12
|
Joined: Sep 2003
Posts: 5,900 Bielefeld, Germany
Pappenheimer
Senior Expert
|
Senior Expert
Joined: Sep 2003
Posts: 5,900
Bielefeld, Germany
|
I'm getting closer to a solution, although I don't understand all things. The "lighting_baking.avi" from Yo Frankie DVD helped me. The tutorial is extremely fast, I had to stop it several times, and I compared the settings seen and changed in the video to mine in blender and vice versa. I see the mix of the 2 textures in the material preview now. If anybody can give an advice how to "apply" this mix to the object in the 3D view as well, it would be appreciated!
|
|
|
Re: export complete levels from blender
[Re: Nowherebrain]
#276388
07/04/09 20:43
07/04/09 20:43
|
Joined: Sep 2003
Posts: 5,900 Bielefeld, Germany
Pappenheimer
Senior Expert
|
Senior Expert
Joined: Sep 2003
Posts: 5,900
Bielefeld, Germany
|
Hi Nowherebrain, your good video tutorials are well known! Thank you very much for your offer, but making a video seems to much of an effort for just me being too dumb to find a single switch or such. I loaded up a small test file, maybe, it is the easiest way to have a look at it and point me to what I missed to do. http://www.puppenheim.org/blend_texture_test.zip
|
|
|
Re: export complete levels from blender
[Re: Nowherebrain]
#276395
07/04/09 21:17
07/04/09 21:17
|
Joined: Jul 2005
Posts: 1,002 Trier, Deutschland
Nowherebrain
Serious User
|
Serious User
Joined: Jul 2005
Posts: 1,002
Trier, Deutschland
|
I assume the kissenfischbaked.tga is the shadow map?...it was not included...no problem. you have the basic setup right, 2 textures/one material. on the UV maps in the mesh edit stuff set the active UV to the shade UV to bake to it(*you bake to the active, from the renderable UV*). Yours is correctly setup for the bake. *important* it will bake to the image assigned to the mesh in the UV image editor...so with your faces selected, go to the UV image editor and select the image you want to bake to(shadows)from the drop down menu. In the render buttons go to the bake tab, then select shadow. click bake.....it should be rendering to the image in the editor...
Now... in the material editor under the texture tab select the shadow map texture. go to the map input and select uv...type the UV name in the empty field(shade in this case). go to the "map to" tab and select multiply(you have done this already), and adjust the Col(coloring)value until you are happy. one last thing in the top menu(file, add, time line, game)in the game menu select Blender GLSL materials...this was not checked and may be the big issue you are having. ...I hope I covered it all as I typed and alt tabbed back and forth checking stuff. If this is not helpfull I will still do a video...it is no problem.
|
|
|
Re: export complete levels from blender
[Re: ventilator]
#276403
07/04/09 21:54
07/04/09 21:54
|
Joined: Jul 2005
Posts: 1,002 Trier, Deutschland
Nowherebrain
Serious User
|
Serious User
Joined: Jul 2005
Posts: 1,002
Trier, Deutschland
|
Yes, there is the second build up with Farsthary's FG(I've toyed with them and they are functional)...as you can tell from your thread there are quite a few Blender heads here....growing daily.
Last edited by Nowherebrain; 07/04/09 21:54.
|
|
|
Re: export complete levels from blender
[Re: Nowherebrain]
#276405
07/04/09 22:12
07/04/09 22:12
|
Joined: Sep 2003
Posts: 5,900 Bielefeld, Germany
Pappenheimer
Senior Expert
|
Senior Expert
Joined: Sep 2003
Posts: 5,900
Bielefeld, Germany
|
bake with an empty material(white) and ao on. Do a full bake and you will have ao and shadows in one pass. Assign the texture in another material after the color. BTW: I am uploading a quick and dirty tut now to you tube. [video:youtube] http://www.youtube.com/watch?v=ts7sXIzw1X0[/video] That was fast! Enjoyed it! Gave me even additional hints how to use blender for such tasks! Great job!
|
|
|
Re: export complete levels from blender
[Re: Nowherebrain]
#278547
07/14/09 12:29
07/14/09 12:29
|
Joined: May 2002
Posts: 7,441
ventilator
OP
Senior Expert
|
OP
Senior Expert
Joined: May 2002
Posts: 7,441
|
switching from python 2.x to 3.x shouldn't be a big deal. the biggest difference of 3.x is that all strings are unicode and for binary data there is a new separate type "bytes". this could require some small changes in my code. ...but blender 2.5 will have a totally new api. from what i have seen so far i would say that i will have to rewrite about 50% of the exporters because of that. i will think about hmp...
|
|
|
Re: export complete levels from blender
[Re: Nowherebrain]
#293783
10/13/09 19:33
10/13/09 19:33
|
Joined: Oct 2005
Posts: 4,771 Bay City, MI
lostclimate
Expert
|
Expert
Joined: Oct 2005
Posts: 4,771
Bay City, MI
|
hey vent, i realize this isnt really 100% related to this thread because its more about the model exporter itself, but is there a way to export the texture list connected to the material connected to the object? also is there a way to determine what that particular texture affects on the material, the reason I ask is then I can add normal and spec maps to models and have them export directly to 3dgs the way they look in blender. (so lets say in blender I am in glsl mode, I add a normal and spec map, and have them selected, when it gets exported the script determines that the normal button is selected, it adds a normal map script, if i have spec map selected too it adds a spec map/ normal map shader). Im not asking you to do this, you've alredy done a tremendous job especially for free. but I wondered if you thought it'd be possible since I am contemplating learning a little python to be able to do it myself.
|
|
|
Re: export complete levels from blender
[Re: ventilator]
#304063
01/04/10 20:44
01/04/10 20:44
|
Joined: Mar 2009
Posts: 112 Germany
KDuke
Member
|
Member
Joined: Mar 2009
Posts: 112
Germany
|
Hi Ventilator! I finally came around to work on my project again. Well I tried to export a very simple level though I when exporting I get an error in export_gs_map.py on line 293 saying
if f.image != None:
ValueError: face has no texture values
Seems as if it tries to access a non-existent member of the face-class! Might you have an idea what the problem might be? Edit: Oh yeah thats only the case for level geometry, objects with the "__"-prefix to be specific.
Last edited by KDuke; 01/04/10 20:57.
Using A7 Free Click and join the 3dgs irc community! Room: #3dgs
|
|
|
Re: export complete levels from blender
[Re: ventilator]
#304085
01/04/10 22:42
01/04/10 22:42
|
Joined: Mar 2009
Posts: 112 Germany
KDuke
Member
|
Member
Joined: Mar 2009
Posts: 112
Germany
|
Lol... yeah thats been it.
Using A7 Free Click and join the 3dgs irc community! Room: #3dgs
|
|
|
Re: export complete levels from blender
[Re: Nowherebrain]
#307063
01/26/10 20:57
01/26/10 20:57
|
Joined: Mar 2009
Posts: 112 Germany
KDuke
Member
|
Member
Joined: Mar 2009
Posts: 112
Germany
|
Well after using this nifty, fine, great (think yourself another thousand praising words here) exporter I wonder how you handle lighting? That's the only thing which could use some improvement. As blender handles lighting differently than acknex I found it really hard to set up nice lighting with blender. This comes especially into mind when having to export the whole level again when doing little alteration.
greetings K-Duke
Using A7 Free Click and join the 3dgs irc community! Room: #3dgs
|
|
|
Re: export complete levels from blender
[Re: ventilator]
#322661
05/08/10 18:23
05/08/10 18:23
|
Joined: Oct 2007
Posts: 5,210 Ä°stanbul, Turkey
Quad
Senior Expert
|
Senior Expert
Joined: Oct 2007
Posts: 5,210
Ä°stanbul, Turkey
|
great, can you make it as an interface(i do not mean the oop interface) usable outside of blender so we can use it for other tools? Like a pyhton wmb7/mdl7 sdk/library?
like someone else could write a batch converter, or exporter for other tools etc.
3333333333
|
|
|
Re: export complete levels from blender
[Re: ventilator]
#322672
05/08/10 19:05
05/08/10 19:05
|
Joined: Sep 2003
Posts: 5,900 Bielefeld, Germany
Pappenheimer
Senior Expert
|
Senior Expert
Joined: Sep 2003
Posts: 5,900
Bielefeld, Germany
|
i was bored today and finished my python wmb7 library. it can write and read wmb7 files. You can always ask me, when you are bored, you know? Sounds great! I was thinking about building my levels in blender last months from time to time, but I don't know how to use the standard terrain shader with it.
|
|
|
Re: export complete levels from blender
[Re: ventilator]
#322706
05/08/10 22:52
05/08/10 22:52
|
Joined: Oct 2007
Posts: 5,210 Ä°stanbul, Turkey
Quad
Senior Expert
|
Senior Expert
Joined: Oct 2007
Posts: 5,210
Ä°stanbul, Turkey
|
my libraries already are useable outside of blender. the blender exporter code is separated from the mdl7/wmb7 code.
i have used my mdl7 library several times for batch converters already. at the moment it only supports writing though. maybe i will implement reading for mdl7 too. in the meantime you could use pyassimp for reading mdl7 files with python. ooh, great, , i didnot checked the code of the exporter. now i only need python bindings for lite-c
3333333333
|
|
|
Re: export complete levels from blender
[Re: Quad]
#327960
06/09/10 15:43
06/09/10 15:43
|
Joined: Oct 2007
Posts: 5,210 Ä°stanbul, Turkey
Quad
Senior Expert
|
Senior Expert
Joined: Oct 2007
Posts: 5,210
Ä°stanbul, Turkey
|
Hello Ventilator,
where can i download the latest wmb exporter?
3333333333
|
|
|
Re: export complete levels from blender
[Re: Quad]
#327964
06/09/10 15:55
06/09/10 15:55
|
Joined: Dec 2008
Posts: 1,218 Germany
Rackscha
Serious User
|
Serious User
Joined: Dec 2008
Posts: 1,218
Germany
|
Wow VENT sound absolutely great . Maybe, is there a possibility for softedges?(bsp maps normaly support only hard egdes). Maybe the level could be inserted as a modelfile with baked shadows for the smooth option...maybe? Greets Rackscha
MY Website with news of my projects: (for example my current Muliplayer Bomberman, GenesisPrecompiler for LiteC and TileMaster, an easy to use Tile editor) Sparetime-Development
|
|
|
Re: export complete levels from blender
[Re: ventilator]
#327988
06/09/10 18:34
06/09/10 18:34
|
Joined: Dec 2008
Posts: 1,218 Germany
Rackscha
Serious User
|
Serious User
Joined: Dec 2008
Posts: 1,218
Germany
|
You mean, Smooth for levelblocks affect the normals of the imported fbx in Wed? Thought its just for Shadows...I'll give it a try^^
EDIT: but split edge means that the mesh will be open, right?(hope new shade c with shadowmapping is coming soon :D) Greets Rackscha
Last edited by Rackscha; 06/09/10 18:48.
MY Website with news of my projects: (for example my current Muliplayer Bomberman, GenesisPrecompiler for LiteC and TileMaster, an easy to use Tile editor) Sparetime-Development
|
|
|
|