feat: implemented recoil

This commit is contained in:
Sara 2025-07-19 14:26:46 +02:00
parent a7b3f97b3b
commit 58e90780d5
6 changed files with 56 additions and 7 deletions

View file

@ -8,6 +8,8 @@ class PlayerCamera : public Camera3D {
static void _bind_methods();
void on_look_input(Vector2 input);
void update_fov();
void ready();
void process(double delta);
protected:
void _notification(int what);
@ -16,6 +18,8 @@ public:
void set_fov_factor(float value);
float get_fov_factor() const;
void recoil(float r);
private:
float base_fov{ 60.f };
float fov_factor{ 1.0f };