Complete overhaul of code structure and relevant files (#639)
This commit is contained in:
20
src/Disp/HelperFunctions/UpdateAscendState.js
Normal file
20
src/Disp/HelperFunctions/UpdateAscendState.js
Normal file
@@ -0,0 +1,20 @@
|
||||
import { ToggleTimerBar } from '../../Config/SpecificToggles';
|
||||
import ToggleBotBar from '../../Config/Toggles/ToggleBotBar';
|
||||
import { CMOptions } from '../../Config/VariablesAndData';
|
||||
import UpdateBackground from './UpdateBackground';
|
||||
|
||||
/**
|
||||
* This function disables and shows the bars created by CookieMonster when the game is "ascending"
|
||||
* It is called by CM.Disp.Draw()
|
||||
*/
|
||||
export default function UpdateAscendState() {
|
||||
if (Game.OnAscend) {
|
||||
l('game').style.bottom = '0px';
|
||||
if (CMOptions.BotBar === 1) l('CMBotBar').style.display = 'none';
|
||||
if (CMOptions.TimerBar === 1) l('CMTimerBar').style.display = 'none';
|
||||
} else {
|
||||
ToggleBotBar();
|
||||
ToggleTimerBar();
|
||||
}
|
||||
UpdateBackground();
|
||||
}
|
||||
Reference in New Issue
Block a user