Damageable Patrol Monster
- com.yahaha.sdk.horrorgameassets
The Damageable Patrol Monster package configures a model that actively pursues and attacks the player when they enter its trigger zone. This monster can also take damage from both player characters and non-player characters (NPCs), adding dynamic combat and AI behavior to your game.
Package structure
- Damageable Patrol Monster (Parent Object)
- TriggerArea (Child Folder)
- MonsterSmart (Child Folder)
- [Trigger] Enable logic (Child Object)
TriggerArea
The TriggerArea component defines the detection zone around the monster. When the player enters this zone, the monster will become alert and initiate pursuit.
MonsterSmart
The MonsterSmart smart asset contains configurable properties that control the monster's movement, behavior, health, and events.
Property | Description |
---|---|
Move Speed | How fast the monster moves during its patrol when the player is outside the alert radius. Ranges from 0 to 15. Default: 4. |
Acceleration | How fast the monster runs during its patrol when the player is detected within the alert radius. Must be 0 or greater. Default: 30. |
Alert Radius | The distance within which the patrolling monster detects and pursues the player. Note that the monster will pursue regardless if the player doesn't hide. Must be 0 or greater. Default: 10. |
Patrol Duration | Duration (in seconds) for which the monster patrols before stopping or changing behavior. Must be 0 or greater. Default: 20. |
Patrol Delay | Delay (in seconds) before the monster starts patrolling after being triggered. Must be 0 or greater. Default: 5. |
HP | Health points of the monster. Ranges from 1 to 2147483647. Default: 1. |
Model List
- Monster: The model representing the patrolling monster with health points.
Event List
- OnPatrolStart: Triggered when the monster begins its patrol.
- OnPatrolEnd: Triggered when the monster ends its patrol.
- OnDeadEvent: Triggered when the monster’s HP reaches zero.
- OnRevivalEvent: Triggered when the monster respawns.
- OnDamageEvent: Triggered when the monster takes damage.
Action List
- StartPatrol: Initiate the monster's patrol behavior.
[Trigger] Enable logic (Child Object)
Events: All trigger zone and trigger events related to TriggerZone.
Action: StartPatrol: Initiate the monster's patrol behavior.
Related components
This package is commonly paired with the Wooden Staff (HandProp), which has an attack power to damage the monster.