Killed/MPkilled eventhandler does not trigger when helicopter is sunk into water, despite alive script command returns false on the same vehicle.
- Legacy ID
- Operating System
- Windows 7
Put down a helicopter, add a killed EH on it. Fly it into water. The EH won't trigger.
@KK - Yup, my bad. Alive returns false on helicopters, but not on ground vehicles. Correcting the description.
edit: also on jets - edit2 : scratch that, killed EH works on jets
So yeah, alive still returns true on ground vehicles. Adding some context here:
I wanted to replace a continuous respawn loop with killed EH (performance ftw!), but I figured out that there is a problem when the vehicle gets into a water. At the moment I see no workaround here, as hit/hitpart/dammaged/handledamage don't return anything either when the vehicle gets destroyed/disabled in the water.
@Gippo - This approch is very smart and I have the same problem (https://github.com/Giallustio/HeartsAndMinds/issues/52#issuecomment-168059442).
A workaround could be check the height for below 0 and briken engine. Happy New Year Gippo. A EUTW player.
@harmdhast: indeed, but check with a helicopter for example. It is totally destroyed (afaik), but no Killed EH is triggered. Bottom line is still, that the Killed EH is still not reliable on vehicles.
@TheMasterofBlubb: Well, sure, but that would need a loop, so why use the killed eventhandler at all. Ideally, you should be able to do this with only using killed EH.
@harmdhast: When you land a helicopter on water. The engine is broken by water and the helicopter is starting to fall under water. When it touchs the underwater ground, the heli is destroyed. But the EH isn't fired.
@Gippo - Could you replace in summary, description and Steps To Reproduce the word "vehicle" by "helicopter" to clarify the feedback ?