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鈥檒l occasionally send you account related emails.

Already on GitHub? Sign in to your account

[MIRROR] [MIRROR] Improve bedsheet interactions [MDB IGNORE] #796

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

Conversation

ArkStation-Bot
Copy link
Collaborator

Original PR: NovaSector/NovaSector#3515

Original PR: tgstation/tgstation#84505

About The Pull Request

This pr simply adds drop/pickup sounds to bedsheets, replaces its attackby(...) and attack_secondary(...) with item_interaction(...) and interact_with_atom_secondary(...), and makes tucking in match the bedsheet pixel_z with that of the living we're tucking in. It also removes a check that's no longer needed to allow for telekinetically tucking someone in.

First bit of note, we use item_interaction(...) instead of wirecutters_act(...)/tool_act(...) as I think tearing up the bedsheets should be the interaction in combat mode too, and everything under tool_act(...) only gets called with combat mode being off.

Second bit of note, we remove the !user.CanReach(target) check from tucking people in, as I believe that's no longer necessary here. This allows us to tuck people in telekinetically, given the bedsheets are adjacent to the one we're tucking in.

Finally, we match the bedsheets' pixel_z with that of the living we're tucking in by setting it directly, and also reset it directly when we smooth the sheets.
I know the elevation element exists, but I believe that only cares about living instances, and besides that really we only want this to be set when tucking someone in rather than always. Most importantly, it works.

Why It's Good For The Game

Using the new item interaction code is better than attackby(...) and such.
Cloth sounds are nicer than no sounds, and make sense given they're, well, cloth.
Tucking someone in with telekinesis is funny.

Previously, bedsheets would not offset their pixel_z to match that of the living they're tucking in, meaning if you were to say rest upon a table the bedsheets would always be awkwardly offset.
This fixes that.

Changelog

馃啈
code: Moved bedsheet interactions to the item interaction code. Please report any issues.
fix: Bedsheets adjust their offset to match that of the living they're tucking in.
sound: Bedsheets use the cloth drop/pickup sounds instead of being silent.
qol: You can tuck someone in telekinetically.
/:cl:

NovaBot13 and others added 2 commits July 4, 2024 12:05
* Improve bedsheet interactions (#84505)

## About The Pull Request

This pr simply adds drop/pickup sounds to bedsheets, replaces its
`attackby(...)` and `attack_secondary(...)` with `item_interaction(...)`
and `interact_with_atom_secondary(...)`, and makes tucking in match the
bedsheet `pixel_z` with that of the living we're tucking in. It also
removes a check that's no longer needed to allow for telekinetically
tucking someone in.

First bit of note, we use `item_interaction(...)` instead of
`wirecutters_act(...)`/`tool_act(...)` as I think tearing up the
bedsheets should be the interaction in combat mode too, and everything
under `tool_act(...)` only gets called with combat mode being off.

Second bit of note, we remove the `!user.CanReach(target)` check from
tucking people in, as I believe that's no longer necessary here. This
allows us to tuck people in telekinetically, given the bedsheets are
adjacent to the one we're tucking in.

Finally, we match the bedsheets' `pixel_z` with that of the living we're
tucking in by setting it directly, and also reset it directly when we
smooth the sheets.
I know the elevation element exists, but I believe that only cares about
living instances, and besides that really we only want this to be set
when tucking someone in rather than always. Most importantly, it works.
## Why It's Good For The Game

Using the new item interaction code is better than `attackby(...)` and
such.
Cloth sounds are nicer than no sounds, and make sense given they're,
well, cloth.
Tucking someone in with telekinesis is funny.

Previously, bedsheets would not offset their `pixel_z` to match that of
the living they're tucking in, meaning if you were to say rest upon a
table the bedsheets would always be awkwardly offset.
This fixes that.
## Changelog
:cl:
code: Moved bedsheet interactions to the item interaction code. Please
report any issues.
fix: Bedsheets adjust their offset to match that of the living they're
tucking in.
sound: Bedsheets use the cloth drop/pickup sounds instead of being
silent.
qol: You can tuck someone in telekinetically.
/:cl:

---------

Co-authored-by: Ghom <[email protected]>

* Improve bedsheet interactions

---------

Co-authored-by: _0Steven <[email protected]>
Co-authored-by: Ghom <[email protected]>
Co-authored-by: NovaBot13 <[email protected]>
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

Successfully merging this pull request may close these issues.

None yet

2 participants