Tribes 2 Links: | Weapons | Armor | Vehicals | Packs, Deployables | Official Map Editor Guide | Scripting |
This is another great tutorial put out on Vengeance Studios: Tribes 2 Editing by SmOkkin'Joe. Thanks!
By:
SmOkkin'
Joe Summary: Grenades are probably the easiest things to add into Tribes2 along with armors. This tutorial will explain how to add them in. I will explain the process of creating a new basic boost grenade and my very own Confusion Grenade. First off, A Grenade is a different type of weapon than the weapons. It is thrown and it doesn't have to be triggered to be blown up. There are Weapons, Grenades, Mines, and Beacons. Unlike Tribes1, the mines in Tribes2 are considered "mines" and not "grenades". Also, if a file has what would be considered two words, such as "flash grenade", instead of writing it like that, say this FlashGrenade so that each new capital letter is the start of a new word. **Note: Save allot. this stuff can be a PITA (Pain In The A--) if you crash and have to start over or accidentally kick the power plug switch. SAVE ALLOT** 1) Here are some little tricks to keep you going. First go into the base folder and open the scripts.VL2 file. I'm assuming that you don't know jack, but if you do, bear with me. Unzip the Scripts.Vl2 file into the base folder. You will see a folder now called scripts. Then Unzip the same scripts.Vl2 file into either the base folder or the scripts folder, but when it asks for a name in that little box, make it "Oscripts" (for Original Scripts). this will be your backup folder where you can replace good files with bad ones. The second little thing is a nice program to make. Open up MS notepad in the start menu, and copy this down: del scripts/*.cs.dso del scripts/weapons/*.cs.dso del scripts/vehicles/*.cs.dso del scripts/packs/*.cs.dso del scripts/turrets/*.cs.dso Then click "save as" and name it Delete_DSO.bat (MAKE SURE THE SAVE TYPE IS ALL FILES AND NOT TEXT FILE). The reason that we are doing this is because the game creates cs.DSO files from every startup. The game tends to use these first if they are there rather than the .CS files, so if they are there, you're files wont be executed and run. save this to you're scripts folder and execute it before you run the game every time. another thing is that if you open them in the text editor, they're encoded and look like the matrix. 2) First off I take the Scripts/weapons/Grenade.cs file and open it up in my text editor. (I use MSVC++ and it works great. I also use one called "GWD Text Editor" which has a very cool "replace in files function"). Anyways, so you've opened up the Grenade.cs file. Next save it "as" BoostGrenade.cs and then make sure that in the weapons folder there is a BoostGrenade.cs and a Grenade.cs file. If there are continue, if not re-try what I just went through. 3) now that you have this new grenade file you have to edit it to make it into a boost grenade that boosts the player. go to your editor's edit menu (most likely) and find the replace option. replace the word Grenade with BoostGrenade, but go slowly because you don't want to replace the Damage Types, or anything with a .dts ending(3-d models of the game) or a wav ending(sounds). also replace HandGrenade with boost grenade. replace them in that order though. otherwise it'll replace HandGreade with BoostGrenade and then when you replace Grenade with BoostGrenade you get stuff like "BoostBoostGrenade" 4) okay find the line that reads KickbackStrength = 2000 (I think). Change the value from 2000 to 15000 (that is what I use to boost a juggernaut) then add the line function: 1000 is
the time- 1000 = 1 sec I think. Ok, now the top section is what the weapon is displayed as. The second half translates inside the computer, that the word Grenade in the quotes should refer to the file Grenade.cs (notice the NameToInv). this is easier to see on the Whiteout Grenade. The top is what the Hud menu say, and the bottom says that that menu item's info is contained within the file FlashGrenade. then add in your boost grenade so that it turns into this. keep the order and add a number. the new stuff is in Blue: Ok then
save the InventoryHud.cs file and make the
changes. This was
found under the light armor information data,
there will be one under the medium male and
heavy male too. no need for the female and
Bioderm, they just use the same data, different
model. This
means that the light armors can all carry
"4" Boost Grenades make sure you
decide on your numbers here. also make sure you
write the CS file name and not what will appear
in the Hud menu. Next add your boost grenade in
the same way to the other armor's inventory. Now
save the file and continue on to 7. Now take
a wild guess at what you're going to do next.... This
file clears the inventory I think. once again
make sure it's the file name and NOT the HUD
name. Ok then add the line:
This
says that the sixth hand weapon is the
CameraGrenade (ItemDataName) and the
ammoDataName is CameraGrenade. the Slot where it
is stored/thrown from is 0 and the BMP for the
HUD is the .PNG file. ** Note
the bitmap name can be any of the HUD *.png
files (such as the shrike or even Spinfusor one)
** Then
save the file as it is. (hud.cs) |
Confusion
Grenade This one is simple now that you know how to make a grenade. just create another grenade called ConfusionGrenade.cs and add it in the same way. i edited the explosion and where it says the shake camera duration,amp (amplitude), and other lines in explosion, just make sure that shakeCamera = true; I set the duration to 10 seconds and the amp is high. is is based on the x,y,z axis "x" and "y" being side-to-side, front-and-back and "z" being up-and-down. shake the numbers up a bit for different effects. That's it! Have fun. Also add both of these to the AmmoPack by opening AmmoPack.cs Turn this: Into this: And then
find this: |