Updates ComponentHandleState usages to be by-ref (#4535)

This commit is contained in:
Vera Aguilera Puerto
2021-08-30 11:33:48 +02:00
committed by GitHub
parent 9cf37b6e68
commit f15ed2ba50
5 changed files with 5 additions and 5 deletions

View File

@@ -24,7 +24,7 @@ namespace Content.Shared.Chemistry
SubscribeLocalEvent<MovespeedModifierMetabolismComponent, ComponentStartup>(AddComponent);
}
private void OnMovespeedHandleState(EntityUid uid, MovespeedModifierMetabolismComponent component, ComponentHandleState args)
private void OnMovespeedHandleState(EntityUid uid, MovespeedModifierMetabolismComponent component, ref ComponentHandleState args)
{
if (args.Current is not MovespeedModifierMetabolismComponentState cast)
return;

View File

@@ -56,7 +56,7 @@ namespace Content.Shared.Placeable
args.Handled = true;
}
private void OnHandleState(EntityUid uid, PlaceableSurfaceComponent component, ComponentHandleState args)
private void OnHandleState(EntityUid uid, PlaceableSurfaceComponent component, ref ComponentHandleState args)
{
if (args.Current is not PlaceableSurfaceComponentState state)
return;

View File

@@ -62,7 +62,7 @@ namespace Content.Shared.Stacks
RaiseLocalEvent(uid, new StackCountChangedEvent(old, component.Count));
}
private void OnStackHandleState(EntityUid uid, SharedStackComponent component, ComponentHandleState args)
private void OnStackHandleState(EntityUid uid, SharedStackComponent component, ref ComponentHandleState args)
{
if (args.Current is not StackComponentState cast)
return;

View File

@@ -89,7 +89,7 @@ namespace Content.Shared.SubFloor
UpdateEntity(uid);
}
private void HandleComponentState(EntityUid uid, SubFloorHideComponent component, ComponentHandleState args)
private void HandleComponentState(EntityUid uid, SubFloorHideComponent component, ref ComponentHandleState args)
{
if (args.Current is not SubFloorHideComponentState state)
return;