GIGA REFACTOR
This commit is contained in:
@@ -18,10 +18,10 @@ private:
|
||||
public:
|
||||
CastleTooltip(client::Client* client);
|
||||
|
||||
virtual void render();
|
||||
virtual void Render();
|
||||
|
||||
void setCastle(const game::TeamCastle* castle) { m_Castle = castle; }
|
||||
bool isShown() { return m_Castle != nullptr; }
|
||||
void SetCastle(const game::TeamCastle* castle) { m_Castle = castle; }
|
||||
bool IsShown() { return m_Castle != nullptr; }
|
||||
};
|
||||
|
||||
} // namespace gui
|
||||
|
||||
@@ -13,7 +13,7 @@ private:
|
||||
public:
|
||||
FrameMenu(client::Client* client);
|
||||
|
||||
virtual void render();
|
||||
virtual void Render();
|
||||
};
|
||||
|
||||
} // namespace gui
|
||||
|
||||
@@ -11,13 +11,13 @@ private:
|
||||
public:
|
||||
GameMenu(client::Client* client);
|
||||
|
||||
virtual void render();
|
||||
virtual void Render();
|
||||
private:
|
||||
void showTPS();
|
||||
void showStats();
|
||||
void showPlayers();
|
||||
void showLobbyProgress();
|
||||
void showTeamSelection();
|
||||
void ShowTPS();
|
||||
void ShowStats();
|
||||
void ShowPlayers();
|
||||
void ShowLobbyProgress();
|
||||
void ShowTeamSelection();
|
||||
};
|
||||
|
||||
} // namespace gui
|
||||
|
||||
@@ -12,15 +12,15 @@ class GuiManager {
|
||||
private:
|
||||
std::vector<std::unique_ptr<GuiWidget>> m_Widgets;
|
||||
public:
|
||||
GuiManager(){}
|
||||
GuiManager() {}
|
||||
|
||||
void renderWidgets() {
|
||||
void RenderWidgets() {
|
||||
for (auto& widget : m_Widgets) {
|
||||
widget->render();
|
||||
widget->Render();
|
||||
}
|
||||
}
|
||||
|
||||
void addWidget(std::unique_ptr<GuiWidget>&& widget) {
|
||||
void AddWidget(std::unique_ptr<GuiWidget>&& widget) {
|
||||
m_Widgets.push_back(std::move(widget));
|
||||
}
|
||||
};
|
||||
|
||||
@@ -14,9 +14,9 @@ protected:
|
||||
public:
|
||||
GuiWidget(client::Client* client) : m_Client(client) {}
|
||||
|
||||
client::Client* getClient() { return m_Client; }
|
||||
client::Client* GetClient() { return m_Client; }
|
||||
|
||||
virtual void render() = 0;
|
||||
virtual void Render() = 0;
|
||||
};
|
||||
|
||||
} // namespace gui
|
||||
|
||||
@@ -26,11 +26,11 @@ public:
|
||||
MainMenu(client::Client* client);
|
||||
~MainMenu();
|
||||
|
||||
virtual void render();
|
||||
virtual void Render();
|
||||
|
||||
const server::Server* getServer() const { return m_Server.get(); }
|
||||
const server::Server* GetServer() const { return m_Server.get(); }
|
||||
private:
|
||||
bool startServer();
|
||||
bool StartServer();
|
||||
};
|
||||
|
||||
} // namespace gui
|
||||
|
||||
@@ -18,10 +18,10 @@ private:
|
||||
public:
|
||||
MobTooltip(client::Client* client);
|
||||
|
||||
virtual void render();
|
||||
virtual void Render();
|
||||
|
||||
void setMob(const game::Mob* mob) { m_Mob = mob; }
|
||||
bool isShown() { return m_Mob != nullptr; }
|
||||
void SetMob(const game::Mob* mob) { m_Mob = mob; }
|
||||
bool IsShown() { return m_Mob != nullptr; }
|
||||
};
|
||||
|
||||
} // namespace gui
|
||||
|
||||
@@ -17,9 +17,9 @@ private:
|
||||
public:
|
||||
SummonMenu(client::Client* client);
|
||||
|
||||
virtual void render();
|
||||
virtual void Render();
|
||||
private:
|
||||
void setSummonMax(int valueIndex);
|
||||
void SetSummonMax(int valueIndex);
|
||||
};
|
||||
|
||||
} // namespace gui
|
||||
|
||||
@@ -37,12 +37,12 @@ public:
|
||||
TowerGui(SDL_Window* wndow, SDL_GLContext glContext, td::render::Renderer* renderer);
|
||||
~TowerGui();
|
||||
|
||||
void render();
|
||||
void Render();
|
||||
private:
|
||||
void initWidgets();
|
||||
void tick();
|
||||
void beginFrame();
|
||||
void endFrame();
|
||||
void InitWidgets();
|
||||
void Tick();
|
||||
void BeginFrame();
|
||||
void EndFrame();
|
||||
};
|
||||
|
||||
} // namespace render
|
||||
|
||||
@@ -13,9 +13,9 @@ private:
|
||||
public:
|
||||
TowerPlacePopup(client::Client* client);
|
||||
|
||||
virtual void render();
|
||||
virtual void Render();
|
||||
|
||||
void setClickPos(const glm::vec2& worldPos);
|
||||
void SetClickPos(const glm::vec2& worldPos);
|
||||
private:
|
||||
static constexpr float m_TowerPopupTileWidth = 200.0f;
|
||||
static constexpr float m_TowerPopupTileHeight = 200.0f;
|
||||
|
||||
@@ -18,11 +18,11 @@ private:
|
||||
public:
|
||||
UpdateMenu(client::Client* client);
|
||||
|
||||
virtual void render();
|
||||
virtual void Render();
|
||||
private:
|
||||
void checkUpdates();
|
||||
bool isUpdateChecked();
|
||||
void renderErrorPopup();
|
||||
void CheckUpdates();
|
||||
bool IsUpdateChecked();
|
||||
void RenderErrorPopup();
|
||||
};
|
||||
|
||||
} // namespace gui
|
||||
|
||||
Reference in New Issue
Block a user