Merge branch 'master-upstream' into expl_int_analyzer

# Conflicts:
#	Content.Server/GameObjects/Components/Body/Part/BodyPartComponent.cs
#	Content.Server/GameObjects/Components/Botany/PlantHolderComponent.cs
#	Content.Server/GameObjects/Components/Chemistry/PillComponent.cs
#	Content.Server/GameObjects/Components/Interactable/TilePryingComponent.cs
#	Content.Server/GameObjects/Components/Items/FloorTileItemComponent.cs
#	Content.Server/GameObjects/Components/Items/RCD/RCDAmmoComponent.cs
#	Content.Server/GameObjects/Components/Items/RCD/RCDComponent.cs
#	Content.Server/GameObjects/Components/Medical/HealingComponent.cs
#	Content.Server/GameObjects/Components/Power/WirePlacerComponent.cs
#	Content.Shared/Chemistry/Solution.cs
This commit is contained in:
Paul
2021-02-04 17:50:28 +01:00
499 changed files with 6357 additions and 8689 deletions

View File

@@ -100,34 +100,34 @@ namespace Content.Server.GameObjects.Components.Fluids
serializer.DataField(ref _safety, "safety", true);
}
async Task IAfterInteract.AfterInteract(AfterInteractEventArgs eventArgs)
async Task<bool> IAfterInteract.AfterInteract(AfterInteractEventArgs eventArgs)
{
if (!ActionBlockerSystem.CanInteract(eventArgs.User))
return;
return false;
if (_hasSafety && _safety)
{
Owner.PopupMessage(eventArgs.User, Loc.GetString("Its safety is on!"));
return;
return true;
}
if (CurrentVolume <= 0)
{
Owner.PopupMessage(eventArgs.User, Loc.GetString("It's empty!"));
return;
return true;
}
var curTime = _gameTiming.CurTime;
if(curTime < _cooldownEnd)
return;
return true;
var playerPos = eventArgs.User.Transform.Coordinates;
if (eventArgs.ClickLocation.GetGridId(_serverEntityManager) != playerPos.GetGridId(_serverEntityManager))
return;
return true;
if (!Owner.TryGetComponent(out SolutionContainerComponent contents))
return;
return true;
var direction = (eventArgs.ClickLocation.Position - playerPos.Position).Normalized;
var threeQuarters = direction * 0.75f;
@@ -183,6 +183,8 @@ namespace Content.Server.GameObjects.Components.Fluids
cooldown.CooldownStart = _lastUseTime;
cooldown.CooldownEnd = _cooldownEnd;
}
return true;
}
bool IUse.UseEntity(UseEntityEventArgs eventArgs)