Greetings fellow gamemakers,
Here is the
Conjured Body Armour that I have been talking about since v1.09. (you need that or higher because these scripts use the variables)
I have included several HUDs in this ZIP, but they are only for examples and place holders.
I didn't bother getting fancy with the HUDs, because I wanted to spend more time scripting and figured you would want to make your own anyway.
There is no model for the pickup yet (Dar13 is working on one now), so you will have to use a temp entity for now for testing.
I have also included the Multiple Timer Script that I wrote for the stock engine (again v1.09 or higher) because this script uses one of the timers for the body armour.
So there are 3 scripts in total...the multiple timer script, the body armour script, and a script for picking up the item.
The files in the zip have been placed in the proper folder structure to work with FPSC, so extract the files accordingly.
Once you have extracted all of the fles (scripts & HUDs) to the proper folders, then here is how you set it up...
1) Place three (3) batteries in your map. ( entities>scifi>items>battery )
2) Edit the first battery's properties to reflect the following changes...
a) Set its AI MAIN to
bodyarmour.fpi ( Files>scriptbank>conjured>bodyarmour.fpi )
b) Set the ALWAYS ACTIVE? to YES
c) Change its name to
bodyarmour (one word all lowercase)
3) Edit the second battery's properties to reflect the following changes...
a) Set its AI MAIN to
maintimer.fpi ( Files>scriptbank>conjured>maintimer.fpi )
b) Set the ALWAYS ACTIVE? to YES
4) Edit the third battery's properties to reflect the following changes...
a) Set its AI MAIN to
bodyarmourpickup.fpi ( Files>scriptbank>conjured>bodyarmourpickup.fpi )
Now run the test and you should be able to pick up the third battery just like a body armour.
Don't forget to place a few enemies and give yourself a gun & some ammo, so you can test the health losses.
You can toggle the armour on and off using the 'm' key. (I should change this to 'b' maybe?)
Your armour will run out after a given amount of time.
The time will pass faster when it is on.
You can tell when the armour is on or off by the amount of health you have. (500 health means its on and anything less means its off)
The HUD is displayed while on or off until the time runs completely out. (so you can still see how much you have left)
Have Fun!
If I forgot anything, just let me know and I'll correct it.