Compare commits

...

2 Commits

Author SHA1 Message Date
9a87acba34 Change cheat name 2026-01-06 11:20:06 +01:00
bd5d04fc44 Change cheat name 2026-01-06 11:19:06 +01:00
4 changed files with 11 additions and 11 deletions

View File

@@ -89,7 +89,7 @@ static FixToggle individualFixes[] = {
static FixToggle cheatFixes[] = {
{ "Time dilation", &Time_Dilation_fix_enabled, GameFixes::TimeDilation, "ALT + 1 (top keyboard row) to toggle" },
{ "God mode", &GodMode_fix_enabled, GameFixes::GodMode, "ALT + 2 (top keyboard row) to toggle.\nJacob won't receive any damage." },
{ "Ignore hits", &Ignore_hits_fix_enabled, GameFixes::Invulnerable, "ALT + 3 (top keyboard row) to toggle.\nJacob can't be hit." },
{ "Ignore hits", &Ignore_hits_fix_enabled, GameFixes::IgnoreHits, "ALT + 3 (top keyboard row) to toggle.\nJacob can't be hit." },
{ "Stealth mode",&Stealth_fix_enabled, GameFixes::Stealth, "ALT + 4 (top keyboard row) to toggle.\nEnemies won't attack you" }
};
// Prepare array of sliders for ImGui
@@ -137,7 +137,7 @@ static void LoadFixDLL()
SetFixes(GameFixes::Fog, Fog_fix_enabled);
SetFixes(GameFixes::TimeDilation, Time_Dilation_fix_enabled);
SetFixes(GameFixes::GodMode, GodMode_fix_enabled);
SetFixes(GameFixes::Invulnerable, Ignore_hits_fix_enabled);
SetFixes(GameFixes::IgnoreHits, Ignore_hits_fix_enabled);
SetFixes(GameFixes::Stealth, Stealth_fix_enabled);
SetFixes(GameFixes::DevConsole, console);
}
@@ -364,7 +364,7 @@ static void on_reshade_present(reshade::api::effect_runtime* runtime) {
static void on_reshade_begin_effects(reshade::api::effect_runtime* runtime, reshade::api::command_list* cmd_list,
reshade::api::resource_view rtv, reshade::api::resource_view rtv_srgb) {
if (!runtime) return;
FindAllUniformVariables(runtime, OSD_SHADER_NAME);
FindAllUniformVariables(runtime, OSD_SHADER_NAME); // Find all uniforms and set their handle
if (InterlockedCompareExchange(&g_uniformReseted, 1, 0) != 0) return; // reset OSD uniforms once
ResetAllUniformVariables(runtime, OSD_SHADER_NAME);
@@ -385,7 +385,7 @@ static void InitializeHotkeys() { // Initialize hotkeys for cheats
});
RegisterHotkey('3', Modifier::Alt, [] {
ToggleOSD(Ignore_hits_fix_enabled, GameFixes::Invulnerable, u_Invulnerability_show, u_Invulnerability_enabled, OSD_duration);
ToggleOSD(Ignore_hits_fix_enabled, GameFixes::IgnoreHits, u_IgnoreHits_show, u_IgnoreHits_enabled, OSD_duration);
});
RegisterHotkey('4', Modifier::Alt, [] {

View File

@@ -19,6 +19,6 @@ enum class GameFixes : int {
FilmGrain,
TimeDilation,
GodMode,
Invulnerable,
IgnoreHits,
Stealth
};

View File

@@ -15,8 +15,8 @@ extern reshade::api::effect_uniform_variable u_td_world;
extern reshade::api::effect_uniform_variable u_td_AI;
extern reshade::api::effect_uniform_variable u_GodMode_show;
extern reshade::api::effect_uniform_variable u_GodMode_enabled;
extern reshade::api::effect_uniform_variable u_Invulnerability_show;
extern reshade::api::effect_uniform_variable u_Invulnerability_enabled;
extern reshade::api::effect_uniform_variable u_IgnoreHits_show;
extern reshade::api::effect_uniform_variable u_IgnoreHits_enabled;
extern reshade::api::effect_uniform_variable u_Stealth_show;
extern reshade::api::effect_uniform_variable u_Stealth_enabled;

View File

@@ -11,8 +11,8 @@ reshade::api::effect_uniform_variable u_td_world = {};
reshade::api::effect_uniform_variable u_td_AI = {};
reshade::api::effect_uniform_variable u_GodMode_show = {};
reshade::api::effect_uniform_variable u_GodMode_enabled = {};
reshade::api::effect_uniform_variable u_Invulnerability_show = {};
reshade::api::effect_uniform_variable u_Invulnerability_enabled = {};
reshade::api::effect_uniform_variable u_IgnoreHits_show = {};
reshade::api::effect_uniform_variable u_IgnoreHits_enabled = {};
reshade::api::effect_uniform_variable u_Stealth_show = {};
reshade::api::effect_uniform_variable u_Stealth_enabled = {};
@@ -44,8 +44,8 @@ void FindAllUniformVariables(reshade::api::effect_runtime* runtime, const char*
u_td_AI = runtime->find_uniform_variable(OSD_SHADER_NAME, "TD_AI");
u_GodMode_show = runtime->find_uniform_variable(OSD_SHADER_NAME, "OSD_ShowGodMode");
u_GodMode_enabled = runtime->find_uniform_variable(OSD_SHADER_NAME, "GodMode_Enabled");
u_Invulnerability_show = runtime->find_uniform_variable(OSD_SHADER_NAME, "OSD_ShowInvuln");
u_Invulnerability_enabled = runtime->find_uniform_variable(OSD_SHADER_NAME, "Invulnerability_Enabled");
u_IgnoreHits_show = runtime->find_uniform_variable(OSD_SHADER_NAME, "OSD_ShowIgnoreHits");
u_IgnoreHits_enabled = runtime->find_uniform_variable(OSD_SHADER_NAME, "IgnoreHits_Enabled");
u_Stealth_show = runtime->find_uniform_variable(OSD_SHADER_NAME, "OSD_ShowStealth");
u_Stealth_enabled = runtime->find_uniform_variable(OSD_SHADER_NAME, "Stealth_Enabled");
}