;LAST UPDATE 2006/02/15 YAG
;BAS cabin lighting system - TJ 2003
;Improved as JASDF AB script by gachopin

_helo = _this select 0
_light = "F2light" createvehicle [0,0,0]
_light inflame true

#loop1
~0.005

_velo = (velocity _helo)
_posx = getpos _helo select 0
_posy = getpos _helo select 1

;_light setpos [_posx,_posy,getpos _helo select 2]
_light setpos (getpos _helo)
_light setvelocity _velo
? _helo animationphase "Ea" == 0:deletevehicle _light;exit
? (getdammage _helo) >=0.9:deletevehicle _light;exit
goto "loop1"