Dicewars-Siedler/src/game/GameLayer.h
2026-02-08 13:02:46 +01:00

47 lines
1.3 KiB
C++

//
// Created by sebastian on 24.12.25.
//
#ifndef DICEWARS_SIEDLER_GAMELAYER_H
#define DICEWARS_SIEDLER_GAMELAYER_H
#include "../engine/layer/Layer.h"
#include "../engine/platform/glfw/MousePicker.h"
#include "../engine/renderer/Renderer.h"
#include "../engine/renderer/loader/Loader.h"
#include "../engine/renderer/model/TexturedModel.h"
#include "../engine/layer/entities/Camera.h"
#include "../engine/renderer/MasterRenderer.h"
#include "hexWorld/Map.h"
class GameLayer: public Layer {
public:
GameLayer();
~GameLayer() override = default;
void onAttach() override;
void onDetach() override;
void onUpdate() override;
private:
Loader loader;
TexturedModel texturedModel;
std::unique_ptr<Entity> entity;
std::unique_ptr<Camera> camera;
std::unique_ptr<Light> light;
std::unique_ptr<MousePicker> mousePicker;
std::unique_ptr<MasterRenderer> renderer = std::make_unique<MasterRenderer>();
std::shared_ptr<TexturedModel> hexModelDefault;
std::shared_ptr<TexturedModel> hexModelWood;
std::vector<std::shared_ptr<Entity>> tileEntities;
std::shared_ptr<TexturedModel> treeModel;
std::unique_ptr<Entity> treeEntity;
std::vector<std::shared_ptr<Entity>> mapEntities;
std::unique_ptr<Map> map;
};
#endif //DICEWARS_SIEDLER_GAMELAYER_H