Easy Event Images with Paint Shop Pro

I am new to map making, but I have found an easy method of making event images with my old version (5) of Paint Shop Pro. Some of the newer versions may have added capabilities, but this works well for me and might help you add some new event images to your maps. It's all about palatte swapping and I am going to try and show you how easy it is. I have never used PhotoShop and I don't know its capabilities, but perhaps users of that program can apply some of this.

First things first. If you have an older version of PSP as I do, you have no capability of working with DDS files within your paint program. I use a small free program called DXTBmp. It will allow you to take DDS files and save them as Targa files and also save files back into DDS format. I have included the version I use. You can also get the latest from many sources on the internet. Type DXTBmp in a search engine and you will have numerous locations where you can get the newest version. I am told that DDS Converter 2 is also a good choice for this, though I have not tried it. Second, you will need a way to unpack FPK files. I use Dragon Unpacker5 which I first heard of on this site. Go to the Wiki Tutorial Section. Under "Creating an Industry from a Copy". You will find links to both Dragon Unpacker as well as PakBuild, which I assume has similar capability. I am including the event_us_transportgoods.dds file which will get you started, but if you should lose it or happen to accidentally change it, the info below will show you where to find the event files within the game.

Events - Successful Completion of a Victory Condition

In order to create an event for a newspaper announcement as those seen after completing a required task i.e. "Ship 30 carloads of Food", you need to start with the standard "event_transportgoods.dds" file. You will find it in the main Sid Meier's Railroad files. Mine are located in C:\Program Files\2K Games\Firaxis Games\Sid Meier's Railroads!. Depending on your install, yours may be different. Using Dragon Unpacker (my choice), open the Interface0.FPK file. Almost all of the event image files are here, but there are a few in the Interface1.FPK file. Scroll down to the event_transportgoods.dds file, right-click and extract the file without convertion. You probably should set up a folder for all this image stuff - mine is called Railroad Image Stuff. Anyway, save the file where you will know where it is.

Now start the DXTBmp program and Open the event_transportgoods.dds file you just saved. First export the Alpha Channel. Save to your file for this event image stuff. It will save as a bmp file. I have included the alpha channel file in the attached zip file.

Now save the event_transportgoods.dds file as a Targa file. Note at the top of the program, it shows you the file type and size you have open. Note that this is a DDS DXT1 file type.

Now I am assuming that you have an image that you want to use for one of the Newspaper images in the game. I found a picture on the internet of a grain elevator with traincars loading. It doesn't matter if the image is color or black and white - either will work. The first thing you need to do is to get the image to 743 pixels by 300 pixels. This is the portion of the event_transportgoods file taken up by the image. You may have to increase the size or reduce the size of your image, but maintain the aspect ratio so that your image is not deformed. You do not want to use a very small image. Trying to increase a 200 x 200 image sufficiently will leave you with a blotchy image. It doesn't have to be 743 x 300 to start with, but I would try and find something that isn't a lot smaller.

You then need to crop the image as necessary to end up with an image that is 743 x 300 that you're happy with. Now that you have your image the proper size, open the file event_transportgoods.tga which you created with DXTBmp, in Paint Shop Pro. With that file active (on top), open the color menu and reduce the color depth to 256. I use the Optimized Median Cut under the Palette section and Nearest Color under the reduction section, but you can experiment with the other choices if you want to.

Now use the color picker tool and left-click on the image. Then, if you click on the foreground color, you will see that the image now has a 256 color palatte.

This is the key to the whole process. You want to save this palette. Go into the Colors menu and click Save Palette. Give it a name like "event newspaper palette" or something you will recognize. I have included a copy of the palatte in the attached zip, but the palette file is specific to Paint Shop Pro. If you use another paint program, you will have to look at it's palatte operations and probably save it within your program.

Now my image that I wanted to use for successful food delivery looked like this:

It has been cropped to 743 x 300. Next you want to change it to Grey Scale. Open the color menu and do that. You now have a Grey Scale image which was automatically changed to 256 color depth, thus it now also has its own palette. (If you start with a black and white image, check the color depth to insure that it is a 256 color image. It should have a palette similar to the one shown above except all the colors will vary from black to white through various shades of grey.) Your grey scale image should look something like this:

Now, with your grey scale image active (on top), go into the color menu and load your saved palette from the event_transportgoods.tga image which you saved a minute ago.

After loading your palette, your image will resemble this:

The image now contains the same brown tones used in the game files, or close enough that you won't be able to tell any difference. (The reduction in color depth made some subtle differences, so I can't claim they are identical, but close enough). Now open the event_transportgoods.tga file, if closed, and copy your image and paste it over the image in the transportgoods picture. Make sure your upper left-hand corner is at 0, 0.

Now save the file to your image stuff as event_transportfood.tga (or whatever is appropriate for your purposes). The color depth will be increased back to 16 million colors as a result of saving the file in Targa format. Now its just a matter of saving our image as a DDS file that the game can use. Re-start the DXTBmp program and load your image - event_transportfood.tga (or whatever). After loading the image you must import the alpha channel which we saved originally.

After loading the previously saved alpha we need only save the file as a DDS. Under the file menu, choose "Save as" a DDS texture and then go to the "Save as type" in the dialogue box and choose DDS DXT1. This was the format of the original events file we started with. You need the alpha channel, so you would not want to use the one with the (NoAlpha) option. Again, save the file where you can find it.

In order to put this image to work, copy it to your Usermaps file in the map you are building. Then you need to insert it into your senario file like this:

Instead of the routine event_transportgoods.dds image appearing in the newspaper announcing the successful completion of a condition, you will get the event_transportfood image (or whatever yours is called) you created in the paper. Do a few of these and you will quickly see how easy it is. I think swapping the palette gives a nice look in the correct color family and provides another way to add interest to the maps you create.

Events - An increase/decrease in a Good

The announcement of an increase or decrease in a good is almost the same. It uses the same overall image size, it's just that some of the image is taken up by an arrow. If you wish to use an increase and/or a decrease in your events file for a good you have created, you need to create an image that is 341 pixels by 300 pixels. The overall image is still 743 by 300, but the arrows are 402 by 300. That leaves 341 in width for your image. This process uses the same alpha channel as above and the same palette. There is no need to go save them again.

This is the event_us_furnitureincrease.dds file converted to targa format (gif for the sake of this tutorial). I have included a zip with this tutorial which includes an up arrow and a down arrow in targa format, as well as a complete event_us_furnitureincrease.tga file. All you need to do to create your own event file is to resize the image you want to use, change it to grey scale, and load the event palette you used before. You should end up with a compatible-looking image in the same tones as the game's event images. Now just paste your image into the event_us_furnitureincrease.tga file and save it as event_us_whateveryourgoodisincrease.tga. Then you can change your increase to a decrease by simply pasting the down arrow included over the top of the current up arrow and resave. As above, in order to get your new image in a format the game can use, re-start DXTBmp and open your image. Import the alpha channel you used above, then save as a DDS texture using the DXT1 file type. It's just that easy.

A word about adjusting your image.

You may end up with an image that just looks too grey. If you examine the palette from the game image files, you will note that there are a good number of grey palette colors in the palette. If your image just happens to have a number of pixels the same shade of grey, it is possible that some of your image will not have the brown tones you may have expected (I had an image like this). A little grey is ok, but you can have too much. In that case it is easy to adjust your image using the color replacer tool (color swapper). Use the eyedropper and right-click on the grey in your image you would like to change. That puts that color in the background color box. Now left-click on the foreground color box. You will see the new palette. Try and choose a color that is not too far from the offending grey, but just adds a bit more brown tone. You don't want to end up with a great deal of contrast where there shouldn't be much. Once you have chosen your replacement color, use the color replacer tool and click around your image. You will see the offending grey color replaced by the newly chosen color. If it doesn't look right, undo and go back and pick a different color from the palette. (I set my tool control size to 200 and my tolerance to 10, but you may need to vary that depending on your image.)

If you are used to using PSP, I'm sure you will have no difficulty making any small adjustments in your image that you feel are necessary. In most cases, I have found that none were needed.