Skip to content

Commit

Permalink
feat: custom animateId (#206)
Browse files Browse the repository at this point in the history
  • Loading branch information
alexander-welshtein authored Feb 26, 2024
1 parent 9b25438 commit 2673a06
Showing 1 changed file with 1 addition and 1 deletion.
2 changes: 1 addition & 1 deletion src/Space.ts
Original file line number Diff line number Diff line change
Expand Up @@ -67,7 +67,7 @@ export abstract class Space {
let player:IPlayer = (typeof p == "function") ? { animate: p } : p;

let k = this.playerCount++;
let pid = this.id + k;
let pid = player.animateID || (this.id + k);

this.players[pid] = player;
player.animateID = pid;
Expand Down

0 comments on commit 2673a06

Please sign in to comment.