From eea697aee6e6f6bf930396e18baa543338221111 Mon Sep 17 00:00:00 2001 From: Explodingbill Date: Fri, 26 Jan 2024 10:13:17 +1100 Subject: [PATCH] No Shaders --- src/Client/ClientSetup.h | 1 + src/Hacks/NoParticles.cpp | 22 ++++++++++++++++++++++ src/Hacks/NoShaders.cpp | 14 ++++++++++++++ src/Hacks/Noclip.cpp | 2 -- 4 files changed, 37 insertions(+), 2 deletions(-) create mode 100644 src/Hacks/NoShaders.cpp diff --git a/src/Client/ClientSetup.h b/src/Client/ClientSetup.h index 0f01bed..2b085dd 100644 --- a/src/Client/ClientSetup.h +++ b/src/Client/ClientSetup.h @@ -100,6 +100,7 @@ class ClientUtils cosmetic->modules.push_back(new Module("No Transition", "no-trans", "Disables the fade scene transitions")); cosmetic->modules.push_back(new Module("No Player Rotation", "no-rot", "Disables rotation on players")); cosmetic->modules.push_back(new Module("No Particles", "no-particles", "Disables particles, seems pretty obvious what this does imo")); + cosmetic->modules.push_back(new Module("No Shaders", "no-shaders", "Disables shaders, maybe read the name")); //cosmetic->modules.push_back(new Module("No Player Rotation", "no-plr-rot", "Disables Player Rotation :3\nIt looks ugly imo but you do you")); Client::instance->windows.push_back(cosmetic); diff --git a/src/Hacks/NoParticles.cpp b/src/Hacks/NoParticles.cpp index d2b8c3a..e53d494 100644 --- a/src/Hacks/NoParticles.cpp +++ b/src/Hacks/NoParticles.cpp @@ -1,9 +1,31 @@ #include +#include #include #include "../Client/Client.h" using namespace geode::prelude; +class $modify (CCParticleSystem) +{ + virtual bool initWithTotalParticles(unsigned int numberOfParticles, bool idk) + { + return CCParticleSystem::initWithTotalParticles(Client::GetModuleEnabled("no-particles") ? 0 : numberOfParticles, idk); + } + + virtual void update(float dt) + { + if (!Client::GetModuleEnabled("no-particles")) + CCParticleSystem::update(dt); + else + this->setScale(0); + } + + virtual void setTotalParticles(unsigned int tp) + { + CCParticleSystem::setTotalParticles(Client::GetModuleEnabled("no-particles") ? 0 : tp); + } +}; + class $modify (CCParticleSystemQuad) { virtual bool initWithTotalParticles(unsigned int numberOfParticles, bool idk) diff --git a/src/Hacks/NoShaders.cpp b/src/Hacks/NoShaders.cpp new file mode 100644 index 0000000..41e4916 --- /dev/null +++ b/src/Hacks/NoShaders.cpp @@ -0,0 +1,14 @@ +#include +#include +#include "../Client/Client.h" + +using namespace geode::prelude; + +class $modify (ShaderLayer) +{ + TodoReturn performCalculations() + { + if (!Client::GetModuleEnabled("no-shaders")) + ShaderLayer::performCalculations(); + } +}; diff --git a/src/Hacks/Noclip.cpp b/src/Hacks/Noclip.cpp index d803fcc..6e5751a 100644 --- a/src/Hacks/Noclip.cpp +++ b/src/Hacks/Noclip.cpp @@ -11,8 +11,6 @@ class $modify (PlayLayer) void destroyPlayer(PlayerObject * p0, GameObject * p1) { - log::info("the heavy is dead"); - if (!Client::GetModuleEnabled("noclip")) PlayLayer::destroyPlayer(p0, p1); }