69 lines
1.8 KiB
C++
69 lines
1.8 KiB
C++
#ifndef LIGHTKEEPER_H
|
|
#define LIGHTKEEPER_H
|
|
|
|
#include <string>
|
|
|
|
#include <destrum/App.h>
|
|
#include <destrum/Scene/SceneManager.h>
|
|
#include <destrum/Graphics/RenderResources.h>
|
|
|
|
#include "destrum/Graphics/Resources/Cubemap.h"
|
|
#include "destrum/Graphics/Resources/Font.h"
|
|
#include "destrum/ObjectModel/GameObject.h"
|
|
|
|
#include <scenes/MainScene.h>
|
|
|
|
class CameraComponent;
|
|
class FirstPersonController;
|
|
class LightKeeper final : public App {
|
|
public:
|
|
LightKeeper();
|
|
virtual ~LightKeeper();
|
|
void customInit() override;
|
|
void customUpdate(float dt) override;
|
|
void customDraw() override;
|
|
void customCleanup() override;
|
|
void customFixedUpdate(float dt) override;
|
|
|
|
void onWindowResize(int newWidth, int newHeight) override;
|
|
void customWindowsMenu() override;
|
|
|
|
private:
|
|
void setupSkybox();
|
|
void drawCrosshair();
|
|
[[nodiscard]] CameraComponent* getSceneCamera() const;
|
|
[[nodiscard]] bool isPlayerViewActive() const;
|
|
|
|
// LightkeeperDebugUi.cpp
|
|
void updateDebugUi();
|
|
void drawDebugMenuBar();
|
|
void drawWindowMenu();
|
|
void drawTestWindow();
|
|
void spawnBall();
|
|
void saveCurrentScene();
|
|
void loadScene();
|
|
void createEmptyScene();
|
|
void findPlayer();
|
|
void submitDebugDraws();
|
|
void submitColliderDebugLines();
|
|
|
|
Camera camera{glm::vec3(0.f, 0.f, -5.f), glm::vec3(0, 1, 0)};
|
|
|
|
std::unique_ptr<CubeMap> skyboxCubemap;
|
|
MainSceneObjects mainScene{};
|
|
|
|
ImageID debug2DTexture{NULL_IMAGE_ID};
|
|
Font hudFont;
|
|
|
|
char scenePath[512]{"scenes/debug_scene.json"};
|
|
char newSceneName[128]{"EmptyScene"};
|
|
std::string sceneStatus;
|
|
bool renderColliders{false};
|
|
bool render2DShapes{true};
|
|
bool renderDebugLines{true};
|
|
bool showTestWindow{true};
|
|
bool useFreeCamera{false};
|
|
};
|
|
|
|
#endif //LIGHTKEEPER_H
|