Chore: fix windows building caz useless MSVC
This commit is contained in:
parent
8d7a694d72
commit
c49b9d540f
4 changed files with 11 additions and 27 deletions
|
|
@ -2,9 +2,14 @@ FROM registry.gitlab.steamos.cloud/steamrt/sniper/sdk:latest
|
||||||
|
|
||||||
WORKDIR /app
|
WORKDIR /app
|
||||||
|
|
||||||
|
RUN echo "deb http://apt.llvm.org/bullseye/ llvm-toolchain-bullseye-21 main" >> /etc/apt/sources.list.d/llvm.list
|
||||||
|
RUN echo "deb-src http://apt.llvm.org/bullseye/ llvm-toolchain-bullseye-21 main" >> /etc/apt/sources.list.d/llvm.list
|
||||||
|
RUN wget -O - https://apt.llvm.org/llvm-snapshot.gpg.key | sudo apt-key add -
|
||||||
|
RUN apt update && apt install -y clang-21
|
||||||
|
RUN ln -sf /usr/bin/clang-21 /usr/bin/clang && ln -sf /usr/bin/clang++-21 /usr/bin/clang++
|
||||||
|
|
||||||
RUN apt update && apt install -y \
|
RUN apt update && apt install -y \
|
||||||
build-essential \
|
build-essential \
|
||||||
g++ \
|
|
||||||
cmake \
|
cmake \
|
||||||
ninja-build \
|
ninja-build \
|
||||||
git \
|
git \
|
||||||
|
|
|
||||||
|
|
@ -38,25 +38,6 @@ namespace RayTracePlugin::shared
|
||||||
if (!g_pGlobalVars) g_pGlobalVars = server->GetGlobals();
|
if (!g_pGlobalVars) g_pGlobalVars = server->GetGlobals();
|
||||||
return g_pNetworkServerService->GetIGameServer()->GetGlobals();
|
return g_pNetworkServerService->GetIGameServer()->GetGlobals();
|
||||||
}
|
}
|
||||||
constexpr float engine_fixed_tick_interval = 0.015625f;
|
|
||||||
const char* GetMapName()
|
|
||||||
{
|
|
||||||
if (getGlobalVars() == nullptr) return nullptr;
|
|
||||||
|
|
||||||
return getGlobalVars()->mapname.ToCStr();
|
|
||||||
}
|
|
||||||
void ServerCommand(const char* command)
|
|
||||||
{
|
|
||||||
auto clean_command = std::string(command);
|
|
||||||
clean_command.append("\n\0");
|
|
||||||
g_pEngine->ServerCommand(clean_command.c_str());
|
|
||||||
}
|
|
||||||
double GetEngineTime() { return Plat_FloatTime(); }
|
|
||||||
float GetTickInterval() { return engine_fixed_tick_interval; }
|
|
||||||
float GetCurrentTime() { return getGlobalVars()->curtime; }
|
|
||||||
int GetTickCount() { return getGlobalVars()->tickcount; }
|
|
||||||
float GetGameFrameTime() { return getGlobalVars()->frametime; }
|
|
||||||
|
|
||||||
bool g_bHasTicked = false;
|
|
||||||
bool g_bDetoursLoaded = false;
|
bool g_bDetoursLoaded = false;
|
||||||
}
|
}
|
||||||
|
|
|
||||||
|
|
@ -37,13 +37,6 @@ namespace RayTracePlugin::shared
|
||||||
extern int source_hook_pluginid;
|
extern int source_hook_pluginid;
|
||||||
|
|
||||||
CGlobalVars* getGlobalVars();
|
CGlobalVars* getGlobalVars();
|
||||||
extern const char *GetMapName();
|
|
||||||
extern void ServerCommand(const char *command);
|
|
||||||
extern double GetEngineTime();
|
|
||||||
extern float GetTickInterval();
|
|
||||||
extern float GetCurrentTime();
|
|
||||||
extern int GetTickCount();
|
|
||||||
extern float GetGameFrameTime();
|
|
||||||
|
|
||||||
extern bool g_bDetoursLoaded;
|
extern bool g_bDetoursLoaded;
|
||||||
}
|
}
|
||||||
|
|
|
||||||
|
|
@ -8,6 +8,11 @@
|
||||||
#include <algorithm>
|
#include <algorithm>
|
||||||
#include <vector.h>
|
#include <vector.h>
|
||||||
|
|
||||||
|
#ifdef _WIN32
|
||||||
|
#undef min
|
||||||
|
#undef max
|
||||||
|
#endif
|
||||||
|
|
||||||
namespace RayTracePlugin::VectorExtends
|
namespace RayTracePlugin::VectorExtends
|
||||||
{
|
{
|
||||||
inline const Vector VectorZero{0.0f, 0.0f, 0.0f};
|
inline const Vector VectorZero{0.0f, 0.0f, 0.0f};
|
||||||
|
|
|
||||||
Loading…
Add table
Add a link
Reference in a new issue