fixed error in fillLevelsSelection

這個提交存在於:
nbillard 2022-12-05 17:54:16 +01:00
父節點 03c76e61bc
當前提交 771eeab446
共有 2 個檔案被更改,包括 3 行新增3 行删除

查看文件

@ -1,6 +1,6 @@
import { levelsBlueprint } from '/modules/levels.mjs' import { levelsBlueprint } from '/modules/levels.mjs'
export const fillLevelSelection = () => { export const fillLevelsSelection = () => {
let levelList = document.getElementById('level-list'); let levelList = document.getElementById('level-list');
for (let i = 0; i < levelsBlueprint.size; ++i) { for (let i = 0; i < levelsBlueprint.size; ++i) {
let listElement = document.createElement("li"); let listElement = document.createElement("li");

查看文件

@ -1,9 +1,9 @@
import { generatePlayground } from '/modules/playground.mjs' import { generatePlayground } from '/modules/playground.mjs'
import {levelsBlueprint } from '/modules/levels.mjs' import { levelsBlueprint } from '/modules/levels.mjs'
import { MoveDirection } from '/modules/enums.mjs' import { MoveDirection } from '/modules/enums.mjs'
import { fillLevelsSelection } from '/modules/fillLevelsSelection.mjs' import { fillLevelsSelection } from '/modules/fillLevelsSelection.mjs'
fillLevelSelection(); fillLevelsSelection();
let canvas = document.getElementById('canvas'); let canvas = document.getElementById('canvas');
let ctx = canvas.getContext('2d'); let ctx = canvas.getContext('2d');
window.ctx = ctx window.ctx = ctx