fix: each damage gets a locally unique ID
This commit is contained in:
parent
3f8c9b6af3
commit
5501b172e0
|
@ -14,6 +14,7 @@ export class Vulnerable extends Trait {
|
|||
}
|
||||
|
||||
initialize() {
|
||||
this.damageId = 0;
|
||||
this.damageList = {};
|
||||
this.locks = new Map();
|
||||
if (hasGraphics) {
|
||||
|
@ -92,6 +93,7 @@ export class Vulnerable extends Trait {
|
|||
this.damageList[entity.instanceUuid] = [];
|
||||
}
|
||||
this.damageList[entity.instanceUuid].push({
|
||||
id: this.damageId++,
|
||||
isDamage,
|
||||
amount,
|
||||
damageSpec,
|
||||
|
|
Loading…
Reference in New Issue
Block a user