TUTORIAL ON HOW TO GET SITH TROOPER WORKING IN-GAME
This is fairly simple really. If you know how to set up sides, then you know how to get the Sith Trooper working in-game correctly.
First step, of course, is to create your mod world, if you haven't done so already. Let's use data_ABC as an example for the tutorial.
Now, second, is to set up your side. So, go into your data_ABC/sides folder, and the create a folder, and name it whatever you want (I recommend using a quick three-letter name for the side, but you can name it whatever). Let's say our new side's name is "sth".
Now go into your newly-created sth folder, and create the following folders: ODF, MSH, and REQ. Once you're done, then go to your assets. Copy the Common folder from your Assets/Sides and paste it into your data_ABC/Sides folder.
Now go to any side in the assets (such as the Rep side, or Imp side... doesn't really matter either way). And copy the REQ file you find in the folder (so for Rep, it'd be the Rep.req you find in your Assets/Sides/Rep folder).
Take that file, and paste the copy into your data_ABC/Sides/sth folder (alternatively, you could just create a new notepad document and save it as an REQ, but it's easier to use an REQ from the assets, since it's basically all set up for you).
Now open the file. If you used the Rep.req file, it should look something like this:
Now, delete all the lines referencing to the units, vehicles, etc. Then, in the space where the Republic units were, type in the name of your unit (let's just call him sth_inf_sithtrooper).
Your REQ should now look something like this:
Now, save the REQ, and exit out. Rename the REQ to sth, or whatever you named your side. Now go into the REQ folder you made in your side. You'll want to make an REQ for your unit. Either make one from scratch, or copy one from the assets to use as a template. Name this REQ "sth_inf_sithtrooper", the same thing you had put in your sth REQ.
Now inside this REQ, you want to call for the ODF of your unit. So type in these lines:
Code: Select all
ucft
{
REQN
{
"class"
"sth_inf_sithtrooper"
}
}
So now your REQ should look like this:
Now that your REQ is calling for your ODF, you'll need to make one in the ODF folder. I recommend copying one from the assets to use as a template. I'm going to use the "rep_inf_default_rifleman" ODF. Name your new ODF "sth_inf_sithtrooper".
So now that you have your ODF in your side's ODF folder, open it up. If you're using the rep_inf_default_rifleman ODF, it should look like this:
(It might also be a good idea to copy the rep_inf_default to your ODF folder as well, since your ODF is calling for it as the base class.)
Now we want to tell it to use the Sith Trooper MSH. So at the top of your ODF, under Properties, type these lines:
GeometryName = "sth_inf_sithtrooper"
GeometryLowRes = "sth_inf_sithtrooper"
FirstPerson = "REP\reptroop;rep_1st_trooper"
--note: this line calls for the First Person geometry; I'm not sure whether you definitely need it or not, but it might be a good idea to copy the "rep_1st"trooper" files from the Rep side into your side's MSH folder, just to be safe.
So your ODF should now look something like this:
As for the weapons, I'm not going to tell you how to go about changing them, but if you're using the rep_inf_default_rifleman ODF, search through the Assets/Sides/Rep folder for all the weapons that the ODF is calling for (don't forget to copy the MSH files as well as the ODF files for the weapons).
Now, take your sth_inf_sithtrooper MSH and TGA files, and paste them into your data_ABC/Sides/sth/MSH folder.
Now go to data_ABC\_BUILD\Sides and create a new folder and name it STH.
Then copy the munge.bat and clean.bat from the ALL folder and paste them in your STH folder and you're done.
And now, your side should be all set up. Now we need to go call for it in the LUA. I'm not going to go into too much depth here, but your LUA should look something like this:
Now munge your map (remember to munge your new side as well), and test. Hope this helps.