Luanti 5.11.0-dev
 
Loading...
Searching...
No Matches
Server::ShutdownState Struct Reference
+ Collaboration diagram for Server::ShutdownState:

Public Member Functions

void reset ()
 
void trigger (float delay, const std::string &msg, bool reconnect)
 
void tick (float dtime, Server *server)
 
std::wstring getShutdownTimerMessage () const
 
bool isTimerRunning () const
 

Public Attributes

bool is_requested = false
 
bool should_reconnect = false
 
std::string message
 

Private Attributes

float m_timer = 0.0f
 

Friends

class TestServerShutdownState
 

Member Function Documentation

◆ getShutdownTimerMessage()

std::wstring Server::ShutdownState::getShutdownTimerMessage ( ) const

References duration_to_string(), and myround().

Referenced by Server::handleCommand_ClientReady().

+ Here is the call graph for this function:
+ Here is the caller graph for this function:

◆ isTimerRunning()

bool Server::ShutdownState::isTimerRunning ( ) const
inline

References m_timer.

Referenced by Server::handleCommand_ClientReady(), and Server::requestShutdown().

+ Here is the caller graph for this function:

◆ reset()

void Server::ShutdownState::reset ( )

References is_requested, m_timer, message, and should_reconnect.

Referenced by Server::requestShutdown(), and TestServerShutdownState::testReset().

+ Here is the caller graph for this function:

◆ tick()

void Server::ShutdownState::tick ( float dtime,
Server * server )

References ARRLEN, infostream, PEER_ID_INEXISTENT, and wide_to_utf8().

Referenced by Server::AsyncRunStep(), and TestServerShutdownState::testTick().

+ Here is the call graph for this function:
+ Here is the caller graph for this function:

◆ trigger()

void Server::ShutdownState::trigger ( float delay,
const std::string & msg,
bool reconnect )

Referenced by Server::requestShutdown(), TestServerShutdownState::testTick(), and TestServerShutdownState::testTrigger().

+ Here is the caller graph for this function:

Friends And Related Symbol Documentation

◆ TestServerShutdownState

friend class TestServerShutdownState
friend

Member Data Documentation

◆ is_requested

◆ m_timer

◆ message

◆ should_reconnect


The documentation for this struct was generated from the following files: