OFPEC Forum
Editors Depot - Mission Editing and Scripting => OFP - Editing/Scripting Multiplayer => Topic started by: LightWalker on 18 Mar 2003, 22:10:48
-
Guys, how can I determine who killed the victim in a multiplayer map?
Lets say we play with 6 players a multiplayer map and a soldier (west of east) is shot.... how can i find out who did it?
-
I don't know, but I suspect an eventhandler might help. Check out the official command ref, both the command addEventHandler and the Scripting Topic Event Handlers. Once you've had a look at those you'll know the right keywords to use to search the FAQ and forum.
-
That would only work from upgrade 1.85 and above. But there must be a way to determine it because OFP keeps track of a personal score of each player.
-
That would only work from upgrade 1.85 and above. But there must be a way to determine it because OFP keeps track of a personal score of each player.
Yes off course, but version 1.85 was it, which opened up
this option for us users. Before it wasn't possible and ppl
were asking for that, so BIS decided to enable that for
us. ;)
-
The only thing you could approach to check who did the kill
is by saving the rating of every unit to a variable, everytime
it changes.(you will need a variable for each unit). Before you
do the command: variable = rating unitxx - you need to compare the value of the variable to the rating.
Now if let's say unit: victim1 get's killed, and you know the
rating off all players (remember it's saved into variables)
check who's rating has changed and whoop - he was it.
:note - this method isn't very accurate, but at least it's a
workaround for versions before "eventhandlers"
~S~ CD