Commit Graph
42 Commits
Author SHA1 Message Date
346a1b8142 Yet Another Surgery Refactor (#18325)
* Initial commit

Fixes up surgery.dm
Adds some tool behavior

* More basic changes

* Checkpointing: this is a little gross right now

* Add signal COMPONENT_CANCEL_ATTACK_CHAIN

* Cleans up surgery initiator

* Mostly gets surgery (and canceling it) working

* Add abstract proxy surgery steps

Also adds them to organ manipulation

* Clean up most existing surgeries

* Rework organ openness, adds define for aborting a beginstep

* surgery works again, also implements retry defines

* fix surgery computer

* add limb repair to synth implant removal

* retry implant checks

* Clean up abductor surgeries as well as some other things

* A lot
- Reworks organ manipulation to use a series of surgery steps instead
- Fixes some runtimes with open hands
- Lets mito zero out the germ level while treating necrosis
- Adds a debug surgery tool

* add debug surgery tool, note some TODOs for later

* Add conditional check for surgeries repeating

* update surgery retry logic to make it more of a bonus

* Lets abductors automatically retry any failed surgery steps

* Rework robotic surgery to use abstract/proxy steps

* Bunch of bugfixes and more!
- Limb reattachment works properly now, you can just slap a limb onto a person
- If the limb isn't robotic, it'll be useless until the surgery is finished with a hemostat, though it might be enough to get the patient out of the OR.

* Remove more now-implicit checks

* Slight reorganization

* more fixes across the board

* Remove unused variable

* Trying not to lose my mind here
- Does away with can_run() entirely
- Cleans up visible messages in code
- begin steps should now all have ..() afterwards
- slime bone surgery should be fixed now
- more docs

* Robotic  surgery is stoppable with a crowbar, all surgery can_start now checks parent

* Fix some broken robotic typepaths

* Typepath fixes, do away with some last TODOs

* Forgor

* Last cleanups before we go gold

* jk lol

* Make early surgery termination clearer

* More "last" cleanups

* Fixes tool flags, surgery initiation

- Fixes surgery not being startable by sharp objects
- Moves surgical tool flags to item traits

* Clean up surgery cancellation, especially for borgos

* I think this should GC better

* Apply suggestions from code review

Co-authored-by: Sirryan2002 <80364400+Sirryan2002@users.noreply.github.com>

* Status is now step number

* Add a 20% chance to find nothing during organ manipulation

* Improve documentation, make forced_surgery a normal arg

* Charlie's reviews

* Why are abductors like this

* Little more verification, ensuring limb augmentation and organ manip healing work properly

* Fix torso organ manip being unfinishable

* Fix cavity implants, open-hand/any item steps

* Make sharp objects not try to start an operation with help intent

* Comments, quick target fix

* Re-order list so advanced bruise pack is pulled first

* Make surgical gripper function like an open hand

* Make mito only use one unit per organ for now

* Check if user is on operable surface before trying to operate

* Reduce admin logging

* Fix some bugs that appeared during the testmerge
- you can no longer start robotic surgeries with a scalpel (lol)
- you can now cancel surgeries on the first step after I fixed some bugs that I introduced (woo hoo)
- Synthetic limb attachment is now combined into a single startable surgery step, though still retains the fun flavor of both

* Swats some more bugs
- (hopefully) fixes a huge source of runtimes where we tried to check if we could run surgeries before checking if the surgery used an organ
- In doing so, moves the logic for determining if a surgery can start to the mob-level
- Fixes robotic reattachment surgery not working

* multi-bug drifting???

- Fixes a bug where a branching surgery with an any tool option could possibly override a step with a matching tool
- Fixes some intermediate surgeries failing due to not having specified possible_locs

* A few more fixes
- Fixes any surgery tool steps again
- Fixes cavity surgery again

* Hopefully fixes getting stuck in robotic organ manip

* Remove extra parent call

* Steel review

* Steel review

* Fix spacing for possible locs

* Roundstart traits

* Advanced surgical traits and other hal fixes

Co-authored-by: Sirryan2002 <80364400+Sirryan2002@users.noreply.github.com>
2022-09-16 18:48:43 +01:00
alex-ghandGitHub fc2b99bd51 Surgery refactors (#18183)
* Remove dead code

* Refactor magic numbers to defines
2022-07-05 21:20:38 +02:00
1ad219e02a Revives "Updates ERT gear and adds holo stretcher #16266" (#18139)
* Updates ERT gear

* Apply suggestions from code review

Co-authored-by: SteelSlayer <42044220+SteelSlayer@users.noreply.github.com>

* Reformats new vars

* Update code/game/objects/items/weapons/storage/boxes.dm

Code Clarity

Co-authored-by: SabreML <57483089+SabreML@users.noreply.github.com>

* Removes unneeded item

* BULK

* repath time

* moxian review

* le beds

* haha webedits

* bubble review

Co-authored-by: warior4356 <warior4356@yahoo.com>
Co-authored-by: SteelSlayer <42044220+SteelSlayer@users.noreply.github.com>
Co-authored-by: SabreML <57483089+SabreML@users.noreply.github.com>
2022-07-05 18:47:20 +02:00
CharlieandGitHub bead47ea29 Adds crawling. (#17899)
* crawling?

* knockdown. CONTAINS CHANGES THAT NEED REVERTING

* plotting can_moves death

* CANMOVE IS DEAD

* mappers are insane

* removes todos as the are todone

* decreases crawling speed

* silly-con fixes

* surgery fixes

* fixes death

* pAI fixes

* removes var/lying

* runtime fix

* decreases default crawling speed

* correct crawling dir

* some more fixes

* stunbaton tweak, revert later

* rejuv fix

* restraint and incapacitated refactor

* crawling dir in line with TG

* fixes vehicle movement and grabs

* alien rest fixes

* antistun fixes

* fixed fall sounds

* forgor to stage this

* first review

* canmove zombie dispersal

* fix

* lots of fixes

* defines

* fixes the trait helper

* if you got no legs you can still crawl

* sillyconfix

* no reverty keepy

* jaunt fix

* hopefully fixes perma sleepy zzz

* admin rejuv temp fix

* rest canceling

* antistun chems now remove knockdown

* buckle offset fix

* fixes some stuff

* crawling delay = 4

* descuffs bed

* sleeping hotfix

* fixes simple mob resting

* V is the macro for resting

* projectiles no dodgy

* refines the projectile check

* god I hate strings

* MORE FIXES

* I hate buckling

* fixes capulettium plus

* winding down

* farie review

* bugs did stop showing up

* SEAN

* todo

* sean review

* ed209

* i HATE cyborgs

* steel review

* laaaaaast things

* reverts stun baton changes

* and done
2022-06-30 11:57:52 -05:00
f4bd86cc5e Surgery on napping people wakes them up. (#17661)
* Surgery on napping people wakes them up.

* Fix a potential afreeze issue

* Code review

* has_status_effect now returns `null` if no status effect

* move `voluntary` to be an arg to New

* Update code/modules/surgery/helpers.dm

Co-authored-by: Charlie <69320440+hal9000PR@users.noreply.github.com>

* And this other IsSleeping call

Co-authored-by: Charlie <69320440+hal9000PR@users.noreply.github.com>
2022-06-25 00:20:24 +01:00
0f7a8707ef [Ready] Refactors stuns and status effects. (#17579)
* Fixes reviver runtime

* Confusion status effect

* Dizzy status effect

* Drowsiness status effect

* decaying -> transient

* Drunkenness status effect

* why use timer when SSfastprocessing work good

* stuns (mostly)

* weaken and immobalise

* stun/weaken times

* update_flags redundancies.

* Slowed()

* Silence + fixes transient decay

* Jittery

* sleeping

* Paralyze -> weaken

* Cult sluring

* paralyse

* Stammer

* slurring + projectile cleanups

* losebreath

* Hallucination

* forgor this

* eyeblurry

* eye blind

* Druggy

* affected didn't like my spacing

* review pass

* second review pass

* some cleanups

* documentation and signal framework

* confusion fix

* Fixes spec_stun

* rejuv fix

* removes a TODO

* conflicted myself

* fixes

* self review

* review

* removes TODOs

* adminfreeze

* TM fixes

* hallucination fix + others

* tones down alchol and runtime fixes

* confusion overlay suggestion

* more fixes

* runtime fix

* losebreath fix

* clamp => directional bounded sum

* steel review

* oops

Co-authored-by: SteelSlayer <42044220+SteelSlayer@users.noreply.github.com>

* reduces the dizziness cycle rate

* borg hotfix

* sanctified decursening

Co-authored-by: mochi <1496804+dearmochi@users.noreply.github.com>
Co-authored-by: SteelSlayer <42044220+SteelSlayer@users.noreply.github.com>
2022-05-24 16:35:26 +01:00
S34NandGitHub 3cd8de4501 Prevents surgery on cult ghosts (#17514)
* prevents surgery on cult ghosts

* no choppy limb please
2022-03-24 19:21:49 +00:00
hal9000PRandGitHub 9c4b73be1e Fixes self surgery with beds (#16004)
* fix

* mochi's suggestion. added check for self surgery starting

* line
2021-05-16 09:37:25 +01:00
AffectedArc07 f2770ed6be Merge remote-tracking branch 'ParadiseSS13/master' into brutal-part1 2021-03-11 18:41:17 +00:00
Fox McCloudandGitHub 02b9445b9b Refactors DNA Mutations; Refactors Mutations to use Traits (#15483)
* Refactors Mutations

* traits

* more work

* styling fix

* yet even more work

* oh hush

* almost there

* it continues yet further

* and that's genetics done

* and that's it folks

* last bit and golem fixup

* oof

* oops

* tweaks and fixes

* styling
2021-02-21 21:25:19 +00:00
AffectedArc07 f5f97882cf BRUTAL Part 1 - No proc var/ in procs 2021-02-01 14:10:08 +00:00
Fox McCloudandvariableundefined 00f5e0613c Stamina Damage Rework (#12591) 2019-10-27 00:23:22 -04:00
Fox McCloudandvariableundefined 5194094d3a Refactors Zone Selection (#12523) 2019-10-08 21:11:09 -04:00
datlo 9f4e602881 remove extra var, floor surgery, add med gripper 2019-01-26 02:47:38 +00:00
datlo 33112e32e3 fix compile error 2019-01-26 01:50:43 +00:00
datlo fdc841be8e whole bunch of surgery changes
early cautery not compiling yet
2019-01-26 00:50:18 +00:00
variableundefinedandGitHub 96f5046f19 Merge pull request #9817 from SamHPurp/stool-bed-chair-fixes
A few fixes
2018-10-12 13:48:02 +08:00
Purpose 6c6d35d133 fixies 2018-10-11 22:02:23 +01:00
Desolate c974e29a3c global lists global defined 2018-10-02 15:52:46 -05:00
Fox McCloud aae5405d03 AGHHHHHHHHHHHHHHHHHHH WHATTT 2018-07-17 04:58:36 -04:00
Fox McCloud 27ebe7a6fe Standardized Robotic Organ Checking--Removes Mechassited Organs 2018-07-07 21:33:42 -04:00
Fox McCloud 5c4aa9b3fd Removes All Weapons 2018-04-15 16:25:56 -04:00
Aurorablade 0aaaf3a11c THESE WOUNDS THEY WILL NOT HEAL 2017-10-15 22:26:34 -04:00
TDSSSandtigercat2000 897e201775 Started on surgery stuff
Adds pain modifier to surgery if patient is conscious

Now actually compiles

Makes surgery easier if patient is drunk, allowing for easier ghetto surgery.

Now reduces failure chance if painkillers are in the patient's system.

Fixed argument spacing (hopefully)

Repairing robotic limbs no longer needs anesthesia.

Revert "Repairing robotic limbs no longer needs anesthesia."

This reverts commit 12c1f4140a.

Repairing robotic limbs doesn't cause a pain modifier, because they don't feel pain. Now actually works.

Moves typecasting from the helper proc to outside fo it and checks for sleeping.

Now correctly checks for repair to robotic limbs.

Increased effectiveness of Hydrocodone and Morphine to 99% on maintainer recommendation.
2017-10-15 15:28:13 -07:00
Fox-McCloud cb35d1f6e9 Binsult.ogg 2017-07-15 12:12:59 -04:00
Crazylemon64 7d2983b4bf Makes IPC surgery much more reliable, object insertion surgery
works better now, and `can_use` is actually called now.
2016-08-14 18:12:23 -07:00
Tigercat2000 78f53553f8 Reduce lines by removing blank lines added by PJ's script 2016-04-05 08:25:57 -07:00
Tigercat2000 9d430844c3 Replace most (if not all) output << operators with to_chat(user, message)
Currently, to_chat is literally just a proc that does user << message.
But it'll let us do output modification in the future, especially for
something like Goon's HTML chat.

Big thanks to PJB for his to_chat script, see
https://github.com/d3athrow/vgstation13/pull/6625 for more details.
2016-04-05 08:15:05 -07:00
Aurorablade c5011003bd its done
Review it, test iit locally. going to bed now, long shift at work
tomarrow.
2016-02-12 03:04:24 -05:00
Aurorablade b42d865c83 almost ready for review 2016-02-11 23:21:13 -05:00
Aurorablade e5f5b68c92 fixed slime surgery 2016-02-07 00:54:46 -05:00
Aurorablade e1899e4af9 almost 2016-02-06 18:42:26 -05:00
Aurorablade 0fc841f0f9 can i sleep uyet 2016-02-03 00:40:10 -05:00
Aurorablade e926935703 onward to merge conflicts! 2016-02-02 02:57:39 -05:00
Aurorablade c4d151ce34 you buy organ, yaya?
Is fresh.
2016-01-30 21:37:55 -05:00
Aurorablade 42d8ac68b5 xeno organ fail still... 2016-01-22 22:01:24 -05:00
Aurorablade cc8f402a4d progress
xeno organ abiltys not working on insert (on non xeno mob)
Limb attachment for robot parts being stupid
2016-01-21 20:42:32 -05:00
Aurorablade 678a2e9f4e commit so i can go bugfix and do other things
besides code in organs...tell me what i did wrong!
2016-01-09 00:05:25 -05:00
Aurorablade 87d2023af3 so you can almost perform surgery with a claymore
things needed: Addeing the sharp object used as a low success allowed
tool on the fly. Handleing advanced scalpals.
2016-01-07 23:25:06 -05:00
Aurorablade 2623f75e0d progress 2016-01-06 23:43:12 -05:00
Aurorablade 948adea83b Added Asses as an organ
...made you look...
seriously though, refined some surgery datums/steps and commiting so i
can go bugfix some stuff...and a sidequest...i need to adjust return
values.
2016-01-04 08:25:39 -05:00
Aurorablade 92e15c1b2a BREAK ALL THE THINGS 2015-12-31 01:23:44 -05:00