Compare commits
3 Commits
75797d968e
...
963257ad79
Author | SHA1 | Date | |
---|---|---|---|
963257ad79 | |||
a7fccfb19d | |||
44d4b88e01 |
Binary file not shown.
Before Width: | Height: | Size: 30 KiB After Width: | Height: | Size: 40 KiB |
13
js/Game.js
13
js/Game.js
@ -68,16 +68,17 @@ export class Game
|
|||||||
}
|
}
|
||||||
|
|
||||||
this.context.clearRect(0, 0, window.innerWidth, window.innerHeight);
|
this.context.clearRect(0, 0, window.innerWidth, window.innerHeight);
|
||||||
|
|
||||||
|
for (const effect of this.level.fullscreenEffects) {
|
||||||
|
effect.update(timestamp);
|
||||||
|
effect.render(this.context, this.camera);
|
||||||
|
}
|
||||||
|
|
||||||
this.architecture.draw(this.context, this.camera);
|
this.architecture.draw(this.context, this.camera);
|
||||||
this.gisela.draw(this.context, this.camera);
|
this.gisela.draw(this.context, this.camera);
|
||||||
this.mrCroc.draw(this.context, this.camera);
|
this.mrCroc.draw(this.context, this.camera);
|
||||||
|
|
||||||
for (const effect of this.level.fullscreenEffects) {
|
this.userInterface.draw(this.context);
|
||||||
effect.update(timestamp);
|
|
||||||
effect.render(this.context, this.camera);
|
|
||||||
}
|
|
||||||
|
|
||||||
this.userInterface.draw(this.context);
|
|
||||||
|
|
||||||
this.lastRendered = timestamp;
|
this.lastRendered = timestamp;
|
||||||
}
|
}
|
||||||
|
@ -83,7 +83,7 @@ const GraphicSet = [
|
|||||||
gravity: 9.806,
|
gravity: 9.806,
|
||||||
tilesetBackground: {
|
tilesetBackground: {
|
||||||
path: 'graveyard-background.png',
|
path: 'graveyard-background.png',
|
||||||
tiles: 5,
|
tiles: 9,
|
||||||
scale: 1,
|
scale: 1,
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
|
@ -317,7 +317,7 @@ export default class RetroArchitecture
|
|||||||
{
|
{
|
||||||
context.drawImage(
|
context.drawImage(
|
||||||
this.tilesetSpriteBackground.canvas,
|
this.tilesetSpriteBackground.canvas,
|
||||||
-(field.tile.index % 2) * this.tileWidth,
|
-((field.tile.index + 2) % this.tilesBackground) * this.tileWidth,
|
||||||
0,
|
0,
|
||||||
this.tileWidth,
|
this.tileWidth,
|
||||||
this.tileHeight,
|
this.tileHeight,
|
||||||
|
Loading…
x
Reference in New Issue
Block a user