Post tutorial RSS The Long awaited tutorial-How to add Cameos to Generals

Here's the answer to the question that has been presented to me; How do you add Cameos to Generals?

Posted by on - Intermediate UI/HUD

Image(s)- The cameos you made previously
Notepad- Standard for Windows
Paint- Also standard for Windows
XCC Mixer-
Get this from my downloads section
Alright, Let's get modding!

Background- For all those C&C vets who have modded previous games you know that cameos were stored as seperate files; however, this is not so in C&C Generals. In Generals, all the cameos are compiled into a sheet of images in the .tga format. The .INI file then divides the cameos up into what is called Mapped Images. So basically, the INI file has a list of coordinates that signifies each indiviual range and then you assign a name to it. There are also 2 types of cameos, large and small. The large one is used for when a building or unit is selected and the small one is used for every other function such as the Generals Power icons.

1. The first thing you need is your cameos(for me it is the RA1 cameos). Small cameos should be 62x50 pixels and large cameos 122x98(However you cna take any cameo and paste it into paint and just change its size, as will be explained later). Now open up paint and change the properties of the paint so that the image size will be 512x512 pixels. Now start copying and pasting all your cameos in a grid like fashion, starting in the upper-left corner, and leaving no spaces between the cameos. Remember that small cameos are 62x50 and large cameos 122x98. Any spaces will cause for the white to become part of your cameo! However don't worry about any extra space that might be left if you have no more cameos to use. When you have pasted all your cameos, save the image in a .png format.

2. Remember I said generals uses a .tga format? Well XCC mixer can convert it to that. Now take a look at your Generals or ZH directory. A big difference between Generals and ZH is where the cameos are stored. Generals has them in Textures.big while ZH has them in EnglishZH.big . Now for the INI it is in INI.big . If you open the .big file you will see the folder Mapped Images. Go to it. Now go to TextureSize_512. This is where the Cameo info is.

3. To get the cameos in game we now have to put them in the right directory. So if you don't already have these folders the nyou need to make them.
For Generals:
For ZH:
Generals Zero Hour\Data\INI\MappedImages\TextureSize_512
Generals Zero Hour\Data\english\Art\Textures
In both cases the cameo sheet you made would go in the textures folder. Now you should see several folders when you go there, but you need to name your cameo sheet, so don't name them after the following files:
A good idea would be to make a new folder with the name of one of these but change the 2nd letter or whatever to an unused letter. Each of the above is for different factions, and the numbers on the end or the different verison of each. My example name would be SGUserInterface512_001.tga.

4. Now that you have all your directories set up and your cameo sheet(s) in place, you now only need to edit the .INI files. You can edit the one I have avaliable for download or simply extract your own .big files with the .big editor. Here's how one of the entries would look like using my downloadable cameo sheet:
MappedImage SASpyPlane
Texture = SRUserInterface512_001.tga
TextureWidth = 512
TextureHeight = 512
Coords = Left:373 Top:301 Right:433 Bottom:349
Status = NONE
The 1st line of this simply names the Cameo, the second is what image to look for(this is your cameo sheet). The next 2 lines simply tell the image specs, and the Coords tells where on the sheet the specific cameo is. It is simple to figure out, you just need to by looking at the image in paint, or you can edit an already existing INI which has sheet that has matching coordinates. Once you have named every image and given the correct coordinates, save the INI using the same base name as the sheet, and move the INI in the correct directory. The images are now ingame!

5.You’re not done yet, even though the cameos are in, nothing is said to have them! So go around and edit them in. Use the names you gave to the cameos in the INI and paste them over the images you want to replace. The Command button INI and the INI for all your units and buildings all have tags for their image. “ButtonImage“ for the small one and SelectPortrait for your large cameos.

Now you are Truly done!

AlphaJunior - - 2 comments

Hai!Can u explain on how to find out the coords of the images with paint.

Reply Good karma Bad karma+1 vote
AlphaJunior - - 2 comments

Never mind, i know how already.

Reply Good karma Bad karma+1 vote
RedBear89 - - 690 comments

Hey.. how i can make the coords..?

Reply Good karma Bad karma+1 vote
ab2531 - - 1,620 comments

Thanks for the tutorial! I would have never have guessed how it works alone. It is so different from modding RA2.

Reply Good karma Bad karma+1 vote
RandomGuyIsRandom - - 15 comments

You're a life-saver. I'm learning to edit stuff. After many times of giving up, I have been able to create my own faction, adding soundtracks using WorldBuilder, adding loadscreen, etc. Of course, I have to jump to different websites for any useful tutorial. I wish all those tutorials were kept in one place. Anyway, thank you very much for sharing your knowledge.

Reply Good karma Bad karma+1 vote
Guest - - 699,437 comments

This comment is currently awaiting admin approval, join now to view.

Post a comment
Sign in or join with:

Only registered members can share their thoughts. So come on! Join the community today (totally free - or sign in with your social account on the right) and join in the conversation.