Home   Help Search Login Register  

Author Topic: Friendly Fire  (Read 451 times)

0 Members and 1 Guest are viewing this topic.

fragger

  • Guest
Friendly Fire
« on: 08 Feb 2004, 20:13:11 »
Im making a multiplayer mission, and I want a script to check if the player on the side of the civilians kills another civilian (friendly fire). If so then I want the game to end.  I also dont want the game to end if the opposing player kills a civilian. How do I do this?  ???

Offline dmakatra

  • Members
  • *
  • Better known as Armsty
Re:Friendly Fire
« Reply #1 on: 08 Feb 2004, 20:16:08 »
You need to fiddle with EHs. Launch a script like this in the EH:

_killer = _this select 0

? _killer side == civilian : forceend true

Or something like that, but you get the picture?

:beat: *Gets Shot* :beat:

fragger

  • Guest
Re:Friendly Fire
« Reply #2 on: 08 Feb 2004, 20:24:57 »
Kind of, i've never used event handlers before but i'll give it a try
i'll look in the editors depot

Offline macguba

  • Former Staff
  • ****
    • macguba's operation flashpoint page
Re:Friendly Fire
« Reply #3 on: 08 Feb 2004, 22:49:19 »
There's a very good thing on EH ... can't remember if its a tute or in the FAQ.   There's something in the comref too.   They are not hard to use and as Armsty says will solve your problem perfectly.

The point is that that you attach the EH "killed" to the loon you don't want to die.   If he does die, the EH detects who killed him:  the script (written by you) called by the EH then checks to see who killed him and what the consequences should be.
« Last Edit: 08 Feb 2004, 22:51:09 by macguba »
Plenty of reviewed ArmA missions for you to play