@@ -178,6 +178,12 @@ class APAdvancedSettingsState extends MusicBeatState
178178 var MHPWeight : Int = 3 ;
179179 var MHPDWeight : Int = 3 ;
180180
181+ // Z11's Optional Hell
182+ var starter_debuff : Bool = false ;
183+ var perma_traps : Bool = false ;
184+ var hard_mode : Bool = false ;
185+ var enable_shop : Bool = false ;
186+
181187 // Navigation cooldown
182188 var navigationCooldown : Float = 0 ;
183189 var navigationDelay : Float = 0.15 ; // 150ms delay between navigation inputs
@@ -451,6 +457,14 @@ class APAdvancedSettingsState extends MusicBeatState
451457 stagesanity = value == true ;
452458 case " charactersanity" :
453459 charactersanity = value == true ;
460+ case " starter_debuff" :
461+ starter_debuff = value == true ;
462+ case " perma_traps" :
463+ perma_traps = value == true ;
464+ case " hard_mode" :
465+ hard_mode = value == true ;
466+ case " enable_shop" :
467+ enable_shop = value == true ;
454468 // Handle any other potential fields that might exist
455469 default :
456470 trace (' Unknown YAML field during import: $field = $value ' );
@@ -876,6 +890,83 @@ class APAdvancedSettingsState extends MusicBeatState
876890 )
877891 ];
878892
893+
894+ // Z11 Options Page - things you can but probably shouldn't turn on
895+ var z11Options : Array <SettingsOption > = [];
896+
897+ z11Options .push ({
898+ name : " Starter Debuffs" ,
899+ description : " Inflicts you with four near-perminant debuffs (SEE WIKI PAGE FOR DEBUFF DETAILS)" ,
900+ callback : function () {
901+ starter_debuff = ! starter_debuff ;
902+ refreshCurrentPage ();
903+ },
904+ locked : false ,
905+ contextMenu : createBoolContextMenu (starter_debuff , function (value : Bool ) {
906+ starter_debuff = value ;
907+ // Don't refresh here - the main callback will handle it
908+ })
909+ });
910+
911+ z11Options .push ({
912+ name : " Perma-Traps" ,
913+ description : " Makes the starting debuffs Trap Items instead (SEE WIKI PAGE FOR DEBUFF DETAILS)" ,
914+ callback : function () {
915+ perma_traps = ! perma_traps ;
916+ refreshCurrentPage ();
917+ },
918+ locked : false ,
919+ contextMenu : createBoolContextMenu (perma_traps , function (value : Bool ) {
920+ perma_traps = value ;
921+ // Don't refresh here - the main callback will handle it
922+ })
923+ });
924+
925+ z11Options .push ({
926+ name : " HARD MODE" ,
927+ description : " Huh? You don't want to be able to play the game right off the bat? No problem! (SEE WIKI PAGE FOR HARD MODE DETAILS)" ,
928+ callback : function () {
929+ hard_mode = ! hard_mode ;
930+ if (hard_mode ) FlxG .sound .play (Paths .sound (' mus-mode' ), 2 );
931+ refreshCurrentPage ();
932+ },
933+ locked : false ,
934+ contextMenu : createBoolContextMenu (hard_mode , function (value : Bool ) {
935+ hard_mode = value ;
936+ if (hard_mode ) FlxG .sound .play (Paths .sound (' mus-mode' ), 2 );
937+ // Don't refresh here - the main callback will handle it
938+ })
939+ });
940+
941+ z11Options .push ({
942+ name : " Enable Shop" ,
943+ description : " Hey there. Heard you wanted to buy things from me. (SEE WIKI PAGE FOR SHOP DETAILS)" ,
944+ callback : function () {
945+ enable_shop = ! enable_shop ;
946+ if (enable_shop ) FlxG .sound .play (Paths .sound (' uh oh' ), 2 );
947+ else FlxG .sound .play (Paths .sound (' ok nevermind were good' ), 2 );
948+ refreshCurrentPage ();
949+ },
950+ locked : false ,
951+ contextMenu : createBoolContextMenu (enable_shop , function (value : Bool ) {
952+ enable_shop = value ;
953+ if (enable_shop ) FlxG .sound .play (Paths .sound (' uh oh' ), 2 );
954+ else FlxG .sound .play (Paths .sound (' ok nevermind were good' ), 2 );
955+ // Don't refresh here - the main callback will handle it
956+ })
957+ });
958+
959+ z11Options .push ({
960+ name : " ???" ,
961+ description : " Oh me? Don't worry about why i'm here. Not yet, at least~" ,
962+ callback : function () {
963+ FlxG .sound .play (Paths .sound (' mus-wawa' ));
964+ refreshCurrentPage ();
965+ },
966+ locked : true ,
967+ contextMenu : createEditContextMenu (() -> giveNotice ())
968+ });
969+
879970 pages = [
880971 {
881972 name : " MAIN SETTINGS" ,
@@ -911,6 +1002,13 @@ class APAdvancedSettingsState extends MusicBeatState
9111002 options : sanityOptions ,
9121003 stateOptions : [],
9131004 color : FlxColor .PINK
1005+ },
1006+ {
1007+ name : " Z11'S OPTIONAL HELL" ,
1008+ description : " Fun(?) things I decided to add for those looking for something more than the usual >:)" ,
1009+ options : z11Options ,
1010+ stateOptions : [],
1011+ color : FlxColor .WHITE
9141012 }
9151013 ];
9161014 }
@@ -1337,7 +1435,9 @@ class APAdvancedSettingsState extends MusicBeatState
13371435 pageIndicator .text = ' ${currentPage + 1 } / ${pages .length } - ${page .name }' ;
13381436
13391437 // Change title color based on page
1340- titleText .color = page .color ;
1438+ if (page .name == " Z11'S OPTIONAL HELL" ) {
1439+ rainbowText = true ;
1440+ } else {rainbowText = false ; titleText .color = page .color ;}
13411441 if (glowEffect != null )
13421442 {
13431443 glowEffect .color = page .color ;
@@ -1493,6 +1593,11 @@ class APAdvancedSettingsState extends MusicBeatState
14931593 case " Sanity Completion Type" : sanity_completion_type ;
14941594 case " Stagesanity" : stagesanity ? " ON" : " OFF" ;
14951595 case " Charactersanity" : charactersanity ? " ON" : " OFF" ;
1596+ case " Starter Debuffs" : starter_debuff ? " ON" : " OFF" ;
1597+ case " Perma-Traps" : perma_traps ? " ON" : " OFF" ;
1598+ case " HARD MODE" : hard_mode ? " ON" : " OFF" ;
1599+ case " Enable Shop" : enable_shop ? " ON" : " OFF" ;
1600+ case " ???" : true ? " Not Yet..." : " Not Yet..." ;
14961601 default : " " ;
14971602 }
14981603 }
@@ -1920,6 +2025,8 @@ class APAdvancedSettingsState extends MusicBeatState
19202025 openSubState (enumSubstate );
19212026 }
19222027
2028+ function giveNotice () openSubState (new Prompt (" Give it time, hun.\n We'll get to know each other soon enough,\n I promise~ " , 0 , null , null , false , " Wait What" , " Who the heck-" ));
2029+
19232030 function setOptionValue (optionName : String , value : Dynamic )
19242031 {
19252032 switch (optionName )
@@ -2969,6 +3076,10 @@ class APAdvancedSettingsState extends MusicBeatState
29693076 sanity_completion_type = Reflect .hasField (settings , " sanity_completion_type" ) ? Reflect .field (settings , " sanity_completion_type" ) : " on_getting" ;
29703077 stagesanity = Reflect .hasField (settings , " stagesanity" ) ? settings .stagesanity : false ;
29713078 charactersanity = Reflect .hasField (settings , " charactersanity" ) ? settings .charactersanity : false ;
3079+ starter_debuff = Reflect .hasField (settings , " starter_debuff" ) ? settings .starter_debuff : false ;
3080+ hard_mode = Reflect .hasField (settings , " hard_mode" ) ? settings .hard_mode : false ;
3081+ enable_shop = Reflect .hasField (settings , " enable_shop" ) ? settings .enable_shop : false ;
3082+ perma_traps = Reflect .hasField (settings , " perma_traps" ) ? settings .perma_traps : false ;
29723083 }
29733084 }
29743085
@@ -3021,6 +3132,10 @@ class APAdvancedSettingsState extends MusicBeatState
30213132 Reflect .setField (settings , " sanity_completion_type" , sanity_completion_type );
30223133 settings .stagesanity = stagesanity ;
30233134 settings .charactersanity = charactersanity ;
3135+ settings .starter_debuff = starter_debuff ;
3136+ settings .perma_traps = perma_traps ;
3137+ settings .hard_mode = hard_mode ;
3138+ settings .enable_shop = enable_shop ;
30243139 }
30253140 }
30263141
@@ -3571,6 +3686,10 @@ class APAdvancedSettingsState extends MusicBeatState
35713686 Reflect .setField (yamlThing , " sanity_completion_type" , sanity_completion_type );
35723687 Reflect .setField (yamlThing , " stagesanity" , stagesanity );
35733688 Reflect .setField (yamlThing , " charactersanity" , charactersanity );
3689+ Reflect .setField (yamlThing , " starter_debuff" , starter_debuff );
3690+ Reflect .setField (yamlThing , " perma_traps" , perma_traps );
3691+ Reflect .setField (yamlThing , " hard_mode" , hard_mode );
3692+ Reflect .setField (yamlThing , " enable_shop" , enable_shop );
35743693 if (startingSong != null )
35753694 {
35763695 Reflect .setField (yamlThing , " starting_song" , startingSong );
@@ -3722,6 +3841,10 @@ class APAdvancedSettingsState extends MusicBeatState
37223841 Reflect .setField (yamlThing , " sanity_completion_type" , sanity_completion_type );
37233842 Reflect .setField (yamlThing , " stagesanity" , stagesanity );
37243843 Reflect .setField (yamlThing , " charactersanity" , charactersanity );
3844+ Reflect .setField (yamlThing , " starter_debuff" , starter_debuff );
3845+ Reflect .setField (yamlThing , " perma_traps" , perma_traps );
3846+ Reflect .setField (yamlThing , " hard_mode" , hard_mode );
3847+ Reflect .setField (yamlThing , " enable_shop" , enable_shop );
37253848 if (startingSong != null )
37263849 {
37273850 Reflect .setField (yamlThing , " starting_song" , startingSong );
@@ -4111,9 +4234,15 @@ class APAdvancedSettingsState extends MusicBeatState
41114234 openSubState (progressSubstate );
41124235 }
41134236
4237+ var pubE : Float = 0 ;
4238+ var rainbowText : Bool = false ;
41144239 override function update (elapsed : Float )
41154240 {
41164241 super .update (elapsed );
4242+ if (rainbowText ) {
4243+ titleText .color = FlxColor .fromHSL (((elapsed / 2 ) / 300 * 360 ) % 360 , 1.0 , 0.5 * 1.0 );
4244+ if (glowEffect != null ) glowEffect .color = FlxColor .fromHSL (((elapsed / 2.5 ) / 300 * 360 ) % 360 , 1.0 , 0.5 * 1.0 );
4245+ }
41174246
41184247 if (forceExportPath != null )
41194248 {
@@ -4286,6 +4415,10 @@ class APAdvancedSettingsState extends MusicBeatState
42864415 }
42874416 else
42884417 {
4418+ if (option .name == " ???" ) {
4419+ FlxG .sound .play (Paths .sound (' mus-wawa' ), 5 );
4420+ giveNotice ();
4421+ }
42894422 FlxG .sound .play (Paths .sound (' cancelMenu' ));
42904423 FlxG .camera .shake (0.01 , 0.2 );
42914424 }
@@ -4410,7 +4543,11 @@ class APAdvancedSettingsState extends MusicBeatState
44104543 enable_sanity_locations : enable_sanity_locations ,
44114544 sanity_completion_type : sanity_completion_type ,
44124545 stagesanity : stagesanity ,
4413- charactersanity : charactersanity
4546+ charactersanity : charactersanity ,
4547+ starter_debuff : starter_debuff ,
4548+ perma_traps : perma_traps ,
4549+ hard_mode : hard_mode ,
4550+ enable_shop : enable_shop
44144551 };
44154552
44164553 if (tempSave != null )
@@ -4488,6 +4625,16 @@ class APAdvancedSettingsState extends MusicBeatState
44884625 stagesanity = data .stagesanity ;
44894626 if (Reflect .hasField (data , " charactersanity" ))
44904627 charactersanity = data .charactersanity ;
4628+
4629+ // Load Z11's Optional Hell
4630+ if (Reflect .hasField (data , " starter_debuff" ))
4631+ starter_debuff = data .starter_debuff ;
4632+ if (Reflect .hasField (data , " perma_traps" ))
4633+ perma_traps = data .perma_traps ;
4634+ if (Reflect .hasField (data , " hard_mode" ))
4635+ hard_mode = data .hard_mode ;
4636+ if (Reflect .hasField (data , " enable_shop" ))
4637+ enable_shop = data .enable_shop ;
44914638 }
44924639 }
44934640
0 commit comments