mirror of
https://gitlab.com/lecarore/breakout71.git
synced 2025-05-05 03:07:14 -04:00
wip
This commit is contained in:
parent
cee5c6bc60
commit
45f9b516fc
23 changed files with 1069 additions and 797 deletions
|
@ -368,11 +368,11 @@ export function render(gameState: GameState) {
|
|||
});
|
||||
//
|
||||
startWork("render:extra_life");
|
||||
if (gameState.extra_lives) {
|
||||
if (gameState.perks.extra_life) {
|
||||
ctx.globalAlpha = gameState.balls.length > 1 ? 0.2 : 1;
|
||||
ctx.globalCompositeOperation = "source-over";
|
||||
ctx.fillStyle = gameState.puckColor;
|
||||
for (let i = 0; i < gameState.extra_lives; i++) {
|
||||
for (let i = 0; i < gameState.perks.extra_life; i++) {
|
||||
ctx.fillRect(
|
||||
gameState.offsetXRoundedDown,
|
||||
gameState.gameZoneHeight - gameState.puckHeight / 2 + 2 * i,
|
||||
|
|
Loading…
Add table
Add a link
Reference in a new issue