Hi,
I'm having trouble sorting this out with the combination of MP scripting and the possibility of the killer being in a vehicle.
Basically, I want to detect who killed civilians and if they have killed 3 civilians to send them to a little cutscene. It worked ok in singleplayer but not on a dedicated server.
All the civilians have a killed eventhandler which creates an array of the things that killed them. Unfortunately if they are killed by a vehicle gunner this lists the vehicle and not the gunner himself. I can work around this by just adding all the crew of the vehicle into the array as well and removing the vehicle, but this seems unwieldy and slow.
I think my way of doing this is a pain and if anyone has any better ideas could you outline them (just in general, I should be able to figure out how to do the scripting)
e.g. what I do now is check the array created by the killed eventhandlers via a script running on the server. If one killer is in the list 3 times then they are sent as a publicvariable, which triggers a trigger (might change this to a publicvariableeventhandler). The script running off the trigger checks if the player is the same as the killer and if so runs the cutscene.