mirror of
https://gitlab.com/lecarore/breakout71.git
synced 2025-06-16 19:25:06 -04:00
wip
This commit is contained in:
parent
9e12f62b81
commit
892f800107
14 changed files with 2866 additions and 2840 deletions
|
@ -12,7 +12,6 @@ import { t } from "./i18n/i18n";
|
|||
import { clamp } from "./pure_functions";
|
||||
import { getSettingValue, getTotalScore } from "./settings";
|
||||
import { isOptionOn } from "./options";
|
||||
import {gameCanvas} from "./render";
|
||||
|
||||
export function describeLevel(level: Level) {
|
||||
let bricks = 0,
|
||||
|
@ -347,13 +346,12 @@ export function escapeAttribute(str: String) {
|
|||
.replace(/'/gi, "'");
|
||||
}
|
||||
|
||||
export function canvasCenterX(gameState:GameState){
|
||||
return gameState.canvasWidth/2
|
||||
export function canvasCenterX(gameState: GameState) {
|
||||
return gameState.canvasWidth / 2;
|
||||
}
|
||||
export function zoneLeftBorderX(gameState:GameState){
|
||||
|
||||
return gameState.offsetXRoundedDown - 1
|
||||
export function zoneLeftBorderX(gameState: GameState) {
|
||||
return gameState.offsetXRoundedDown - 1;
|
||||
}
|
||||
export function zoneRightBorderX(gameState: GameState) {
|
||||
return gameState.canvasWidth - gameState.offsetXRoundedDown + 1;
|
||||
}
|
||||
export function zoneRightBorderX(gameState:GameState){
|
||||
return gameCanvas.width - gameState.offsetXRoundedDown + 1
|
||||
}
|
Loading…
Add table
Add a link
Reference in a new issue