-
Notifications
You must be signed in to change notification settings - Fork 101
Commit
This commit does not belong to any branch on this repository, and may belong to a fork outside of the repository.
- Loading branch information
1 parent
8f6aa7b
commit 9a1d536
Showing
47 changed files
with
544 additions
and
0 deletions.
There are no files selected for viewing
47 changes: 47 additions & 0 deletions
47
Content.Server/InteractionVerbs/Actions/ToggleLayersAction.cs
This file contains 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,47 @@ | ||
using Content.Server.Humanoid; | ||
using Content.Shared.Humanoid; | ||
using Content.Shared.Humanoid.Markings; | ||
using Content.Shared.InteractionVerbs; | ||
|
||
namespace Content.Server.InteractionVerbs.Actions; | ||
|
||
/// <summary> | ||
/// Toggles a humanoid visual layer. | ||
/// </summary> | ||
[Serializable] | ||
public sealed partial class ToggleLayersAction : InteractionAction | ||
{ | ||
[DataField] | ||
public HumanoidVisualLayers? NeededMarkingCategory; | ||
|
||
[DataField] | ||
public HashSet<HumanoidVisualLayers> ToggleLayers; | ||
|
||
public override bool CanPerform(InteractionArgs args, InteractionVerbPrototype proto, bool isBefore, VerbDependencies deps) | ||
{ | ||
if (NeededMarkingCategory == null) | ||
return true; | ||
|
||
var markingCategory = MarkingCategoriesConversion.FromHumanoidVisualLayers(NeededMarkingCategory.Value); | ||
|
||
return deps.EntMan.TryGetComponent(args.Target, out HumanoidAppearanceComponent? bodyAppearance) | ||
&& bodyAppearance.MarkingSet.Markings.TryGetValue(markingCategory, out var markingList) | ||
&& markingList.Count > 0; // Check if at least one entry exists | ||
} | ||
|
||
public override bool Perform(InteractionArgs args, InteractionVerbPrototype proto, VerbDependencies deps) | ||
{ | ||
if (deps.EntMan.TryGetComponent<HumanoidAppearanceComponent>(args.Target, out var humanoidAppearance)) | ||
{ | ||
foreach (HumanoidVisualLayers layer in ToggleLayers) | ||
{ | ||
deps.EntMan.System<HumanoidAppearanceSystem>().SetLayerVisibility( | ||
args.Target, | ||
layer, humanoidAppearance.HiddenLayers.Contains(layer) | ||
); | ||
} | ||
} | ||
|
||
return true; | ||
} | ||
} |
This file contains 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
This file contains 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
This file contains 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
This file contains 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
This file contains 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
This file contains 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,19 @@ | ||
interaction-ToggleUndershirt-name = Toggle undershirt | ||
interaction-ToggleUndershirt-description = Toggle the undershirt of this person! | ||
interaction-ToggleUndershirt-success-self-popup = You toggle {THE($target)}'s undershirt. | ||
interaction-ToggleUndershirt-success-target-popup = {THE($user)} toggles your undershirt! | ||
interaction-ToggleUndershirt-fail-self-popup = You fail to toggle the undershirt. | ||
interaction-ToggleUndershirt-delayed-self-popup = You try to toggle {THE($target)}'s undershirt. | ||
interaction-ToggleUndershirt-delayed-target-popup = {THE($user)} is trying to toggle your undershirt! | ||
interaction-ToggleUnderwear-name = Toggle underwear | ||
interaction-ToggleUnderwear-description = Toggle the underwear of this person! | ||
interaction-ToggleUnderwear-success-self-popup = You toggle {THE($target)}'s underwear. | ||
interaction-ToggleUnderwear-success-target-popup = {THE($user)} toggles your underwear! | ||
interaction-ToggleUnderwear-fail-self-popup = You fail to toggle the underwear. | ||
interaction-ToggleUnderwear-delayed-self-popup = You try to toggle {THE($target)}'s underwear. | ||
interaction-ToggleUnderwear-delayed-target-popup = {THE($user)} is trying to toggle your underwear! |
This file contains 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,41 @@ | ||
markings-category-Undershirt = Undershirt | ||
markings-category-Underwear = Underwear | ||
marking-UndershirtStandard = Undershirt (Standard) | ||
marking-UndershirtStandard-t_undershirt = Undershirt | ||
marking-UndershirtSleeveless = Undershirt (Sleeveless) | ||
marking-UndershirtSleeveless-t_undershirt_sleeveless = Undershirt | ||
marking-UndershirtRolled = Undershirt (Rolled) | ||
marking-UndershirtRolled-t_rolled_undershirt = Undershirt | ||
marking-UndershirtRolledSleeveless = Undershirt (Sleeveless Rolled) | ||
marking-UndershirtRolledSleeveless-t_rolled_undershirt_sleeveless = Undershirt | ||
marking-UndershirtLong = Undershirt (Long) | ||
marking-UndershirtLong-t_long_undershirt = Undershirt | ||
marking-UndershirtClassic = Bra (Classic) | ||
marking-UndershirtClassic-snow_classic = Bra | ||
marking-UndershirtSports = Bra (Sport) | ||
marking-UndershirtSports-snow_sports = Bra | ||
marking-UndershirtStrapless = Bra (Strapless) | ||
marking-UndershirtStrapless-snow_strapless = Bra | ||
marking-UnderwearBoxers = Boxers | ||
marking-UnderwearBoxers-snow_boxers = Boxers | ||
marking-UnderwearBriefs = Briefs | ||
marking-UnderwearBriefs-snow_briefs = Briefs | ||
marking-UnderwearLowriders = Lowrides | ||
marking-UnderwearLowriders-snow_lowriders = Lowrides | ||
marking-UnderwearSatin = Satin | ||
marking-UnderwearSatin-snow_satin = Satin | ||
marking-UnderwearTanga = Tanga | ||
marking-UnderwearTanga-snow_tanga = Tanga |
This file contains 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
This file contains 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
This file contains 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
This file contains 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
111 changes: 111 additions & 0 deletions
111
Resources/Prototypes/Entities/Mobs/Customization/Markings/undershirt.yml
This file contains 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,111 @@ | ||
- type: marking | ||
id: UndershirtStandard | ||
bodyPart: Undershirt | ||
markingCategory: Undershirt | ||
speciesRestriction: [Shadowkin, Diona, Arachnid, Reptilian, Moth, SlimePerson, Resomi, Rodentia, Human, Rodentia, Felinid, Oni, Vulpkanin, Harpy] | ||
coloring: | ||
default: | ||
type: | ||
!type:SimpleColoring | ||
color: "#FFFFFF" | ||
sprites: | ||
- sprite: Floof/Mobs/Customization/undershirt.rsi | ||
state: t_undershirt | ||
|
||
- type: marking | ||
id: UndershirtSleeveless | ||
bodyPart: Undershirt | ||
markingCategory: Undershirt | ||
speciesRestriction: [Shadowkin, Diona, Arachnid, Reptilian, Moth, SlimePerson, Resomi, Rodentia, Human, Rodentia, Felinid, Oni, Vulpkanin, Harpy] | ||
coloring: | ||
default: | ||
type: | ||
!type:SimpleColoring | ||
color: "#FFFFFF" | ||
sprites: | ||
- sprite: Floof/Mobs/Customization/undershirt.rsi | ||
state: t_undershirt_sleeveless | ||
|
||
- type: marking | ||
id: UndershirtRolled | ||
bodyPart: Undershirt | ||
markingCategory: Undershirt | ||
speciesRestriction: [Shadowkin, Diona, Arachnid, Reptilian, Moth, SlimePerson, Resomi, Rodentia, Human, Rodentia, Felinid, Oni, Vulpkanin, Harpy] | ||
coloring: | ||
default: | ||
type: | ||
!type:SimpleColoring | ||
color: "#FFFFFF" | ||
sprites: | ||
- sprite: Floof/Mobs/Customization/undershirt.rsi | ||
state: t_rolled_undershirt | ||
|
||
- type: marking | ||
id: UndershirtRolledSleeveless | ||
bodyPart: Undershirt | ||
markingCategory: Undershirt | ||
speciesRestriction: [Shadowkin, Diona, Arachnid, Reptilian, Moth, SlimePerson, Resomi, Rodentia, Human, Rodentia, Felinid, Oni, Vulpkanin, Harpy] | ||
coloring: | ||
default: | ||
type: | ||
!type:SimpleColoring | ||
color: "#FFFFFF" | ||
sprites: | ||
- sprite: Floof/Mobs/Customization/undershirt.rsi | ||
state: t_rolled_undershirt_sleeveless | ||
|
||
- type: marking | ||
id: UndershirtLong | ||
bodyPart: Undershirt | ||
markingCategory: Undershirt | ||
speciesRestriction: [Shadowkin, Diona, Arachnid, Reptilian, Moth, SlimePerson, Resomi, Rodentia, Human, Rodentia, Felinid, Oni, Vulpkanin, Harpy] | ||
coloring: | ||
default: | ||
type: | ||
!type:SimpleColoring | ||
color: "#FFFFFF" | ||
sprites: | ||
- sprite: Floof/Mobs/Customization/undershirt.rsi | ||
state: t_long_undershirt | ||
|
||
- type: marking | ||
id: UndershirtClassic | ||
bodyPart: Undershirt | ||
markingCategory: Undershirt | ||
speciesRestriction: [Shadowkin, Diona, Arachnid, Reptilian, Moth, SlimePerson, Resomi, Rodentia, Human, Rodentia, Felinid, Oni, Vulpkanin, Harpy] | ||
coloring: | ||
default: | ||
type: | ||
!type:SimpleColoring | ||
color: "#FFFFFF" | ||
sprites: | ||
- sprite: Floof/Mobs/Customization/undershirt.rsi | ||
state: snow_bra | ||
|
||
- type: marking | ||
id: UndershirtSports | ||
bodyPart: Undershirt | ||
markingCategory: Undershirt | ||
speciesRestriction: [Shadowkin, Diona, Arachnid, Reptilian, Moth, SlimePerson, Resomi, Rodentia, Human, Rodentia, Felinid, Oni, Vulpkanin, Harpy] | ||
coloring: | ||
default: | ||
type: | ||
!type:SimpleColoring | ||
color: "#FFFFFF" | ||
sprites: | ||
- sprite: Floof/Mobs/Customization/undershirt.rsi | ||
state: snow_sports | ||
|
||
- type: marking | ||
id: UndershirtStrapless | ||
bodyPart: Undershirt | ||
markingCategory: Undershirt | ||
speciesRestriction: [Shadowkin, Diona, Arachnid, Reptilian, Moth, SlimePerson, Resomi, Rodentia, Human, Rodentia, Felinid, Oni, Vulpkanin, Harpy] | ||
coloring: | ||
default: | ||
type: | ||
!type:SimpleColoring | ||
color: "#FFFFFF" | ||
sprites: | ||
- sprite: Floof/Mobs/Customization/undershirt.rsi | ||
state: snow_strapless |
Oops, something went wrong.