Skip to content
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

Chameleon clothes + EMP behaviour #30924

Open
wants to merge 10 commits into
base: master
Choose a base branch
from

Conversation

mhamsterr
Copy link
Contributor

@mhamsterr mhamsterr commented Aug 12, 2024

About the PR

Chameleon clothes are now affected by EMP explosions. After being EMP'd, they scramble your camouflage by changing their state once to a completely random.

Why / Balance

it looks hilarious, also SS13 had it (tg at least)

Technical details

On EmpEvent, if item should be affected by EMP (there's a component datafield that lets you disable "EMP-behaviour") it marks itself as "affected" and "disabled". And while it is disabled (has EmpDisabledComponent basically) server tries to pick a random clothing element that fits this slot and then applies it.
And since getting a list of valid targets is now also required on server, some stuff was moved from Client to Shared.

Media

Continious (EmpContinious => True) (default):

empdempnew5persec.mp4

Single:

empchameleononce.mp4

Requirements

  • I have read and I am following the Pull Request Guidelines. I understand that not doing so may get my pr closed at maintainer’s discretion
  • I have added screenshots/videos to this PR showcasing its changes ingame, or this PR does not require an ingame showcase

Breaking changes

None?


Changelog

🆑 mhamster

  • tweak: Chameleon clothes are now affected by any kind of EMP explosion, which makes them go wild and change your current outfit to a random mess once.

@UbaserB
Copy link
Member

UbaserB commented Aug 12, 2024

My only concern is that it may be flashing a bit too fast.

@Plykiya
Copy link
Contributor

Plykiya commented Aug 12, 2024

The effect is way too intense, it would look better if chameleon gear had a proper full outfit change at once action and it swapped outfits entirely rather than each piece randomly individually. TG did support things like this.

Even with that kind of thing in, the swapping would need to happen slower.

@beck-thompson
Copy link
Contributor

I think it would also be fine if it just switched to one piece of clothing once randomly! This shows someone is a syndicate 100% but if only switched once, you could potentially talk your way out of it. Either way I love the idea!

@mhamsterr
Copy link
Contributor Author

My only concern is that it may be flashing a bit too fast.

Even with that kind of thing in, the swapping would need to happen slower.

How 5 changes/second looks like:

empdempnew5persec.mp4

This felt a bit toooo slow, so i think default 7 should work fine
Still, forks can set their own values if they feel like it

@Ilya246
Copy link
Contributor

Ilya246 commented Aug 12, 2024

this penalises using EMP implant and chame at the same time which i'm not sure is a good thing

@mhamsterr
Copy link
Contributor Author

I think it would also be fine if it just switched to one piece of clothing once randomly! This shows someone is a syndicate 100% but if only switched once, you could potentially talk your way out of it. Either way I love the idea!

empchameleononce.mp4

Behavior can be changed using EmpContinious datafield.

@SlamBamActionman
Copy link
Member

this penalises using EMP implant and chame at the same time which i'm not sure is a good thing

I don't mind this too much since if you're using an EMP implant you are pretty much exposing yourself anyways.

It's a cool effect that will probably never really come into play, but I like it and think it's funny.

it would look better if chameleon gear had a proper full outfit change at once action

this pls

@TurboTrackerss14
Copy link
Contributor

Just wanted to but my head in and say that most every traitor/syndicate item is emp immune.
Its like one of their key components.

However for the funny this does seem fairly reasonable, especially as a way to break the metashield for chameleon items.
I look forward to seeing a scientist accidentally trigger EMP artifact and become a walking 80s catwalk model.

@EmoGarbage404 EmoGarbage404 added the S: Awaiting Changes Status: Changes are required before another review can happen label Aug 12, 2024
@EmoGarbage404
Copy link
Member

as far as the concept of this goes, i think this is good. EMPs are a powerful anti-sec tool and neutering their utility in combination with stealth options is good and forces syndicate members to be a bit more aggressive.

@github-actions github-actions bot added S: Needs Review Status: Requires additional reviews before being fully accepted and removed S: Awaiting Changes Status: Changes are required before another review can happen labels Aug 14, 2024
@ElPidor

This comment was marked as spam.

@ps3moira
Copy link
Contributor

is this just waiting a final review?

@mhamsterr
Copy link
Contributor Author

this pls

I think it would be more reasonable to do this in other pr

is this just waiting a final review?

Pretty much yeah, if there are no other suggestions.

@SlamBamActionman SlamBamActionman added the S: Untriaged Status: Indicates an item has not been triaged and doesn't have appropriate labels. label Nov 14, 2024
@beck-thompson beck-thompson added P3: Standard Priority: Default priority for repository items. T: New Feature Type: New feature or content, or extending existing content D2: Medium Difficulty: A good amount of codebase knowledge required. T: Balance Change Type: Balance changes through direct value changes, or changes to mechanics that affect it A: Roundflow/Antag Area: Roundflow - "What happens in the game", including antagonist roles and their capabilities size/L Denotes a PR that changes 1000-4999 lines. and removed S: Untriaged Status: Indicates an item has not been triaged and doesn't have appropriate labels. labels Nov 18, 2024
@github-actions github-actions bot added the S: Merge Conflict Status: Needs to resolve merge conflicts before it can be accepted label Jan 2, 2025
Copy link
Contributor

github-actions bot commented Jan 2, 2025

This pull request has conflicts, please resolve those before we can evaluate the pull request.

+ time stuff
+ EmpChangeIntensity
+ EmpContinious
+ moved random pick logic into GetRandomValidPrototype
mhamsterr and others added 2 commits January 25, 2025 19:37
Co-Authored-By: Nemanja <98561806+emogarbage404@users.noreply.github.com>
@mhamsterr mhamsterr force-pushed the emp-chameleon-2024-08 branch from b73e571 to 59740e5 Compare January 25, 2025 12:43
@github-actions github-actions bot added size/M Denotes a PR that changes 100-999 lines. and removed size/L Denotes a PR that changes 1000-4999 lines. S: Merge Conflict Status: Needs to resolve merge conflicts before it can be accepted labels Jan 25, 2025
@github-actions github-actions bot added size/S Denotes a PR that changes 10-99 lines. and removed size/M Denotes a PR that changes 100-999 lines. labels Jan 25, 2025
@github-actions github-actions bot added size/M Denotes a PR that changes 100-999 lines. and removed size/S Denotes a PR that changes 10-99 lines. labels Jan 25, 2025
@beck-thompson beck-thompson self-assigned this Jan 25, 2025
Copy link
Contributor

@beck-thompson beck-thompson left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Style stuff and one issue with PDAs / IDs! Overall looks great

@@ -94,6 +118,32 @@ public void SetSelectedPrototype(EntityUid uid, string? protoId, bool forceUpdat
Dirty(uid, component);
}

public string GetRandomValidPrototype(SlotFlags slot)
{
return _random.Pick(GetValidTargets(slot).ToList());
Copy link
Contributor

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

This doesn't quite work! I was super confused for a while but there is an issue with PDAs. When a PDA gets zapped, it picks a random item from that slot. However, a LOT of items in the ID card slot slots IDs, not PDAs so there is a very good chance it doesn't update every time.

You'll have to do something with the RequireTag I think (See #30514 for more info)

Co-Authored-By: beck-thompson <107373427+beck-thompson@users.noreply.github.com>
@github-actions github-actions bot added the S: Merge Conflict Status: Needs to resolve merge conflicts before it can be accepted label Feb 14, 2025
Copy link
Contributor

This pull request has conflicts, please resolve those before we can evaluate the pull request.

@github-actions github-actions bot removed the S: Merge Conflict Status: Needs to resolve merge conflicts before it can be accepted label Feb 25, 2025
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
A: Roundflow/Antag Area: Roundflow - "What happens in the game", including antagonist roles and their capabilities D2: Medium Difficulty: A good amount of codebase knowledge required. P3: Standard Priority: Default priority for repository items. S: Needs Review Status: Requires additional reviews before being fully accepted size/M Denotes a PR that changes 100-999 lines. T: Balance Change Type: Balance changes through direct value changes, or changes to mechanics that affect it T: New Feature Type: New feature or content, or extending existing content
Projects
None yet
Development

Successfully merging this pull request may close these issues.

10 participants