OFPEC Forum

Editors Depot - Mission Editing and Scripting => OFP - Editing/Scripting General => Topic started by: rhysduk on 07 Jun 2004, 00:29:23

Title: Eventhandlers
Post by: rhysduk on 07 Jun 2004, 00:29:23
Hi guys,

I know how to use Eventhandlers to a certain ecxtent, but what i want to know is when a unit dies that has an Eventhandler attached to it, does this EH get deleted or not?

For example, a Vulcan has a "Hit" EH attached to it, when its destroyed and respawned, will the EH automatically be attached to this newly crate vulcan because it has the same name as the previous vulcan? Or do i have to assign a new eventhandler to it?

Rhys
Title: Re:Eventhandlers
Post by: Killswitch on 07 Jun 2004, 15:28:20
Yes, when a unit dies, the EH that was attached to it is "deleted".

This means that you have to addEventHandler the hit EH to each newly createVehicle:d Vulcan.

(Of course, vehicles that have EH:s defined in their config won't have this problem, since they have their EH:s inherently)

Title: Re:Eventhandlers
Post by: rhysduk on 07 Jun 2004, 22:54:45
Thanks Killswitch, much appreciated..

Topic to be left open.. more wuestion when i remember them  ::)

Rhys