Add invicible cheat

This commit is contained in:
Garrett Cox
2024-11-24 23:37:48 -06:00
committed by Alejandro Asenjo Nitti
parent 7d60b7e65d
commit 29da9a6ea0
2 changed files with 4 additions and 1 deletions
+3 -1
View File
@@ -5559,7 +5559,9 @@ void Player_UpdateShields(Player* player) {
if (player->damage <= 0) {
player->damage = 0;
}
player->shields -= 2;
if (!CVarGetInteger("gInvincible", 0)) {
player->shields -= 2;
}
if (player->shields <= 0) {
player->shields = 0;
player->damage = 0;
+1
View File
@@ -460,6 +460,7 @@ void DrawEnhancementsMenu() {
void DrawCheatsMenu() {
if (UIWidgets::BeginMenu("Cheats")) {
UIWidgets::CVarCheckbox("Infinite Lives", "gInfiniteLives");
UIWidgets::CVarCheckbox("Invincible", "gInvincible");
UIWidgets::CVarCheckbox("Unbreakable Wings", "gUnbreakableWings");
UIWidgets::CVarCheckbox("Infinite Bombs", "gInfiniteBombs");
UIWidgets::CVarCheckbox("Hyper Laser", "gHyperLaser");