Skip to content

Commit

Permalink
stuff
Browse files Browse the repository at this point in the history
  • Loading branch information
TheSillyDoggo committed Jan 23, 2024
1 parent d03b79f commit a4ec7fc
Show file tree
Hide file tree
Showing 6 changed files with 64 additions and 10 deletions.
2 changes: 1 addition & 1 deletion src/Client/AndroidUI.h
Original file line number Diff line number Diff line change
Expand Up @@ -157,7 +157,7 @@ class AndroidUI : public cocos2d::CCLayerColor {
backSpr->runAction(CCSpeed::create(CCFadeIn::create(0.5f), 1.0f / v));

auto backBtn = CCMenuItemSpriteExtra::create(backSpr, this, menu_selector(AndroidUI::close));
backBtn->setPosition(ccp(20, -24));
backBtn->setPosition(ccp(24, -23));
backBtn->setSizeMult(1.15f);

backMenu->addChild(backBtn);
Expand Down
6 changes: 4 additions & 2 deletions src/Client/ClientSetup.h
Original file line number Diff line number Diff line change
Expand Up @@ -26,7 +26,7 @@ class ClientUtils

static void SetupSpeedhack()
{
Window* speedhack = new Window();
Window* speedhack = new Speedhack();
speedhack->name = "Speedhack";
speedhack->id = "speedhack-window";
speedhack->windowPos = ImVec2(50 + (50 + (Client::instance->tileSize.x)) * 2, 50);
Expand Down Expand Up @@ -70,7 +70,9 @@ class ClientUtils
bypass->modules.push_back(new Module("Copy any level", "copy-hack", "Allows you to copy any level from the servers\nCode by Firee"));
bypass->modules.push_back(new Module("No Copy Mark", "noc-hack", "Hides the (c) mark from your levels on publish.\nCode by Firee"));
bypass->modules.push_back(new Module("Safe mode", "safe-mode", "Disables all progress on levels"));
bypass->modules.push_back(new Module("Auto Safe mode\nNOT YET IMPLEMENTED", "auto-safe-mode", "NOT YET IMPLEMENTED"));
bypass->modules.push_back(new Module("Auto Safe mode", "auto-safe-mode", "Automatically enables safe mode if you have cheats enabled"));
bypass->modules.push_back(new Module("Slider Limit Bypass", "slider-limit", "Allows sliders to go beyond the limit of the slider"));
bypass->modules.push_back(new Module("Fire in the hole!", "fire-in-the-hole", "Replaces every single sfx with\n<cr>FIRE IN THE HOLE!</c>"));


Client::instance->windows.push_back(bypass);
Expand Down
2 changes: 1 addition & 1 deletion src/Client/Module.h
Original file line number Diff line number Diff line change
Expand Up @@ -143,7 +143,7 @@ class Module
label->setAnchorPoint(ccp(0, 0.5f));
label->setScale(0.575f);
label->setPosition(pos + ccp(15, 0));
label->limitLabelWidth(100, 0.575f, 0.1f);
label->limitLabelWidth(110, 0.575f, 0.1f);

auto info = CCMenuItemSpriteExtra::create(CCSprite::createWithSpriteFrameName("GJ_infoIcon_001.png"), menu, menu_selector(Module::onInfoAndroid));
info->setScale(0.55f);
Expand Down
41 changes: 40 additions & 1 deletion src/Client/Window.h
Original file line number Diff line number Diff line change
Expand Up @@ -155,13 +155,50 @@ class Window

menu->addChild(back);

int y = 0;

for (size_t m = 0; m < modules.size(); m++)
{
modules[m]->makeAndroid(menu, {20, (menu->getContentSize().height - 20 - 20) - 7 - (28.0f * (m - 1.0f))});
float x = 20;

if (!(m % 2 == 0))
x = 188;

modules[m]->makeAndroid(menu, {x, (menu->getContentSize().height - 20 - 20) - 7 - (28.0f * (y - 1.0f)) });

if ((m - 1) % 2 == 0 && m != 0)
y++;
}
}
};

class Speedhack : public Window
{
public:
Speedhack()
{
name = "Speedhack";
id = "speedhack-window";
}

void cocosCreate(CCMenu* menu)
{
auto back = CCScale9Sprite::create("square02_small.png");
back->setContentSize(menu->getContentSize() / 0.5f);
back->setPosition(ccp(0, 0));
back->setAnchorPoint(ccp(0, 0));
back->setScale(0.5f);
back->setOpacity(100);

menu->addChild(back);

for (size_t m = 0; m < modules.size(); m++)
{
modules[m]->makeAndroid(menu, {20, (menu->getContentSize().height - 20 - 20) - 7 - (28.0f * (m - 1.0f))});
}
}
};

class Credits : public Window
{
public:
Expand Down Expand Up @@ -397,6 +434,8 @@ class Config : public Window

void createBtn(CCNode* menu, int i)
{
CCEGLView::get()->setFrameSize(1280, 720);

std::stringstream ss;
ss << "GJ_square0";
ss << i;
Expand Down
23 changes: 18 additions & 5 deletions src/Hacks/FireInTheHole.cpp
Original file line number Diff line number Diff line change
@@ -1,13 +1,14 @@
/*#include <Geode/Geode.hpp>
#include <Geode/Geode.hpp>
#include <Geode/modify/FMODAudioEngine.hpp>
#include <Geode/modify/MusicDownloadManager.hpp>
#include "../Client/Client.h"

using namespace geode::prelude;

class $modify (FMODAudioEngine)
{
static void onModify(auto& self) {
auto res = self.getHook("FMODAudioEngine::playEffect");
auto res = self.getHook("FMODAudioEngine::playEffectAdvanced");
if (!res) {
log::error("Something went horribly wrong");
return;
Expand All @@ -17,8 +18,20 @@ class $modify (FMODAudioEngine)

void playEffect(gd::string p0, float p1, float p2, float p3)
{
log::info(p0);
if (!Client::GetModuleEnabled("fire-in-the-hole"))
FMODAudioEngine::playEffect(p0, p1, p2, p3);
else
FMODAudioEngine::playEffect("sfx/s4451.ogg", p1, p2, p3);
}
};

FMODAudioEngine::playEffect(p0, p1, p2, p3);
class $modify (MusicDownloadManager)
{
gd::string pathForSFX(int p0)
{
if (!Client::GetModuleEnabled("fire-in-the-hole"))
return MusicDownloadManager::pathForSFX(p0);
else
return "sfx/s4451.ogg";
}
};*/
};
Empty file added src/Hacks/SliderLimit.cpp
Empty file.

0 comments on commit a4ec7fc

Please sign in to comment.