mirror of
https://github.com/izzy2lost/2ship2harkinian-Android.git
synced 2026-06-19 01:20:08 -07:00
[Enhancement] No Blast Mask Cooldown (#242)
* No Blast Mask Cooldown * Re-add empty line * Change enum name
This commit is contained in:
@@ -325,6 +325,7 @@ void DrawEnhancementsMenu() {
|
||||
UIWidgets::CVarCheckbox("Fierce Deity's Mask Anywhere", "gEnhancements.Masks.FierceDeitysAnywhere", {
|
||||
.tooltip = "Allow using Fierce Deity's mask outside of boss rooms."
|
||||
});
|
||||
UIWidgets::CVarCheckbox("No Blast Mask Cooldown", "gEnhancements.Masks.NoBlastMaskCooldown", {});
|
||||
|
||||
ImGui::EndMenu();
|
||||
}
|
||||
|
||||
@@ -11,6 +11,7 @@ void InitEnhancements() {
|
||||
// Masks
|
||||
RegisterFastTransformation();
|
||||
RegisterFierceDeityAnywhere();
|
||||
RegisterNoBlastMaskCooldown();
|
||||
|
||||
// Restorations
|
||||
RegisterSideRoll();
|
||||
|
||||
@@ -5,6 +5,7 @@
|
||||
#include "Cheats/Infinite.h"
|
||||
#include "Cycle/EndOfCycle.h"
|
||||
#include "Masks/FierceDeityAnywhere.h"
|
||||
#include "Masks/NoBlastMaskCooldown.h"
|
||||
#include "Masks/FastTransformation.h"
|
||||
#include "Cutscenes/SkipEntranceCutscenes.h"
|
||||
#include "Cutscenes/HideTitleCards.h"
|
||||
|
||||
@@ -32,6 +32,7 @@ typedef enum {
|
||||
GI_VB_SHOW_TITLE_CARD,
|
||||
GI_VB_PLAY_ENTRANCE_CS,
|
||||
GI_VB_DISABLE_FD_MASK,
|
||||
GI_VB_SET_BLAST_MASK_COOLDOWN_TIMER,
|
||||
GI_VB_PATCH_SIDEROLL,
|
||||
GI_VB_PREVENT_MASK_TRANSFORMATION_CS,
|
||||
} GIVanillaBehavior;
|
||||
|
||||
@@ -0,0 +1,10 @@
|
||||
#include <libultraship/bridge.h>
|
||||
#include "Enhancements/GameInteractor/GameInteractor.h"
|
||||
|
||||
void RegisterNoBlastMaskCooldown() {
|
||||
REGISTER_VB_SHOULD(GI_VB_SET_BLAST_MASK_COOLDOWN_TIMER, {
|
||||
if (CVarGetInteger("gEnhancements.Masks.NoBlastMaskCooldown", 0)) {
|
||||
*should = false;
|
||||
}
|
||||
});
|
||||
}
|
||||
@@ -0,0 +1,6 @@
|
||||
#ifndef NO_BLAST_MASK_COOLDOWN_H
|
||||
#define NO_BLAST_MASK_COOLDOWN_H
|
||||
|
||||
void RegisterNoBlastMaskCooldown();
|
||||
|
||||
#endif // NO_BLAST_MASK_COOLDOWN_H
|
||||
@@ -3726,7 +3726,9 @@ void Player_ProcessItemButtons(Player* this, PlayState* play) {
|
||||
|
||||
if (bomb != NULL) {
|
||||
bomb->timer = 0;
|
||||
this->blastMaskTimer = 310;
|
||||
if (GameInteractor_Should(GI_VB_SET_BLAST_MASK_COOLDOWN_TIMER, true, NULL)) {
|
||||
this->blastMaskTimer = 310;
|
||||
}
|
||||
}
|
||||
}
|
||||
} else if (item == ITEM_F1) {
|
||||
|
||||
Reference in New Issue
Block a user