Home of FourCentsShygenPathmapsPathfinding filesPiti - A Single Player Sea BattleSome Battlefield TutorialsBattlefield command referenceContact 4cShy

Murphy's Law of Combat #115
If at first you don't succeed,
call in an airstrike

A combination of landing craft smallOnes,
info and regular pathmaps


Genpathmaps is a diagnostic and converion tool for Battlefield pathfinding files. If you're not into creating Battlefield 1942 levels with AI support, you don't need this tool. If you are working with pathfinding files, you might like it.

If you've plunged into the rfa archives, then you've probably noticed that most of the files are simple text (con) files. These are easily edited with any text editor and there is plenty of information for those who want to know how.

Then there are those annoying binary files. Most of those are images, including the pathfinding files. The pathfinding files are compressed 1 and 2 bit images. One set of images for each vehicle used in the map.

genPathmaps will convert them into bitmap images that can be edited with almost any image editing software, and convert them back. It will also generate diagnostic images, like the images on this page, so you can find any problems that might exist in them.

infantry smallOnes on west Wake island

Red lines connect infantry smallOnes
points from tile to tile

When EA Games released the game debugger, I stopped working on this tool and started playing with the debugger. The debugger did all the things that my tool could not. But after generating pathfinding maps for many levels, I noticed that the pathfinding files it generated still needed to be touched up some.

So here it is. With it, you can convert the pathfinding files generated by the game debugger into bmp and 8 bit raw bitmap images, touch them up with any image editing software and convert them back into compressed game pathfinding files.


  • There is now support for Battlefield Vietnam pathfinding files.
  • Maximum map dimentions now support 8192x8192 sized maps.
  • Converts any of the pathfinding raw files into 1 bit bmp or 8 bit raw images for editing.
  • Creates diagnotic images of the smallOnes and info files.
  • Convert edited 1 bit bmp or 8 bit raw images back into compressed pathfinding files.
  • Outputs text files from the smallOnes file for editing and converts them back.
  • Genpathmaps now accepts individual files for input, instead of a directory.
  • There are now batch files that can be placed on your desktop and used for drag and drop.


The current version of genpathmaps is: genpathmaps_20041114.rar

Notes on usage

The batch files that come with this tool are meant to be place on your desktop (or any other place that's handy). Then drag and drop the files that need converting onto them. Double clicking on the batch files will give a brief explaination of there use and the folder that converted files will be stored.

I've found the bmp bitmaps easier to use, so support for 8bit raw images is limited. The bmp bitmaps can be viewed and edited by just about any image viewer/editor, while 8 bit raw files need more powerful image editing software, like PhotoShop. Also, the diagnostic images (smallOnes and info) are in color for bmp bitmaps, while 8 bit raw diagnositc images are greyscale and harder to see. If you insist on using 8 bit raw images, the level 2 search maps for boats and landing craft need to be resized to, and saved as, level 0 search maps before converting back to compressed pathfinding raw files. The genpathmaps tool only supports level 0 search maps for input when generating compressed pathfinding raw files.

The bmp images generated by genpathmaps have the same orientaion as the game. That means the origin (point 0x0) is at the bottom left hand side. The 8 bit raw images are flipped verticaly, putting the origin at the top left hand side. If you plan on using the image to plan out your strategic areas and landing zones, the 8 bit raw agree with PhotoShop, that also uses the top left hand side as point 0x0, while the bmp images have to be flipped in this case.

The genpathmaps tool will convert any of the game generated, compressed raw files (not the 8 bit) into viewable images. Although the game generated info files should be exactly the same as those generated the genpathmaps tool, there are differences between the game's smallOnes and that created by genpathmaps. If you would like to compare the differences between them:

  • First, drag and drop the game generated smallOnes file (e.g. Car.raw is the smallOnes file for the car vehicle type) onto the genbmp or gen8bit batch file.
  • Go into the diag directory and copy or move the image to your desktop, or some other place where it will not be overwriten.
  • Then drag and drop the level 0 search map onto the same batch file. The smallOnes image in the diag directory will have been generated by the genpathmaps tool and the saved image will be that generated by the game.

The main differences between the smallOnes generated by genpathmaps and those created by the game debugger are:

  • The point don't line up. That's fine, choice of these points is somewhat arbitrary. The only thing that matters is that they are contained in the correct DoGo area of the info file that the point is associated with.
  • Some of the points in the image generated from the game's smallOnes file are larger than the others, while all the points in the image generated by the genpathmaps tool are the same size. That is the one mystery I have yet to solve. For some points in the game generated smallOnes file, a couple of bits are set high. I mark them in the diagnostic images by making the point bigger than the other. It might be a way to instruct the AI to choose it over others when planning a new path. I'm not sure yet, but it doesn't seem to matter if it is set or not.
  • There might be X's or crosses drawn on some of the grid tiles in the smallOnes diagnostic images. Only 13 of the 16 bytes in a smallOne record are used, but sometimes the last 3 bytes contain information. I've come to believe that the game neglects to completely clear the record in memory before writing to it and this is just garbage. Until I'm sure, the information is marked for my benifit and can be ignored.

The genpathmaps tool is also capable of converting smallOnes raw files into text files and back. This allows the smallOnes points to be manually placed. It requires a greater understanding of the pathfinding process and is intended for advanced users. To get a comptete list of option and a brief explaination of how this is done, from a command prompt in the genpathmaps directory, type:
    genpathmaps /h
If you have any questions, please feel free to contact me.

Too much landing craft and infantry information

I've tested this verion thoroughly and haven't found any bugs. That doesn't mean there aren't any. If you find one please let me know.

All the bitmap images created with this tool are constrained to the size of the original image. I did this so that level 2 search maps for boats and landing craft can be used as if they were level 0 maps. All you have to do is rename the image. It also makes them easy to overlay on each other in an image editor. The pics on this page were created by doing just that.

I hope you find this a useful addition to your existing tools.

Counter by 4cShy
Since Dec 6, 2004

Last Updated: Jun  9, 2005