diff --git a/SpaceCadetPinball/control.cpp b/SpaceCadetPinball/control.cpp index 56cf46c..806bcfe 100644 --- a/SpaceCadetPinball/control.cpp +++ b/SpaceCadetPinball/control.cpp @@ -902,9 +902,19 @@ void control::table_set_replay(float value) control_info_text_box_tag.Component->Display(pinball::get_rc_string(0, 0), value); } -int control::cheat_bump_rank() +void control::cheat_bump_rank() { - return 0; + char Buffer[64]{}; + + auto rank = control_middle_circle_tag.Component->Message(37, 0.0); + if (rank < 9) + { + control_middle_circle_tag.Component->Message(41, 2.0f); + auto rankText = pinball::get_rc_string(RankRcArray[rank], 1); + snprintf(Buffer, sizeof Buffer, pinball::get_rc_string(83, 0), rankText); + control_mission_text_box_tag.Component->Display(Buffer, 8.0); + control_soundwave10_tag.Component->Play(); + } } bool control::light_on(component_tag* tag) diff --git a/SpaceCadetPinball/control.h b/SpaceCadetPinball/control.h index 138ed95..2613e56 100644 --- a/SpaceCadetPinball/control.h +++ b/SpaceCadetPinball/control.h @@ -81,7 +81,7 @@ public: static void table_set_multiball(); static void table_bump_ball_sink_lock(); static void table_set_replay(float value); - static int cheat_bump_rank(); + static void cheat_bump_rank(); static bool light_on(component_tag* tag); static int SpecialAddScore(int score); static int AddRankProgress(int rank); diff --git a/SpaceCadetPinball/high_score.cpp b/SpaceCadetPinball/high_score.cpp index 2e59385..6bb9c7c 100644 --- a/SpaceCadetPinball/high_score.cpp +++ b/SpaceCadetPinball/high_score.cpp @@ -99,7 +99,6 @@ int high_score::write(high_score_struct* table, int* ptrToSmth) { } scoreSum += tablePtr->Score; - ++position; ++tablePtr; } scramble_number_string(scoreSum, buf);