Hello, does anyone have a way to convert a .obj file into a Quake 2 map? Or import .obj geometry into a map?
Offhand, I would assume this is more than a complicated procedure. It's not just about geometry, but also about properly setting up things like texture data, lighting, visibility, all the items you'd need in a map... But I'm wondering if there is a feasible process to bring in .obj files to use as geometry in a level.
I was doing a google search, and I found a tool someone made and posted to the func_messageboard, but the link to the file is dead. Likewise the other leads I try to follow tend to be somewhat sparse on information and reliability; some only work with tools/editors I can't get running on my machine, some I can't really tell what version of Quake or figure out their directions... Eff this, I'm just gonna ask. Does anyone here have a way to import .obj files into a Quake 2 map?
It is quite possible, but is in no way straightforward and would take considerable effort. I haven't seen any ready-to-use tools; at least few years ago when I was playing with the idea of converting some of the Unreal maps (.t3d, conversion to/from .obj is easy so this example probably applies here) I had to craft a quick'n'dirty Perl script for that. Unfortunately I had never finished it, let alone making it production quality.
You probably won't find general solution that would eat any *.obj file, but for a particular one it should be possible to come up with some hackish, ad-hoc solution.
Last Edit: May 6, 2018 22:34:59 GMT -5 by sP1Sp0pD: Fix a typo
Also, depends on how you were going to use the .Obj.. As a "freestanding" model? Or as part of the structure?
I believe Paril posted som supereasy hack on how to change the model of any entity.. But then you'll need to change the .obj to an .md2 first though.. Couldn't find the thread now, but I'll keep looking for it, or maybe try it out from memory..
An obj file stores a mesh of a single object. A Quake map consists of a set of volumes. If you keep this in mind and think about your question, the answer is that there is no way to convert the mesh into a map. Think about your mesh: how would you expect the volumes to look?
You could of course import a small map object (like a statue or a lamp) from such a file, no problem. This is very similar to using the mesh to make the floor of an outdoor area or to use it as a rock wall (modern Quake compilers can do such things, see Pyramid of the magician by Sock). But to use the obj file as the map itself won't be possible.
Also note that the computation of VIS blocking, bot navigation, sound, lighting, and basically everything else in the Quake 2 engine is based on brush volumes. So if you import everything as one large model, you will also get performance issues etc.
If you try to convert the mesh into a set of volumes automatically, you will get many very ugly brushes and lots of trouble (brush limit, impossible to edit further, performance, ...).