Wrinkler button disappear when not active
This commit is contained in:
File diff suppressed because one or more lines are too long
2
dist/CookieMonster.js
vendored
2
dist/CookieMonster.js
vendored
File diff suppressed because one or more lines are too long
2
dist/CookieMonster.js.map
vendored
2
dist/CookieMonster.js.map
vendored
File diff suppressed because one or more lines are too long
@@ -5,7 +5,7 @@ import { CMOptions } from '../VariablesAndData';
|
|||||||
* It is called by changes in CM.Options.WrinklerButtons
|
* It is called by changes in CM.Options.WrinklerButtons
|
||||||
*/
|
*/
|
||||||
export default function ToggleWrinklerButtons() {
|
export default function ToggleWrinklerButtons() {
|
||||||
if (CMOptions.WrinklerButtons) {
|
if (CMOptions.WrinklerButtons && Game.elderWrath) {
|
||||||
l('PopAllNormalWrinklerButton').style.display = '';
|
l('PopAllNormalWrinklerButton').style.display = '';
|
||||||
l('PopFattestWrinklerButton').style.display = '';
|
l('PopFattestWrinklerButton').style.display = '';
|
||||||
} else {
|
} else {
|
||||||
|
|||||||
@@ -1,3 +1,4 @@
|
|||||||
|
import ToggleWrinklerButtons from '../Config/Toggles/ToggleWrinklerButtons';
|
||||||
import { CMOptions } from '../Config/VariablesAndData';
|
import { CMOptions } from '../Config/VariablesAndData';
|
||||||
import { Beautify } from './BeautifyAndFormatting/BeautifyFormatting';
|
import { Beautify } from './BeautifyAndFormatting/BeautifyFormatting';
|
||||||
import UpdateBuildings from './BuildingsUpgrades/Buildings';
|
import UpdateBuildings from './BuildingsUpgrades/Buildings';
|
||||||
@@ -52,6 +53,9 @@ export default function Draw() {
|
|||||||
// Change menu refresh interval
|
// Change menu refresh interval
|
||||||
RefreshMenu();
|
RefreshMenu();
|
||||||
|
|
||||||
|
// Update display of wrinkler buttons, this checks if Elder Pledge has been bought and if they should be disabled
|
||||||
|
ToggleWrinklerButtons();
|
||||||
|
|
||||||
// Replace Cookies counter because Orteil uses very weird code to "pad" it...
|
// Replace Cookies counter because Orteil uses very weird code to "pad" it...
|
||||||
if (CMOptions.Scale) {
|
if (CMOptions.Scale) {
|
||||||
let str = l('cookies').innerHTML.replace(
|
let str = l('cookies').innerHTML.replace(
|
||||||
|
|||||||
@@ -59,6 +59,7 @@ export default function InitializeCookieMonster() {
|
|||||||
Game.CalculateGains();
|
Game.CalculateGains();
|
||||||
|
|
||||||
LoadConfig(); // Must be after all things are created!
|
LoadConfig(); // Must be after all things are created!
|
||||||
|
Game.UpdateMenu();
|
||||||
CMLastAscendState = Game.OnAscend;
|
CMLastAscendState = Game.OnAscend;
|
||||||
|
|
||||||
if (Game.prefs.popups)
|
if (Game.prefs.popups)
|
||||||
|
|||||||
Reference in New Issue
Block a user