1
0
mirror of https://github.com/TerryCavanagh/VVVVVV.git synced 2024-06-25 05:58:30 +02:00

Add glitchrunner mode, in game options

Glitchrunner mode is intended to re-enable glitches that existed in
older versions of VVVVVV. These glitches were removed because they could
legitimately affect a casual player's experience. Glitches like various
R-pressing screwery, Space Station 1 skip, telejumping, Gravitron
out-of-bounds, etc. will not be patched.
This commit is contained in:
Misa 2020-06-25 14:31:37 -07:00 committed by Ethan Lee
parent 18b34d0066
commit 779083b417
4 changed files with 40 additions and 10 deletions

View File

@ -387,6 +387,7 @@ void Game::init(void)
#endif
over30mode = false;
glitchrunnermode = false;
ingame_titlemode = false;
kludge_ingametemp = Menu::mainmenu;
@ -4756,6 +4757,11 @@ void Game::loadstats()
over30mode = atoi(pText);
}
if (pKey == "glitchrunnermode")
{
glitchrunnermode = atoi(pText);
}
if (pKey == "vsync")
{
graphics.vsync = atoi(pText);
@ -5010,6 +5016,10 @@ void Game::savestats()
msg->LinkEndChild(doc.NewText(help.String((int) over30mode).c_str()));
dataNode->LinkEndChild(msg);
msg = doc.NewElement("glitchrunnermode");
msg->LinkEndChild(doc.NewText(help.String((int) glitchrunnermode).c_str()));
dataNode->LinkEndChild(msg);
msg = doc.NewElement("vsync");
msg->LinkEndChild(doc.NewText(help.String((int) graphics.vsync).c_str()));
dataNode->LinkEndChild(msg);
@ -7129,6 +7139,7 @@ void Game::createmenu( enum Menu::MenuName t, bool samemenu/*= false*/ )
break;
case Menu::options:
option("accessibility options");
option("glitchrunner mode");
#if !defined(MAKEANDPLAY)
option("unlock play modes");
#endif
@ -7140,7 +7151,7 @@ void Game::createmenu( enum Menu::MenuName t, bool samemenu/*= false*/ )
}
option("return");
menuxoff = -40;
menuxoff = -50;
menuyoff = 0;
break;
case Menu::accessibility:

View File

@ -404,6 +404,7 @@ public:
}
bool over30mode;
bool glitchrunnermode; // Have fun speedrunners! <3 Misa
bool ingame_titlemode;

View File

@ -564,21 +564,26 @@ void menuactionpress()
game.createmenu(Menu::accessibility);
map.nexttowercolour();
break;
#if !defined(MAKEANDPLAY)
case 1:
// Glitchrunner mode
music.playef(11);
game.glitchrunnermode = !game.glitchrunnermode;
break;
#if !defined(MAKEANDPLAY)
case 2:
//unlock play options
music.playef(11);
game.createmenu(Menu::unlockmenu);
map.nexttowercolour();
break;
#endif
case OFFSET+2:
case OFFSET+3:
//clear data menu
music.playef(11);
game.createmenu(Menu::controller);
map.nexttowercolour();
break;
case OFFSET+3:
case OFFSET+4:
//clear data menu
music.playef(11);
game.createmenu(Menu::cleardatamenu);
@ -587,7 +592,7 @@ void menuactionpress()
}
int mmmmmm_offset = music.mmmmmm ? 0 : -1;
if (game.currentmenuoption == OFFSET+4+mmmmmm_offset)
if (game.currentmenuoption == OFFSET+5+mmmmmm_offset)
{
//**** TOGGLE MMMMMM
if(game.usingmmmmmm > 0){
@ -600,7 +605,7 @@ void menuactionpress()
music.play(music.currentsong);
game.savestats();
}
else if (game.currentmenuoption == OFFSET+5+mmmmmm_offset)
else if (game.currentmenuoption == OFFSET+6+mmmmmm_offset)
{
//back
music.playef(11);

View File

@ -88,24 +88,37 @@ void menurender()
graphics.Print( -1, 65, "Disable screen effects, enable", tr, tg, tb, true);
graphics.Print( -1, 75, "slowdown modes or invincibility", tr, tg, tb, true);
break;
#if !defined(MAKEANDPLAY)
case 1:
graphics.bigprint( -1, 30, "Glitchrunner Mode", tr, tg, tb, true);
graphics.Print( -1, 65, "Re-enable glitches that existed", tr, tg, tb, true);
graphics.Print( -1, 75, "in previous versions of the game", tr, tg, tb, true);
if (game.glitchrunnermode)
{
graphics.Print( -1, 95, "Glitchrunner mode is ON", tr, tg, tb, true);
}
else
{
graphics.Print( -1, 95, "Glitchrunner mode is OFF", tr/2, tg/2, tb/2, true);
}
break;
#if !defined(MAKEANDPLAY)
case 2:
graphics.bigprint( -1, 30, "Unlock Play Modes", tr, tg, tb, true);
graphics.Print( -1, 65, "Unlock parts of the game normally", tr, tg, tb, true);
graphics.Print( -1, 75, "unlocked as you progress", tr, tg, tb, true);
break;
#endif
case OFFSET+2:
case OFFSET+3:
graphics.bigprint( -1, 30, "Game Pad Options", tr, tg, tb, true);
graphics.Print( -1, 65, "Rebind your controller's buttons", tr, tg, tb, true);
graphics.Print( -1, 75, "and adjust sensitivity", tr, tg, tb, true);
break;
case OFFSET+3:
case OFFSET+4:
graphics.bigprint( -1, 30, "Clear Data", tr, tg, tb, true);
graphics.Print( -1, 65, "Delete your save data", tr, tg, tb, true);
graphics.Print( -1, 75, "and unlocked play modes", tr, tg, tb, true);
break;
case OFFSET+4:
case OFFSET+5:
if(music.mmmmmm){
graphics.bigprint( -1, 30, "Soundtrack", tr, tg, tb, true);
graphics.Print( -1, 65, "Toggle between MMMMMM and PPPPPP", tr, tg, tb, true);