Skip to content

Commit

Permalink
make it even more gay
Browse files Browse the repository at this point in the history
  • Loading branch information
mrcryostat committed Apr 24, 2024
1 parent 8a48364 commit 440ea39
Show file tree
Hide file tree
Showing 3 changed files with 66 additions and 14 deletions.
24 changes: 15 additions & 9 deletions mod.json
Original file line number Diff line number Diff line change
Expand Up @@ -5,7 +5,7 @@
"mac": "2.200",
"android": "2.205"
},
"version": "v1.0.11",
"version": "v1.0.12",
"id": "the_bearodactyl.gay-wave-trail",
"name": "Gay Wave Trail",
"developer": "The Bearodactyl",
Expand All @@ -14,34 +14,40 @@
"enable": {
"name": "Enable the G A E",
"type": "bool",
"description": "what this does is self explanitory",
"description": "uwu",
"default": true
},
"speed": {
"name": "How fast is your wave trail?",
"name": "Sonic says: you've gotta be fast when\nyou're trying to pick up a femboy twink",
"type": "float",
"default": 10,
"min": 1,
"max": 20,
"max": 100,
"control": {
"slider-step": 1
},
"description": "The speed of the alphabet mafia"
"description": "\n\nMy personal record for getting\na date with a buff furry dude\nis 0.8 seconds (real)"
},
"saturation": {
"name": "How fruity is your wave trail?",
"name": "HOW GAY ARE YOU???????",
"type": "float",
"default": 100,
"min": 0,
"max": 100,
"control": {
"slider-step": 1
},
"description": "The larger the number, the better"
"description": "You think you're more fruity than me? wrong."
},
"mirror-players": {
"name": "Mirror the player colors",
"description": "It's like looking in a BatMirror\n- Batman",
"name": "You're fruity? OMG SAME",
"description": "It's like looking in a Bat-Mirror\n- Batman",
"type": "bool",
"default": true
},
"no-reg-trail": {
"name": "Don't be a coward. Be yourself without a disguise :)",
"description": "in other words: don't be dream.",
"type": "bool",
"default": true
}
Expand Down
18 changes: 13 additions & 5 deletions src/main.cpp
Original file line number Diff line number Diff line change
Expand Up @@ -8,7 +8,8 @@
using namespace geode::prelude;

// thanks to shadowforce78
void HSVtoRGBbutDifferentIGuess(float &fR, float &fG, float &fB, float &fH, float &fS, float &fV) {
void HSVtoRGBbutDifferentIGuess(float &fR, float &fG, float &fB, float &fH,
float &fS, float &fV) {
float fC = fV * fS; // Chroma
float fHPrime = fmod(fH / 60.0, 6);
float fX = fC * (1 - fabs(fmod(fHPrime, 2) - 1));
Expand Down Expand Up @@ -69,10 +70,8 @@ cocos2d::_ccColor3B getRainbow(float offset, float saturation) {
return out;
}

// thanks to shadowforce78
class $modify(PlayerObject) {
void flashPlayer(float p0, float p1, cocos2d::ccColor3B mainColor, cocos2d::ccColor3B secondColor) {
// neutralised kappa
}
};

Expand All @@ -94,21 +93,30 @@ class $modify(PlayLayer) {
auto rainbowColor2 = getRainbow(180, saturation);
auto rainbowColor3 = getRainbow(90, saturation);
bool enable = Mod::get()->getSettingValue<bool>("enable");
bool noRegularTrail = Mod::get()->getSettingValue<bool>("no-reg-trail");

if (m_player1->m_isDart && noRegularTrail) {
m_player1->m_regularTrail->setVisible(false);
}

if (m_player2->m_isDart && noRegularTrail) {
m_player2->m_regularTrail->setVisible(false);
}

if (enable == true) {
if (!mirror_players) {
if (m_player1->m_waveTrail) {
m_player1->m_waveTrail->setColor(rainbowColor);
}

if (m_player2->m_waveTrail) {
m_player2->m_waveTrail->setColor(rainbowColor2);
}
} else {
if (m_player1->m_waveTrail) {
m_player1->m_waveTrail->setColor(rainbowColor);
}

if (m_player2->m_waveTrail) {
m_player2->m_waveTrail->setColor(rainbowColor);
}
Expand Down
38 changes: 38 additions & 0 deletions src/pause_button.cpp
Original file line number Diff line number Diff line change
@@ -0,0 +1,38 @@
#include <Geode/Geode.hpp>
#include <Geode/modify/Modify.hpp>
#include <Geode/modify/PauseLayer.hpp>
#include <Geode/ui/GeodeUI.hpp>

using namespace geode::prelude;

struct GayPauseLayer : Modify<GayPauseLayer, PauseLayer> {
void onGaySettings(CCObject *object) {
geode::openSettingsPopup(Mod::get());
}

void customSetup() {
PauseLayer::customSetup();

auto winSize = CCDirector::sharedDirector()->getWinSize();
auto ccmenu = CCMenu::create();

ccmenu->setPosition(CCPoint{0, 0});
ccmenu->setID("gay-settings-button-menu"_spr);

auto *settingsButtonSprite = CCSprite::create("logo.png"_spr);

settingsButtonSprite->setScale(0.25f);

auto settingsBtn = CCMenuItemSpriteExtra::create(
settingsButtonSprite,
this,
menu_selector(GayPauseLayer::onGaySettings)
);

settingsBtn->setID("gay-settings-button"_spr);
settingsBtn->setPosition(CCPoint{ 30, 30 });
ccmenu->addChild(settingsBtn);

this->addChild(ccmenu);
}
};

0 comments on commit 440ea39

Please sign in to comment.