26 Commits

Author SHA1 Message Date
Thunder12345 20118ad747 Converts a bunch of time/delay vars to use time defines (#92495)
## About The Pull Request

Converts as many time vars expressed in deciseconds as I could find to
use time defines.

## Why It's Good For The Game

Makes these values neater and more readable.

## Changelog
🆑
code: Converted a lot of time-based variables to be expressed with time
defines.
/🆑
# Conflicts:
#	code/modules/clothing/head/hat.dm
#	code/modules/clothing/shoes/boots.dm
#	code/modules/clothing/suits/utility.dm
2025-08-19 22:38:55 -04:00
plsleavemealon d19a65d157 Morbid surgery expansion (#91627)
## About The Pull Request


This PR tweaks how tools with the CRUEL_IMPLEMENT interact with
patients. Essentially, when performing a surgery without anesthetic, it
will give them the same mood debuff that they would suffer if you had
failed a surgery step (fairly long lasting mood debuff that is
removeable with alcohol or a nap).

Also adds experimental surgeries to morbid surgeries, meaning coroners
now do them faster and get a mood bonus for completing them. The
experimental surgery step now also causes a lot of pain when performed
by someone who is morbidly inclined, such as the coroner. This step is
the part where you are interacting with the patient with an open hand
and is contextual to the experimental surgery (thread the patients
veins, ground their nerves, etc). Anesthetic will mitigate this
entirely.

## Why It's Good For The Game

Cruel tools are cruel for a reason, using them on the living is akin to
torture. So they are going to hurt, a lot. And this gives those tools
some added mechanical flavor befitting of a mad doctor. Experimental
surgeries are all quite morbid in general, so its very thematic to add
them to the list of morbid surgeries. And the part where you start
interacting with the body is perhaps the most morbid part of those
surgeries! It also makes sense for that to cause quite a lot of pain,
its a delicate procedure so you really should have the patient under
anesthesia of some kind.

## Changelog

🆑
add:experimental surgeries are now morbid surgeries, and as such
coroners, or anyone else morbidly inclined, get a slight speed boost
when performing them. Coroner's, or anyone morbidly inclined will also
get a mood boost from completing these surgeries.
add:morbid tools now cause a great deal of pain for the patient if used
without anesthesia. The experimental surgery step will now cause a great
deal of pain when performed by someone who is morbidly inclined, such as
the coroner, however this can be avoided with anesthesia.
/🆑
2025-06-21 22:21:56 -04:00
Ghom 778ed9f1ab The death or internal/external organ pathing (ft. fixed fox ears and recoloring bodypart overlays with dye sprays) (#87434)
## About The Pull Request
This PR kills the abstract internal and external typepaths for organs,
now replaced by an EXTERNAL_ORGAN flag to distinguish the two kinds.

This PR also fixes fox ears (from #87162, no tail is added) and
mushpeople's caps (they should be red, the screenshot is a tad
outdated).

And yes, you can now use a hair dye spray to recolor body parts like
most tails, podpeople hair, mushpeople caps and cat ears. The process
can be reversed by using the spray again.

## Why It's Good For The Game
Time-Green put some effort during the last few months to untie functions
and mechanics from external/internal organ pathing. Now, all that this
pathing is good for are a few typechecks, easily replaceable with
bitflags.

Also podpeople and mushpeople need a way to recolor their "hair". This
kind of applies to fish tails from the fish infusion, which colors can't
be selected right now. The rest is just there if you ever want to
recolor your lizard tail for some reason.

Proof of testing btw (screenshot taken before mushpeople cap fix, right
side has dyed body parts, moth can't be dyed, they're already fabolous):

![immagine](https://github.com/user-attachments/assets/2bb625c9-9233-42eb-b9b8-e0bd6909ce89)

## Changelog

🆑
code: Removed internal/external pathing from organs in favor of a bit
flag. Hopefully this shouldn't break anything about organs.
fix: Fixed invisible fox ears.
fix: Fixed mushpeople caps not being colored red by default.
add: You can now dye most tails, podpeople hair, mushpeople caps etc.
with a hair dye spray.
/🆑
2024-10-30 08:03:02 +01:00
grungussuss 58501dce77 Reorganizes the sound folder (#86726)
## About The Pull Request

<details>

- renamed ai folder to announcer

-- announcer --
- moved vox_fem to announcer
- moved approachingTG to announcer

- separated the ambience folder into ambience and instrumental
-- ambience --

- created holy folder moved all related sounds there
- created engineering folder and moved all related sounds there
- created security folder and moved ambidet there
- created general folder and moved ambigen there
- created icemoon folder and moved all icebox-related ambience there
- created medical folder and moved all medbay-related ambi there
- created ruin folder and moves all ruins ambi there
- created beach folder and moved seag and shore there
- created lavaland folder and moved related ambi there
- created aurora_caelus folder and placed its ambi there
- created misc folder and moved the rest of the files that don't have a
specific category into it

-- instrumental --

- moved traitor folder here
- created lobby_music folder and placed our songs there (title0 not used
anywhere? - server-side modification?)

-- items --

- moved secdeath to hailer
- moved surgery to handling

-- effects --

- moved chemistry into effects
- moved hallucinations into effects
- moved health into effects
- moved magic into effects

-- vehicles --

- moved mecha into vehicles


created mobs folder

-- mobs --

- moved creatures folder into mobs
- moved voice into mobs

renamed creatures to non-humanoids
renamed voice to humanoids

-- non-humanoids--

created cyborg folder
created hiss folder
moved harmalarm.ogg to cyborg

-- humanoids --




-- misc --

moved ghostwhisper to misc
moved insane_low_laugh to misc

I give up trying to document this.

</details>

- [X] ambience
- [x] announcer
- [x] effects
- [X] instrumental
- [x] items
- [x] machines
- [x] misc 
- [X] mobs
- [X] runtime
- [X] vehicles

- [ ] attributions

## Why It's Good For The Game

This folder is so disorganized that it's vomit inducing, will make it
easier to find and add new sounds, providng a minor structure to the
sound folder.

## Changelog
🆑 grungussuss
refactor: the sound folder in the source code has been reorganized,
please report any oddities with sounds playing or not playing
server: lobby music has been repathed to sound/music/lobby_music
/🆑
2024-09-23 22:24:50 -07:00
necromanceranne 7088097eb8 [NO SELF SURGERY] Cybernetically augmented humanoids have alternative surgeries (both standard and advanced) [NO SELF SURGERY], as well as other misc additions (#84980)
<!-- Write **BELOW** The Headers and **ABOVE** The comments else it may
not be viewable. -->
<!-- You can view Contributing.MD for a detailed description of the pull
request process. -->

## About The Pull Request

### Cybernetic variant surgeries

Many of the surgeries able to be performed on organic limbs now have a
version for robotic limbs. This includes;

### NONE OF THESE ARE SELF SURGERY OPTIONS

- Organ repair surgeries
- Stomach Pumps
- Blood filtering
- Autopsies
- Lobotomies
- Pacification
- Lipoplasty
- Amputation
- Brainwashing (including the Sleeper Agent protocol)
- Nerve Splicing and Nerve Grounding
- Vein Threading and Vein Muscle Membrane
- Ligament Hook and Ligament Reinforcement
- Cortex Folding and Cortex Imprint

These utilize mechanical steps and unique versions of their special step
that uses mechanical tools. But many of these are able to be performed
using standard surgery tools.

In fact, I've improved the chances for doing surgery using standard
tools for mechanical steps, recognizing that medical is often going to
end up with synths in medbay whether we like it or not.

### NONE OF THESE ARE SELF SURGERY OPTIONS

### Organ Repair Surgeries correct EMP Failure Cascades

When you repair a synthetic organ using the organ repair surgery, it
reverses the effects of organ failure from an EMP. That is, the
permanent failure of an organ. This allows for an alternative method to
replacing that organ wholesale, which makes treating synths a lot easier
for medical and EMPs less of a RNG death knell for people with
cybernetic organs. However, it still needs the surgery to correct the
error, so this isn't removing the danger of being EMP'd.

### Health Scanners report EMP Failure Cascades

Scanning someone with a cybernetic organ now actually tells you that the
organ is failing. Wow, why wasn't this already the case?

## Why It's Good For The Game

#### Surgeries

With the new techweb changes, augmented crew are becoming a lot, lot
more common place, as are the implantation of cybernetics. These are
required for research to be able to progress both medical and robotics
technology. Therefore, those using these items are becoming a lot more
common place.

However, our medical system is quite blind to these people as of the
moment. A lot of surgeries that are critical to recovering the
injured/dead do not work on them outright, and medical can't resolve the
problems that come with cybernetic organs entirely.

This change hopefully modernizes our surgeries to account for these
synthetic/cybernetically-altered crew members that neither forces people
to choose between taking them to medical or robotics (they're often
going to end up in medical regardless), and letting either department to
function as a place for these crew to obtain medical services.

Also gives them some cooler flavour to their surgeries, which I think is
the most important part of this change. It actually feels like you're
more than human without getting too much in the way of gameplay loops
and over complicating things.

Edit: To provide a bit of extra clarity on 'Why allow the advanced
surgeries?'

You can actually have the benefits of the advanced surgeries as an
augmented humanoid. The problem is that it has to take place before you
are augmented. They're not mutually exclusive, just slow to apply. There
isn't much reason for there not to be a method to apply them to robotic
people, particularly since augmentations are expected earlier in the
round than advanced surgeries.

#### EMP Failure and Detection

This mechanic is probably what people hate the most about cybernetics.
It is largely invisible, and forces you to have to go through a tedious
process of organ replacement on what could be any one of your organs,
since it wasn't being broadcast to the user which one is failing until
you are possibly already doubling over.

Now, it is easier for medical staff to identify if they have a
cybernetically enhanced patient in the midst of a failure cascade, and
have the means to resolve the problem. Robotics and cyborgs can too,
since sometimes they'll have the means usually to do the same operations
and detection.

## Changelog

<!-- If your PR modifies aspects of the game that can be concretely
observed by players or admins you should add a changelog. If your change
does NOT meet this description, remove this section. Be sure to properly
mark your PRs to prevent unnecessary GBP loss. You can read up on GBP
and it's effects on PRs in the tgstation guides for contributors. Please
note that maintainers freely reserve the right to remove and add tags
should they deem it appropriate. You can attempt to finagle the system
all you want, but it's best to shoot for clear communication right off
the bat. -->

🆑
add: Robotic variants of many of the standard and advanced humanoid
surgeries. You cannot perform self surgery with these surgeries.
balance: It is easier to do robotic surgeries with normal surgery tools.
qol: It is now possible to detect EMP organ failure cascades via health
scanners.
qol: EMP organ failure cascades can be reversed by doing organ repair
surgeries targeting the failing organ.
/🆑

<!-- Both 🆑's are required for the changelog to work! You can put
your name to the right of the first 🆑 if you want to overwrite your
GitHub username as author ingame. -->
<!-- You can use multiple of the same prefix (they're only used for the
icon ingame) and delete the unneeded ones. Despite some of the tags,
changelogs should generally represent how a player might be affected by
the changes rather than a summary of the PR's contents. -->

---------

Co-authored-by: Jacquerel <hnevard@gmail.com>
2024-07-22 18:07:05 +01:00
Zephyr ecbcef778d Refactors Regenerate Organs, and a few organ helpers (#74219)
## About The Pull Request

Refactors regenerate organs to be slightly more intelligent in handling
organ changes and replacements.
Noteably:
- We don't remove organs that were modified by the owner; such as
changing out your heart for a cybernetic
- We early break out of the for loop if they aren't supposed to have an
organ there and remove it
- We check for the organ already being correct, and just healing it and
continuing if it is

Also changes the names of some of the organ helpers into snake_case
### Mapping March
Ckey to receive rewards: N/A

## Why It's Good For The Game
## Changelog

---------

Co-authored-by: Jacquerel <hnevard@gmail.com>
2023-03-26 17:54:36 +01:00
John Willard 3b0794eca9 Surgery code improvements (#71182)
## About The Pull Request

* Changes a lot of things about surgeries to hopefully bring it up to
more modern code standards.
* Removes a ton of single-letter vars used in checking surgeries on
people.
* Makes use of continue/break in for() loops.
* Properly documents the vars on surgeries
* Turns 'ignore clothes', 'self operating', 'lying required', 'require
limb' and 'require real limb' from vars into surgery flags
* Removes a lot re-defines of target_mobtype being set to human, as
that's the base anyways.
* Also tries to organize the vars on each surgery a bit.
* Makes the surgery initiator hopefully a little bit more sane
* Removes the surgery's can_cancel and stomach pump's
accumulated_experience vars, as they were entirely unused.

## Why It's Good For The Game

I looked at surgery code and couldn't stand it, this is hopefully
helping bring it to something we can stand.
This however doesn't touch the individual surgery steps.

## Changelog

im exhausted i don't know if this has in-game effects
2022-11-20 23:22:46 -08:00
lizardqueenlexi 588779256e Surgery computers tell which tool to use. (#70973)
## About The Pull Request


![image](https://user-images.githubusercontent.com/105025397/199194075-d1a3b42a-5c2e-4a02-84d1-84b4be2b601b.png)

All surgery step names, displayed in the surgical computer, will now
show which tool to use for that step in parentheses. In cases where
multiple tools have a 100% success chance, all are listed; if no tool
has a 100% chance then the "correct" one is shown.

Surgery computers will never display "alternate" tools for surgeries
(those with a lower success chance), but this shouldn't be a problem.
Surgical computers are _usually_ in places with surgical tools at hand,
and NanoTrasen wouldn't want to encourage doing brain surgery with a
screwdriver. Y'know, probably.
## Why It's Good For The Game

Firstly, this change is particularly helpful to new players. If you have
little experience with surgery, it's not always clear which tool you're
meant to use for which step. This is especially true for some of the
odder surgeries - if you didn't already know, it's not clear at all that
"brainwash" means "use a hemostat". While there are certainly guides on
the wiki, it's nice to have as much information provided in-game as
possible.

Secondly, this change brings consistency. A _small_ number of surgical
steps (healing broken bones, namely) already do this! I see no reason
why this shouldn't be extended to the remaining surgical steps,
especially because it's not particularly obtrusive to the surgery
computer interface.
## Changelog
🆑
qol: Made surgical computers tell you what tool to use for the current
surgical step.
/🆑

Co-authored-by: Mothblocks <35135081+Mothblocks@users.noreply.github.com>
2022-11-04 01:00:12 -07:00
Kapu1178 6d470992cb This tail refactor turned into an organ refactor. Funny how that works. (#67017)
* Fuck you (refactors ur tails)

* Errors

* Wow. Pain.

* Fixes up probably everything

* finish up here

* Fixes hard del maybe

* original owner hard del

* garbage collection runtime

* suck my peen byond

* Mapped tails

* motherfucker.

* motherrfucker. again.

* Whooopppppsie

* yeah bad idea

* Turns out external organs literally just sat in nullspace forever if their parent was deleted, and didnt Remove() themselves, causing harddels.

* So anyways I repathed all organs

* Fixes

* really.

* unit test... test

* unit test-test but it passes linters this time because im a moh-ron

* I've lost track of what im doing at this point

* Hopefully fixes hard del?

* meh

* Update code/datums/dna.dm

* things n stuff

* repath from master pull
2022-05-30 21:18:34 -07:00
nmajask 64d5de009c Revives "Adds sound effects to surgeries" (#65578)
* Adds surgical sounds

Rough implementation as I don't have too much time tonight.

* Fixed falure_sound

Fixed a typo

* Removed the lists

Removed the lists and added sounds to revival surgery, stuff will probably break

* Fixes the playsounds still using pick

* Added sounds to more surgeries

Added sounds to four more surgeries
2022-03-25 20:07:00 -04:00
FlamingLily c5a110308d Surgery pain messages and screaming in agony (#61252)
Adds (purely flavourful) unique pain messages to surgery steps, with a 30% chance for forced screaming in agonizing pain

Messages are things like "You feel a horrible stabbing in your chest" and w/ever.

Also see Skyrat-SS13/Skyrat-tg#5899
2021-09-15 13:30:49 +01:00
Watermelon914 375a20e49b Refactors most spans into span procs (#59645)
Converts most spans into span procs. Mostly used regex for this and sorted out any compile time errors afterwards so there could be some bugs.
Was initially going to do defines, but ninja said to make it into a proc, and if there's any overhead, they can easily be changed to defines.

Makes it easier to control the formatting and prevents typos when creating spans as it'll runtime if you misspell instead of silently failing.
Reduces the code you need to write when writing spans, as you don't need to close the span as that's automatically handled by the proc.

(Note from Lemon: This should be converted to defines once we update the minimum version to 514. Didn't do it now because byond pain and such)
2021-06-14 13:03:53 -07:00
FlamingLily 3958db8d27 Cleans up surgery and organ code. (#59068)
About The Pull Request

Scrubs those filthy single letter variables out of surgery and organ code.
Replaces a few 0s and 1s with FALSE and TRUE where relevant
Normalises and cleans up surgery step lists and surgical implements lists.
Replaces a whole lotta for loops with for x as anything in y lops

This is my first PR (upstream anyway) so I encourage you to treat my code with as much confidence as I treat it, which is to say none, because there's a strong chance I've totally broken everything.

But it compiles!
Why It's Good For The Game

code improvement, follows contributing guidelines.
Changelog

🆑 FlamingLily
code: Cleanup of surgery and organ code
/🆑
2021-05-22 19:49:47 +12:00
Qustinnus f66ca34626 Refactors monkeys into a species (#55614)
Changes monkeys from carbon subtype to species.
2020-12-30 16:30:15 +01:00
Jared-Fogle 418bd80a6b Remove healing skill (#52005)
* Remove healing skill

* Remove dissection from tech web
2020-07-07 10:10:12 -04:00
moo bb3d562d01 Cobbduceus: Surgery Skill XP/Step Buffs (#49196)
* 💉

* 🐣

* excels help

* waaa_fb

* fixed lobotomy skill

* waaa_fb2
2020-02-14 19:17:27 +01:00
moo 964b3d65d5 Cobbduceus: Healing lvl? (Medical Skill) (#47538)
* b

* helps to commit huh

* math is hard

* parenthesis are even harder

* Update code/datums/skills/_skill.dm

Co-Authored-By: Bobbahbrown <bobbahbrown@gmail.com>

* removes efficiency... or efficacy 😏

* baby sha... i mean files
2019-11-21 04:49:24 +00:00
Fikou e450be44dc surgery tool refactor (#46856)
* awooooooooooooooooo

* a

* aw shet

* woops!!

* a

* wow heck you
2019-10-09 12:25:42 -04:00
kingofkosmos df1fecc58c Adds notice-span to visible_messages with no spans (#46044)
About The Pull Request

Adds 'notice' span class to all visible_messages which had no span class, making all those black messages blue.
Why It's Good For The Game

This should help differentiate action-messages from talking-messages in the chat. More actions will be blue, thus black talking-messages should pop out more.
2019-08-26 20:50:00 +12:00
XDTM 3f28227f6c Makes surgery more stealthy (#44483)
About The Pull Request

Part of #44440

Surgery now gives detailed description to the surgeon and anyone within one tile of distance, and more vague or ambiguous descriptions to the patient and anyone further away. This can lead to a surgeon being able to perform a brainwashing in place of a brain surgery with nobody being the wiser, or implanting a different organ than the one agreed on, and so on.
Changelog

cl
add: Surgery steps are now shown in detail only to the surgeon and anyone standing adjacent to them; the patient and people watching from further away get a more vague/ambiguous description.
/cl
2019-06-18 11:44:58 +12:00
AnturK 199339d994 Surgery cleanup (#40788)
* Surgery cleanup

* Proper mobtype
2018-10-12 04:42:48 -04:00
XDTM b9445db807 Advanced surgeries are directly downloaded from the computers instead of using disks (#39451)
Removes needless back-and-forth with surgery disks, making advanced surgery a
bit less annoying to set up. Disks still work to install surgeries locally,
although the only disk currently obtainable is the traitor brainwashing disk.
2018-08-11 16:06:28 -07:00
Ian Turk fbe5f4a062 Replaced body zone magic strings with defines 2018-03-19 15:44:51 -05:00
SailorDave 8168146809 🆑 SailorDave
tweak: The names of Surgery Disks now match their type of surgery.
/🆑
[why]: Fixes https://github.com/tgstation/tgstation/issues/35888
2018-03-13 19:53:52 -04:00
ACCount 1b725c1227 Makes new surgeries check for tool qualities (#35847)
* Makes new surgeries check for tool qualities

* Gives augments and autosurgeon some tool_act love

* okay

* Fix duplicate definition
2018-02-24 01:13:04 -05:00
XDTM 9d41e9734d Extensive surgery additions (#35520)
* Extensive surgery additions

* ,

* bioware

* restrict

* implants

* oops my hand slipped

* "i only changed a few lines, surely it's gonna compile, let's just push it and be done with it" --me, once again

* zombie surgery

* Adds brainwashing antag datum

* Antur Reviews

* @Antur part 2

* wow
2018-02-19 14:29:06 +02:00