OFPEC Forum
Editors Depot - Mission Editing and Scripting => OFP - Editing/Scripting Multiplayer => Topic started by: Echo Commando on 06 Dec 2003, 17:26:48
-
Hello All,
I'm making a multiplayer mission, and i need 2 things, a script, where i can buy weapons and ammo, and equipment from a truck or ammo crate...
And a bounty system, so you get the money to buy guns by killing enimies, but i want the bounty to varie, IE killing commander gets more then killing a soilder etc.... Anyone wanna help me out here?
(PS I did search for weapon purchasing scripts, but most of them don't explain how to change them, or don't use money.)
-
k then, here we go.
Firstly, in a script make this:
moneyplayer1 = *amount of starting money here*
moneyplayer2 = *amount of starting money here*
moneyplayer3 = *amount of starting money here*
ect.
for every player
Then make a script like this:
if (!alive man) then {moneyplayer1 = moneyplayer1 +*amount of money earned when some1 guys*}
for every man U wanna get a bounty from
and for buying, do something like this:
ammobox addWeaponCargo [1,"M16"]
moneyplayer1 = moneyplayer1 -*cost of M16*
or
"5TTruck" camcreate getPos carpark
moneyplayer1 = moneyplayer1 -*cost of 5ton truck*