More refactoring of the FSM to MainUI. Move the overlay out and some more.

This commit is contained in:
Zed A. Shaw 2025-02-21 00:19:35 -05:00
parent a7a60ad35c
commit 23ed1594f2
4 changed files with 106 additions and 82 deletions

View file

@ -1,20 +1,24 @@
#pragma once
#include "levelmanager.hpp"
#include <SFML/Graphics/RenderWindow.hpp>
#include "stats.hpp"
#include "overlay_ui.hpp"
namespace gui {
class MainUI {
public:
Stats $stats;
sf::RenderWindow& $window;
GameLevel $level;
sf::RenderWindow $window;
TexturePack& $textures;
OverlayUI $overlay_ui;
MainUI(GameLevel level) :
$level(level),
$window(sf::VideoMode({SCREEN_WIDTH, SCREEN_HEIGHT}), "Zed's Raycaster Thing")
{
$window.setVerticalSyncEnabled(VSYNC);
$window.setFramerateLimit(FRAME_LIMIT);
}
MainUI(sf::RenderWindow& window, GameLevel level, TexturePack &textures);
void debug();
void draw_stats();
void draw_blood();
void render();
void draw();
};
}