Skip to content

Commit

Permalink
fix player name rotation
Browse files Browse the repository at this point in the history
  • Loading branch information
embix committed Dec 22, 2024
1 parent e25bc34 commit 85391ef
Showing 1 changed file with 2 additions and 1 deletion.
3 changes: 2 additions & 1 deletion ts/RailroadMap.ts
Original file line number Diff line number Diff line change
Expand Up @@ -1116,9 +1116,10 @@ export class RailroadMap {
private renderPlayer(player: Player) {
if (!player.name) return;
if (!player.location) return;
const rotation = this.inverted ? 180 : 0;
return this.layers.players
.text(player.name)
.attr('transform', makeTransform(player.location.x, player.location.y, 180))
.attr('transform', makeTransform(player.location.x, player.location.y, rotation))
.addClass('player');
}

Expand Down

0 comments on commit 85391ef

Please sign in to comment.