Parasite Host: Miner
The Miner Host is one of the three different types of corpses that can spawn throughout the levels. The other two are the Civilian and the Gunslinger. Former workers of the mine, they are both strong and well equipped with a pickaxe and dynamite. They are tanky, brawly units that look to overwhelm the player with a barrage of attacks. They also move faster then the other hosts, forcing the player to target these enemies down before they bring the run to an end. Like the other host's, the Snake will appear during each attack, allowing the player to score critical hits.
Behavior Tree
When unoccupied by a parasite the corpse will do nothing, so there is no need for idle behaviors. When it becomes occupied it will automatically know where the snake saw the player last.
Once the Miner has found the player, it will always move towards them without fail, only stopping for certain attacks like the Dynamite Throw and the end of the Pickaxe Attack.
The Miner will always use the Dynamite throw first if the player is far enough away provided it is not on cooldown.
The Miner will default to Stone Breaker and then the flail combo if the Miner is within 400 units of the player. If these two attacks are on cooldown, and the player is still close, the Miner will use the push.
Mechanics
Stone Breaker
Design: The miner lunges at the player, winding up and slamming their pickaxe down. The goal is to give the miner a distance closing attack that can setup for the flail combo attack. It's end animation mean's that this attack can be punished if it's successfully dodged.
Damage: 40
Frequency: Often
Movement Speed: 350 units per second
Code:
The zombie starts the animation and spawns a head in a random socket for 3 seconds.
On notify from the animation montage it creates a hitbox that deals damage and knocks the player back.
The knockback is tied to an event dispatcher and uses launch character.
Flail Attack
Design: The Miner Host flails around wildly, chasing the player while he does so. This attack punishes players with bad positioning or players who got themselves stuck in a corner.
Damage: 20 per hit (up to four hits)
Frequency: low
Movement Speed: 250 Units per second
Code:
The Behavior Tree Task sets the movement speed and has the Miner chase the player and then plays the montage, which shoots out four notifies.
Each notify runs an event on the Miner's blueprint that creates a damaging hitbox that also has knockback.
Once the animation has ended or is interrupted, it resets all variables and movement speed to defaults.
Push
Design: The push is an attack on the Miner with no cooldown. If the other attacks are on cooldown and the player is range, the Miner will always resort to this attack. It does a small amount of damage and knocks the player back. It's role is a filler attack that keeps the Miner an active threat between it's stronger attacks.
Damage: 20
Speed: 250 units a second
Frequency: Often
Code:
The Miner spawn's a snake head, and play's the shove montage, which fires off a notify that activates a hitbox attached to the hand.
This deals damage and knocks the player back a short distance if the player is hit.
Afterwards, it resets the blackboard values and then returns to chasing the player.