-
Notifications
You must be signed in to change notification settings - Fork 146
New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
Tail Covers! #427
Tail Covers! #427
Changes from all commits
File filter
Filter by extension
Conversations
Jump to
Diff view
Diff view
There are no files selected for viewing
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,17 @@ | ||
using Robust.Shared.Serialization; | ||
|
||
namespace Content.Shared.Clothing.Components | ||
{ | ||
[Serializable, NetSerializable] | ||
public enum TailVisuals | ||
{ | ||
Tailcover, | ||
} | ||
|
||
[Serializable, NetSerializable] | ||
public enum TailcoverVisuals | ||
{ | ||
True, | ||
False, | ||
} | ||
} |
Original file line number | Diff line number | Diff line change | ||||
---|---|---|---|---|---|---|
|
@@ -19,13 +19,17 @@ public abstract class ClothingSystem : EntitySystem | |||||
[Dependency] private readonly TagSystem _tagSystem = default!; | ||||||
[Dependency] private readonly InventorySystem _invSystem = default!; | ||||||
[Dependency] private readonly SharedHandsSystem _handsSystem = default!; | ||||||
[Dependency] private readonly SharedAppearanceSystem _appearance = default!; | ||||||
|
||||||
[ValidatePrototypeId<TagPrototype>] | ||||||
private const string HairTag = "HidesHair"; | ||||||
|
||||||
[ValidatePrototypeId<TagPrototype>] | ||||||
private const string NoseTag = "HidesNose"; | ||||||
|
||||||
[ValidatePrototypeId<TagPrototype>] | ||||||
private const string TailTag = "HidesTail"; | ||||||
|
||||||
public override void Initialize() | ||||||
{ | ||||||
base.Initialize(); | ||||||
|
@@ -136,6 +140,12 @@ protected virtual void OnGotEquipped(EntityUid uid, ClothingComponent component, | |||||
ToggleVisualLayer(args.Equipee, HumanoidVisualLayers.Hair, HairTag); | ||||||
if ((new string[] { "mask", "head" }).Contains(args.Slot) && _tagSystem.HasTag(args.Equipment, NoseTag)) | ||||||
ToggleVisualLayer(args.Equipee, HumanoidVisualLayers.Snout, NoseTag); | ||||||
if ((new string[] { "outerClothing" }).Contains(args.Slot) && _tagSystem.HasTag(args.Equipee, TailTag) && _tagSystem.HasTag(args.Equipment, TailTag)) | ||||||
There was a problem hiding this comment. Choose a reason for hiding this commentThe reason will be displayed to describe this comment to others. Learn more.
Suggested change
|
||||||
{ | ||||||
_humanoidSystem.SetLayerVisibility(args.Equipee, HumanoidVisualLayers.Tail, false); | ||||||
TryComp(args.Equipee, out AppearanceComponent? appearance); | ||||||
_appearance.SetData(args.Equipee, TailVisuals.Tailcover, TailcoverVisuals.True, appearance); | ||||||
} | ||||||
} | ||||||
|
||||||
protected virtual void OnGotUnequipped(EntityUid uid, ClothingComponent component, GotUnequippedEvent args) | ||||||
|
@@ -145,6 +155,12 @@ protected virtual void OnGotUnequipped(EntityUid uid, ClothingComponent componen | |||||
ToggleVisualLayer(args.Equipee, HumanoidVisualLayers.Hair, HairTag); | ||||||
if ((new string[] { "mask", "head" }).Contains(args.Slot) && _tagSystem.HasTag(args.Equipment, NoseTag)) | ||||||
ToggleVisualLayer(args.Equipee, HumanoidVisualLayers.Snout, NoseTag); | ||||||
if ((new string[] { "outerClothing" }).Contains(args.Slot) && _tagSystem.HasTag(args.Equipee, TailTag) && _tagSystem.HasTag(args.Equipment, TailTag)) | ||||||
There was a problem hiding this comment. Choose a reason for hiding this commentThe reason will be displayed to describe this comment to others. Learn more.
Suggested change
|
||||||
{ | ||||||
_humanoidSystem.SetLayerVisibility(args.Equipee, HumanoidVisualLayers.Tail, true); | ||||||
TryComp(args.Equipee, out AppearanceComponent? appearance); | ||||||
_appearance.SetData(args.Equipee, TailVisuals.Tailcover, TailcoverVisuals.False, appearance); | ||||||
} | ||||||
There was a problem hiding this comment. Choose a reason for hiding this commentThe reason will be displayed to describe this comment to others. Learn more. I'm definitely not going to ask this of you, but seeing incredibly cursed visualizer code get extended even further, makes me realize I should probably revisit this later and expand that aforementioned component into one that lets you arbitrarily declare layers to be hidden when equipping clothing with a specific condition. Harpies want to hide their tail, everyone wants to hide their hair, harpies need to hide their wings, and their tail, and their ear tufts, it's all something I could finangle into a single check. |
||||||
} | ||||||
|
||||||
private void OnGetState(EntityUid uid, ClothingComponent component, ref ComponentGetState args) | ||||||
|
Original file line number | Diff line number | Diff line change | ||||||||||||||
---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|
|
@@ -76,6 +76,16 @@ | |||||||||||||||
sprite: "DeltaV/Effects/creampie.rsi" | ||||||||||||||||
state: "creampie_vulpkanin" | ||||||||||||||||
visible: false | ||||||||||||||||
- map: [ "tailcover" ] | ||||||||||||||||
sprite: "Clothing/tailcover.rsi" | ||||||||||||||||
state: "tailcover-vulpkanin" | ||||||||||||||||
visible: false | ||||||||||||||||
- type: GenericVisualizer | ||||||||||||||||
visuals: | ||||||||||||||||
enum.TailVisuals.Tailcover: | ||||||||||||||||
tailcover: | ||||||||||||||||
True: {visible: true} | ||||||||||||||||
False: {visible: false} | ||||||||||||||||
- type: MeleeWeapon | ||||||||||||||||
hidden: true | ||||||||||||||||
soundHit: | ||||||||||||||||
|
@@ -97,6 +107,12 @@ | |||||||||||||||
Female: FemaleVulpkanin | ||||||||||||||||
Unsexed: MaleVulpkanin | ||||||||||||||||
- type: DogVision | ||||||||||||||||
- type: Tag | ||||||||||||||||
tags: | ||||||||||||||||
- CanPilot | ||||||||||||||||
- FootstepSound | ||||||||||||||||
- DoorBumpOpener | ||||||||||||||||
- HidesTail | ||||||||||||||||
Comment on lines
+110
to
+115
There was a problem hiding this comment. Choose a reason for hiding this commentThe reason will be displayed to describe this comment to others. Learn more.
Suggested change
|
||||||||||||||||
- type: LanguageKnowledge | ||||||||||||||||
speaks: | ||||||||||||||||
- GalacticCommon | ||||||||||||||||
|
Original file line number | Diff line number | Diff line change | ||||||||||||||
---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|
|
@@ -5,6 +5,68 @@ | |||||||||||||||
id: BaseMobReptilian | ||||||||||||||||
abstract: true | ||||||||||||||||
components: | ||||||||||||||||
- type: Sprite | ||||||||||||||||
layers: | ||||||||||||||||
- map: [ "enum.HumanoidVisualLayers.Chest" ] | ||||||||||||||||
- map: [ "enum.HumanoidVisualLayers.Head" ] | ||||||||||||||||
- map: [ "enum.HumanoidVisualLayers.Snout" ] | ||||||||||||||||
- map: [ "enum.HumanoidVisualLayers.Eyes" ] | ||||||||||||||||
- map: [ "enum.HumanoidVisualLayers.RArm" ] | ||||||||||||||||
- map: [ "enum.HumanoidVisualLayers.LArm" ] | ||||||||||||||||
- map: [ "enum.HumanoidVisualLayers.RLeg" ] | ||||||||||||||||
- map: [ "enum.HumanoidVisualLayers.LLeg" ] | ||||||||||||||||
- shader: StencilClear | ||||||||||||||||
sprite: Mobs/Species/Human/parts.rsi #PJB on stencil clear being on the left leg: "...this is 'fine'" -https://github.com/space-wizards/space-station-14/pull/12217#issuecomment-1291677115 | ||||||||||||||||
# its fine, but its still very stupid that it has to be done like this instead of allowing sprites to just directly insert a stencil clear. | ||||||||||||||||
# sprite refactor when | ||||||||||||||||
state: l_leg | ||||||||||||||||
- shader: StencilMask | ||||||||||||||||
map: ["enum.HumanoidVisualLayers.StencilMask"] | ||||||||||||||||
sprite: Mobs/Customization/masking_helpers.rsi | ||||||||||||||||
state: unisex_full | ||||||||||||||||
visible: false | ||||||||||||||||
- map: ["jumpsuit"] | ||||||||||||||||
- map: ["enum.HumanoidVisualLayers.LFoot"] | ||||||||||||||||
- map: ["enum.HumanoidVisualLayers.RFoot"] | ||||||||||||||||
- map: ["enum.HumanoidVisualLayers.LHand"] | ||||||||||||||||
- map: ["enum.HumanoidVisualLayers.RHand"] | ||||||||||||||||
- map: [ "gloves" ] | ||||||||||||||||
- map: [ "shoes" ] | ||||||||||||||||
- map: [ "ears" ] | ||||||||||||||||
- map: [ "outerClothing" ] | ||||||||||||||||
- map: [ "eyes" ] | ||||||||||||||||
- map: [ "belt" ] | ||||||||||||||||
- map: [ "id" ] | ||||||||||||||||
- map: [ "neck" ] | ||||||||||||||||
- map: [ "back" ] | ||||||||||||||||
- map: [ "enum.HumanoidVisualLayers.FacialHair" ] | ||||||||||||||||
- map: [ "enum.HumanoidVisualLayers.Hair" ] | ||||||||||||||||
- map: [ "enum.HumanoidVisualLayers.HeadSide" ] | ||||||||||||||||
- map: [ "enum.HumanoidVisualLayers.HeadTop" ] | ||||||||||||||||
- map: [ "enum.HumanoidVisualLayers.Tail" ] | ||||||||||||||||
- map: [ "mask" ] | ||||||||||||||||
- map: [ "head" ] | ||||||||||||||||
- map: [ "pocket1" ] | ||||||||||||||||
- map: [ "pocket2" ] | ||||||||||||||||
- map: ["enum.HumanoidVisualLayers.Handcuffs"] | ||||||||||||||||
color: "#ffffff" | ||||||||||||||||
sprite: Objects/Misc/handcuffs.rsi | ||||||||||||||||
state: body-overlay-2 | ||||||||||||||||
visible: false | ||||||||||||||||
- map: [ "clownedon" ] # Dynamically generated | ||||||||||||||||
sprite: "Effects/creampie.rsi" | ||||||||||||||||
state: "creampie_human" | ||||||||||||||||
visible: false | ||||||||||||||||
- map: [ "tailcover" ] | ||||||||||||||||
sprite: "Clothing/tailcover.rsi" | ||||||||||||||||
state: "tailcover-reptilian" | ||||||||||||||||
visible: false | ||||||||||||||||
- type: GenericVisualizer | ||||||||||||||||
visuals: | ||||||||||||||||
enum.TailVisuals.Tailcover: | ||||||||||||||||
tailcover: | ||||||||||||||||
True: {visible: true} | ||||||||||||||||
False: {visible: false} | ||||||||||||||||
- type: HumanoidAppearance | ||||||||||||||||
species: Reptilian | ||||||||||||||||
- type: Hunger | ||||||||||||||||
|
@@ -59,6 +121,12 @@ | |||||||||||||||
types: | ||||||||||||||||
Heat : 1.5 #per second, scales with temperature & other constants | ||||||||||||||||
- type: Wagging | ||||||||||||||||
- type: Tag | ||||||||||||||||
tags: | ||||||||||||||||
- CanPilot | ||||||||||||||||
- FootstepSound | ||||||||||||||||
- DoorBumpOpener | ||||||||||||||||
- HidesTail | ||||||||||||||||
Comment on lines
+124
to
+129
There was a problem hiding this comment. Choose a reason for hiding this commentThe reason will be displayed to describe this comment to others. Learn more.
Suggested change
|
||||||||||||||||
- type: LanguageKnowledge | ||||||||||||||||
speaks: | ||||||||||||||||
- GalacticCommon | ||||||||||||||||
|
Original file line number | Diff line number | Diff line change | ||||||||||||||
---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|
|
@@ -7,6 +7,61 @@ | |||||||||||||||
components: | ||||||||||||||||
- type: Sprite | ||||||||||||||||
scale: 0.8, 0.8 | ||||||||||||||||
layers: | ||||||||||||||||
- map: [ "enum.HumanoidVisualLayers.Chest" ] | ||||||||||||||||
- map: [ "enum.HumanoidVisualLayers.Head" ] | ||||||||||||||||
- map: [ "enum.HumanoidVisualLayers.Snout" ] | ||||||||||||||||
- map: [ "enum.HumanoidVisualLayers.Eyes" ] | ||||||||||||||||
- map: [ "enum.HumanoidVisualLayers.RArm" ] | ||||||||||||||||
- map: [ "enum.HumanoidVisualLayers.LArm" ] | ||||||||||||||||
- map: [ "enum.HumanoidVisualLayers.RLeg" ] | ||||||||||||||||
- map: [ "enum.HumanoidVisualLayers.LLeg" ] | ||||||||||||||||
- shader: StencilClear | ||||||||||||||||
sprite: Mobs/Species/Human/parts.rsi #PJB on stencil clear being on the left leg: "...this is 'fine'" -https://github.com/space-wizards/space-station-14/pull/12217#issuecomment-1291677115 | ||||||||||||||||
# its fine, but its still very stupid that it has to be done like this instead of allowing sprites to just directly insert a stencil clear. | ||||||||||||||||
# sprite refactor when | ||||||||||||||||
state: l_leg | ||||||||||||||||
- shader: StencilMask | ||||||||||||||||
map: ["enum.HumanoidVisualLayers.StencilMask"] | ||||||||||||||||
sprite: Mobs/Customization/masking_helpers.rsi | ||||||||||||||||
state: unisex_full | ||||||||||||||||
visible: false | ||||||||||||||||
- map: ["jumpsuit"] | ||||||||||||||||
- map: ["enum.HumanoidVisualLayers.LFoot"] | ||||||||||||||||
- map: ["enum.HumanoidVisualLayers.RFoot"] | ||||||||||||||||
- map: ["enum.HumanoidVisualLayers.LHand"] | ||||||||||||||||
- map: ["enum.HumanoidVisualLayers.RHand"] | ||||||||||||||||
- map: [ "gloves" ] | ||||||||||||||||
- map: [ "shoes" ] | ||||||||||||||||
- map: [ "ears" ] | ||||||||||||||||
- map: [ "outerClothing" ] | ||||||||||||||||
- map: [ "eyes" ] | ||||||||||||||||
- map: [ "belt" ] | ||||||||||||||||
- map: [ "id" ] | ||||||||||||||||
- map: [ "neck" ] | ||||||||||||||||
- map: [ "back" ] | ||||||||||||||||
- map: [ "enum.HumanoidVisualLayers.FacialHair" ] | ||||||||||||||||
- map: [ "enum.HumanoidVisualLayers.Hair" ] | ||||||||||||||||
- map: [ "enum.HumanoidVisualLayers.HeadSide" ] | ||||||||||||||||
- map: [ "enum.HumanoidVisualLayers.HeadTop" ] | ||||||||||||||||
- map: [ "enum.HumanoidVisualLayers.Tail" ] | ||||||||||||||||
- map: [ "mask" ] | ||||||||||||||||
- map: [ "head" ] | ||||||||||||||||
- map: [ "pocket1" ] | ||||||||||||||||
- map: [ "pocket2" ] | ||||||||||||||||
- map: ["enum.HumanoidVisualLayers.Handcuffs"] | ||||||||||||||||
color: "#ffffff" | ||||||||||||||||
sprite: Objects/Misc/handcuffs.rsi | ||||||||||||||||
state: body-overlay-2 | ||||||||||||||||
visible: false | ||||||||||||||||
- map: [ "clownedon" ] # Dynamically generated | ||||||||||||||||
sprite: "Effects/creampie.rsi" | ||||||||||||||||
state: "creampie_human" | ||||||||||||||||
visible: false | ||||||||||||||||
- map: [ "tailcover" ] | ||||||||||||||||
sprite: "Clothing/tailcover.rsi" | ||||||||||||||||
state: "tailcover-felinds" | ||||||||||||||||
visible: false | ||||||||||||||||
- type: HumanoidAppearance | ||||||||||||||||
species: Felinid | ||||||||||||||||
initial: Felinid | ||||||||||||||||
|
@@ -65,6 +120,18 @@ | |||||||||||||||
Unsexed: MaleFelinid | ||||||||||||||||
- type: Felinid | ||||||||||||||||
- type: NoShoesSilentFootsteps | ||||||||||||||||
- type: GenericVisualizer | ||||||||||||||||
visuals: | ||||||||||||||||
enum.TailVisuals.Tailcover: | ||||||||||||||||
tailcover: | ||||||||||||||||
True: {visible: true} | ||||||||||||||||
False: {visible: false} | ||||||||||||||||
- type: Tag | ||||||||||||||||
tags: | ||||||||||||||||
- CanPilot | ||||||||||||||||
- FootstepSound | ||||||||||||||||
- DoorBumpOpener | ||||||||||||||||
- HidesTail | ||||||||||||||||
Comment on lines
+129
to
+134
There was a problem hiding this comment. Choose a reason for hiding this commentThe reason will be displayed to describe this comment to others. Learn more.
Suggested change
|
||||||||||||||||
- type: LanguageKnowledge | ||||||||||||||||
speaks: | ||||||||||||||||
- GalacticCommon | ||||||||||||||||
|
Original file line number | Diff line number | Diff line change | ||||
---|---|---|---|---|---|---|
@@ -0,0 +1,23 @@ | ||||||
{ | ||||||
"version": 1, | ||||||
"license": "CC-BY-SA-4.0", | ||||||
"copyright": "TailCover by gentlebutter (588410099190726656) and ghostprince (115894681304301569)", | ||||||
There was a problem hiding this comment. Choose a reason for hiding this commentThe reason will be displayed to describe this comment to others. Learn more.
Suggested change
|
||||||
"size": { | ||||||
"x": 32, | ||||||
"y": 32 | ||||||
}, | ||||||
"states": [ | ||||||
{ | ||||||
"name": "tailcover-vulpkanin", | ||||||
"directions": 4 | ||||||
}, | ||||||
{ | ||||||
"name": "tailcover-reptilian", | ||||||
"directions": 4 | ||||||
}, | ||||||
{ | ||||||
"name": "tailcover-felinds", | ||||||
"directions": 4 | ||||||
} | ||||||
] | ||||||
} | ||||||
Comment on lines
+1
to
+23
There was a problem hiding this comment. Choose a reason for hiding this commentThe reason will be displayed to describe this comment to others. Learn more. If you check in Resources/Textures/DeltaV/Mobs/Customization/Harpy, there is a stray png file listed as harpy_wingcover.png not present in any RSI. Do you mind moving it to this folder, and rename it to tailcover-harpy, then add the TailVisual component and required visual layers to Harpy? There was a problem hiding this comment. Choose a reason for hiding this commentThe reason will be displayed to describe this comment to others. Learn more. Will do. There was a problem hiding this comment. Choose a reason for hiding this commentThe reason will be displayed to describe this comment to others. Learn more. |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Would be good to have this be a generic
MarkingHidesLayerX
.