Luanti 5.11.0-dev
 
Loading...
Searching...
No Matches
ClientLauncher Class Reference

#include <clientlauncher.h>

+ Collaboration diagram for ClientLauncher:

Public Member Functions

 ClientLauncher ()=default
 
 ~ClientLauncher ()
 
bool run (GameStartData &start_data, const Settings &cmd_args)
 

Private Member Functions

void init_args (GameStartData &start_data, const Settings &cmd_args)
 
bool init_engine ()
 
void init_input ()
 
void config_guienv ()
 
bool launch_game (std::string &error_message, bool reconnect_requested, GameStartData &start_data, const Settings &cmd_args)
 
void main_menu (MainMenuData *menudata)
 

Static Private Member Functions

static void setting_changed_callback (const std::string &name, void *data)
 

Private Attributes

bool skip_main_menu = false
 
bool random_input = false
 
RenderingEnginem_rendering_engine = nullptr
 
InputHandlerinput = nullptr
 
MyEventReceiverreceiver = nullptr
 

Constructor & Destructor Documentation

◆ ClientLauncher()

ClientLauncher::ClientLauncher ( )
default

◆ ~ClientLauncher()

ClientLauncher::~ClientLauncher ( )

References Settings::deregisterAllChangedCallbacks(), g_fontengine, g_gamecallback, g_menumgr, g_settings, g_sound_manager_singleton, guienv, guiroot, input, m_rendering_engine, MainMenuManager::menuCount(), and receiver.

+ Here is the call graph for this function:

Member Function Documentation

◆ config_guienv()

void ClientLauncher::config_guienv ( )
private

References g_settings, RenderingEngine::get_video_driver(), RenderingEngine::getDisplayDensity(), Settings::getFloat(), guienv, m_rendering_engine, porting::path_share, and rangelim.

Referenced by run(), and setting_changed_callback().

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

◆ init_args()

void ClientLauncher::init_args ( GameStartData & start_data,
const Settings & cmd_args )
private

References GameStartData::address, Settings::exists(), g_settings, Settings::get(), Settings::getBool(), Settings::getFlag(), GameStartData::name, random_input, skip_main_menu, and GameParams::world_path.

Referenced by run().

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

◆ init_engine()

bool ClientLauncher::init_engine ( )
private

References errorstream, m_rendering_engine, and receiver.

Referenced by run().

+ Here is the caller graph for this function:

◆ init_input()

void ClientLauncher::init_input ( )
private

References errorstream, g_settings, RenderingEngine::get_raw_device(), Settings::getBool(), infostream, input, InputHandler::joystick, m_rendering_engine, JoystickController::onJoystickConnect(), random_input, and receiver.

Referenced by run().

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

◆ launch_game()

◆ main_menu()

void ClientLauncher::main_menu ( MainMenuData * menudata)
private

References g_menumgr, g_settings, g_settings_path, RenderingEngine::get_gui_env(), RenderingEngine::get_raw_device(), RenderingEngine::get_scene_manager(), RenderingEngine::get_video_driver(), guiroot, infostream, input, isMenuActive(), InputHandler::joystick, m_rendering_engine, RenderingEngine::run(), porting::signal_handler_killstatus(), sleep_ms, FrameMarker::started(), and Settings::updateConfigFile().

Referenced by launch_game().

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

◆ run()

◆ setting_changed_callback()

void ClientLauncher::setting_changed_callback ( const std::string & name,
void * data )
staticprivate

References config_guienv().

Referenced by run().

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

Member Data Documentation

◆ input

InputHandler* ClientLauncher::input = nullptr
private

◆ m_rendering_engine

RenderingEngine* ClientLauncher::m_rendering_engine = nullptr
private

◆ random_input

bool ClientLauncher::random_input = false
private

Referenced by init_args(), and init_input().

◆ receiver

MyEventReceiver* ClientLauncher::receiver = nullptr
private

◆ skip_main_menu

bool ClientLauncher::skip_main_menu = false
private

Referenced by init_args(), launch_game(), and run().


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