Home   Help Search Login Register  

Author Topic: invincibility  (Read 1387 times)

0 Members and 1 Guest are viewing this topic.

bobthedinosaur

  • Guest
invincibility
« on: 19 Jan 2004, 11:39:14 »
i found a giant script on the forums on how to make a unit invincible but i don't understand any of it, the other method i've found is to setcaptive true
is there any other easier command to make a unit unkillable? ???

Offline macguba

  • Former Staff
  • ****
    • macguba's operation flashpoint page
Re:invincibility
« Reply #1 on: 19 Jan 2004, 11:56:05 »
setCaptive true does not make a unit unkillable.   What it does is stop the enemy from shooting at the loon deliberately.    It can still be killed by blast, driving accidents etc.

The best way (I believe) of making a loon invincible is to use the eventhandler "hit" to make the loon setDammage 0 whenever he is hit.    Eventhandlers are like little script launchers that you can attach to unit and which activate when the event occurs.   There are about six of them, there's a list in the EdDepot somewhere and no doubt a tutorial.      However, you have to use the big script - invincibility is tricky and there is no absolutely certain way of achieving it.
Plenty of reviewed ArmA missions for you to play

GrimMonkey

  • Guest
Re:invincibility
« Reply #2 on: 19 Jan 2004, 18:29:35 »
Like Macguba said, EH's seem to be the only solution.

Code: [Select]
This AddEventHandler ["Hit", "(_this Select 0) SetDammage 0"]; This AddEventHandler ["Killed", "(_this Select 0) SetDammage 0"]
Just add that to the unit's init. field so he won't get injured when he gets shot.

Note: Sometimes they might die of an overload of attacks, I was testing this out and two guys were constantly firing, one threw a grenade and I died. This is your best bet for invincibility.


Beware the GrimMonkey

Offline Tomb

  • Contributing Member
  • **
  • in2 Metal? Go 2 my sig
Re:invincibility
« Reply #3 on: 19 Jan 2004, 18:39:03 »
the most extravagant way to become a "tank" is to make a small addon:


all ya need is to alter the "Armor" in the config. make it some 12000 or alike  ;D