Gas tanks and masks (#2409)

Co-authored-by: a.rudenko <creadth@gmail.com>
Co-authored-by: creadth <creadth@users.noreply.github.com>
Co-authored-by: DrSmugleaf <DrSmugleaf@users.noreply.github.com>
This commit is contained in:
Víctor Aguilera Puerto
2020-10-27 20:53:44 +01:00
committed by GitHub
parent 329926b175
commit 870d052354
77 changed files with 1653 additions and 58 deletions

View File

@@ -109,14 +109,16 @@ namespace Content.Server.Interfaces.GameObjects.Components.Items
/// </summary>
/// <param name="slot">The slot of which to drop to drop the item.</param>
/// <param name="mobChecks">Whether to check the <see cref="ActionBlockerSystem.CanDrop()"/> for the mob or not.</param>
/// <param name="doDropInteraction">Whether to perform Dropped interactions.</param>
/// <returns>True on success, false if something blocked the drop.</returns>
bool Drop(string slot, bool mobChecks = true);
bool Drop(string slot, bool mobChecks = true, bool doDropInteraction = true);
/// <summary>
/// Drops an item held by one of our hand slots to the same position as our owning entity.
/// </summary>
/// <param name="entity">The item to drop.</param>
/// <param name="mobChecks">Whether to check the <see cref="ActionBlockerSystem.CanDrop()"/> for the mob or not.</param>
/// <param name="doDropInteraction">Whether to perform Dropped interactions.</param>
/// <returns>True on success, false if something blocked the drop.</returns>
/// <exception cref="ArgumentNullException">
/// Thrown if <see cref="entity"/> is null.
@@ -124,7 +126,7 @@ namespace Content.Server.Interfaces.GameObjects.Components.Items
/// <exception cref="ArgumentException">
/// Thrown if <see cref="entity"/> is not actually held in any hand.
/// </exception>
bool Drop(IEntity entity, bool mobChecks = true);
bool Drop(IEntity entity, bool mobChecks = true, bool doDropInteraction = true);
/// <summary>
/// Drops the item in a slot.
@@ -132,8 +134,9 @@ namespace Content.Server.Interfaces.GameObjects.Components.Items
/// <param name="slot">The slot to drop the item from.</param>
/// <param name="coords"></param>
/// <param name="doMobChecks">Whether to check the <see cref="ActionBlockerSystem.CanDrop()"/> for the mob or not.</param>
/// <param name="doDropInteraction">Whether to perform Dropped interactions.</param>
/// <returns>True if an item was dropped, false otherwise.</returns>
bool Drop(string slot, EntityCoordinates coords, bool doMobChecks = true);
bool Drop(string slot, EntityCoordinates coords, bool doMobChecks = true, bool doDropInteraction = true);
/// <summary>
/// Drop the specified entity in our hands to a certain position.
@@ -145,6 +148,7 @@ namespace Content.Server.Interfaces.GameObjects.Components.Items
/// <param name="entity">The entity to drop, must be held in one of the hands.</param>
/// <param name="coords">The coordinates to drop the entity at.</param>
/// <param name="doMobChecks">Whether to check the <see cref="ActionBlockerSystem.CanDrop()"/> for the mob or not.</param>
/// <param name="doDropInteraction">Whether to perform Dropped interactions.</param>
/// <returns>
/// True if the drop succeeded,
/// false if it failed (due to failing to eject from our hand slot, etc...)
@@ -155,7 +159,7 @@ namespace Content.Server.Interfaces.GameObjects.Components.Items
/// <exception cref="ArgumentException">
/// Thrown if <see cref="entity"/> is not actually held in any hand.
/// </exception>
bool Drop(IEntity entity, EntityCoordinates coords, bool doMobChecks = true);
bool Drop(IEntity entity, EntityCoordinates coords, bool doMobChecks = true, bool doDropInteraction = true);
/// <summary>
/// Drop the item contained in a slot into another container.
@@ -163,13 +167,14 @@ namespace Content.Server.Interfaces.GameObjects.Components.Items
/// <param name="slot">The slot of which to drop the entity.</param>
/// <param name="targetContainer">The container to drop into.</param>
/// <param name="doMobChecks">Whether to check the <see cref="ActionBlockerSystem.CanDrop(IEntity)"/> for the mob or not.</param>
/// <param name="doDropInteraction">Whether to perform Dropped interactions.</param>
/// <returns>True on success, false if something was blocked (insertion or removal).</returns>
/// <exception cref="InvalidOperationException">
/// Thrown if dry-run checks reported OK to remove and insert,
/// but practical remove or insert returned false anyways.
/// This is an edge-case that is currently unhandled.
/// </exception>
bool Drop(string slot, BaseContainer targetContainer, bool doMobChecks = true);
bool Drop(string slot, BaseContainer targetContainer, bool doMobChecks = true, bool doDropInteraction = true);
/// <summary>
/// Drops an item in one of the hands into a container.
@@ -177,6 +182,7 @@ namespace Content.Server.Interfaces.GameObjects.Components.Items
/// <param name="entity">The item to drop.</param>
/// <param name="targetContainer">The container to drop into.</param>
/// <param name="doMobChecks">Whether to check the <see cref="ActionBlockerSystem.CanDrop()"/> for the mob or not.</param>
/// <param name="doDropInteraction">Whether to perform Dropped interactions.</param>
/// <returns>True on success, false if something was blocked (insertion or removal).</returns>
/// <exception cref="InvalidOperationException">
/// Thrown if dry-run checks reported OK to remove and insert,
@@ -189,7 +195,7 @@ namespace Content.Server.Interfaces.GameObjects.Components.Items
/// <exception cref="ArgumentException">
/// Thrown if <see cref="entity"/> is not actually held in any hand.
/// </exception>
bool Drop(IEntity entity, BaseContainer targetContainer, bool doMobChecks = true);
bool Drop(IEntity entity, BaseContainer targetContainer, bool doMobChecks = true, bool doDropInteraction = true);
/// <summary>
/// Checks whether the item in the specified hand can be dropped.