65 lines
2.1 KiB
JavaScript
65 lines
2.1 KiB
JavaScript
const tileSize = 32;
|
|
|
|
const text = require(__dirname + "/../../res/lang/default.js");
|
|
|
|
let level = {
|
|
tiles: [
|
|
1, 2, 2, 2, 2, 2, 2, 2, 2, 2, 2, 2, 2, 2, 2, 2, 2, 2, 2, 2, 2, 2, 2, 2, 2, 2, 2, 2, 5, 6,
|
|
4, 21, 22, 23, 21, 22, 23, 27, 28, 23, 21, 22, 23, 21, 22, 23, 21, 22, 23, 21, 22, 23, 21, 22, 23, 27, 28, 23, 21, 7,
|
|
4, 17, 17, 17, 17, 17, 17, 19, 17, 17, 19, 17, 20, 17, 17, 17, 17, 17, 17, 17, 18, 17, 17, 20, 17, 17, 17, 17, 17, 7,
|
|
4, 17, 18, 17, 17, 17, 17, 17, 17, 17, 17, 17, 17, 17, 17, 17, 20, 17, 17, 17, 17, 17, 17, 17, 17, 17, 17, 20, 17, 7,
|
|
4, 17, 17, 17, 17, 18, 17, 17, 17, 20, 17, 18, 17, 17, 19, 17, 17, 17, 17, 17, 19, 17, 17, 17, 17, 17, 17, 17, 18, 7,
|
|
14, 11, 11, 11, 11, 11, 11, 11, 11, 11, 11, 11, 11, 11, 11, 11, 11, 11, 11, 11, 11, 11, 11, 16, 47, 12, 11, 11, 10, 13,
|
|
0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 14, 50, 13, 0, 0, 0, 0,
|
|
],
|
|
size: {
|
|
w: 30 * tileSize,
|
|
h: 7 * tileSize
|
|
},
|
|
startPos: [
|
|
{ x: 5 * tileSize, y: 3 * tileSize },
|
|
{ x: 24 * tileSize, y: 4 * tileSize },
|
|
{ x: 24 * tileSize, y: 3 * tileSize },
|
|
],
|
|
entities: [
|
|
{
|
|
type: "Portal",
|
|
pos: { x: 5 * tileSize, y: tileSize },
|
|
texture: "Door_n",
|
|
action: (_player, level) => {
|
|
level.switch = { module: __dirname + "/1-1.js", pos: 0 };
|
|
},
|
|
key: "1-1_1"
|
|
},
|
|
{
|
|
type: "Portal",
|
|
pos: { x: 24 * tileSize, y: tileSize },
|
|
texture: "Door_n",
|
|
action: (_player, level) => {
|
|
level.switch = { module: __dirname + "/1-4.js", pos: 0 };
|
|
},
|
|
key: "1-4"
|
|
},
|
|
{
|
|
type: "Portal",
|
|
pos: { x: 24 * tileSize, y: 5 * tileSize },
|
|
texture: "Door_s",
|
|
action: (_player, level) => {
|
|
level.switch = { module: __dirname + "/1-3.js", pos: 0 };
|
|
},
|
|
key: ""
|
|
},
|
|
{
|
|
type: "Sign",
|
|
pos: { x: 22 * tileSize, y: tileSize },
|
|
text: text.game.signs["1-2"]
|
|
},
|
|
{
|
|
type: "Rock",
|
|
pos: { x: 15 * tileSize, y: 2 * tileSize },
|
|
texture: "Big"
|
|
}
|
|
]
|
|
};
|
|
|
|
module.exports = level; |