Event count tracking and notification
The Counter component (Component) tracks the number of occurrences of specific events and notifies when a target count is reached. It is ideal for gameplay mechanics that depend on collecting items, completing objectives, or any scenario where counting discrete events triggers further actions.
Adding the Component
To add the Component, go to the Properties window, find and add the Component under the Horror Logic package.

Configuring the Component
Set two properties of the Component. For more information, see Counter.
Property | Description |
---|---|
Notify Key Value Event | When enabled, sends notification whenever the count changes. Disabled by default. |
Key Value | The total number of events to track. |
Usage
- The Counter component does not automatically detect events; it relies on other components (like Event Trigger) to increment its count.
- Use the Event Trigger component to listen for specific game events (e.g., OnPickedUp) and send increment commands to the Counter.
- When the Counter reaches the target Key Value, it emits the OnKeyValueReached event, which you can use to trigger gameplay actions.