mirror of
https://github.com/OpenLiberty/liberty-bikes.git
synced 2025-01-18 10:23:58 +08:00
Put glow effect around player trails
This commit is contained in:
parent
3862357b4e
commit
90a2c1cd42
@ -145,6 +145,8 @@ export class GameComponent implements OnInit, OnDestroy {
|
||||
playersMoved = true;
|
||||
|
||||
// Stamp down player on trails canvas so it can be erased properly when obstacles roll over it
|
||||
this.trailsContext.shadowBlur = 20;
|
||||
this.trailsContext.shadowColor = player.color;
|
||||
this.trailsContext.fillStyle = player.color;
|
||||
this.trailsContext.fillRect(Constants.BOX_SIZE * player.x + player.width / 2 * Constants.BOX_SIZE - Constants.BOX_SIZE / 2,
|
||||
Constants.BOX_SIZE * player.y + player.height / 2 * Constants.BOX_SIZE - Constants.BOX_SIZE / 2,
|
||||
|
Loading…
Reference in New Issue
Block a user