From 6f7b9d89c4e65e99196a751e4c43711a573e9eb4 Mon Sep 17 00:00:00 2001 From: nathansmithsmith Date: Mon, 25 Sep 2023 21:35:26 -0600 Subject: Now switching cameras in game --- src/cameras.h | 10 +++++++--- 1 file changed, 7 insertions(+), 3 deletions(-) (limited to 'src/cameras.h') diff --git a/src/cameras.h b/src/cameras.h index c892ee1..debd658 100644 --- a/src/cameras.h +++ b/src/cameras.h @@ -3,8 +3,11 @@ #ifndef CAMERAS_H #define CAMERAS_H -#define CAMERA_DIS 5.0 -#define CAMERA_COUNT 1 +#define FIRST_PERSON_CAMERA_DISTANCE 5.0 + +#define THIRD_PERSON_CAMERA_DISTANCE (Vector3){0.0, 10.0, -20.0} + +#define CAMERA_COUNT 2 // Each camera has a game loop callback and a init callback. typedef void (*CameraInitCb)(Game * game, Camera3D * camera); @@ -14,7 +17,8 @@ extern const CameraInitCb cameraInitCallbacks[CAMERA_COUNT]; extern const CameraCb cameraCallbacks[CAMERA_COUNT]; typedef enum CameraId { - FIRST_PERSON_CAMERA + FIRST_PERSON_CAMERA, + THIRD_PERSON_CAMERA } CameraId; // A array of the cameras. -- cgit v1.2.3