Files
CookieMonster/src/Disp/HelperFunctions/UpdateBackground.js
Daniël van Noord 1c8bd79640 Fixed linting issues
2021-05-01 22:43:02 +02:00

13 lines
644 B
JavaScript

/**
* This function sets the size of the background of the full game and the left column
* depending on whether certain abrs are activated
* It is called by CM.Disp.UpdateAscendState() and CM.Disp.UpdateBotTimerBarPosition()
*/
export default function UpdateBackground() {
Game.Background.canvas.width = Game.Background.canvas.parentNode.offsetWidth;
Game.Background.canvas.height = Game.Background.canvas.parentNode.offsetHeight;
Game.LeftBackground.canvas.width = Game.LeftBackground.canvas.parentNode.offsetWidth;
Game.LeftBackground.canvas.height = Game.LeftBackground.canvas.parentNode.offsetHeight;
Game.DrawBackground();
}