66 lines
1.4 KiB
C++
66 lines
1.4 KiB
C++
#pragma once
|
|
|
|
#include "Level.h"
|
|
#include <cstdint>
|
|
|
|
namespace Game
|
|
{
|
|
enum class CameraMode
|
|
{
|
|
Walk,
|
|
Freefly,
|
|
};
|
|
|
|
enum class InputMode
|
|
{
|
|
UI,
|
|
Game,
|
|
};
|
|
|
|
struct Time
|
|
{
|
|
double Now = 0.0;
|
|
double Delta = 0.0;
|
|
int64_t NowHP = 0;
|
|
int64_t DeltaHP = 1000;
|
|
int64_t StartTime = 0;
|
|
};
|
|
|
|
struct PlayerData
|
|
{
|
|
Transform FreeflyCamTransform;
|
|
float FreeflyXRot = 0.0f;
|
|
float FreeflyYRot = 0.0f;
|
|
float WalkXRot = 0.0f;
|
|
float WalkYRot = 0.0f;
|
|
Transform PlayerCamTransform;
|
|
CameraMode CameraM = CameraMode::Freefly;
|
|
InputMode InputM = InputMode::Game;
|
|
};
|
|
|
|
struct InstanceDebugData
|
|
{
|
|
uint16_t SelectedDebugLevel = UINT16_MAX;
|
|
uint64_t ImguiIniSize = 0;
|
|
char ImguiIni[4096]{0};
|
|
static constexpr uint32_t MaxAssets = 128;
|
|
uint32_t AssetCount = 0;
|
|
Generated::AssetHandle AssetHandles[MaxAssets]{0};
|
|
char AssetHandlePaths[MaxAssets][128];
|
|
bool ShowImguiDemo = false;
|
|
uint8_t DebugCardRotation = 0;
|
|
bool ShortenLogFileNames = true;
|
|
};
|
|
|
|
struct GameInstance
|
|
{
|
|
bool IsInitialized = false;
|
|
uint64_t Size = sizeof(GameInstance);
|
|
uint64_t UsedScratchAmount = 0;
|
|
Time Time;
|
|
PlayerData Player;
|
|
Level GameLevel;
|
|
InstanceDebugData DebugData;
|
|
};
|
|
} // namespace Game
|