diff --git a/js/levels/5.mjs b/js/levels/5.mjs index e080537..312cf14 100644 --- a/js/levels/5.mjs +++ b/js/levels/5.mjs @@ -26,7 +26,7 @@ create_level(5, { y: 600, } }, - next_level: 5, + next_level: 6, enemies: [ ...generate_oscillator(11, { pos: { diff --git a/js/levels/6.mjs b/js/levels/6.mjs new file mode 100644 index 0000000..fd003d9 --- /dev/null +++ b/js/levels/6.mjs @@ -0,0 +1,74 @@ +import { create_level } from "./core.mjs"; + +import bounding_walls from "./templates/bounding_walls.mjs"; + + + +create_level(6, { + player: { + pos: { + x: 20, + y: 570, + }, + size: { + x: 10, + y: 10, + }, + speed: 40, + }, + goal: { + pos: { + x: 700, + y: 300, + }, + }, + next_level: 6, + enemies: [ + ...bounding_walls(10), + + // wall with holes + { + pos: [50, 50], + size: [20, 50], + }, + { + pos: [50, 150], + size: [20, 100], + }, + { + pos: [50, 300], + size: [20, 50], + }, + { + pos: [50, 400], + size: [20, 100], + }, + { + pos: [50, 550], + size: [20, 100], + }, + // back segment + { + pos: [70, 50], + size: [20, 550], + }, + + // wall patroller + { + pos: [15, 295], + size: [30, 10], + behaviour: "path", + meta: [ + ["points", [ + [15, 10], + [15, 580], + ]], + ["speeds", [ + 1, + 1/4, + ]], + ["offset", 3/4], + ], + }, + ], +}); diff --git a/js/levels/main.mjs b/js/levels/main.mjs index 8adfc15..f1d7e57 100644 --- a/js/levels/main.mjs +++ b/js/levels/main.mjs @@ -3,6 +3,7 @@ import "./2.mjs"; import "./3.mjs"; import "./4.mjs"; import "./5.mjs"; +import "./6.mjs";