Remove redundant IComponent casts

This commit is contained in:
metalgearsloth
2021-12-07 21:54:00 +11:00
parent 8d4799e611
commit 373b5988d7
29 changed files with 53 additions and 53 deletions

View File

@@ -37,11 +37,11 @@ namespace Content.Shared.Body.Components
{
if (old.Body == null)
{
IoCManager.Resolve<IEntityManager>().EventBus.RaiseLocalEvent(((IComponent) this).Owner, new RemovedFromPartEvent(old));
IoCManager.Resolve<IEntityManager>().EventBus.RaiseLocalEvent(Owner, new RemovedFromPartEvent(old));
}
else
{
IoCManager.Resolve<IEntityManager>().EventBus.RaiseLocalEvent(((IComponent) this).Owner, new RemovedFromPartInBodyEvent(old.Body, old));
IoCManager.Resolve<IEntityManager>().EventBus.RaiseLocalEvent(Owner, new RemovedFromPartInBodyEvent(old.Body, old));
}
}
@@ -49,11 +49,11 @@ namespace Content.Shared.Body.Components
{
if (value.Body == null)
{
IoCManager.Resolve<IEntityManager>().EventBus.RaiseLocalEvent(((IComponent) this).Owner, new AddedToPartEvent(value));
IoCManager.Resolve<IEntityManager>().EventBus.RaiseLocalEvent(Owner, new AddedToPartEvent(value));
}
else
{
IoCManager.Resolve<IEntityManager>().EventBus.RaiseLocalEvent(((IComponent) this).Owner, new AddedToPartInBodyEvent(value.Body, value));
IoCManager.Resolve<IEntityManager>().EventBus.RaiseLocalEvent(Owner, new AddedToPartInBodyEvent(value.Body, value));
}
}
}