Decompiling Maps
Before you read on make sure you know that decompiling maps can be a very sticky business. It is widly frowned upon by the majority of professional level designers. For good reason, when you decompile a map you are taking their hard work and using it for yourself. So before you get the idea to go around decompiling every map and throwing the vmf's up on the internet, please take the time and think about something you have dedicated a small portion of your life to, and then imagine someone breaking it into a million pieces.
When you decompile a map you should be thinking one of two things:
- You are curious how a certain part of his/her map works
- You are going to greatly change the map and only use the skeleton, and of course give the author full rights to your work.
The Hackers Toolbox
To decompile maps I suggest the following tools:
- entspy
- vmex
Optional
- BSP2MAP
- MapFool
EntSpy is a program that will let you edit almost all the entities in a specified map.
Vmex will decompile source maps for you with almost perfect accuracy. It gets a little shady when it comes to decompiling HL1 maps. VMex is also built with a protection system that any map maker can use to stop VMex from decompiling his/her map. More on this later.
BSP2MAP This program will decompile some HL1 maps. Unfortunetly, HL1 maps do not store as much information about the geometry of a map, so the geometry has to be recreated using the polygons.
MapFool This is a niffty program that will help you with porting HL1 maps to Source, it lets you open the wads and even save them as new materials and textures for use in your new source map.
xwad is a tool that can convert bmp, wad, & spr to tga, vtf, and vmt.
Getting Dirty
To start off, you are required to have installed the JRE, which can be downloaded from http://java.sun.com/j2se/1.5.0/download.jsp. Once that is installed you are ready to decompile your first map. Download VMex and copy it to a folder that is close to a drive letter (eg, "C:\VMex") the reason will soon be clear. You'll motice VMex comes with two bat files, these, unfortunetly, have to be run from the command prompt, so goto Start->Run and type in "cmd"
When the screen pops up, navigate to the folder you installed VMex to by use of the cd command. Example, to get to the drive I mentioned earlier, type "cd C:\VMex" (without the quotes). Good thing you installed it close to a root directory!
When I go to decompile maps I usually copy the map I am decompiling to the VMex directory, but this step is optional, its just a matter of avoiding a lot of typeing. On the command prompt type in "vmex my_mapname" with your map file substitued for my_mapname. After a few seconds and a bunch of .'s you should be all set with a genuine VMF file.