refactor(cmd): add support for cmds + cleanup
This commit is contained in:
parent
1bb9add331
commit
cae0793e7f
2
.github/workflows/build.yml
vendored
2
.github/workflows/build.yml
vendored
@ -39,7 +39,7 @@ jobs:
|
||||
uses: microsoft/setup-msbuild@v1.1.3
|
||||
|
||||
- name: Generate project files
|
||||
run: tools/premake5 vs2022 --ci-build
|
||||
run: tools/premake5 vs2022
|
||||
|
||||
- name: Set up problem matching
|
||||
uses: ammaraskar/msvc-problem-matcher@master
|
||||
|
@ -77,11 +77,6 @@ newoption {
|
||||
description = "Enable development builds of the client."
|
||||
}
|
||||
|
||||
newoption {
|
||||
trigger = "ci-build",
|
||||
description = "Enable CI builds of the client."
|
||||
}
|
||||
|
||||
newaction {
|
||||
trigger = "version",
|
||||
description = "Returns the version string for the current commit of the source code.",
|
||||
@ -249,7 +244,7 @@ workspace "boiii"
|
||||
defines {"DEV_BUILD"}
|
||||
end
|
||||
|
||||
if _OPTIONS["ci-build"] then
|
||||
if os.getenv("CI") then
|
||||
defines {"CI"}
|
||||
end
|
||||
|
||||
|
@ -77,7 +77,7 @@ namespace branding
|
||||
|
||||
std::string str = "BOIII: " VERSION;
|
||||
//str += "\n\n" + get_connectivity_info();
|
||||
game::R_AddCmdDrawText(str.data(), 0x7FFFFFFF, font, static_cast<float>(x),
|
||||
game::R_AddCmdDrawText(str.data(), std::numeric_limits<int>::max(), font, static_cast<float>(x),
|
||||
y + static_cast<float>(font[2]) * scale,
|
||||
scale, scale, 0.0f, color, game::ITEM_TEXTSTYLE_NORMAL);
|
||||
}
|
||||
|
@ -1,5 +1,4 @@
|
||||
#include <std_include.hpp>
|
||||
#include "network.hpp"
|
||||
#include "loader/component_loader.hpp"
|
||||
|
||||
#include "scheduler.hpp"
|
||||
@ -9,6 +8,8 @@
|
||||
#include <utils/string.hpp>
|
||||
#include <utils/finally.hpp>
|
||||
|
||||
#include "network.hpp"
|
||||
|
||||
namespace network
|
||||
{
|
||||
namespace
|
||||
|
@ -1,5 +1,4 @@
|
||||
#pragma once
|
||||
#include "game/game.hpp"
|
||||
|
||||
namespace network
|
||||
{
|
||||
|
@ -1,11 +1,11 @@
|
||||
#include <std_include.hpp>
|
||||
#include "loader/component_loader.hpp"
|
||||
#include "game/game.hpp"
|
||||
#include "steam/steam.hpp"
|
||||
|
||||
#include "party.hpp"
|
||||
#include "network.hpp"
|
||||
#include "scheduler.hpp"
|
||||
#include "game/game.hpp"
|
||||
#include "steam/steam.hpp"
|
||||
|
||||
#include <utils/hook.hpp>
|
||||
#include <utils/string.hpp>
|
||||
|
@ -1,6 +1,4 @@
|
||||
#pragma once
|
||||
|
||||
#include <game/game.hpp>
|
||||
#include <utils/info_string.hpp>
|
||||
|
||||
namespace party
|
||||
|
@ -5,7 +5,6 @@
|
||||
|
||||
#include "game/game.hpp"
|
||||
|
||||
#include <cassert>
|
||||
#include <utils/hook.hpp>
|
||||
#include <utils/concurrency.hpp>
|
||||
#include <utils/thread.hpp>
|
||||
|
@ -1,5 +1,6 @@
|
||||
#include <std_include.hpp>
|
||||
#include "loader/component_loader.hpp"
|
||||
|
||||
#include "splash.hpp"
|
||||
#include "resource.hpp"
|
||||
|
||||
|
@ -1,7 +1,5 @@
|
||||
#include <std_include.hpp>
|
||||
#include "loader/component_loader.hpp"
|
||||
#include "steam_proxy.hpp"
|
||||
#include "scheduler.hpp"
|
||||
|
||||
#include <utils/nt.hpp>
|
||||
#include <utils/flags.hpp>
|
||||
@ -12,6 +10,9 @@
|
||||
#include "steam/interface.hpp"
|
||||
#include "steam/steam.hpp"
|
||||
|
||||
#include "steam_proxy.hpp"
|
||||
#include "scheduler.hpp"
|
||||
|
||||
namespace steam_proxy
|
||||
{
|
||||
namespace
|
||||
|
@ -1,5 +1,4 @@
|
||||
#pragma once
|
||||
#include <utils/nt.hpp>
|
||||
|
||||
namespace steam_proxy
|
||||
{
|
||||
|
@ -19,4 +19,11 @@ namespace game
|
||||
}();
|
||||
return base;
|
||||
}
|
||||
|
||||
CmdArgs* cmd_args_t::operator->() const
|
||||
{
|
||||
return Sys_GetTLS()->cmdArgs;
|
||||
}
|
||||
|
||||
cmd_args_t cmd_args;
|
||||
}
|
||||
|
@ -50,6 +50,13 @@ namespace game
|
||||
private:
|
||||
size_t address_;
|
||||
};
|
||||
|
||||
struct cmd_args_t
|
||||
{
|
||||
CmdArgs* operator->() const;
|
||||
};
|
||||
|
||||
extern cmd_args_t cmd_args;
|
||||
}
|
||||
|
||||
inline size_t operator"" _g(const size_t val)
|
||||
|
@ -6,8 +6,7 @@
|
||||
|
||||
namespace game
|
||||
{
|
||||
#define Com_Error(code, fmt, ...) \
|
||||
Com_Error_(__FILE__, __LINE__, code, fmt, ##__VA_ARGS__)
|
||||
#define Com_Error(code, fmt, ...) Com_Error_(__FILE__, __LINE__, code, fmt, ##__VA_ARGS__)
|
||||
|
||||
// CL
|
||||
WEAK symbol<void(int controllerIndex, XSESSION_INFO* hostInfo, const netadr_t* addr, int numPublicSlots,
|
||||
|
@ -1,8 +1,9 @@
|
||||
#include <std_include.hpp>
|
||||
#include "../steam.hpp"
|
||||
#include "component/steam_proxy.hpp"
|
||||
|
||||
//#include <game/game.hpp>
|
||||
#include <utils/nt.hpp>
|
||||
|
||||
#include "component/steam_proxy.hpp"
|
||||
|
||||
namespace steam
|
||||
{
|
||||
|
@ -1,8 +1,12 @@
|
||||
#include <std_include.hpp>
|
||||
#include "../steam.hpp"
|
||||
|
||||
#include "game/game.hpp"
|
||||
|
||||
#include "component/party.hpp"
|
||||
#include "component/network.hpp"
|
||||
#include "utils/string.hpp"
|
||||
|
||||
#include <utils/string.hpp>
|
||||
|
||||
namespace steam
|
||||
{
|
||||
|
@ -1,5 +1,8 @@
|
||||
#include <std_include.hpp>
|
||||
#include "../steam.hpp"
|
||||
|
||||
#include <utils/nt.hpp>
|
||||
|
||||
#include "component/steam_proxy.hpp"
|
||||
|
||||
namespace steam
|
||||
|
Loading…
Reference in New Issue
Block a user