mirror of
https://github.com/XLabsProject/s1x-client.git
synced 2023-08-02 15:02:12 +02:00
Use StartServer for now
This commit is contained in:
parent
3427387795
commit
0ef00b5a18
@ -105,7 +105,7 @@ namespace dedicated
|
||||
game::dvar_t* gscr_set_dynamic_dvar()
|
||||
{
|
||||
auto s = game::Scr_GetString(0);
|
||||
auto dvar = game::Dvar_FindVar(s);
|
||||
auto* dvar = game::Dvar_FindVar(s);
|
||||
if (dvar && !strncmp("scr_", dvar->name, 4))
|
||||
{
|
||||
return dvar;
|
||||
@ -132,7 +132,7 @@ namespace dedicated
|
||||
{
|
||||
command::execute("exec default_xboxlive.cfg", true);
|
||||
command::execute("onlinegame 1", true);
|
||||
command::execute("xblive_privatematch 0", true);
|
||||
command::execute("xblive_privatematch 1", true);
|
||||
}
|
||||
|
||||
class component final : public component_interface
|
||||
|
@ -29,6 +29,8 @@ namespace party
|
||||
|
||||
void perform_game_initialization()
|
||||
{
|
||||
command::execute("onlinegame 1", true);
|
||||
command::execute("xblive_privatematch 1", true);
|
||||
command::execute("startentitlements", true);
|
||||
}
|
||||
|
||||
@ -202,8 +204,18 @@ namespace party
|
||||
|
||||
printf("Starting map: %s\n", mapname.data());
|
||||
|
||||
game::SV_StartMapForParty(0, mapname.data(), false, false);
|
||||
return;
|
||||
auto* gametype = game::Dvar_FindVar("g_gametype");
|
||||
if (gametype && gametype->current.string)
|
||||
{
|
||||
command::execute(utils::string::va("ui_gametype %s", gametype->current.string), true);
|
||||
}
|
||||
command::execute(utils::string::va("ui_mapname %s", mapname.data()), true);
|
||||
|
||||
// StartServer
|
||||
reinterpret_cast<void(*)(unsigned int)>(0x140492260)(0);
|
||||
|
||||
//game::SV_StartMapForParty(0, mapname.data(), false, false);
|
||||
//return;
|
||||
}
|
||||
}
|
||||
|
||||
|
Loading…
Reference in New Issue
Block a user