After years of conflict, the Allies are finally on the brink of victory. Cowering behind the walls of the Kremlin, the Soviets decide to turn to one last act of desperation - the use of an experimental time travel device. The mission: to go back in time to eliminate Albert Einstein before he creates the technologies that will lead the Allies to ultimate victory. After a successful mission, the Soviets return to the present and find the Allied position weakened. But before they can truly celebrate, they find out their actions have spawned a new threat and global superpower: the mysterious, technologically-advanced Empire of the Rising Sun. Welcome to World War III.
Continuing the Hooked on CnC Tutorial for RA3, We take a few more steps on making your unit yours Tutorial originally Posted by Jackal16, Tutorial written by EvilConker. *Warning! This Tutorial is outdated. Sorry.
Posted by Jason_Zombolt on Jun 11th, 2010
Basic Client Side Coding.
Mod SDK Guide
Please note that when copying code from the tutorials, you may have to replace the speech marks with your own as this has been known to cause problems.
How to change unit icons
So, this, is, the, cameo tutorial. Cameos, in case you didn’t know, are those images that you use for the icons of units, so
when you train something at a building, or build a building, you know what you’re training. So as you see, this is very important
for new units, or editing existing ones. So, today we’re going to edit the cameo for a new unit, lets take that mytank one.
Currently, here’s it’s main settings:
The two things that will change our cameos is the two areas:
Now, we just change both the things in the quotations to: “Portrait_mytank” Of course, the script asks for a button and a portrait,
and yes, you could do two different images, but for the sake of basics, we’ll make both the same portrait.
Now, close it, and we’re going to our images folder in: C:\RA3 MOD SDK\Art\images
If you see the harbringer portraits, you got the right place. Now, we’re going to copy the .xml which is SampleUpdatedPackedImages, lets
just call it SampleUpdatedPackedImages 2, now, open it up, and delete everything untill you got something that looks like this:
Ok, now, what we do is that we change every instance that says “Portrait_AlliedHarbringerGunship” to “Portrait_mytank” There are 4.
Once you’ve done all that, save and quit the .xml. Now, what we need to do, is actually make the portrait. Use your favorite drawing
program that can make tga’s (I made my picture in flash, then copied it over to gimp) but the important thing is THAT YOU NAME IT”Portrait_mytank” and you MUST save it in the images folder alongside the portrait for the allied harbringer.
Note: The dimensions are optimal at 128 X 128 or 76 X 106, in reality, it’s going to get resized anyway, but, I did it like that.
Now let me just explain what we just did, any new cameo assets MUST be taken in through the SampleUpdatedPackedImages, or else, they won’t be used.
Ok, one final step left here, go to your mod.xml, and at the bottom, before the /assetdeclaration tag, put this:
Now, build your mod, and enjoy, if it’s not working, go check your names, they must all be EXACTLY the same.
How to edit sounds
Ohai again, and welcome to the second tutorial I (EvilConker) am making for this fine site right here. Ok, so, today, we’re going to be changing unit
sounds (oh boy!) This is helpfull, if you want to make a unit, but don’t want to re-use any sound banks. Just a note, sound bank is a term for a unit’s sounds
and voices. Ok, we’re going to be using our new unit, mytank, that Jackal and Overmind helped you make in the last couple of tuturiols (see: Modding your first unit)
Now, what we do, is that we open up mytank.xml (or whatever you named it) and we’re going to go to the deep bottom of the file, you should see something
like this at the last lines of the file:
If you can’t find it, search for “AudioArrayVoice.”
Now we’re going to need to change all of these names, they just point to what MP3’s we want to use for the voices in SoundEffects.xml which we’ll get
to in a moment.
So, change all the things that say Gaurdian, to mytank, leave all the ALL’s and anything that comes after the mytank. So, it should look like this:
Ok, we’re done here, close, and go to the sample mod, here you’ll find a number of xml’s, we need the one called “SoundEffects.xml” Copy it, and bring it to
your mod’s folder.
So, I assume now that you have it open, so, you should see a ton of random stuff, DON’T DELETE ANYTHING I DON’T TELL YOU TO.
Delete everything from:
Because those are all for sound effects, which I’m assuming you don’t have. We’re focusing on voices here, but sound effects work almost exactly the same way.
So what we do is that we’re going to look at the first block:
This is the voice bank for the unit’s attack voice, when you tell it to go destroy something.
Now, what we’re going to first, change the name of the sound bank, just remove the Harbringer part, and replace it with “mytank” so it should read:
So, now we have a list of random text that has labeled around them.
Their names only hold organizational value, but, just to be organized, change the “AUHarbi” to “AUmyta” On each one, so you should now have a list of files saying:
These tell the game which sounds it can randomly pick from when your clicking on a unit (since we’ve evolved since the 1990’s, units won’t say the same thing twice,) you can have more or less then the ones given.
So now you’re going to actually make the sounds, for skimming it purposes, unless you’re going to use them, delete every other little box of text under this one
but be carefull not to delete or bad things will happen.
Now, you have to make a bunch of Wav’s of your unit talking, a wav is just a sound file, most voice recording and sound recording programs can make them, while naming your files
I need to bring your attention to the last part of those names we just edited.
See where it says voiAttacka? Well, that last letter, as you might know, isn’t the last word in Attack, it’s the first letter in the alphabet, see how the
next one has a random b at the end of voiAttack, so the next one’s voiAttackb? Well, in case you didn’t notice what I’m getting at, it’s organized
so that each file has a different letter in the alphabet, this has numerous advantages, such as the fact that it keeps all your sound files in one place.
So I suggest you do it.
Anyways, back to making those unit sounds, so make some wavs of your unit saying stuff, and BE SURE TO SAVE THEM AT THIS ADRESS:
This points to your sound folder that’s in the audio folder that’s right under the art folder in the main MOD SDK folder.
THIS IS WHERE ALL YOUR SOUNDS SHOULD BE.
The harbringer probably has a couple there already, as they came with the mod sdk.
So, where were we?
Oh yes, so now that you have files labeled “AUmytan_voiAttack” with the last letter going from a-f, go to your audio folder in the main Mod SDK folder.
Here you’ll find two folder’s named ModkitMP3Examples, and Sound, which is where our unit speeches are located, you’ll also find a file called AudioAssets.
This is the file we’re looking for, now, we need to copy it, and name it “AudioAssets2″ Open it up, delete everything from:
BUT DO NOT DELETE THOSE.
Ok, now just paste this in the middle:
Now, let me explain what these peices of codes are, I’ll break it down.
So, now that we’re done here, lets GTFO the file, and go to mod.xml in our mod’s file.
And at the end of it, but not before AssetDeclaration , past this in:
Then build, and we’re done.
If it doesn’t work, remember, you have to rewrite every quotation mark you copy from here.
Sorry for the long time between tut post, as I was learning myself. I'll have more sooner than last time. And Remember, Have Fun, and Happy Modding!