Creating cameo images from PNGs
It took me ages, so I'd figure I'd share how I got an RGB PNG successfully converted to a SHP file. A big thanks to Doctor Destiny. I'm not the one with all the know-how here, I'm just interpreting it
1. Setup XCC
Open the XCC Mixer (Start->All Programs->XCC->Mixer).
Select View->Directories... from the menu, and set your Red Alert 2 directory.
Restart XCC Mixer.
Once it has restarted, click and drag the second vertical bar (as part of the double vertical bar) to the right, to open another file view.
2. Setup your working environment
Create a directory to work with all your files. You could create this folder in My Documents, or for quick access in XCC, you probably want to store it directly under C:\.
I recommend copying your RA2 directory underneath your working directory, so that you always have the original game available. If you do follow this step, change your RA2 directory in XCC, and restart XCC.
In the left fileview, navigate to your RA2 directory (or the RA2 you are working with if you followed the above step), and find the languages.mix file. Double-click on it.
Navigate to your working directory in the right fileview.
Right-click on cameo.mix in the left fileview, and select "Extract...". Save this file to your working directory.
Select File->Close on the XCC menu (make sure that you have the left fileview selected; just click a file in the left fileview).
Double-click cameo.mix in the right fileview (you may need to press F5 while the right fileview is selected).
In the left fileview, you should have your working directory open, and in the right fileview, you should have cameo.mix open (a whole bunch of shp files listed)
Locate engnicon.shp in the right fileview. Right-click on this file, and select Copy as PCX.
In the left fileview, right-click on any file, and select "Explore". This should open up a Windows Explorer window.
Drag engnicon 0000.pcx from Windows Explorer into the right fileview. Right-click on engnicon 0000.pcx in the right fileview, and select "Copy as PAL (JASC)"
Rename the PAL file if you want.
3. Setup the GIMP
Open the GIMP.
Create a new file. It doesn't matter about the settings of this file, we're only using it to access the Dialogs menu.
Select Dialogs->Palettes on the menubar (image window).
Click the little arrow in the top-right corner.
Select Palettes Menu->Import Palette...
Select the Palette File radiobox, click the browse button and navigate to the PAL file you saved in step 2.
The palette should appear as shown in the image below. If your palette appears darker than this, then you most likely selected "Copy as PAL" instead of "Copy as PAL (JASC)" in step 2. Go back and correct this.
4. Create your image
Create your image in any image program you want; it doesn't have to be the GIMP. To maintain the RA2 appearance however, I recommend setting the 4 corner pixels and their direct horizontal and vertical adjacent pixels, to #0000FF (blue), and then applying an inner bevel (1 pixel wide) to the remaining image.
# = Blue Pixel
. = Image
5. Convert your image
Open your image in the GIMP.
Select Image->Mode->Indexed on the menubar (image window).
Select the Use Custom Palette radiobox, click the image on the button to select the palette you imported in step 3.
Save your image as a PCX (not sure it matters though). Make sure the filename is in the format <text> ####.pcx, where <text> is any text no longer than 8 characters you like (you probably should follow the RA2 naming conventions though), and #### is a 4-digit, 0-based number. An example name is hqhero 0000.pcx.
Repeat these steps for each image.
6. Import your images
Go back to XCC Mixer. Make sure the left fileview is your working directory, and the right fileview has cameo.mix open.
On the menu, select View->Palet->Red Alert->"ra2.mix - cache.mix - cameo.pal".
Navigate to your working directory in Windows Explorer. You should have this window open from before, but incase you don't, you can right-click on any file on the left fileview and select "Explore" to open it.
Drag the PCX files you created in step 5 into the right fileview.
Right-click on each imported file in the right fileview, and select "Copy as SHP (TS)".
Right-click on each imported file in the right fileview, and select "Delete". (We don't want to clutter our cameo.mix file with unneeded files).
Drag the new SHP files from the Windows Explorer window into the right fileview.
When you select one of your SHP files in XCC, the preview should show you the image correctly. If it doesn't, well, you've done something wrong.
7. Using them in RA2
Open up XCC Mix Editor (Start->Programs->XCC->Mix Editor).
Click New to create a new .mix file.
Name your .mix file ecachemd##.mix where ## is a two-digit number of your choosing, placing it inside the RA2 directory.
Click Insert to add your .shp file. It is recommended that your .shp files for cameos are using the Westwood naming convention, ####icon.shp, where #### is a 4 or less character string.
Click Save to save your mix file.
To test it's working:
Open the ArtMD.ini file in your RA2 directory.
Use the search feature of your text editor to find [GI].
Change the [GI] Cameo so that instead it is ####icon, where #### is the 4 or less character string you named you file before (without .shp on the end).
Save the file, and start RA2. When you build an Allied barracks, your icon should show for the standard GI.
If instead you see Missing Cameo, see this topic.
To set the GI cameo back to default again, follow the steps above, instead setting Cameo to GIICON.
That's all for now. I hope you enjoyed the guide. If you have problems with the guide, or I've missed anything out, reply to this topic. I hope to extend this guide with how to create a unit (with it's own graphic) as soon as I figure it out