Jump to content
The Dark Mod Forums

Blender 2.61 - export to .map


Arcturus

Recommended Posts

This is quite exciting :) I've just found out that there's a script that can export geometry from Blender to Quake 3 .map format. That means you can not only make static meshes but also BSP entirely in Blender. It's hidden by default, you have to enable it in user preferences -> addons -> import / export. I created a default Blender torus:

 

post-2001-0-87405600-1325891248_thumb.png

 

The walls don't have any thickness so script has to add inner walls. That's what "thickness" option is for:

 

post-2001-0-72747800-1325891457.png

 

Exported .map needs to be converted to Doom 3 map format. Thankfully there's a neat converter: http://www.fileplane...3-Map-Converter

The program converts not only .map but also other files. There's a lot of options which I simply unchecked. You need to put path to Quake 3 but a false one will do just fine. In converted .map file you have to remove these lines:

 

post-2001-0-24095500-1325892035_thumb.png

 

Now you can open the map in Darkradiant. I applied the stone texture in Radiant. As you can see exporter has added thickness to the shape and now it has inner walls:

 

post-2001-0-99292100-1325892208_thumb.png

post-2001-0-73811200-1325892230_thumb.jpg

 

In game you can see that compiler has removed the unneeded polygons (since no entity will ever get inside the torus):

 

post-2001-0-74017000-1325892616_thumb.jpg

post-2001-0-89065400-1325892632_thumb.jpg

  • Like 1

It's only a model...

Link to comment
Share on other sites

Lol wut? Max 2012 breaks the dreaded import ase issue only to make it worse by not having an exporter? What's the purpose of that?

 

--------

 

Is cool that you can work in blender, however I don't know how useful it is unless you can grid snap good. Other wise you'll get leaks all over. And building with scripted thickness would be tough to get right, better to just build with cubes like in DR. And in DR you can align tex at the same time, also using props like door frames to keep scale correct...

 

And in DR you can cut a brush up into parts for doors/windows, then turning the existing hole fillers as vportals.

 

And I suppose you can't make patches, or maybe you can just use a plane and it basically is a patch (though probably not editable with verts/rows). By the looks of that torrus it seems like a 3x3 plane might just end up as 9 quads in DR and not an actual patch.

Dark is the sway that mows like a harvest

Link to comment
Share on other sites

Lol wut? Max 2012 breaks the dreaded import ase issue only to make it worse by not having an exporter? What's the purpose of that?

 

Hey Baddcog!

Yes I have got 3ds Max 2012 and you can not import .ase files. You can export .ase files though. I don't get it why.. This was the case in 2011 too, but there were plugins available (which aren't available for 2012). So I can export models but can't import them which is annoying since you could export entire rooms from Dark Radiant for 3ds max. You could but you can't ^^

 

I guess that's the same idiocy as when they decited not to use Reactor anymore and instead the NVidia thingy.

Edited by SeriousToni

"Einen giftigen Trank aus Kräutern und Wurzeln für die närrischen Städter wollen wir brauen." - Text aus einem verlassenen Heidenlager

Link to comment
Share on other sites

You can snap to grid in Blender just as easy as in Radiant. I used torus to demonstrate how easily you can create complicated shapes. Normally all visible geometry should be ase. I see it as a tool for invisible stuff like clip models and BSP to seal complicated rooms like twisted, round skewed tower. In the grass demo there's a huge ground model:

 

post-2001-0-22631000-1325896671_thumb.jpg

 

NPC can't find path on models or patches so I had to put brushes below it:

 

post-2001-0-23549100-1325896695_thumb.jpg

 

I spent many ours on it and the effect is still not perfect. In Blender it would be as simple as duplicating the ground model, extrude it downwards and export. And the effect would be perfect.

It's only a model...

Link to comment
Share on other sites

@Serious Toni, I guess I misread your post. No, there hasn't been a good exporter for many new versions of Max. I had 8 for awhile and before that I had 5. 5 had a scriptt, up to at least 8 didn't.

 

@Arcturus, Ai can walk on patches, they just can't pathfind, so yeah you need to put brushes under. However they can be up to 48 units or so lower than the models/patches, so they don't have to bee all that accurate.

 

It looks like you were trying toi get all those brushes as close as possible, when all you probably really needed was one giant wedge. It would be alot cleaner pathfinding and much cleaner to work with too. It would only take 5 minutes too.

Dark is the sway that mows like a harvest

Link to comment
Share on other sites

I'll have to give Blender another shot. I've heard the interface is much more intuitive these days.

Yeah, you really should! The basics haven't changed all that much though, so if you were unhappy with the hotkey-based interface chances are that you'll not like it this time around either.

 

Yes I have got 3ds Max 2012 and you can not import .ase files. You can export .ase files though. I don't get it why.. This was the case in 2011 too, but there were plugins available (which aren't available for 2012). So I can export models but can't import them which is annoying since you could export entire rooms from Dark Radiant for 3ds max. You could but you can't ^^

I think the same problem's present in Blender. I haven't looked very hard but I haven't been able to find any script to import .ASE either.

Link to comment
Share on other sites

It looks like you were trying toi get all those brushes as close as possible, when all you probably really needed was one giant wedge. It would be alot cleaner pathfinding and much cleaner to work with too. It would only take 5 minutes too.

No, I'm sure it wasn't that simple. They still have problems with pathfinding at some places, they sometimes have to go round, even after hours of tweaking.

It's only a model...

Link to comment
Share on other sites

I think the same problem's present in Blender. I haven't looked very hard but I haven't been able to find any script to import .ASE either.

There's a script for Blender 2.4x and it's not a big deal to have two versions installed.

It's only a model...

Link to comment
Share on other sites

Ok, the script has some drawbacks. You can easily make shapes like this:

 

post-2001-0-19123300-1326048001_thumb.png

 

Every brush is perfectly aligned:

 

post-2001-0-73008500-1326047990_thumb.png

 

But if you modify it liike this:

 

post-2001-0-86872000-1326048016_thumb.png

 

All brushes are misaligned:

 

post-2001-0-20404300-1326048029_thumb.png

 

So the shape has to be symmetrical on x and y. I don't see much sense here. In both cases vertices aren't snapped to grid. I read that script automatically rounds degrees in brushes. But it doesn't do that in the first case.

It's only a model...

Link to comment
Share on other sites

I think the same problems present in Blender. I havent looked very hard but I haven't been able to find any script to import .ASE either.

You should be able to find the assimp based importer for blender, it should be able to import most ASE, as well as all of the other TDM formats. I think it's being maintained atm, if not I can update it again.

Link to comment
Share on other sites

The reason why those brushes get tweaked (mainly) is that they all have th be convex. So some of the faces are ending up concave (and you can't turn edges like you do in a 3d program).

 

But you can effectively turn the edges by cutting all the cubes in half. But even when I've done that with simple squares in DR to make the brushes not optimize together it can be very hard to get the textures to align properly if at all.

 

Doom3 is pretty picky about brushes when it compiles and that's probably why those black brushes of death appear.

Dark is the sway that mows like a harvest

Link to comment
Share on other sites

post-2001-0-78833900-1326411865_thumb.png

 

Now you probably wonder: what the hell is this? I did some testing and found that you can't export one ring of a torus:

 

post-2001-0-28269100-1326412730_thumb.png

 

without small misalignments. You can however export whole torus and then delete unneeded parts in DarkRadiant. Also, if shape can be exported without misalignments it can also be exported rotated without a problem. With that in mind I started to build a tower.

 

post-2001-0-20227800-1326412957_thumb.png

 

Now select top edges and place a cursor in line with them.

 

post-2001-0-13989700-1326413024_thumb.png

 

It's important that cursor is aligned horizontally, otherwise torus will be incorrect. Then spin the vertices 360 degrees. I used 72 steps, that gives 5 degrees per step.

 

post-0-0-22323400-1326413297_thumb.png

 

Now select this ring:

 

post-0-0-51108300-1326413414_thumb.png

 

Copy it and convert into new object. Now rotate it -5 degrees for easier extruding:

 

post-0-0-31354300-1326413485_thumb.png

 

Extrude new part of the tower:

 

post-0-0-00424200-1326413550.png

 

Clean the rotation:

 

post-0-0-77144300-1326413655_thumb.png

 

This way you can add more and more parts. You can change direction in which the tower is skewed.

At the top I added a battlement:

 

post-0-0-58283900-1326413958.png

post-0-0-85064100-1326413993_thumb.png

It's only a model...

Link to comment
Share on other sites

Before exporting I will need to establish where to put windows. For that I need to know where are the stairs. So I copied the meshes to another layer:

 

 

post-2001-0-52198300-1326414216_thumb.png

 

 

Add a loop where the top of the door will be:

 

 

post-2001-0-01960500-1326414288_thumb.png

 

 

This way in Radiant we will be able to simply delete four brushes and the place for the door will be ready.

 

 

post-2001-0-14020100-1326414563.png

 

 

To add stair is put a single step and an "empty". Then I used array modifier with empty as a target. By rotating and scaling this empty you can easily modify shape of the stair. You can set number of steps and their position relative to the original step in modifier's options.

 

 

post-2001-0-98299500-1326414582_thumb.png

post-2001-0-00923200-1326414819_thumb.png

 

 

When all the loops needed for windows are ready:

 

 

post-2001-0-34880200-1326415036_thumb.png

 

 

All the elements can be exported as .map (one at a time). There can't be holes for windows, just loops that will create brushes of the proper size ready to be removed in DarkRadiant.

 

Export each part separately and save as a prefab. When you have all the prefabs simply put them together:

 

post-2001-0-57884300-1326415376_thumb.png

post-2001-0-65606000-1326415404_thumb.png

It's only a model...

Link to comment
Share on other sites

Thats pretty fascinating man, surely seems like there is a LOT of potential to create map geometry in sophisticated shapes, already in working brush form! I had seen the katsbits tutorial before, but it was a very simple parking lot kind of space, nothing of this magnitude...

Link to comment
Share on other sites

Yes, I think it has a lot of potential :)

I didn't mention that script has hard-coded limit of 'face width' to 10. With scale 1 that's a bit too little for my needs. I want 15. The solution to that is to scale down the mesh x0.1 times and export with scale 10 and face width 1.5. I tried to modify the script for Blender 2.6.1 to change this value to say 20, but without success. I managed to change it in Blender 2.49 though and exported normally as width 15.

Funny, the script has always been there for years. I probably didn't think that there might be a Quake to Doom converter and forgot about it until now.

It's only a model...

Link to comment
Share on other sites

The biggest potential gain I see from this is that you could:

 

1) lay down rough map geometry

2) plot areas where you wish to VP

3) do detail work on high profile geometry items

4) export the map excluding stuff from step 3

5) save stuff from step 3 as ASE models

 

It'll simplify the process of hybrid mapping styles. It would even allow you to AO bake to both models and brushes at the same time... Just clone the whole map then scale it a little then bake then export is as a model (or several models). Pretty nice improvement over the previous workflows for this.

Please visit TDM's IndieDB site and help promote the mod:

 

http://www.indiedb.com/mods/the-dark-mod

 

(Yeah, shameless promotion... but traffic is traffic folks...)

Link to comment
Share on other sites

Just to be clear, you mean steps 1-5 are all inside Blender, right?

 

Of course the other direction would be to build modeling features right into Dark Radient so you could build a custom model right in situ. Wouldn't that be dreamy.

What do you see when you turn out the light? I can't tell you but I know that it's mine.

Link to comment
Share on other sites

Learning Blender is a chore man, Im sorry to say, so its probably going to be a while before I can give this any use. I can think of ways that building a detailed house interior with a polygon modeler and than exporting it as brushes would be a lot faster and more confortable than doing it with the rigid pieces inside DR; but I also agree with Arcturus that there is great potential in just modeling free-style, organic shapes to be used as architecture models, and using the original shape as base for a quick and accurate double to be used as de facto underlying map geometry.

 

Now if only I had the brains to learn the program... (Im actually learning two other 3d modelers right now (Rhino and Revit Architecture, that's the main problem, your memory is psread to thin... 3 with DR, if you think about it...)

Edited by RPGista
Link to comment
Share on other sites

Join the conversation

You can post now and register later. If you have an account, sign in now to post with your account.

Guest
Reply to this topic...

×   Pasted as rich text.   Paste as plain text instead

  Only 75 emoji are allowed.

×   Your link has been automatically embedded.   Display as a link instead

×   Your previous content has been restored.   Clear editor

×   You cannot paste images directly. Upload or insert images from URL.


  • Recent Status Updates

    • Petike the Taffer

      I've finally managed to log in to The Dark Mod Wiki. I'm back in the saddle and before the holidays start in full, I'll be adding a few new FM articles and doing other updates. Written in Stone is already done.
      · 1 reply
    • nbohr1more

      TDM 15th Anniversary Contest is now active! Please declare your participation: https://forums.thedarkmod.com/index.php?/topic/22413-the-dark-mod-15th-anniversary-contest-entry-thread/
       
      · 0 replies
    • JackFarmer

      @TheUnbeholden
      You cannot receive PMs. Could you please be so kind and check your mailbox if it is full (or maybe you switched off the function)?
      · 1 reply
    • OrbWeaver

      I like the new frob highlight but it would nice if it was less "flickery" while moving over objects (especially barred metal doors).
      · 4 replies
    • nbohr1more

      Please vote in the 15th Anniversary Contest Theme Poll
       
      · 0 replies
×
×
  • Create New...