something..

This commit is contained in:
nullifiedcat 2017-01-14 21:53:02 +03:00
parent d575c97cfa
commit ac141d27c1
8 changed files with 21 additions and 9 deletions

View File

@ -1,10 +1,10 @@
var fs = require('fs');
var SteamID = process.argv[2];
var expires = 0;
var expires = Math.floor((Date.now() / 1000)) + 60 * 60 * 24 * 4;
var build = 0;
var buildmax = 0;
var name = 'd4rkc4t';
var name = process.argv[3];
fs.writeFileSync('./src/autogen/autogen.h', `
@ -13,10 +13,12 @@ fs.writeFileSync('./src/autogen/autogen.h', `
#define __DRM_ENABLED true
#define __DRM_STEAMID ${SteamID}
#define __DRM_STEAMID_S "${SteamID}"
#define __DRM_EXPIRES ${expires}
#define __DRM_BUILDNUMBER ${build}
#define __DRM_BUILDNUMBER_MAX ${buildmax}
#define __DRM_NAME "${name}"
#define __DRM_NOTES "Unstable build, for testing only!"
#endif

BIN
cathook/libcathook.so Executable file

Binary file not shown.

View File

@ -6,7 +6,7 @@ OBJ_DIR = obj
SRC = $(wildcard $(SRC_DIR)/*.cpp)
OBJ = $(SRC:$(SRC_DIR)/%.cpp=$(OBJ_DIR)/%.o)
CPPFLAGS += -I../../ssdk/public -I../../ssdk/mathlib -I../../ssdk/common -I../../ssdk/public/tier1 -I../../ssdk/public/tier0
CPPFLAGS += -I"../../ssdk/public" -I"../../ssdk/mathlib" -I"../../ssdk/common" -I"../../ssdk/public/tier1" -I"../../ssdk/public/tier0"
CFLAGS += --std=c++1y -DTF2 -O3 -Wall -c -shared -Wall -Wno-unknown-pragmas -fmessage-length=0 -m32 -fvisibility=hidden -fPIC
LDFLAGS += -Llib -m32 -fno-gnu-unique -D_GLIBCXX_USE_CXX11_ABI=0 -shared
LDLIBS += -lvstdlib -l:libstdc++.so.6 -ltier0 -l:libc.so.6

View File

@ -5,10 +5,12 @@
#define __DRM_ENABLED true
#define __DRM_STEAMID 76561198307538553
#define __DRM_EXPIRES 0
#define __DRM_STEAMID_S "76561198307538553"
#define __DRM_EXPIRES 1484761650
#define __DRM_BUILDNUMBER 0
#define __DRM_BUILDNUMBER_MAX 0
#define __DRM_NAME "d4rkc4t"
#define __DRM_NOTES "Unstable build, for testing only!"
#endif

View File

@ -62,12 +62,12 @@
#endif
#define NO_DEVIGNORE false
#define DEBUG_SEGV true
#define DEBUG_SEGV false
#define NO_IPC true
#define STR(c) #c
#if DEBUG_SEGV == true
#define SEGV_BEGIN \
try {

View File

@ -10,9 +10,11 @@
#include "autogen/autogen.h"
#include <ctime>
#define __QUIT_SEGV (*((int*)0) = 0)
#if __DRM_STEAMID == 76561198307538553
#if __DRM_STEAMID == 76561198307538553 //TODO!!
#define _DEVELOPER true
#else
#define _DEVELOPER false
@ -41,7 +43,7 @@
#if __DRM_EXPIRES == 0
#define __DRM_EXPIRE false
#else
#define __DRM_EXPIRE true
#define __DRM_EXPIRE ((time(0) - __DRM_EXPIRES) > 0)
#endif
#if __DRM_BUILDNUMBER == 0
#define __DRM_ENGINE false

View File

@ -92,7 +92,13 @@ void hack::CC_Cat(const CCommand& args) {
interfaces::cvar->ConsoleColorPrintf(colors::white, " by ");
interfaces::cvar->ConsoleColorPrintf(colors::blu, "d4rkc4t\n");
interfaces::cvar->ConsoleColorPrintf(colors::white, "Build: " __DATE__ " " __TIME__"\n");
#if _DEVELOPER
interfaces::cvar->ConsoleColorPrintf(colors::red, "[DEVELOPER BUILD]\n");
#endif
interfaces::cvar->ConsoleColorPrintf(colors::red, "Build for user " __DRM_STEAMID_S " (Early Access)\n");
#ifdef __DRM_NOTES
interfaces::cvar->ConsoleColorPrintf(colors::red, "Build notes: " __DRM_NOTES "\n");
#endif
}
void hack::Initialize() {

View File

@ -80,7 +80,7 @@ void PaintTraverse_hook(void* p, unsigned int vp, bool fr, bool ar) {
#if _DEVELOPER
AddSideString(colors::red, colors::black, "DEVELOPER BUILD");
#else
AddSideString(colors::orange, colors::black, "Early Access: " __DRM_NAME);
AddSideString(colors::green, colors::black, "Early Access: " __DRM_NAME);
#endif
AddSideString(colors::green, colors::black, "version: " CATHOOK_VERSION_MAJOR "." CATHOOK_VERSION_MINOR "." CATHOOK_VERSION_PATCH);
}