UnlockingGenerator
Gets called when the player is unlocking the generator.
Start a script section
!-- OnEvent UnlockingGenerator
-- require @evPlayer *evGenerator $evCanOpen $evIsAllowed
# Add your instructions here
- Group: PlayerEvents
- Cancellable: Yes
- Event data:
PlayerUnlockingGeneratorEventArgs
Injected variables
| Variable | Type | Description |
|---|---|---|
@evPlayer | player value | Gets the player who is unlocking the generator. |
*evGenerator | reference to Generator object | The generator that is involved in the event. |
$evCanOpen | bool value | Gets whether the player can open the generator. |
$evIsAllowed | bool value | Gets whether this event is allowed. Not allowing this event will not unlock the generator and no denied animation is played. |