Skip to content

Commit

Permalink
chore: Adjust levels so top is closer to UI
Browse files Browse the repository at this point in the history
  • Loading branch information
joshuacurtiss committed Jun 5, 2024
1 parent 8a42b66 commit 08249bb
Show file tree
Hide file tree
Showing 3 changed files with 10 additions and 8 deletions.
8 changes: 4 additions & 4 deletions src/levels.json
Original file line number Diff line number Diff line change
Expand Up @@ -3,7 +3,6 @@
" ",
" ",
" ",
" ",
" __________________________ ",
" ⌈⌉ ⌈⌉ ⌈⌉ ⌈⌉ ⌈⌉ ⌈⌉ ",
" ⌈⌉ ⌈⌉ ⌈⌉ ⌈⌉ ⌈⌉ ⌈⌉ ",
Expand All @@ -26,7 +25,8 @@
" ",
" ",
" ",
" (⎽⎽⎽⎽)(⎽⎽⎽⎽)(⎽⎽⎽⎽)(⎽⎽⎽⎽) "
" (⎽⎽⎽⎽)(⎽⎽⎽⎽)(⎽⎽⎽⎽)(⎽⎽⎽⎽) ",
" "
],
[
" ",
Expand All @@ -40,7 +40,6 @@
" ",
" ",
" ",
" ",
" ________ ________ ",
" ⌈⌉ ⌈⌉ ⌈⌉ ",
" ⌈⌉ ⌈⌉ ______________ ⌈⌉ ",
Expand All @@ -55,6 +54,7 @@
" ",
" ",
" ",
" (⎽⎽⎽⎽)(⎽⎽⎽⎽)(⎽⎽⎽⎽)(⎽⎽⎽⎽) "
" (⎽⎽⎽⎽)(⎽⎽⎽⎽)(⎽⎽⎽⎽)(⎽⎽⎽⎽) ",
" "
]
]
2 changes: 1 addition & 1 deletion src/objects/Powerup.ts
Original file line number Diff line number Diff line change
Expand Up @@ -41,7 +41,7 @@ export interface PowerupCompOpt {
}

const PowerupCompOptDefaults: PowerupCompOpt = {
pos: vec2(128, 108),
pos: vec2(128, 100),
timeout: 20,
type: 0,
};
Expand Down
8 changes: 5 additions & 3 deletions src/scenes/GameScene.ts
Original file line number Diff line number Diff line change
Expand Up @@ -95,8 +95,10 @@ export default function(options: Partial<GameSceneOpt>) {
const music = play('music', { paused: true, loop: true, volume: 0.6 });

// UI Setup
const ui = add([fixed(), z(100)]);
const UI_FONT_SIZE = 10;
const ui = add([
fixed(),
]);
ui.add([
sprite('head-p'),
pos(184, 8),
Expand Down Expand Up @@ -169,7 +171,7 @@ export default function(options: Partial<GameSceneOpt>) {
waitSpawnPowerup();

// Enemy Setup
addEnemy({ type: 'hotdog', pos: vec2(160, 173) });
addEnemy({ type: 'hotdog', pos: vec2(224, 165) });

// Next Scene management (when player dies or wins)
function goNextScene(action: 'win' | 'die') {
Expand All @@ -191,7 +193,7 @@ export default function(options: Partial<GameSceneOpt>) {
// Player setup
opt.players.forEach(p=>p.pos = vec2(-20));
player.level = levelNumber;
player.pos = vec2(128, 173);
player.pos = vec2(128, 165);
player.setObjects({ floors, stairs, stairtops });
player.setAnim(vec2(0));
player.isAlive = true;
Expand Down

0 comments on commit 08249bb

Please sign in to comment.