1
0
mirror of https://github.com/rwengine/openrw.git synced 2024-11-25 11:52:40 +01:00
openrw/rwgame/states/DebugState.hpp
Filip Gawin 495c831972 Mark classes as final
It lets complier to make extra optimization.

See:
https://gcc.godbolt.org/#compilers:!((compiler:g6,options:'-O2+-Wall++-
xc%2B%2B+-
std%3Dc%2B%2B11',sourcez:MYGwhgzhAECC0G8BQAHArgIxAS2ALiWiOgDdsAnAFzTBFIHtsATaAMwAoBKaAXmgAYA3EgC%2BwpKEgwAQtDzR0WXHESpMOfIWIlGLDt1bYAdrWj0SAU3LlmF4WKQTwUaAGE5C9cvjJFGgsQMzGxcZpbWtvbiOsGs9PTs0gBk0BjcyIEYAHT69o4xLBhg5OyuKcDpWkTAOVz2QAA%3D%3D)),filterAsm:
(commentOnly:!t,directives:!t,intel:!t,labels:!t),version:3
2018-07-07 22:55:10 +02:00

46 lines
1.1 KiB
C++

#ifndef DEBUGSTATE_HPP
#define DEBUGSTATE_HPP
#include "State.hpp"
class DebugState final : public State {
ViewCamera _debugCam;
glm::vec3 _movement{};
glm::vec2 _debugLook{};
bool _freeLook = false;
bool _sonicMode = false;
bool _invertedY;
std::shared_ptr<Menu> createDebugMenu();
std::shared_ptr<Menu> createMapMenu();
std::shared_ptr<Menu> createVehicleMenu();
std::shared_ptr<Menu> createAIMenu();
std::shared_ptr<Menu> createWeaponMenu();
std::shared_ptr<Menu> createWeatherMenu();
std::shared_ptr<Menu> createMissionsMenu();
public:
DebugState(RWGame* game, const glm::vec3& vp = {},
const glm::quat& vd = {1.0f, 0.0f, 0.0f, 0.0f});
void enter() override;
void exit() override;
void tick(float dt) override;
void draw(GameRenderer* r) override;
void handleEvent(const SDL_Event& event) override;
void printCameraDetails();
void spawnVehicle(unsigned int id);
void spawnFollower(unsigned int id);
void giveItem(int slot);
const ViewCamera& getCamera(float) override;
};
#endif // DEBUGSTATE_HPP