Add Dying animation

This commit is contained in:
Morph01
2024-08-22 17:53:25 +02:00
parent 1f52eb2c52
commit faf6a9116d
3 changed files with 828 additions and 110 deletions

View File

@@ -8,6 +8,7 @@
#include <godot_cpp/classes/navigation_agent3d.hpp>
#include <godot_cpp/variant/node_path.hpp>
#include <godot_cpp/variant/string_name.hpp>
#include <godot_cpp/classes/timer.hpp>
namespace blitz {
@@ -37,12 +38,14 @@ class Zombie : public godot::CharacterBody3D {
std::vector<godot::StringName> m_BodyPartsCollision = {"Neck", "Spine", "Hips", "LeftArm", "LeftForearm", "LeftHand", "RightArm",
"RightForearm", "RightHand", "LeftUpLeg", "RightUpLeg", "LeftLeg", "RightLeg", "LeftFoot", "RightFoot"};
int m_Health = 6;
godot::Timer* m_Timer;
void set_m_PlayerPath(const godot::NodePath& path);
godot::NodePath get_m_PlayerPath() const;
void hit_finished();
void apply_damage(int dam);
void connect_collision_shapes(const std::vector<godot::StringName>& body_parts);
void _on_timer_timeout();
};
} // namespace blitz