fix: do actually send a removal step for removed (not just obscured) entities
This commit is contained in:
parent
7c253fa13f
commit
f3bc4b8ecb
|
@ -140,9 +140,14 @@ export class Informed extends decorate(Trait) {
|
|||
const parts = removal.get('parts');
|
||||
const layerId = parts[3];
|
||||
const uuid = parts[5];
|
||||
this._rememberedEntities[uuid] = state.getIn(
|
||||
const remembered = state.getIn(
|
||||
['room', 'layers', layerId, 'entityList', uuid]
|
||||
);
|
||||
// Actually destroyed?
|
||||
if (!remembered) {
|
||||
return;
|
||||
}
|
||||
this._rememberedEntities[uuid] = remembered;
|
||||
// Add overrides.
|
||||
const overrides = this.entityOverrides(
|
||||
removal.get('path'),
|
||||
|
@ -155,7 +160,12 @@ export class Informed extends decorate(Trait) {
|
|||
});
|
||||
// Remove all removes.
|
||||
return steps.filter((step) => {
|
||||
return !isRemove(step);
|
||||
if (!isRemove(step)) {
|
||||
return true;
|
||||
}
|
||||
const parts = step.get('parts');
|
||||
const uuid = parts[5];
|
||||
return !(uuid in this._rememberedEntities);
|
||||
});
|
||||
}
|
||||
|
||||
|
|
Loading…
Reference in New Issue
Block a user