Quake (1996 game) bsp import script

Thanks eppo! I’ll give it a spin after work.

:smiley:

I can use this with Jedi Outcast 2!?
It was build on the Quake engine and used .bsp maps!

I looked at the pic, but your code looks different from the last version of the add-on, which can be found here: http://www.quaketastic.com/files/misc/blender-quake_bsp_importer-v0.0.4.zip

Here is the error: http://www.pasteall.org/60773

Nice one!

https://www.quaddicted.com/files/tools/blender-quake_bsp_importer-v0.0.5.zip

Sorry for confusion, i likely have grabbed v0.0.5 file…
Anyhow, here’s v0.0.6. Rename .blend to .zip (just delete blend extension) and install as usual.
Did not see anything wrong, had imported one more map; will try to weed out any leftover errors if there are, just paste error message and point to the map download.

Attachments

blender-quake_bsp_importer-v0.0.6.zip.blend (10.4 KB)

Yep, that one works like a charm! Thanks a bunch!

Do you know if there is a way to export into FBX and preserve textures ? I tried, and it keeps materials, but textures aren’t being embedded into FBX. Lights don’t seem to export too, as when I import FBX into Unity, they come in as some point prefabs.

Glad to see a few of you are using this addon. I’ll try and add the fixes eppo mentioned and update the addon as soon as I can. It might even be worth doing some more work on it if enough people actually want to use it for stuff - it should certainly be handy for porting Quake levels to more modern engines, or just doing renders.

One thing I would like to try is importing the light maps, but I’m not sure how much work it will be. Making it easier to separate entities, and naming things like doors based on key values in the entity lump would also be hight on my list of improvements, but again, it’s a lot of faff, so it might not happen.

Oh, I forgot that Slight made some excellent additions, so hopefully it will be easier to make further improvements starting from his version of the script. The renders he did are awesome and look almost exactly like Quake - Awesome work! :smiley:

Motorsep: if the lights are named, or otherwise distinguishable, you could create a script that converts them to lights in unity.

Shouldn’t Blender’s light just get saved into FBX and imported as Unity lights?

I wish I could, but I am no programmer :confused:

I was really hoping just export it to FBX, bring it to Unity and bake lightmaps out of the box.

OK, well I don’t know much about Unity importing lights directly from fbx files, but I don’t think it supports it at all, does it? I think it’s Unity that turns the light into an empty GameObject.

Maybe you could bake the lightmaps inside Blender instead? I’ve never done this myself, but presumably you just need to add a new UV set using lightmap pack to generate the UVs, then bake the lighting.

As a sidenote, I think some more modern bsps lack lighting information, since the light entity data for all static (non-animating) lights in Quake is redundant once the bsp lightmap has been calculated, and modern map compilers remove this redundant info. I guess it would be great to get the lightmap data correctly importing directly into Blender. Not sure how to do this, but it should be possible. If I did get it working, it would be pretty low resolution though, so it might be best to relight everything in Blender.

I doubt Unity turns lights into points. The whole idea is to import scenes from 3D apps and not to mess with it.

Maybe it’s possible, but only for standard lightmaps, not directional ones.

I filed bug report https://developer.blender.org/T46021

Hmm… You are correct sir! Unity doesn’t import lights. That sucks. I wonder if it’s even feasible to match lighting settings even with C# script that would add children to empties in Unity…

Is there any way you can make an add-on to export ascii (txt) file where each line would contain light’s name, light’s intensity/radius, light color (for those maps with colored lights) and whatever else light’s parameters quake has.

Something like this: light.001;300;1_0.75_0;

This way when FBX is exported, and this txt with lighting info is exported, it can be used in Unity. C# script could parent lights to empties in Unity (or replace empties with lights), import txt file and set up each light with lighting data from txt file.

After that all that would have to be done is lightmap baking and a level would be ready to go :slight_smile:

Welp

I guess this would be useful for… making a remastered quake fanart?

Another thing that I had in mind and forgot to ask about - could you please add an option for importer to import sound entities (so when it’s checked in the UI, it only brings in sound entities, not all entities) ?

motorsep: Try this Unity addon I found: https://github.com/mikezila/uQuake1
I think this is going to be a lot more useful to you than my Blender addon :slight_smile:

Also, I put my addon on Github, complete with the changes made by Slight (0.0.5) and the fix by Eppo.


It’s now 0.0.6 and unless I suddenly get an uncontrollable urge to work on it, or it stops working, I don’t think I’ll ever touch it again to be honest. Still, I hope some of you will get some use from it!

Ah, nice one… Thanks for the link!

So, I tried Unity add-on. It works, but, it creates scene with large amount of draw calls. No good. Also it doesn’t look like lightmaps gets baked on the geometry, because it’s procedurally generated based on BSP data.

So, I am messing with this addon:


Going to make stereo panorama for VR :slight_smile:

Ultimate goal is to make a playable scene for Gear VR to see performance impact.

P.S. I am thinking it would be nice to add motion blur and trails (to the chainsaw “blade”) to make it look more dynamic. How would I do that?