From 1e635b52e59395becbe4c34e585bd16e4c0d5f47 Mon Sep 17 00:00:00 2001 From: julianacat Date: Wed, 16 Aug 2017 08:00:59 -0500 Subject: [PATCH 1/2] CSS support --- build-css | 2 ++ build-debug-css | 1 + src/interfaces.cpp | 5 ++++- 3 files changed, 7 insertions(+), 1 deletion(-) create mode 100755 build-css create mode 100755 build-debug-css diff --git a/build-css b/build-css new file mode 100755 index 00000000..85467a7c --- /dev/null +++ b/build-css @@ -0,0 +1,2 @@ +make -j4 -e GAME=css NO_WARNINGS=1 +strip --strip-all bin/libcathook.so \ No newline at end of file diff --git a/build-debug-css b/build-debug-css new file mode 100755 index 00000000..59a39749 --- /dev/null +++ b/build-debug-css @@ -0,0 +1 @@ +make -j4 -e GAME=css BUILD_DEBUG=1 \ No newline at end of file diff --git a/src/interfaces.cpp b/src/interfaces.cpp index 0ea76c7c..2815a7de 100644 --- a/src/interfaces.cpp +++ b/src/interfaces.cpp @@ -150,7 +150,10 @@ void CreateInterfaces() { g_ppScreenSpaceRegistrationHead = *(CScreenSpaceEffectRegistration***)(gSignatures.GetClientSignature("E8 ? ? ? ? 8B 10 C7 44 24 04 ? ? ? ? 89 04 24 FF 52 28 85 C0 75 4B 8B 35 ? ? ? ? 85 F6 74 31 90 8B 5E 04 85 DB 74 22 8B 03 89 1C 24") + 27); } logging::Info("Finding HUD"); - { + IF_GAME (IsCSS()) { + logging::Info("FATAL: Signatures not defined for CSS - HUD"); + g_CHUD = nullptr; + } else { uintptr_t hud_sig = gSignatures.GetClientSignature("FF 50 08 D9 9D 24 FE FF FF 89 3C 24 E8 ? ? ? ? C7 44 24 04 ? ? ? ? C7 04 24 ? ? ? ? D9 9D 20 FE FF FF E8 ? ? ? ? 85 C0 74 3B 66 0F 6E C3 C7 44 24 10 00 00 00 00 F3 0F 5C 85 20 FE FF FF") + 28; g_CHUD = *reinterpret_cast(hud_sig); logging::Info("HUD 0x%08x 0x%08x", hud_sig, g_CHUD); From 3a47e59a9cd8fa6233b0878c15af848379108021 Mon Sep 17 00:00:00 2001 From: julianacat Date: Wed, 16 Aug 2017 09:54:42 -0500 Subject: [PATCH 2/2] gcc7 fix for arch --- build-css | 3 +-- build-debug-css | 2 +- build-tf2 | 2 +- makefile | 2 +- simple-ipc | 2 +- 5 files changed, 5 insertions(+), 6 deletions(-) diff --git a/build-css b/build-css index 85467a7c..42221e12 100755 --- a/build-css +++ b/build-css @@ -1,2 +1 @@ -make -j4 -e GAME=css NO_WARNINGS=1 -strip --strip-all bin/libcathook.so \ No newline at end of file +make -j4 GAME=css NO_WARNINGS=1 \ No newline at end of file diff --git a/build-debug-css b/build-debug-css index 59a39749..cc481df1 100755 --- a/build-debug-css +++ b/build-debug-css @@ -1 +1 @@ -make -j4 -e GAME=css BUILD_DEBUG=1 \ No newline at end of file +make -j4 GAME=css BUILD_DEBUG=1 \ No newline at end of file diff --git a/build-tf2 b/build-tf2 index 3a68e42b..f76d0d36 100755 --- a/build-tf2 +++ b/build-tf2 @@ -1 +1 @@ -make -j4 NO_WARNINGS=1 \ No newline at end of file +make -j4 NO_WARNINGS=1 diff --git a/makefile b/makefile index 2ba97255..b4973d96 100644 --- a/makefile +++ b/makefile @@ -51,7 +51,7 @@ RES_DIR=res OUT_DIR=bin TARGET = $(OUT_DIR)/$(OUT_NAME) -INCLUDES=-Iucccccp -isystem$(SSDK_DIR)/public -isystem$(SSDK_DIR)/mathlib -isystem$(SSDK_DIR)/common -isystem$(SSDK_DIR)/public/tier1 -isystem$(SSDK_DIR)/public/tier0 -isystem$(SSDK_DIR) +INCLUDES=-Iucccccp -isystem/usr/include/c++/6.3.1 -isystem$(SSDK_DIR)/public -isystem$(SSDK_DIR)/mathlib -isystem$(SSDK_DIR)/common -isystem$(SSDK_DIR)/public/tier1 -isystem$(SSDK_DIR)/public/tier0 -isystem$(SSDK_DIR) LDLIBS=-static -l:libc.so.6 -l:libstdc++.so.6 -l:libtier0.so -l:libvstdlib.so LDFLAGS=-shared -L$(realpath $(LIB_DIR)) SOURCES=$(shell find $(SRC_DIR) -name "*.c*" -print) diff --git a/simple-ipc b/simple-ipc index 94b3e53b..e532876f 160000 --- a/simple-ipc +++ b/simple-ipc @@ -1 +1 @@ -Subproject commit 94b3e53b00ac5be465ebe44ea5fe1b1fbc18aa8f +Subproject commit e532876ffd707a48389d54ff904dcc40a84f2839