mirror of
https://github.com/space-wizards/RobustToolbox.git
synced 2026-02-15 03:30:53 +01:00
FlushEntity() and EntityManager event changes (#4791)
This commit is contained in:
@@ -46,9 +46,9 @@ public sealed class PvsOverrideSystem : EntitySystem
|
||||
_player.PlayerStatusChanged -= OnPlayerStatusChanged;
|
||||
}
|
||||
|
||||
private void OnDeleted(EntityUid uid, MetaDataComponent meta)
|
||||
private void OnDeleted(Entity<MetaDataComponent> entity)
|
||||
{
|
||||
Clear(uid);
|
||||
Clear(entity);
|
||||
}
|
||||
|
||||
private void Clear(EntityUid uid)
|
||||
|
||||
@@ -40,14 +40,14 @@ namespace Robust.Server.GameStates
|
||||
EntityManager.EntityDirtied -= OnEntityDirty;
|
||||
}
|
||||
|
||||
private void OnEntityAdd(EntityUid e)
|
||||
private void OnEntityAdd(Entity<MetaDataComponent> e)
|
||||
{
|
||||
DebugTools.Assert(_currentIndex == _gameTiming.CurTick.Value % DirtyBufferSize ||
|
||||
_gameTiming.GetType().Name == "IGameTimingProxy");// Look I have NFI how best to excuse this assert if the game timing isn't real (a Mock<IGameTiming>).
|
||||
_addEntities[_currentIndex].Add(e);
|
||||
}
|
||||
|
||||
private void OnEntityDirty(EntityUid uid)
|
||||
private void OnEntityDirty(Entity<MetaDataComponent> uid)
|
||||
{
|
||||
if (!_addEntities[_currentIndex].Contains(uid))
|
||||
_dirtyEntities[_currentIndex].Add(uid);
|
||||
|
||||
Reference in New Issue
Block a user