×
Spam Prevention - Please Read! (23 Apr 2021)

Due to a problem with spammers the rules for posting in the forums have changed for new users.

Newly registered users won't have their posts published until a moderator approves them.

Research into .MAP format

More
5 years 5 months ago #29 by Slippery Jim
Research into .MAP format was created by Slippery Jim
Since the .map format is basically a text file it is very useful for us if we wish to try to rip Swat 3 maps for upgrading in Last Resort.

The purpose of this thread is to store information and links that would be useful to people like AlienAbducter and Furrycat (or any programmer) to help us build tools to rip the Swat 3 maps.

Please Log in or Create an account to join the conversation.

More
5 years 5 months ago #30 by Slippery Jim
Replied by Slippery Jim on topic Research into .MAP format
Although Hammer/Worldcraft was designed for the Half Life engine the format of many of the files it uses goes further back to the Quake days. If you also read about the making of Swat 3 you will read that originally they started off with Quake:

A couple of people on our team developed a prototype using Quake, but our project had so many new features that we decided we'd be better off developing our own engine.


The .map format explained:

www.gamers.org/dEngine/quake/QDP/qmapspec.html


Not sure if this forum quote is useful about reverse engineering a map:

the .map format specifies 3 vertices and 2 [] brackets. The 3 vertices define a plane and the 2 [] brackets define the u and v texture axis. You need to cut 3 planes to get the polygons of the brush and then load textures get the texture sizes and calculate the texture coordinates

Please Log in or Create an account to join the conversation.

More
5 years 5 months ago #31 by Slippery Jim
Replied by Slippery Jim on topic Research into .MAP format
Although Hammer/Worldcraft was designed for the Half Life engine the format of many of the files it uses goes further back to the Quake days. If you also read about the making of Swat 3 you will read that originally they started off with Quake:

A couple of people on our team developed a prototype using Quake, but our project had so many new features that we decided we'd be better off developing our own engine.


The .map format explained:

www.gamers.org/dEngine/quake/QDP/qmapspec.html


Not sure if this forum quote is useful about reverse engineering a map:

the .map format specifies 3 vertices and 2 [] brackets. The 3 vertices define a plane and the 2 [] brackets define the u and v texture axis. You need to cut 3 planes to get the polygons of the brush and then load textures get the texture sizes and calculate the texture coordinates

Please Log in or Create an account to join the conversation.

More
5 years 5 months ago #32 by Slippery Jim
Replied by Slippery Jim on topic Research into .MAP format
RIPPING SWAT 3 MAPS INTO MAYA WITH TEXTURES:

We discovered that you can use a tool called 3D Ripper DX and if you run AlienAbducter's SCN Editor in DirectX mode you can rip a Swat 3 map. It appears that running the map right in Swat 3 to capture won't work because of the way the engine doesn't render unseen polygons. The SCN Editor utility renders all the polygons in the map so it is perfect for ripping. The captured map will load in Maya with all the texture information retained. The only problem is we have no proper way to get it into Worldcraft yet.

Blender has a feature to export to .map format but you end up with a lot of strange spikes (distorted geometry). You can delete them manually but of course you are deleting a lot of the map geometry. Milkshape also has a way of exporting to .map format and it appeared to work a little better than Blender but it still had too many spikes.

Final note: We have only tested importing MissionA. Of course we need to test further to see if 3D Ripper DX + SCN Editor = full map captures.

Click to enlarge:

Please Log in or Create an account to join the conversation.

More
5 years 5 months ago - 5 years 5 months ago #33 by Slippery Jim
Replied by Slippery Jim on topic Research into .MAP format


The image above shows a test map that I made to aid in reverse engineering a Swat 3 map. I have included all the files below. All the information is contained in the README file.

The "basic_map" contains one floor polygon only (8 units thick) and the least amount of entities to make it a valid Swat 3 map. It has also been compiled in Worldcraft into .SCN file.

I have included a photo of what this map looks like and the textures used in it with the file "basic_map.gif"


The original map files generated in Worldcraft/Hammer:
=======================================
basic_map.map
basic_map.max
basic_map.rmf
basic_map.rmx
basic_map.scn

(I have also included the original textures and .wad file so you can also open it in Worldcraft if you wish.)


- The built .SCN file was opened with the SCN Editor (in directx mode) and captured with 3DRipperDX. This capture is contained in the folder "captured_3DRipper"

- Using Milkshape3D the .OBJ capture file was imported and then exported to "basic_map_milkshape.map" and also to "basic_map_milkshape.txt" (Milkshape has a text export feature...not sure if useful).

Note: the textures names were lost during the import into Milkshape. Perhaps if I had fiddled with it the textures would have worked properly.

Download the file basic_map.rar here

Please Log in or Create an account to join the conversation.

More
1 year 4 months ago - 1 year 4 months ago #1478 by DarkSynopsis
Replied by DarkSynopsis on topic Research into .MAP format
Was just thinking about this again today and with more having been done with SCNEdit with the web Map Viewer and such, looking at the .MAP format specs it has 1st Point, 2nd Point, 3rd Point, can these values not be gotten with what currently exists within SCNEdit's code?

Seems like it should be possible to dump all those values into a Text File with a code edit? or if I recall a python exporter was mentioned when it came to the web Map Viewer? maybe you are already grabbing all the values?

Please Log in or Create an account to join the conversation.

More
1 year 4 months ago - 1 year 4 months ago #1481 by Slippery Jim
Replied by Slippery Jim on topic Research into .MAP format
Naa, never tried to use that python script to export into map format. It no doubt can be done technically but it would take a lot of research and coding.

From my understanding a compiled map is broken down into triangles so putting it back into the Worldcraft environment would be an interesting task.

Please Log in or Create an account to join the conversation.

More
1 year 4 months ago #1485 by DarkSynopsis
Replied by DarkSynopsis on topic Research into .MAP format
fair enough, just wondered if more research had gone into over the years, I was trying to toy with SCNEdit but I can't even get the thing to build >.> was originally trying to build in VS2017, had to go find 2010 for the compiler which reduced the errors it was throwing out but lots of "‘string’ is ambiguous" errors.

Noticed there was a CodeBlocks project file in the folder but even installing that didn't seem to help, even tried some older versions.

Please Log in or Create an account to join the conversation.

Time to create page: 0.134 seconds
Powered by Kunena Forum