|
VoltMod
C++23 framework for CS2 server plugins
|
One layout's player screens, each created the first time something draws for that slot. More...
#include <PlayerScreens.hpp>
Public Member Functions | |
| PlayerScreens (ScreenManager &screens, std::string layout) | |
| Screen & | For (int slot) |
| Screen * | Find (int slot) |
One layout's player screens, each created the first time something draws for that slot.
A player screen costs an entity, so this makes one per player who is actually shown the layout rather than one per connected player. A screen removes its entity when its slot changes hands and respawns for the next player on Screen::EnsureSpawned.
Definition at line 19 of file PlayerScreens.hpp.
| VoltMod::PlayerScreens::PlayerScreens | ( | ScreenManager & | screens, |
| std::string | layout | ||
| ) |
screens must outlive this.
Definition at line 9 of file PlayerScreens.cpp.
slot's screen if one was created, or null. Never creates.
Definition at line 33 of file PlayerScreens.cpp.
References VoltMod::IsValidSlot(), and VoltMod::ReadFile().
Referenced by VoltMod::PanoramaMenuLayout::Hide().
slot's screen, created on first use. One ScreenManager::ForPlayer refuses is logged once and stays empty, so its writes fail quietly.
Definition at line 12 of file PlayerScreens.cpp.
References VoltMod::ScreenManager::ForPlayer(), VoltMod::IsValidSlot(), VoltMod::ReadFile(), and VoltMod::Log::Warn().
Referenced by VoltMod::PanoramaMenuLayout::SetEmpty(), VoltMod::PanoramaMenuLayout::SetFooter(), VoltMod::PanoramaMenuLayout::SetHeader(), VoltMod::PanoramaMenuLayout::SetHomeVisible(), VoltMod::PanoramaMenuLayout::SetPager(), VoltMod::PanoramaMenuLayout::SetPrompt(), VoltMod::PanoramaMenuLayout::SetRow(), VoltMod::PanoramaMenuLayout::SetSidebarVisible(), VoltMod::PanoramaMenuLayout::SetTab(), and VoltMod::PanoramaMenuLayout::Show().