This repository was archived by the owner on Dec 30, 2024. It is now read-only.
-
Notifications
You must be signed in to change notification settings - Fork 46
Blood Fillers #172
Draft
Pspritechologist
wants to merge
8
commits into
master
Choose a base branch
from
BloodFiller
base: master
Could not load branches
Branch not found: {{ refName }}
Loading
Could not load tags
Nothing to show
Loading
Are you sure you want to change the base?
Some commits from the old base branch may be removed from the timeline,
and old review comments may become outdated.
Draft
Blood Fillers #172
Changes from all commits
Commits
Show all changes
8 commits
Select commit
Hold shift + click to select a range
3d79084
Started work on what used to be a "SiliconFiller", but now is a tool …
Pspritechologist 7c849b2
Removed Silicon remnants
Pspritechologist 01c60dc
Big ol update to just about everything
Pspritechologist f2ed9fc
Simple Silicon stuff
Pspritechologist 99ac8d5
Merge branch 'master' of https://github.com/Park-Station/Parkstation …
Pspritechologist e070cc1
Review suggestions
Pspritechologist d6f27be
Allowed reagents is now a list
Pspritechologist f1b3725
blood filler cargo orders (#173)
SomeCabbage File filter
Filter by extension
Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
There are no files selected for viewing
167 changes: 167 additions & 0 deletions
167
Content.Server/SimpleStation14/BloodstreamFiller/Components/BloodstreamFillerComponent.cs
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
| Original file line number | Diff line number | Diff line change |
|---|---|---|
| @@ -0,0 +1,167 @@ | ||
| using Content.Shared.Damage; | ||
| using Content.Shared.Damage.Prototypes; | ||
| using Robust.Shared.Audio; | ||
|
|
||
| namespace Content.Server.SimpleStation14.BloodstreamFiller.Components; | ||
|
|
||
| [RegisterComponent] | ||
| public sealed class BloodstreamFillerComponent : Component | ||
| { | ||
| /// <summary> | ||
| /// The duration of the fill DoAfter, in seconds. | ||
| /// </summary> | ||
| [DataField("fillTime"), ViewVariables(VVAccess.ReadWrite)] | ||
| public float FillTime = 1.0f; | ||
|
|
||
| /// <summary> | ||
| /// The multiplier for the DoAfter time when attempting to fill yourself. | ||
| /// </summary> | ||
| [DataField("selfFillMutli"), ViewVariables(VVAccess.ReadWrite)] | ||
| public float SelfFillMutli = 3.5f; | ||
|
|
||
| /// <summary> | ||
| /// The name of the volume to refill. | ||
| /// </summary> | ||
| /// <remarks> | ||
| /// Should match the <see cref="SolutionContainerComponent"/> name or otherwise. | ||
| /// </remarks> | ||
| [DataField("solution"), ViewVariables(VVAccess.ReadWrite)] | ||
| public string Solution { get; } = "filler"; | ||
|
|
||
| /// <summary> | ||
| /// The amount of reagent that this bloodstream filler will fill with at most. | ||
| /// </summary> | ||
| [DataField("amount"), ViewVariables(VVAccess.ReadWrite)] | ||
| public float Amount = 100.0f; | ||
|
|
||
| /// <summary> | ||
| /// The regent allowed to be used by this filler. | ||
| /// </summary> | ||
| /// <remarks> | ||
| /// If null, any reagent will be allowed. | ||
| /// </remarks> | ||
| [DataField("reagents"), ViewVariables(VVAccess.ReadWrite)] | ||
| public List<string> Reagents = new(); | ||
|
|
||
| /// <summary> | ||
| /// Will this filler only fill Silicons? | ||
| /// </summary> | ||
| /// <remarks> | ||
| /// Somewhat niche use case, but Bloodstreams are very inflexible. | ||
| /// </remarks> | ||
| [DataField("siliconOnly"), ViewVariables(VVAccess.ReadWrite)] | ||
| public bool SiliconOnly = true; | ||
|
|
||
| /// <summary> | ||
| /// Can this bloodfiller be used to overfill someone? | ||
| /// </summary> | ||
| /// <remarks> | ||
| /// If true, the bloodfiller will be able to fill someone already at max blood, causing damage and spilling blood. | ||
| /// </remarks> | ||
| [DataField("overfill"), ViewVariables(VVAccess.ReadWrite)] | ||
| public bool Overfill = true; | ||
|
|
||
| /// <summary> | ||
| /// The multiplier for the DoAfter time when attempting to overfill someone. | ||
| /// </summary> | ||
| [DataField("overfillMulti"), ViewVariables(VVAccess.ReadWrite)] | ||
| public float OverfillMulti = 5.5f; | ||
|
|
||
| /// <summary> | ||
| /// The amount of damage dealt when overfilling someone. | ||
| /// </summary> | ||
| /// <remarks> | ||
| /// This must be specified in YAML. | ||
| /// </remarks> | ||
| [DataField("overfillDamage"), ViewVariables(VVAccess.ReadWrite)] | ||
| public DamageSpecifier OverfillDamage = default!; | ||
|
|
||
| #region Player Feedback | ||
| /// <summary> | ||
| /// The sound played when the filler is used. | ||
| /// </summary> | ||
| [DataField("useSound")] | ||
| public SoundSpecifier UseSound = new SoundPathSpecifier("/Audio/Effects/bang.ogg"); | ||
|
|
||
| /// <summary> | ||
| /// The sound played when the filler refills. | ||
| /// </summary> | ||
| [DataField("refillSound")] | ||
| public SoundSpecifier RefillSound = new SoundPathSpecifier("/Audio/Effects/buckle.ogg"); | ||
|
|
||
| /// <summary> | ||
| /// The sound played when overfilling someone. | ||
| /// </summary> | ||
| [DataField("overfillSound")] | ||
| public SoundSpecifier OverfillSound = new SoundPathSpecifier("/Audio/Effects/demon_dies.ogg"); | ||
|
|
||
| /// <summary> | ||
| /// The popup text when the filler is used. | ||
| /// </summary> | ||
| [DataField("usePopup")] | ||
| public string UsePopup = "bloodfiller-use-user"; | ||
|
|
||
| /// <summary> | ||
| /// The popup text when the filler is used on you. | ||
| /// </summary> | ||
| [DataField("usedOnPopup")] | ||
| public string UsedOnPopup = "bloodfiller-use-target"; | ||
|
|
||
| /// <summary> | ||
| /// The popup text when the bloodfiller is empty. | ||
| /// </summary> | ||
| [DataField("emptyPopup")] | ||
| public string EmptyPopup = "bloodfiller-use-empty"; | ||
|
|
||
| /// <summary> | ||
| /// The popup text when the bloodfiller can't be used on the target. | ||
| /// </summary> | ||
| /// <remarks> | ||
| /// Due to <see cref="SiliconOnly"/> or otherwise. | ||
| /// </remarks> | ||
| [DataField("targetInvalidPopup")] | ||
| public string TargetInvalidPopup = "bloodfiller-use-invalid-target"; | ||
|
|
||
| /// <summary> | ||
| /// The popup text when the bloodfiller doesn't have the target's blood. | ||
| /// </summary> | ||
| [DataField("targetBloodInvalidPopup")] | ||
| public string TargetBloodInvalidPopup = "bloodfiller-use-invalid-blood"; | ||
|
|
||
| /// <summary> | ||
| /// The popup text when the filler is already full. | ||
| /// </summary> | ||
| [DataField("refillFullPopup")] | ||
| public string RefillFullPopup = "bloodfiller-refill-filler-full"; | ||
|
|
||
| /// <summary> | ||
| /// The popup text when the tank is empty. | ||
| /// </summary> | ||
| [DataField("refillTankEmptyPopup")] | ||
| public string RefillTankEmptyPopup = "bloodfiller-refill-tank-empty"; | ||
|
|
||
| /// <summary> | ||
| /// The popup text when trying to refill the bloodfiller from a tank with the wrong reagent. | ||
| /// </summary> | ||
| [DataField("refillReagentInvalidPopup")] | ||
| public string RefillReagentInvalidPopup = "bloodfiller-refill-reagent-invalid"; | ||
|
|
||
| /// <summary> | ||
| /// The popup text when either a tank or filler contains a dirty mixture. | ||
| /// </summary> | ||
| [DataField("dirtyPopup")] | ||
| public string DirtyPopup = "bloodfiller-reagent-dirty"; | ||
|
|
||
| /// <summary> | ||
| /// The popup text when trying to overfill someone. | ||
| /// </summary> | ||
| [DataField("targetOverfillPopup")] | ||
| public string TargetOverfillPopup = "bloodfiller-user-overfill"; | ||
|
|
||
| /// <summary> | ||
| /// The popup text when getting overfilled. | ||
| /// </summary> | ||
| [DataField("overfilledPopup")] | ||
| public string OverfilledPopup = "bloodfiller-target-overfill"; | ||
| #endregion Player Feedback | ||
| } | ||
Oops, something went wrong.
Add this suggestion to a batch that can be applied as a single commit.
This suggestion is invalid because no changes were made to the code.
Suggestions cannot be applied while the pull request is closed.
Suggestions cannot be applied while viewing a subset of changes.
Only one suggestion per line can be applied in a batch.
Add this suggestion to a batch that can be applied as a single commit.
Applying suggestions on deleted lines is not supported.
You must change the existing code in this line in order to create a valid suggestion.
Outdated suggestions cannot be applied.
This suggestion has been applied or marked resolved.
Suggestions cannot be applied from pending reviews.
Suggestions cannot be applied on multi-line comments.
Suggestions cannot be applied while the pull request is queued to merge.
Suggestion cannot be applied right now. Please check back later.
Uh oh!
There was an error while loading. Please reload this page.