From fdb6e27c652ff3bf3907d0ee1331c7b1f0761269 Mon Sep 17 00:00:00 2001 From: Token <56667933+TokenStyle@users.noreply.github.com> Date: Sat, 23 Nov 2024 02:20:55 +0500 Subject: [PATCH] =?UTF-8?q?=D0=A5=D0=B8=D1=80=D1=83=D1=80=D0=B3=D0=B8?= =?UTF-8?q?=D1=8F=20(=D0=BF=D0=BE=D0=BF=D1=8B=D1=82=D0=BA=D0=B0=202)=20(#6?= =?UTF-8?q?5)?= MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit * The ShitMed * Fixes fix locale * Delete redudant systems * fix components * fix error, update system * Update BodyPartComponent.cs * fix max health, fix test legs * fix test * Port fixes from EE (#875) * [Fix] Healing Fixes (#874) * Targeting & Healing Fixes * Update Content.Server/Medical/HealingSystem.cs Co-authored-by: gluesniffler <159397573+gluesniffler@users.noreply.github.com> * Fix Vital Damage * Update BodyPartComponent.cs * fix --------- Co-authored-by: gluesniffler <159397573+gluesniffler@users.noreply.github.com> * [Port] Surgery fixes: Part 2 (#876) * Fix a ton of shitmed Fixed a buncho crap * Guidebook * Russian Locale * fix * hotfix added https://github.com/Rxup/space-station-14/commit/e92f0132c17b4f565030fb58cc52f41652d1d169 --------- Co-authored-by: gluesniffler Co-authored-by: Zack Backmen Co-authored-by: Token * remove backmen ccvar * Body doll in the Health Analyzer menu (#877) * fixes and fix guidebook paths (#887) * fixes * Added some experimental lag fixes to surgery. Might have crashes * russian locale * Revert "Added some experimental lag fixes to surgery. Might have crashes" This reverts commit de95d851a3f2c909a8d1dc1dde3f554fdae7057d. * [Port] Surgery fixes: Part 3 (#892) * Added some experimental lag fixes to surgery. Might have crashes * Fix * migrate and add comments to shit * fix --------- Co-authored-by: gluesniffler * [Tweak] Rework BodyPartComponent to use DamageSpecifier (#890) * Rework BodyPart to use DamageSpecifier * Fix that shit * Update Content.Shared/Backmen/Surgery/Body/SharedBodySystem.Integrity.cs Co-authored-by: gluesniffler <159397573+gluesniffler@users.noreply.github.com> * Uh? * Update HealthAnalyzerWindow.xaml.cs * balanced a buncho crap --------- Co-authored-by: gluesniffler <159397573+gluesniffler@users.noreply.github.com> * [Port] Surgery fixes: Part 4 (#909) * defelinization almost real * fix? * Corvax next fix that surgery doesn't work with fatal error --------- Co-authored-by: gluesniffler Roudenn: https://github.com/Rxup/space-station-14/pull/909 * [Fix] surgery emergency fix * Fixed mechanics of attaching body parts to Body. (now taken from prototypes, not generated at random) --------- Co-authored-by: gluesniffler KayzelW: https://github.com/Rxup/space-station-14/pull/912 * [Balance] Surgery healing tweaks (#911) * Balance surgery * Fix Severing parts --------- Co-authored-by: gluesniffler Roudenn: https://github.com/Rxup/space-station-14/pull/911 * [Port] Surgery Update V: The Phantom Gib (#919) * Megasquached Surgery Updates Megasquached Surgery Updates Quick patch to see if tests shut up Refactored body parts to use damageablecomponent newmed health analyzer real, also refactors and some bugfixes * added solidus's comments, pending removal of namespace thingies for this repo, also fixed some healing thingies * fixes? * fix gib torso * fix prototypes * oops --------- Co-authored-by: gluesniffler Co-authored-by: Zack Backmen Roudenn: https://github.com/Rxup/space-station-14/pull/919 * let me pass tests * let me pass test pls * let me pass test pls * let me pass tests * chief medical officer pass tests * no felinid ears no fun pass tests * [Port] Surgery Fixes: Popup Walker (#923) * Megasquached Surgery Updates Megasquached Surgery Updates Quick patch to see if tests shut up Please do not cherrypick this one yet. Refactored body parts to use damageablecomponent newmed health analyzer real, also refactors and some bugfixes * added solidus's comments, pending removal of namespace thingies for this repo, also fixed some healing thingies * fixes? * fix gib torso * fix prototypes * oops * Shitmed Update 1 (#1240) First in a series of PRs to introduce bugfixes and updates to Shitmed, this will generally feature PRs from Goobstation or Backmen as well since they are actively helping me maintain the code. Usual Shoutouts: Deltanedas: https://github.com/Goob-Station/Goob-Station/pull/882 --- :cl: Mocho, Deltanedas - add: You can now perform surgery as a monke. Rejoice. - add: You can perform surgery on a lot of animals now, I missed a lot of them so just ask if you want any particular critter to get it. - tweak: Entities now perish after 60 seconds of losing their heart and/or brain. - fix: Entities properly take asphyxiation damage after losing their brain. - fix: Torsos being gibbable, which would break surgery or just about anything. - fix: Items not being removed from their respective slots if the parts were gibbed rather than dropped. - fix: Animal organs not being usable properly in surgeries - fix: Cyborg limbs are now usable as pseudo-peg arm/legs. --------- Signed-off-by: gluesniffler <159397573+gluesniffler@users.noreply.github.com> Co-authored-by: FoxxoTrystan <45297731+FoxxoTrystan@users.noreply.github.com> Co-authored-by: goet <6637097+goet@users.noreply.github.com> Co-authored-by: Saphire Lattice Co-authored-by: Roudenn <149893554+Roudenn@users.noreply.github.com> * Shitmed Surgery Popups (#1241) Adds popups for surgery steps in Shitmed that every player within PVS range can see. This allows other players to see if the correct procedure is being performed. This PR also includes locale text for the new procedures and steps in #1240. **Remove Brain / Insert Brain** https://github.com/user-attachments/assets/ac20afa1-df74-48ab-b1d5-2e9a273dfba2
See more **Amputate Right Arm** https://github.com/user-attachments/assets/17f78683-6d3b-44ee-aea3-bb6987844fdc **Attach Right Arm** https://github.com/user-attachments/assets/584d4da2-d8b0-4c82-a323-26636e7fa4b8
:cl: Skubman - add: Surgery step descriptions (like making an incision, removing/attaching limbs and organs) are now shown as popups to everyone in range upon the start of the step. This makes it clear which surgical procedure is being done and to which body part. No more stealthy brain-stealing in front of everyone! * fix the things + locale --------- Signed-off-by: gluesniffler <159397573+gluesniffler@users.noreply.github.com> Co-authored-by: gluesniffler Co-authored-by: Zack Backmen Co-authored-by: gluesniffler <159397573+gluesniffler@users.noreply.github.com> Co-authored-by: FoxxoTrystan <45297731+FoxxoTrystan@users.noreply.github.com> Co-authored-by: goet <6637097+goet@users.noreply.github.com> Co-authored-by: Saphire Lattice Co-authored-by: Skubman * [PORT]Health Analyzer update (#925) Add amazing Health analyzer UI. https://github.com/Rxup/space-station-14/pull/925 * Update HealthAnalyzerSystem.cs * Update medical-scanner-component.ftl * Update HealthAnalyzerWindow.xaml.cs * Update health-analyzer-component.ftl * fix --------- Co-authored-by: trest100 <144359854+trest100@users.noreply.github.com> * let me pass tests * remove shadowkin let tests pass * first commit * Revert "first commit" formatting changes Reverted only formats though, being saved moves everythin to appropriate folders, and nice and clean This reverts commit e66b04b5244516f2abfd50da41fbe133d76bf467. * add corvax next comments for changes for easier upstreams Be aware though, that everything that related to BodySystem, OrganComponent, DamageSystem etc was changed completely - add comments _CorvaxNext - moved .ftl files and cvars to appropriate Corvax Next folders - removed unnecessary felinids and silicon_base * namespaces changes for everythin * Revert "namespaces changes for everythin" This reverts commit 221ee3eecbb3d379aaef4170ceca6bffb15ace36. * [Fix] Surgery Hotfix: Head and Limbs dissapears --------- Signed-off-by: gluesniffler <159397573+gluesniffler@users.noreply.github.com> Co-authored-by: gluesniffler Co-authored-by: Roudenn Co-authored-by: Zack Backmen Co-authored-by: Rouden <149893554+Roudenn@users.noreply.github.com> Co-authored-by: gluesniffler <159397573+gluesniffler@users.noreply.github.com> Co-authored-by: FoxxoTrystan <45297731+FoxxoTrystan@users.noreply.github.com> Co-authored-by: goet <6637097+goet@users.noreply.github.com> Co-authored-by: Saphire Lattice Co-authored-by: Skubman Co-authored-by: Trest <144359854+trest100@users.noreply.github.com> Co-authored-by: AwareFoxy Co-authored-by: AwareFoxy <135021509+AwareFoxy@users.noreply.github.com> --- Content.Client/Body/Systems/BodySystem.cs | 7 - Content.Client/Hands/Systems/HandsSystem.cs | 37 +- .../UI/HealthAnalyzerBoundUserInterface.cs | 31 +- .../UI/HealthAnalyzerWindow.xaml | 222 ++++- .../UI/HealthAnalyzerWindow.xaml.cs | 146 +++- .../Humanoid/HumanoidAppearanceSystem.cs | 8 +- Content.Client/Input/ContentContexts.cs | 6 + .../Inventory/ClientInventorySystem.cs | 15 +- .../Inventory/InventorySlotsComponent.cs | 2 +- .../Options/UI/Tabs/KeyRebindTab.xaml.cs | 10 + Content.Client/Stylesheets/StyleNano.cs | 55 ++ .../Screens/DefaultGameScreen.xaml | 2 + .../Screens/DefaultGameScreen.xaml.cs | 1 + .../Screens/SeparatedChatGameScreen.xaml | 2 + .../Screens/SeparatedChatGameScreen.xaml.cs | 1 + .../Systems/Alerts/Widgets/AlertsUI.xaml | 10 +- .../Inventory/InventoryUIController.cs | 4 +- .../Xenonids/UI/XenoChoiceControl.xaml | 19 + .../Xenonids/UI/XenoChoiceControl.xaml.cs | 28 + Content.Client/_CorvaxNext/Body/BodySystem.cs | 72 ++ .../Body/Components/BrainComponent.cs | 4 + .../Body/Components/LungComponent.cs | 4 + .../Body/Components/StomachComponent.cs | 4 + .../_CorvaxNext/Surgery/SurgeryBui.cs | 360 ++++++++ .../Surgery/SurgeryStepButton.xaml | 4 + .../Surgery/SurgeryStepButton.xaml.cs | 16 + .../_CorvaxNext/Surgery/SurgerySystem.cs | 11 + .../_CorvaxNext/Surgery/SurgeryWindow.xaml | 23 + .../_CorvaxNext/Surgery/SurgeryWindow.xaml.cs | 14 + .../_CorvaxNext/Targeting/TargetingSystem.cs | 101 +++ .../PartStatus/PartStatusUIController.cs | 80 ++ .../PartStatus/Widgets/PartStatusControl.xaml | 57 ++ .../Widgets/PartStatusControl.xaml.cs | 48 ++ .../Targeting/TargetingUIController.cs | 81 ++ .../Targeting/Widgets/TargetingControl.xaml | 218 +++++ .../Widgets/TargetingControl.xaml.cs | 58 ++ .../Atmos/EntitySystems/BarotraumaSystem.cs | 5 +- Content.Server/Body/Systems/BodySystem.cs | 73 +- Content.Server/Body/Systems/BrainSystem.cs | 34 +- .../Body/Systems/RespiratorSystem.cs | 10 +- .../Thresholds/Behaviors/GibBehavior.cs | 5 +- .../Thresholds/Behaviors/GibPartBehavior.cs | 20 + .../EntityEffects/Effects/HealthChange.cs | 8 +- Content.Server/Hands/Systems/HandsSystem.cs | 50 +- .../Components/HealthAnalyzerComponent.cs | 8 + Content.Server/Medical/CryoPodSystem.cs | 1 + Content.Server/Medical/HealingSystem.cs | 30 +- .../Medical/HealthAnalyzerSystem.cs | 79 +- .../DelayedDeath/DelayedDeathComponent.cs | 16 + .../DelayedDeath/DelayedDeathSystem.cs | 32 + .../_CorvaxNext/Surgery/SurgerySystem.cs | 177 ++++ .../_CorvaxNext/Systems/HeartSystem.cs | 40 + .../_CorvaxNext/Targeting/TargetingSystem.cs | 53 ++ Content.Shared/Body/Organ/OrganComponent.cs | 30 +- Content.Shared/Body/Organ/TailComponent.cs | 8 + Content.Shared/Body/Part/BodyPartComponent.cs | 105 ++- Content.Shared/Body/Part/BodyPartEvents.cs | 24 + .../Body/Systems/SharedBodySystem.Body.cs | 124 ++- .../Body/Systems/SharedBodySystem.Organs.cs | 19 + .../Body/Systems/SharedBodySystem.Parts.cs | 281 ++++++- .../Body/Systems/SharedBodySystem.cs | 5 +- Content.Shared/Corvax/CCCVars/CCCVars.cs | 2 +- .../Damage/Systems/DamageOnInteractSystem.cs | 19 +- .../Damage/Systems/DamageableSystem.cs | 51 +- .../Hands/Components/HandsComponent.cs | 1 + .../Events/ProfileLoadFinishedEvent.cs | 8 + .../Humanoid/HumanoidVisualLayersExtension.cs | 12 + .../SharedHumanoidAppearanceSystem.cs | 4 +- Content.Shared/Input/ContentKeyFunctions.cs | 6 + .../Inventory/InventoryComponent.cs | 1 + .../Inventory/InventorySystem.Slots.cs | 46 +- .../Inventory/InventoryTemplatePrototype.cs | 7 + .../HealthAnalyzerScannedUserMessage.cs | 17 +- .../Systems/MobStateSystem.StateMachine.cs | 8 +- .../StatusEffect/StatusEffectsSystem.cs | 2 +- .../Weapons/Melee/MeleeWeaponComponent.cs | 30 +- .../Weapons/Melee/SharedMeleeWeaponSystem.cs | 4 +- Content.Shared/_CorvaxNext/NextVars.cs | 10 + .../Surgery/Body/AmputateAttemptEvent.cs | 7 + .../Body/BodyPartAppearanceComponent.cs | 44 + .../Surgery/Body/DebrainedComponent.cs | 6 + .../Surgery/Body/Organs/EarsComponent.cs | 6 + .../Surgery/Body/Organs/EyesComponent.cs | 6 + .../Surgery/Body/Organs/HeartComponent.cs | 6 + .../Surgery/Body/Organs/LiverComponent.cs | 6 + .../Body/Organs/MarkingContainerComponent.cs | 15 + .../Body/SharedBodySystem.PartAppearance.cs | 194 +++++ .../Body/SharedBodySystem.Targeting.cs | 500 ++++++++++++ .../SurgeryCloseIncisionConditionComponent.cs | 6 + .../SurgeryLarvaConditionComponent.cs | 6 + .../SurgeryMarkingConditionComponent.cs | 27 + ...SurgeryOperatingTableConditionComponent.cs | 6 + .../SurgeryOrganConditionComponent.cs | 18 + .../SurgeryPartConditionComponent.cs | 17 + .../Conditions/SurgeryPartPresentCondition.cs | 6 + .../SurgeryPartRemovedConditionComponent.cs | 20 + .../Surgery/Conditions/SurgeryValidEvent.cs | 9 + .../SurgeryWoundedConditionComponent.cs | 7 + .../Effects/Complete/SurgeryCompletedEvent.cs | 7 + .../Complete/SurgeryRemoveLarvaComponent.cs | 6 + .../SurgeryDamageChangeEffectComponent.cs | 17 + ...rgerySpecialDamageChangeEffectComponent.cs | 14 + .../Step/SurgeryStepCavityEffectComponent.cs | 10 + .../Step/SurgeryStepEmoteEffectComponent.cs | 12 + .../Effects/Step/SurgeryStepSpawnEffect.cs | 13 + .../Step/SurgeryTendWoundsEffectComponent.cs | 20 + .../Surgery/OperatingTableComponent.cs | 6 + .../Surgery/SharedSurgerySystem.Steps.cs | 772 ++++++++++++++++++ .../Surgery/SharedSurgerySystem.cs | 287 +++++++ .../_CorvaxNext/Surgery/StepInvalidReason.cs | 10 + .../Steps/Parts/BleedersClampedComponent.cs | 6 + .../Parts/BodyPartReattachedComponent.cs | 6 + .../Steps/Parts/BodyPartSawedComponent.cs | 6 + .../Steps/Parts/IncisionOpenComponent.cs | 6 + .../Parts/InternalBleedersClampedComponent.cs | 6 + .../Steps/Parts/OrganReattachedComponent.cs | 6 + .../Steps/Parts/PartRemovedComponent.cs | 6 + .../Steps/Parts/RibcageOpenComponent.cs | 6 + .../Steps/Parts/RibcageSawedComponent.cs | 6 + .../Steps/Parts/SkinRetractedComponent.cs | 6 + .../Steps/SurgeryAddMarkingStepComponent.cs | 34 + .../Steps/SurgeryAddOrganStepComponent.cs | 6 + .../Steps/SurgeryAddPartStepComponent.cs | 6 + .../Steps/SurgeryAffixOrganStepComponent.cs | 6 + .../Steps/SurgeryAffixPartStepComponent.cs | 6 + .../Steps/SurgeryCanPerformStepEvent.cs | 14 + .../SurgeryCutLarvaRootsStepComponent.cs | 6 + .../SurgeryRemoveMarkingStepComponent.cs | 29 + .../Steps/SurgeryRemoveOrganStepComponent.cs | 6 + .../Steps/SurgeryRemovePartStepComponent.cs | 6 + .../Steps/SurgeryRepeatableStepComponent.cs | 6 + .../Steps/SurgeryStepCompleteCheckEvent.cs | 4 + .../Surgery/Steps/SurgeryStepComponent.cs | 22 + .../_CorvaxNext/Surgery/SurgeryComponent.cs | 18 + .../Surgery/SurgeryDoAfterEvent.cs | 18 + .../Surgery/SurgerySpeedModifierComponent.cs | 11 + .../Surgery/SurgeryStepDamageChangeEvent.cs | 9 + .../Surgery/SurgeryStepDamageEvent.cs | 9 + .../_CorvaxNext/Surgery/SurgeryStepEvent.cs | 7 + .../Surgery/SurgeryTargetComponent.cs | 10 + .../_CorvaxNext/Surgery/SurgeryUI.cs | 32 + .../Surgery/SurgeryUiRefreshEvent.cs | 14 + .../Surgery/Tools/BoneGelComponent.cs | 11 + .../Surgery/Tools/BoneSawComponent.cs | 10 + .../Surgery/Tools/BoneSetterComponent.cs | 6 + .../Surgery/Tools/CauteryComponent.cs | 10 + .../Surgery/Tools/HemostatComponent.cs | 10 + .../Surgery/Tools/ISurgeryToolComponent.cs | 11 + .../Surgery/Tools/RetractorComponent.cs | 10 + .../Surgery/Tools/ScalpelComponent.cs | 10 + .../Surgery/Tools/SurgeryToolComponent.cs | 16 + .../Surgery/Tools/SurgicalDrillComponent.cs | 10 + .../_CorvaxNext/Targeting/Events.cs | 37 + .../Targeting/SharedTargetingSystem.cs | 27 + .../_CorvaxNext/Targeting/TargetBodyPart.cs | 30 + .../_CorvaxNext/Targeting/TargetIntegrity.cs | 13 + .../Targeting/TargetingComponent.cs | 57 ++ .../Audio/Medical/Surgery/attributions.yml | 49 ++ Resources/Audio/Medical/Surgery/cautery1.ogg | Bin 0 -> 34770 bytes Resources/Audio/Medical/Surgery/cautery2.ogg | Bin 0 -> 16854 bytes Resources/Audio/Medical/Surgery/hemostat1.ogg | Bin 0 -> 15729 bytes Resources/Audio/Medical/Surgery/organ1.ogg | Bin 0 -> 18912 bytes Resources/Audio/Medical/Surgery/organ2.ogg | Bin 0 -> 18946 bytes .../Audio/Medical/Surgery/retractor1.ogg | Bin 0 -> 11537 bytes .../Audio/Medical/Surgery/retractor2.ogg | Bin 0 -> 9915 bytes Resources/Audio/Medical/Surgery/saw.ogg | Bin 0 -> 46750 bytes Resources/Audio/Medical/Surgery/scalpel1.ogg | Bin 0 -> 13736 bytes Resources/Audio/Medical/Surgery/scalpel2.ogg | Bin 0 -> 13098 bytes .../en-US/_corvaxnext/guidebook/guides.ftl | 4 + .../_corvaxnext/surgery/surgery-popup.ftl | 52 ++ .../en-US/_corvaxnext/surgery/surgery-ui.ftl | 12 + .../en-US/escape-menu/ui/options-menu.ftl | 8 + .../ru-RU/_corvaxnext/guidebook/guides.ftl | 4 + .../_corvaxnext/surgery/surgery-items.ftl | 33 + .../surgery/surgery-operations.ftl | 61 ++ .../_corvaxnext/surgery/surgery-popup.ftl | 52 ++ .../ru-RU/_corvaxnext/surgery/surgery-ui.ftl | 20 + .../components/health-analyzer-component.ftl | 2 +- .../components/medical-scanner-component.ftl | 1 + .../furniture/tables/operating_table.ftl | 2 +- .../Prototypes/Body/Organs/Animal/animal.yml | 7 + .../Prototypes/Body/Organs/Animal/slimes.yml | 4 + Resources/Prototypes/Body/Organs/arachnid.yml | 19 +- Resources/Prototypes/Body/Organs/diona.yml | 19 +- Resources/Prototypes/Body/Organs/human.yml | 353 ++++---- Resources/Prototypes/Body/Organs/moth.yml | 1 + Resources/Prototypes/Body/Organs/slime.yml | 4 + Resources/Prototypes/Body/Organs/vox.yml | 1 + Resources/Prototypes/Body/Parts/animal.yml | 12 +- Resources/Prototypes/Body/Parts/base.yml | 60 +- Resources/Prototypes/Body/Parts/silicon.yml | 13 +- Resources/Prototypes/Body/Parts/skeleton.yml | 36 +- Resources/Prototypes/Body/Parts/vox.yml | 2 +- .../Prototypes/Body/Prototypes/a_ghost.yml | 16 +- .../Prototypes/Body/Prototypes/arachnid.yml | 1 + .../Prototypes/Body/Prototypes/diona.yml | 1 + .../Prototypes/Body/Prototypes/dwarf.yml | 1 + .../Body/Prototypes/gingerbread.yml | 1 + .../Prototypes/Body/Prototypes/human.yml | 33 +- Resources/Prototypes/Body/Prototypes/moth.yml | 1 + .../Prototypes/Body/Prototypes/primate.yml | 8 + .../Prototypes/Body/Prototypes/reptilian.yml | 1 + .../Prototypes/Body/Prototypes/skeleton.yml | 1 + .../Prototypes/Body/Prototypes/slime.yml | 1 + Resources/Prototypes/Body/Prototypes/vox.yml | 1 + .../Catalog/Fills/Backpacks/duffelbag.yml | 2 + .../Catalog/Fills/Crates/medical.yml | 6 +- .../Entities/Clothing/Belt/belts.yml | 2 +- .../Prototypes/Entities/Mobs/NPCs/animals.yml | 49 +- .../Prototypes/Entities/Mobs/NPCs/carp.yml | 5 + .../Entities/Mobs/NPCs/regalrat.yml | 13 +- .../Prototypes/Entities/Mobs/NPCs/slimes.yml | 7 + .../Prototypes/Entities/Mobs/Species/base.yml | 5 + .../Entities/Mobs/Species/skeleton.yml | 3 +- .../Entities/Mobs/Species/slime.yml | 2 + .../Objects/Specific/Medical/surgery.yml | 115 ++- .../Furniture/Tables/operating_table.yml | 1 + .../Entities/Structures/Machines/lathe.yml | 1 + .../Prototypes/EntityLists/Tools/surgery.yml | 8 +- Resources/Prototypes/Guidebook/medical.yml | 29 + Resources/Prototypes/Reagents/gases.yml | 16 +- .../Prototypes/Roles/Jobs/Medical/chemist.yml | 8 + .../Jobs/Medical/chief_medical_officer.yml | 7 +- .../Roles/Jobs/Medical/medical_doctor.yml | 8 + .../Roles/Jobs/Medical/medical_intern.yml | 8 + .../Roles/Jobs/Medical/paramedic.yml | 8 + .../_CorvaxNext/Damage/containers.yml | 5 + .../_CorvaxNext/Damage/modifier_sets.yml | 11 + .../_CorvaxNext/Entities/Machines/lathe.yml | 42 + .../Objects/Circuitboards/production.yml | 13 + .../Objects/Specific/Medical/surgery.yml | 76 ++ .../Entities/Surgery/surgeries.yml | 642 +++++++++++++++ .../Entities/Surgery/surgery_steps.yml | 570 +++++++++++++ .../_CorvaxNext/Recipes/Lathes/surgery.yml | 91 +++ .../Guidebook/Medical/OrganManipulation.xml | 50 ++ .../Guidebook/Medical/PartManipulation.xml | 51 ++ .../Corvax/Guidebook/Medical/Surgery.xml | 40 + .../Guidebook/Medical/UtilitySurgeries.xml | 24 + .../Textures/Interface/Ashen/target_doll.png | Bin 0 -> 422 bytes .../Interface/Clockwork/target_doll.png | Bin 0 -> 1219 bytes .../Interface/Default/target_doll.png | Bin 0 -> 422 bytes .../Interface/Minimalist/target_doll.png | Bin 0 -> 422 bytes .../Interface/Plasmafire/target_doll.png | Bin 0 -> 462 bytes .../Textures/Interface/Retro/target_doll.png | Bin 0 -> 383 bytes .../Interface/Slimecore/target_doll.png | Bin 0 -> 422 bytes .../Interface/Targeting/Doll/eyes.png | Bin 0 -> 5227 bytes .../Interface/Targeting/Doll/eyes_hover.png | Bin 0 -> 6856 bytes .../Interface/Targeting/Doll/groin.png | Bin 0 -> 5485 bytes .../Interface/Targeting/Doll/groin_hover.png | Bin 0 -> 6452 bytes .../Interface/Targeting/Doll/head.png | Bin 0 -> 5663 bytes .../Interface/Targeting/Doll/head_hover.png | Bin 0 -> 7153 bytes .../Interface/Targeting/Doll/leftarm.png | Bin 0 -> 5779 bytes .../Targeting/Doll/leftarm_hover.png | Bin 0 -> 6652 bytes .../Interface/Targeting/Doll/leftfoot.png | Bin 0 -> 5462 bytes .../Targeting/Doll/leftfoot_hover.png | Bin 0 -> 5476 bytes .../Interface/Targeting/Doll/lefthand.png | Bin 0 -> 5462 bytes .../Targeting/Doll/lefthand_hover.png | Bin 0 -> 6174 bytes .../Interface/Targeting/Doll/leftleg.png | Bin 0 -> 5488 bytes .../Targeting/Doll/leftleg_hover.png | Bin 0 -> 6185 bytes .../Interface/Targeting/Doll/mouth.png | Bin 0 -> 5219 bytes .../Interface/Targeting/Doll/mouth_hover.png | Bin 0 -> 5208 bytes .../Interface/Targeting/Doll/rightarm.png | Bin 0 -> 5773 bytes .../Targeting/Doll/rightarm_hover.png | Bin 0 -> 6592 bytes .../Interface/Targeting/Doll/rightfoot.png | Bin 0 -> 5454 bytes .../Targeting/Doll/rightfoot_hover.png | Bin 0 -> 5465 bytes .../Interface/Targeting/Doll/righthand.png | Bin 0 -> 5467 bytes .../Targeting/Doll/righthand_hover.png | Bin 0 -> 6207 bytes .../Interface/Targeting/Doll/rightleg.png | Bin 0 -> 5473 bytes .../Targeting/Doll/rightleg_hover.png | Bin 0 -> 5908 bytes .../Interface/Targeting/Doll/torso.png | Bin 0 -> 5284 bytes .../Interface/Targeting/Doll/torso_hover.png | Bin 0 -> 5672 bytes .../Targeting/Status/groin.rsi/groin_0.png | Bin 0 -> 157 bytes .../Targeting/Status/groin.rsi/groin_1.png | Bin 0 -> 157 bytes .../Targeting/Status/groin.rsi/groin_2.png | Bin 0 -> 157 bytes .../Targeting/Status/groin.rsi/groin_3.png | Bin 0 -> 157 bytes .../Targeting/Status/groin.rsi/groin_4.png | Bin 0 -> 157 bytes .../Targeting/Status/groin.rsi/groin_5.png | Bin 0 -> 157 bytes .../Targeting/Status/groin.rsi/groin_6.png | Bin 0 -> 157 bytes .../Targeting/Status/groin.rsi/groin_7.png | Bin 0 -> 157 bytes .../Targeting/Status/groin.rsi/groin_8.png | Bin 0 -> 178 bytes .../Targeting/Status/groin.rsi/meta.json | 38 + .../Targeting/Status/head.rsi/head_0.png | Bin 0 -> 140 bytes .../Targeting/Status/head.rsi/head_1.png | Bin 0 -> 140 bytes .../Targeting/Status/head.rsi/head_2.png | Bin 0 -> 140 bytes .../Targeting/Status/head.rsi/head_3.png | Bin 0 -> 140 bytes .../Targeting/Status/head.rsi/head_4.png | Bin 0 -> 140 bytes .../Targeting/Status/head.rsi/head_5.png | Bin 0 -> 140 bytes .../Targeting/Status/head.rsi/head_6.png | Bin 0 -> 140 bytes .../Targeting/Status/head.rsi/head_7.png | Bin 0 -> 140 bytes .../Targeting/Status/head.rsi/head_8.png | Bin 0 -> 155 bytes .../Targeting/Status/head.rsi/meta.json | 38 + .../Status/leftarm.rsi/leftarm_0.png | Bin 0 -> 144 bytes .../Status/leftarm.rsi/leftarm_1.png | Bin 0 -> 144 bytes .../Status/leftarm.rsi/leftarm_2.png | Bin 0 -> 144 bytes .../Status/leftarm.rsi/leftarm_3.png | Bin 0 -> 144 bytes .../Status/leftarm.rsi/leftarm_4.png | Bin 0 -> 144 bytes .../Status/leftarm.rsi/leftarm_5.png | Bin 0 -> 144 bytes .../Status/leftarm.rsi/leftarm_6.png | Bin 0 -> 144 bytes .../Status/leftarm.rsi/leftarm_7.png | Bin 0 -> 144 bytes .../Status/leftarm.rsi/leftarm_8.png | Bin 0 -> 154 bytes .../Targeting/Status/leftarm.rsi/meta.json | 38 + .../Status/leftfoot.rsi/leftfoot_0.png | Bin 0 -> 145 bytes .../Status/leftfoot.rsi/leftfoot_1.png | Bin 0 -> 145 bytes .../Status/leftfoot.rsi/leftfoot_2.png | Bin 0 -> 145 bytes .../Status/leftfoot.rsi/leftfoot_3.png | Bin 0 -> 145 bytes .../Status/leftfoot.rsi/leftfoot_4.png | Bin 0 -> 145 bytes .../Status/leftfoot.rsi/leftfoot_5.png | Bin 0 -> 145 bytes .../Status/leftfoot.rsi/leftfoot_6.png | Bin 0 -> 145 bytes .../Status/leftfoot.rsi/leftfoot_7.png | Bin 0 -> 145 bytes .../Status/leftfoot.rsi/leftfoot_8.png | Bin 0 -> 166 bytes .../Targeting/Status/leftfoot.rsi/meta.json | 38 + .../Status/lefthand.rsi/lefthand_0.png | Bin 0 -> 136 bytes .../Status/lefthand.rsi/lefthand_1.png | Bin 0 -> 136 bytes .../Status/lefthand.rsi/lefthand_2.png | Bin 0 -> 136 bytes .../Status/lefthand.rsi/lefthand_3.png | Bin 0 -> 136 bytes .../Status/lefthand.rsi/lefthand_4.png | Bin 0 -> 136 bytes .../Status/lefthand.rsi/lefthand_5.png | Bin 0 -> 136 bytes .../Status/lefthand.rsi/lefthand_6.png | Bin 0 -> 136 bytes .../Status/lefthand.rsi/lefthand_7.png | Bin 0 -> 136 bytes .../Status/lefthand.rsi/lefthand_8.png | Bin 0 -> 152 bytes .../Targeting/Status/lefthand.rsi/meta.json | 38 + .../Status/leftleg.rsi/leftleg_0.png | Bin 0 -> 141 bytes .../Status/leftleg.rsi/leftleg_1.png | Bin 0 -> 141 bytes .../Status/leftleg.rsi/leftleg_2.png | Bin 0 -> 141 bytes .../Status/leftleg.rsi/leftleg_3.png | Bin 0 -> 141 bytes .../Status/leftleg.rsi/leftleg_4.png | Bin 0 -> 141 bytes .../Status/leftleg.rsi/leftleg_5.png | Bin 0 -> 141 bytes .../Status/leftleg.rsi/leftleg_6.png | Bin 0 -> 141 bytes .../Status/leftleg.rsi/leftleg_7.png | Bin 0 -> 141 bytes .../Status/leftleg.rsi/leftleg_8.png | Bin 0 -> 170 bytes .../Targeting/Status/leftleg.rsi/meta.json | 38 + .../Targeting/Status/rightarm.rsi/meta.json | 38 + .../Status/rightarm.rsi/rightarm_0.png | Bin 0 -> 147 bytes .../Status/rightarm.rsi/rightarm_1.png | Bin 0 -> 147 bytes .../Status/rightarm.rsi/rightarm_2.png | Bin 0 -> 147 bytes .../Status/rightarm.rsi/rightarm_3.png | Bin 0 -> 147 bytes .../Status/rightarm.rsi/rightarm_4.png | Bin 0 -> 147 bytes .../Status/rightarm.rsi/rightarm_5.png | Bin 0 -> 147 bytes .../Status/rightarm.rsi/rightarm_6.png | Bin 0 -> 147 bytes .../Status/rightarm.rsi/rightarm_7.png | Bin 0 -> 147 bytes .../Status/rightarm.rsi/rightarm_8.png | Bin 0 -> 158 bytes .../Targeting/Status/rightfoot.rsi/meta.json | 38 + .../Status/rightfoot.rsi/rightfoot_0.png | Bin 0 -> 176 bytes .../Status/rightfoot.rsi/rightfoot_1.png | Bin 0 -> 144 bytes .../Status/rightfoot.rsi/rightfoot_2.png | Bin 0 -> 144 bytes .../Status/rightfoot.rsi/rightfoot_3.png | Bin 0 -> 144 bytes .../Status/rightfoot.rsi/rightfoot_4.png | Bin 0 -> 144 bytes .../Status/rightfoot.rsi/rightfoot_5.png | Bin 0 -> 144 bytes .../Status/rightfoot.rsi/rightfoot_6.png | Bin 0 -> 144 bytes .../Status/rightfoot.rsi/rightfoot_7.png | Bin 0 -> 144 bytes .../Status/rightfoot.rsi/rightfoot_8.png | Bin 0 -> 161 bytes .../Targeting/Status/righthand.rsi/meta.json | 38 + .../Status/righthand.rsi/righthand_0.png | Bin 0 -> 138 bytes .../Status/righthand.rsi/righthand_1.png | Bin 0 -> 138 bytes .../Status/righthand.rsi/righthand_2.png | Bin 0 -> 138 bytes .../Status/righthand.rsi/righthand_3.png | Bin 0 -> 138 bytes .../Status/righthand.rsi/righthand_4.png | Bin 0 -> 138 bytes .../Status/righthand.rsi/righthand_5.png | Bin 0 -> 138 bytes .../Status/righthand.rsi/righthand_6.png | Bin 0 -> 138 bytes .../Status/righthand.rsi/righthand_7.png | Bin 0 -> 138 bytes .../Status/righthand.rsi/righthand_8.png | Bin 0 -> 152 bytes .../Targeting/Status/rightleg.rsi/meta.json | 38 + .../Status/rightleg.rsi/rightleg_0.png | Bin 0 -> 178 bytes .../Status/rightleg.rsi/rightleg_1.png | Bin 0 -> 141 bytes .../Status/rightleg.rsi/rightleg_2.png | Bin 0 -> 141 bytes .../Status/rightleg.rsi/rightleg_3.png | Bin 0 -> 141 bytes .../Status/rightleg.rsi/rightleg_4.png | Bin 0 -> 141 bytes .../Status/rightleg.rsi/rightleg_5.png | Bin 0 -> 141 bytes .../Status/rightleg.rsi/rightleg_6.png | Bin 0 -> 141 bytes .../Status/rightleg.rsi/rightleg_7.png | Bin 0 -> 141 bytes .../Status/rightleg.rsi/rightleg_8.png | Bin 0 -> 166 bytes .../Targeting/Status/torso.rsi/meta.json | 38 + .../Targeting/Status/torso.rsi/torso_0.png | Bin 0 -> 160 bytes .../Targeting/Status/torso.rsi/torso_1.png | Bin 0 -> 160 bytes .../Targeting/Status/torso.rsi/torso_2.png | Bin 0 -> 160 bytes .../Targeting/Status/torso.rsi/torso_3.png | Bin 0 -> 160 bytes .../Targeting/Status/torso.rsi/torso_4.png | Bin 0 -> 160 bytes .../Targeting/Status/torso.rsi/torso_5.png | Bin 0 -> 160 bytes .../Targeting/Status/torso.rsi/torso_6.png | Bin 0 -> 160 bytes .../Targeting/Status/torso.rsi/torso_7.png | Bin 0 -> 160 bytes .../Targeting/Status/torso.rsi/torso_8.png | Bin 0 -> 186 bytes .../Medical/Surgery/bone_gel.rsi/bone-gel.png | Bin 0 -> 432 bytes .../Surgery/bone_gel.rsi/bone-gel_0.png | Bin 0 -> 391 bytes .../Surgery/bone_gel.rsi/bone-gel_25.png | Bin 0 -> 444 bytes .../Surgery/bone_gel.rsi/bone-gel_50.png | Bin 0 -> 456 bytes .../Surgery/bone_gel.rsi/bone-gel_75.png | Bin 0 -> 444 bytes .../Medical/Surgery/bone_gel.rsi/meta.json | 29 + .../bone_gel.rsi/predator_bone-gel.png | Bin 0 -> 585 bytes .../Surgery/bonesetter.rsi/bonesetter.png | Bin 0 -> 581 bytes .../Medical/Surgery/bonesetter.rsi/meta.json | 17 + .../bonesetter.rsi/predator_bonesetter.png | Bin 0 -> 489 bytes .../Surgery/manipulation.rsi/insertion.png | Bin 0 -> 379 bytes .../Surgery/manipulation.rsi/meta.json | 14 + .../limbgrower.rsi/limbgrower_fill.png | Bin 0 -> 9056 bytes .../limbgrower.rsi/limbgrower_idleoff.png | Bin 0 -> 3320 bytes .../limbgrower.rsi/limbgrower_idleon.png | Bin 0 -> 11102 bytes .../limbgrower.rsi/limbgrower_openpanel.png | Bin 0 -> 3981 bytes .../limbgrower.rsi/limbgrower_panelopen.png | Bin 0 -> 2273 bytes .../limbgrower.rsi/limbgrower_unfill.png | Bin 0 -> 9104 bytes .../Machines/limbgrower.rsi/meta.json | 85 ++ Resources/keybinds.yml | 25 + 401 files changed, 8913 insertions(+), 409 deletions(-) delete mode 100644 Content.Client/Body/Systems/BodySystem.cs create mode 100644 Content.Client/Xenonids/UI/XenoChoiceControl.xaml create mode 100644 Content.Client/Xenonids/UI/XenoChoiceControl.xaml.cs create mode 100644 Content.Client/_CorvaxNext/Body/BodySystem.cs create mode 100644 Content.Client/_CorvaxNext/Body/Components/BrainComponent.cs create mode 100644 Content.Client/_CorvaxNext/Body/Components/LungComponent.cs create mode 100644 Content.Client/_CorvaxNext/Body/Components/StomachComponent.cs create mode 100644 Content.Client/_CorvaxNext/Surgery/SurgeryBui.cs create mode 100644 Content.Client/_CorvaxNext/Surgery/SurgeryStepButton.xaml create mode 100644 Content.Client/_CorvaxNext/Surgery/SurgeryStepButton.xaml.cs create mode 100644 Content.Client/_CorvaxNext/Surgery/SurgerySystem.cs create mode 100644 Content.Client/_CorvaxNext/Surgery/SurgeryWindow.xaml create mode 100644 Content.Client/_CorvaxNext/Surgery/SurgeryWindow.xaml.cs create mode 100644 Content.Client/_CorvaxNext/Targeting/TargetingSystem.cs create mode 100644 Content.Client/_CorvaxNext/UserInterface/Systems/PartStatus/PartStatusUIController.cs create mode 100644 Content.Client/_CorvaxNext/UserInterface/Systems/PartStatus/Widgets/PartStatusControl.xaml create mode 100644 Content.Client/_CorvaxNext/UserInterface/Systems/PartStatus/Widgets/PartStatusControl.xaml.cs create mode 100644 Content.Client/_CorvaxNext/UserInterface/Systems/Targeting/TargetingUIController.cs create mode 100644 Content.Client/_CorvaxNext/UserInterface/Systems/Targeting/Widgets/TargetingControl.xaml create mode 100644 Content.Client/_CorvaxNext/UserInterface/Systems/Targeting/Widgets/TargetingControl.xaml.cs create mode 100644 Content.Server/Destructible/Thresholds/Behaviors/GibPartBehavior.cs create mode 100644 Content.Server/_CorvaxNext/DelayedDeath/DelayedDeathComponent.cs create mode 100644 Content.Server/_CorvaxNext/DelayedDeath/DelayedDeathSystem.cs create mode 100644 Content.Server/_CorvaxNext/Surgery/SurgerySystem.cs create mode 100644 Content.Server/_CorvaxNext/Systems/HeartSystem.cs create mode 100644 Content.Server/_CorvaxNext/Targeting/TargetingSystem.cs create mode 100644 Content.Shared/Body/Organ/TailComponent.cs create mode 100644 Content.Shared/Humanoid/Events/ProfileLoadFinishedEvent.cs create mode 100644 Content.Shared/_CorvaxNext/Surgery/Body/AmputateAttemptEvent.cs create mode 100644 Content.Shared/_CorvaxNext/Surgery/Body/BodyPartAppearanceComponent.cs create mode 100644 Content.Shared/_CorvaxNext/Surgery/Body/DebrainedComponent.cs create mode 100644 Content.Shared/_CorvaxNext/Surgery/Body/Organs/EarsComponent.cs create mode 100644 Content.Shared/_CorvaxNext/Surgery/Body/Organs/EyesComponent.cs create mode 100644 Content.Shared/_CorvaxNext/Surgery/Body/Organs/HeartComponent.cs create mode 100644 Content.Shared/_CorvaxNext/Surgery/Body/Organs/LiverComponent.cs create mode 100644 Content.Shared/_CorvaxNext/Surgery/Body/Organs/MarkingContainerComponent.cs create mode 100644 Content.Shared/_CorvaxNext/Surgery/Body/SharedBodySystem.PartAppearance.cs create mode 100644 Content.Shared/_CorvaxNext/Surgery/Body/SharedBodySystem.Targeting.cs create mode 100644 Content.Shared/_CorvaxNext/Surgery/Conditions/SurgeryCloseIncisionConditionComponent.cs create mode 100644 Content.Shared/_CorvaxNext/Surgery/Conditions/SurgeryLarvaConditionComponent.cs create mode 100644 Content.Shared/_CorvaxNext/Surgery/Conditions/SurgeryMarkingConditionComponent.cs create mode 100644 Content.Shared/_CorvaxNext/Surgery/Conditions/SurgeryOperatingTableConditionComponent.cs create mode 100644 Content.Shared/_CorvaxNext/Surgery/Conditions/SurgeryOrganConditionComponent.cs create mode 100644 Content.Shared/_CorvaxNext/Surgery/Conditions/SurgeryPartConditionComponent.cs create mode 100644 Content.Shared/_CorvaxNext/Surgery/Conditions/SurgeryPartPresentCondition.cs create mode 100644 Content.Shared/_CorvaxNext/Surgery/Conditions/SurgeryPartRemovedConditionComponent.cs create mode 100644 Content.Shared/_CorvaxNext/Surgery/Conditions/SurgeryValidEvent.cs create mode 100644 Content.Shared/_CorvaxNext/Surgery/Conditions/SurgeryWoundedConditionComponent.cs create mode 100644 Content.Shared/_CorvaxNext/Surgery/Effects/Complete/SurgeryCompletedEvent.cs create mode 100644 Content.Shared/_CorvaxNext/Surgery/Effects/Complete/SurgeryRemoveLarvaComponent.cs create mode 100644 Content.Shared/_CorvaxNext/Surgery/Effects/Step/SurgeryDamageChangeEffectComponent.cs create mode 100644 Content.Shared/_CorvaxNext/Surgery/Effects/Step/SurgerySpecialDamageChangeEffectComponent.cs create mode 100644 Content.Shared/_CorvaxNext/Surgery/Effects/Step/SurgeryStepCavityEffectComponent.cs create mode 100644 Content.Shared/_CorvaxNext/Surgery/Effects/Step/SurgeryStepEmoteEffectComponent.cs create mode 100644 Content.Shared/_CorvaxNext/Surgery/Effects/Step/SurgeryStepSpawnEffect.cs create mode 100644 Content.Shared/_CorvaxNext/Surgery/Effects/Step/SurgeryTendWoundsEffectComponent.cs create mode 100644 Content.Shared/_CorvaxNext/Surgery/OperatingTableComponent.cs create mode 100644 Content.Shared/_CorvaxNext/Surgery/SharedSurgerySystem.Steps.cs create mode 100644 Content.Shared/_CorvaxNext/Surgery/SharedSurgerySystem.cs create mode 100644 Content.Shared/_CorvaxNext/Surgery/StepInvalidReason.cs create mode 100644 Content.Shared/_CorvaxNext/Surgery/Steps/Parts/BleedersClampedComponent.cs create mode 100644 Content.Shared/_CorvaxNext/Surgery/Steps/Parts/BodyPartReattachedComponent.cs create mode 100644 Content.Shared/_CorvaxNext/Surgery/Steps/Parts/BodyPartSawedComponent.cs create mode 100644 Content.Shared/_CorvaxNext/Surgery/Steps/Parts/IncisionOpenComponent.cs create mode 100644 Content.Shared/_CorvaxNext/Surgery/Steps/Parts/InternalBleedersClampedComponent.cs create mode 100644 Content.Shared/_CorvaxNext/Surgery/Steps/Parts/OrganReattachedComponent.cs create mode 100644 Content.Shared/_CorvaxNext/Surgery/Steps/Parts/PartRemovedComponent.cs create mode 100644 Content.Shared/_CorvaxNext/Surgery/Steps/Parts/RibcageOpenComponent.cs create mode 100644 Content.Shared/_CorvaxNext/Surgery/Steps/Parts/RibcageSawedComponent.cs create mode 100644 Content.Shared/_CorvaxNext/Surgery/Steps/Parts/SkinRetractedComponent.cs create mode 100644 Content.Shared/_CorvaxNext/Surgery/Steps/SurgeryAddMarkingStepComponent.cs create mode 100644 Content.Shared/_CorvaxNext/Surgery/Steps/SurgeryAddOrganStepComponent.cs create mode 100644 Content.Shared/_CorvaxNext/Surgery/Steps/SurgeryAddPartStepComponent.cs create mode 100644 Content.Shared/_CorvaxNext/Surgery/Steps/SurgeryAffixOrganStepComponent.cs create mode 100644 Content.Shared/_CorvaxNext/Surgery/Steps/SurgeryAffixPartStepComponent.cs create mode 100644 Content.Shared/_CorvaxNext/Surgery/Steps/SurgeryCanPerformStepEvent.cs create mode 100644 Content.Shared/_CorvaxNext/Surgery/Steps/SurgeryCutLarvaRootsStepComponent.cs create mode 100644 Content.Shared/_CorvaxNext/Surgery/Steps/SurgeryRemoveMarkingStepComponent.cs create mode 100644 Content.Shared/_CorvaxNext/Surgery/Steps/SurgeryRemoveOrganStepComponent.cs create mode 100644 Content.Shared/_CorvaxNext/Surgery/Steps/SurgeryRemovePartStepComponent.cs create mode 100644 Content.Shared/_CorvaxNext/Surgery/Steps/SurgeryRepeatableStepComponent.cs create mode 100644 Content.Shared/_CorvaxNext/Surgery/Steps/SurgeryStepCompleteCheckEvent.cs create mode 100644 Content.Shared/_CorvaxNext/Surgery/Steps/SurgeryStepComponent.cs create mode 100644 Content.Shared/_CorvaxNext/Surgery/SurgeryComponent.cs create mode 100644 Content.Shared/_CorvaxNext/Surgery/SurgeryDoAfterEvent.cs create mode 100644 Content.Shared/_CorvaxNext/Surgery/SurgerySpeedModifierComponent.cs create mode 100644 Content.Shared/_CorvaxNext/Surgery/SurgeryStepDamageChangeEvent.cs create mode 100644 Content.Shared/_CorvaxNext/Surgery/SurgeryStepDamageEvent.cs create mode 100644 Content.Shared/_CorvaxNext/Surgery/SurgeryStepEvent.cs create mode 100644 Content.Shared/_CorvaxNext/Surgery/SurgeryTargetComponent.cs create mode 100644 Content.Shared/_CorvaxNext/Surgery/SurgeryUI.cs create mode 100644 Content.Shared/_CorvaxNext/Surgery/SurgeryUiRefreshEvent.cs create mode 100644 Content.Shared/_CorvaxNext/Surgery/Tools/BoneGelComponent.cs create mode 100644 Content.Shared/_CorvaxNext/Surgery/Tools/BoneSawComponent.cs create mode 100644 Content.Shared/_CorvaxNext/Surgery/Tools/BoneSetterComponent.cs create mode 100644 Content.Shared/_CorvaxNext/Surgery/Tools/CauteryComponent.cs create mode 100644 Content.Shared/_CorvaxNext/Surgery/Tools/HemostatComponent.cs create mode 100644 Content.Shared/_CorvaxNext/Surgery/Tools/ISurgeryToolComponent.cs create mode 100644 Content.Shared/_CorvaxNext/Surgery/Tools/RetractorComponent.cs create mode 100644 Content.Shared/_CorvaxNext/Surgery/Tools/ScalpelComponent.cs create mode 100644 Content.Shared/_CorvaxNext/Surgery/Tools/SurgeryToolComponent.cs create mode 100644 Content.Shared/_CorvaxNext/Surgery/Tools/SurgicalDrillComponent.cs create mode 100644 Content.Shared/_CorvaxNext/Targeting/Events.cs create mode 100644 Content.Shared/_CorvaxNext/Targeting/SharedTargetingSystem.cs create mode 100644 Content.Shared/_CorvaxNext/Targeting/TargetBodyPart.cs create mode 100644 Content.Shared/_CorvaxNext/Targeting/TargetIntegrity.cs create mode 100644 Content.Shared/_CorvaxNext/Targeting/TargetingComponent.cs create mode 100644 Resources/Audio/Medical/Surgery/attributions.yml create mode 100644 Resources/Audio/Medical/Surgery/cautery1.ogg create mode 100644 Resources/Audio/Medical/Surgery/cautery2.ogg create mode 100644 Resources/Audio/Medical/Surgery/hemostat1.ogg create mode 100644 Resources/Audio/Medical/Surgery/organ1.ogg create mode 100644 Resources/Audio/Medical/Surgery/organ2.ogg create mode 100644 Resources/Audio/Medical/Surgery/retractor1.ogg create mode 100644 Resources/Audio/Medical/Surgery/retractor2.ogg create mode 100644 Resources/Audio/Medical/Surgery/saw.ogg create mode 100644 Resources/Audio/Medical/Surgery/scalpel1.ogg create mode 100644 Resources/Audio/Medical/Surgery/scalpel2.ogg create mode 100644 Resources/Locale/en-US/_corvaxnext/guidebook/guides.ftl create mode 100644 Resources/Locale/en-US/_corvaxnext/surgery/surgery-popup.ftl create mode 100644 Resources/Locale/en-US/_corvaxnext/surgery/surgery-ui.ftl create mode 100644 Resources/Locale/ru-RU/_corvaxnext/guidebook/guides.ftl create mode 100644 Resources/Locale/ru-RU/_corvaxnext/surgery/surgery-items.ftl create mode 100644 Resources/Locale/ru-RU/_corvaxnext/surgery/surgery-operations.ftl create mode 100644 Resources/Locale/ru-RU/_corvaxnext/surgery/surgery-popup.ftl create mode 100644 Resources/Locale/ru-RU/_corvaxnext/surgery/surgery-ui.ftl create mode 100644 Resources/Prototypes/_CorvaxNext/Damage/containers.yml create mode 100644 Resources/Prototypes/_CorvaxNext/Damage/modifier_sets.yml create mode 100644 Resources/Prototypes/_CorvaxNext/Entities/Machines/lathe.yml create mode 100644 Resources/Prototypes/_CorvaxNext/Entities/Objects/Circuitboards/production.yml create mode 100644 Resources/Prototypes/_CorvaxNext/Entities/Objects/Specific/Medical/surgery.yml create mode 100644 Resources/Prototypes/_CorvaxNext/Entities/Surgery/surgeries.yml create mode 100644 Resources/Prototypes/_CorvaxNext/Entities/Surgery/surgery_steps.yml create mode 100644 Resources/Prototypes/_CorvaxNext/Recipes/Lathes/surgery.yml create mode 100644 Resources/ServerInfo/Corvax/Guidebook/Medical/OrganManipulation.xml create mode 100644 Resources/ServerInfo/Corvax/Guidebook/Medical/PartManipulation.xml create mode 100644 Resources/ServerInfo/Corvax/Guidebook/Medical/Surgery.xml create mode 100644 Resources/ServerInfo/Corvax/Guidebook/Medical/UtilitySurgeries.xml create mode 100644 Resources/Textures/Interface/Ashen/target_doll.png create mode 100644 Resources/Textures/Interface/Clockwork/target_doll.png create mode 100644 Resources/Textures/Interface/Default/target_doll.png create mode 100644 Resources/Textures/Interface/Minimalist/target_doll.png create mode 100644 Resources/Textures/Interface/Plasmafire/target_doll.png create mode 100644 Resources/Textures/Interface/Retro/target_doll.png create mode 100644 Resources/Textures/Interface/Slimecore/target_doll.png create mode 100644 Resources/Textures/Interface/Targeting/Doll/eyes.png create mode 100644 Resources/Textures/Interface/Targeting/Doll/eyes_hover.png create mode 100644 Resources/Textures/Interface/Targeting/Doll/groin.png create mode 100644 Resources/Textures/Interface/Targeting/Doll/groin_hover.png create mode 100644 Resources/Textures/Interface/Targeting/Doll/head.png create mode 100644 Resources/Textures/Interface/Targeting/Doll/head_hover.png create mode 100644 Resources/Textures/Interface/Targeting/Doll/leftarm.png create mode 100644 Resources/Textures/Interface/Targeting/Doll/leftarm_hover.png create mode 100644 Resources/Textures/Interface/Targeting/Doll/leftfoot.png create mode 100644 Resources/Textures/Interface/Targeting/Doll/leftfoot_hover.png create mode 100644 Resources/Textures/Interface/Targeting/Doll/lefthand.png create mode 100644 Resources/Textures/Interface/Targeting/Doll/lefthand_hover.png create mode 100644 Resources/Textures/Interface/Targeting/Doll/leftleg.png create mode 100644 Resources/Textures/Interface/Targeting/Doll/leftleg_hover.png create mode 100644 Resources/Textures/Interface/Targeting/Doll/mouth.png create mode 100644 Resources/Textures/Interface/Targeting/Doll/mouth_hover.png create mode 100644 Resources/Textures/Interface/Targeting/Doll/rightarm.png create mode 100644 Resources/Textures/Interface/Targeting/Doll/rightarm_hover.png create mode 100644 Resources/Textures/Interface/Targeting/Doll/rightfoot.png create mode 100644 Resources/Textures/Interface/Targeting/Doll/rightfoot_hover.png create mode 100644 Resources/Textures/Interface/Targeting/Doll/righthand.png create mode 100644 Resources/Textures/Interface/Targeting/Doll/righthand_hover.png create mode 100644 Resources/Textures/Interface/Targeting/Doll/rightleg.png create mode 100644 Resources/Textures/Interface/Targeting/Doll/rightleg_hover.png create mode 100644 Resources/Textures/Interface/Targeting/Doll/torso.png create mode 100644 Resources/Textures/Interface/Targeting/Doll/torso_hover.png create mode 100644 Resources/Textures/Interface/Targeting/Status/groin.rsi/groin_0.png create mode 100644 Resources/Textures/Interface/Targeting/Status/groin.rsi/groin_1.png create mode 100644 Resources/Textures/Interface/Targeting/Status/groin.rsi/groin_2.png create mode 100644 Resources/Textures/Interface/Targeting/Status/groin.rsi/groin_3.png create mode 100644 Resources/Textures/Interface/Targeting/Status/groin.rsi/groin_4.png create mode 100644 Resources/Textures/Interface/Targeting/Status/groin.rsi/groin_5.png create mode 100644 Resources/Textures/Interface/Targeting/Status/groin.rsi/groin_6.png create mode 100644 Resources/Textures/Interface/Targeting/Status/groin.rsi/groin_7.png create mode 100644 Resources/Textures/Interface/Targeting/Status/groin.rsi/groin_8.png create mode 100644 Resources/Textures/Interface/Targeting/Status/groin.rsi/meta.json create mode 100644 Resources/Textures/Interface/Targeting/Status/head.rsi/head_0.png create mode 100644 Resources/Textures/Interface/Targeting/Status/head.rsi/head_1.png create mode 100644 Resources/Textures/Interface/Targeting/Status/head.rsi/head_2.png create mode 100644 Resources/Textures/Interface/Targeting/Status/head.rsi/head_3.png create mode 100644 Resources/Textures/Interface/Targeting/Status/head.rsi/head_4.png create mode 100644 Resources/Textures/Interface/Targeting/Status/head.rsi/head_5.png create mode 100644 Resources/Textures/Interface/Targeting/Status/head.rsi/head_6.png create mode 100644 Resources/Textures/Interface/Targeting/Status/head.rsi/head_7.png create mode 100644 Resources/Textures/Interface/Targeting/Status/head.rsi/head_8.png create mode 100644 Resources/Textures/Interface/Targeting/Status/head.rsi/meta.json create mode 100644 Resources/Textures/Interface/Targeting/Status/leftarm.rsi/leftarm_0.png create mode 100644 Resources/Textures/Interface/Targeting/Status/leftarm.rsi/leftarm_1.png create mode 100644 Resources/Textures/Interface/Targeting/Status/leftarm.rsi/leftarm_2.png create mode 100644 Resources/Textures/Interface/Targeting/Status/leftarm.rsi/leftarm_3.png create mode 100644 Resources/Textures/Interface/Targeting/Status/leftarm.rsi/leftarm_4.png create mode 100644 Resources/Textures/Interface/Targeting/Status/leftarm.rsi/leftarm_5.png create mode 100644 Resources/Textures/Interface/Targeting/Status/leftarm.rsi/leftarm_6.png create mode 100644 Resources/Textures/Interface/Targeting/Status/leftarm.rsi/leftarm_7.png create mode 100644 Resources/Textures/Interface/Targeting/Status/leftarm.rsi/leftarm_8.png create mode 100644 Resources/Textures/Interface/Targeting/Status/leftarm.rsi/meta.json create mode 100644 Resources/Textures/Interface/Targeting/Status/leftfoot.rsi/leftfoot_0.png create mode 100644 Resources/Textures/Interface/Targeting/Status/leftfoot.rsi/leftfoot_1.png create mode 100644 Resources/Textures/Interface/Targeting/Status/leftfoot.rsi/leftfoot_2.png create mode 100644 Resources/Textures/Interface/Targeting/Status/leftfoot.rsi/leftfoot_3.png create mode 100644 Resources/Textures/Interface/Targeting/Status/leftfoot.rsi/leftfoot_4.png create mode 100644 Resources/Textures/Interface/Targeting/Status/leftfoot.rsi/leftfoot_5.png create mode 100644 Resources/Textures/Interface/Targeting/Status/leftfoot.rsi/leftfoot_6.png create mode 100644 Resources/Textures/Interface/Targeting/Status/leftfoot.rsi/leftfoot_7.png create mode 100644 Resources/Textures/Interface/Targeting/Status/leftfoot.rsi/leftfoot_8.png create mode 100644 Resources/Textures/Interface/Targeting/Status/leftfoot.rsi/meta.json create mode 100644 Resources/Textures/Interface/Targeting/Status/lefthand.rsi/lefthand_0.png create mode 100644 Resources/Textures/Interface/Targeting/Status/lefthand.rsi/lefthand_1.png create mode 100644 Resources/Textures/Interface/Targeting/Status/lefthand.rsi/lefthand_2.png create mode 100644 Resources/Textures/Interface/Targeting/Status/lefthand.rsi/lefthand_3.png create mode 100644 Resources/Textures/Interface/Targeting/Status/lefthand.rsi/lefthand_4.png create mode 100644 Resources/Textures/Interface/Targeting/Status/lefthand.rsi/lefthand_5.png create mode 100644 Resources/Textures/Interface/Targeting/Status/lefthand.rsi/lefthand_6.png create mode 100644 Resources/Textures/Interface/Targeting/Status/lefthand.rsi/lefthand_7.png create mode 100644 Resources/Textures/Interface/Targeting/Status/lefthand.rsi/lefthand_8.png create mode 100644 Resources/Textures/Interface/Targeting/Status/lefthand.rsi/meta.json create mode 100644 Resources/Textures/Interface/Targeting/Status/leftleg.rsi/leftleg_0.png create mode 100644 Resources/Textures/Interface/Targeting/Status/leftleg.rsi/leftleg_1.png create mode 100644 Resources/Textures/Interface/Targeting/Status/leftleg.rsi/leftleg_2.png create mode 100644 Resources/Textures/Interface/Targeting/Status/leftleg.rsi/leftleg_3.png create mode 100644 Resources/Textures/Interface/Targeting/Status/leftleg.rsi/leftleg_4.png create mode 100644 Resources/Textures/Interface/Targeting/Status/leftleg.rsi/leftleg_5.png create mode 100644 Resources/Textures/Interface/Targeting/Status/leftleg.rsi/leftleg_6.png create mode 100644 Resources/Textures/Interface/Targeting/Status/leftleg.rsi/leftleg_7.png create mode 100644 Resources/Textures/Interface/Targeting/Status/leftleg.rsi/leftleg_8.png create mode 100644 Resources/Textures/Interface/Targeting/Status/leftleg.rsi/meta.json create mode 100644 Resources/Textures/Interface/Targeting/Status/rightarm.rsi/meta.json create mode 100644 Resources/Textures/Interface/Targeting/Status/rightarm.rsi/rightarm_0.png create mode 100644 Resources/Textures/Interface/Targeting/Status/rightarm.rsi/rightarm_1.png create mode 100644 Resources/Textures/Interface/Targeting/Status/rightarm.rsi/rightarm_2.png create mode 100644 Resources/Textures/Interface/Targeting/Status/rightarm.rsi/rightarm_3.png create mode 100644 Resources/Textures/Interface/Targeting/Status/rightarm.rsi/rightarm_4.png create mode 100644 Resources/Textures/Interface/Targeting/Status/rightarm.rsi/rightarm_5.png create mode 100644 Resources/Textures/Interface/Targeting/Status/rightarm.rsi/rightarm_6.png create mode 100644 Resources/Textures/Interface/Targeting/Status/rightarm.rsi/rightarm_7.png create mode 100644 Resources/Textures/Interface/Targeting/Status/rightarm.rsi/rightarm_8.png create mode 100644 Resources/Textures/Interface/Targeting/Status/rightfoot.rsi/meta.json create mode 100644 Resources/Textures/Interface/Targeting/Status/rightfoot.rsi/rightfoot_0.png create mode 100644 Resources/Textures/Interface/Targeting/Status/rightfoot.rsi/rightfoot_1.png create mode 100644 Resources/Textures/Interface/Targeting/Status/rightfoot.rsi/rightfoot_2.png create mode 100644 Resources/Textures/Interface/Targeting/Status/rightfoot.rsi/rightfoot_3.png create mode 100644 Resources/Textures/Interface/Targeting/Status/rightfoot.rsi/rightfoot_4.png create mode 100644 Resources/Textures/Interface/Targeting/Status/rightfoot.rsi/rightfoot_5.png create mode 100644 Resources/Textures/Interface/Targeting/Status/rightfoot.rsi/rightfoot_6.png create mode 100644 Resources/Textures/Interface/Targeting/Status/rightfoot.rsi/rightfoot_7.png create mode 100644 Resources/Textures/Interface/Targeting/Status/rightfoot.rsi/rightfoot_8.png create mode 100644 Resources/Textures/Interface/Targeting/Status/righthand.rsi/meta.json create mode 100644 Resources/Textures/Interface/Targeting/Status/righthand.rsi/righthand_0.png create mode 100644 Resources/Textures/Interface/Targeting/Status/righthand.rsi/righthand_1.png create mode 100644 Resources/Textures/Interface/Targeting/Status/righthand.rsi/righthand_2.png create mode 100644 Resources/Textures/Interface/Targeting/Status/righthand.rsi/righthand_3.png create mode 100644 Resources/Textures/Interface/Targeting/Status/righthand.rsi/righthand_4.png create mode 100644 Resources/Textures/Interface/Targeting/Status/righthand.rsi/righthand_5.png create mode 100644 Resources/Textures/Interface/Targeting/Status/righthand.rsi/righthand_6.png create mode 100644 Resources/Textures/Interface/Targeting/Status/righthand.rsi/righthand_7.png create mode 100644 Resources/Textures/Interface/Targeting/Status/righthand.rsi/righthand_8.png create mode 100644 Resources/Textures/Interface/Targeting/Status/rightleg.rsi/meta.json create mode 100644 Resources/Textures/Interface/Targeting/Status/rightleg.rsi/rightleg_0.png create mode 100644 Resources/Textures/Interface/Targeting/Status/rightleg.rsi/rightleg_1.png create mode 100644 Resources/Textures/Interface/Targeting/Status/rightleg.rsi/rightleg_2.png create mode 100644 Resources/Textures/Interface/Targeting/Status/rightleg.rsi/rightleg_3.png create mode 100644 Resources/Textures/Interface/Targeting/Status/rightleg.rsi/rightleg_4.png create mode 100644 Resources/Textures/Interface/Targeting/Status/rightleg.rsi/rightleg_5.png create mode 100644 Resources/Textures/Interface/Targeting/Status/rightleg.rsi/rightleg_6.png create mode 100644 Resources/Textures/Interface/Targeting/Status/rightleg.rsi/rightleg_7.png create mode 100644 Resources/Textures/Interface/Targeting/Status/rightleg.rsi/rightleg_8.png create mode 100644 Resources/Textures/Interface/Targeting/Status/torso.rsi/meta.json create mode 100644 Resources/Textures/Interface/Targeting/Status/torso.rsi/torso_0.png create mode 100644 Resources/Textures/Interface/Targeting/Status/torso.rsi/torso_1.png create mode 100644 Resources/Textures/Interface/Targeting/Status/torso.rsi/torso_2.png create mode 100644 Resources/Textures/Interface/Targeting/Status/torso.rsi/torso_3.png create mode 100644 Resources/Textures/Interface/Targeting/Status/torso.rsi/torso_4.png create mode 100644 Resources/Textures/Interface/Targeting/Status/torso.rsi/torso_5.png create mode 100644 Resources/Textures/Interface/Targeting/Status/torso.rsi/torso_6.png create mode 100644 Resources/Textures/Interface/Targeting/Status/torso.rsi/torso_7.png create mode 100644 Resources/Textures/Interface/Targeting/Status/torso.rsi/torso_8.png create mode 100644 Resources/Textures/Objects/Specific/Medical/Surgery/bone_gel.rsi/bone-gel.png create mode 100644 Resources/Textures/Objects/Specific/Medical/Surgery/bone_gel.rsi/bone-gel_0.png create mode 100644 Resources/Textures/Objects/Specific/Medical/Surgery/bone_gel.rsi/bone-gel_25.png create mode 100644 Resources/Textures/Objects/Specific/Medical/Surgery/bone_gel.rsi/bone-gel_50.png create mode 100644 Resources/Textures/Objects/Specific/Medical/Surgery/bone_gel.rsi/bone-gel_75.png create mode 100644 Resources/Textures/Objects/Specific/Medical/Surgery/bone_gel.rsi/meta.json create mode 100644 Resources/Textures/Objects/Specific/Medical/Surgery/bone_gel.rsi/predator_bone-gel.png create mode 100644 Resources/Textures/Objects/Specific/Medical/Surgery/bonesetter.rsi/bonesetter.png create mode 100644 Resources/Textures/Objects/Specific/Medical/Surgery/bonesetter.rsi/meta.json create mode 100644 Resources/Textures/Objects/Specific/Medical/Surgery/bonesetter.rsi/predator_bonesetter.png create mode 100644 Resources/Textures/Objects/Specific/Medical/Surgery/manipulation.rsi/insertion.png create mode 100644 Resources/Textures/Objects/Specific/Medical/Surgery/manipulation.rsi/meta.json create mode 100644 Resources/Textures/Structures/Machines/limbgrower.rsi/limbgrower_fill.png create mode 100644 Resources/Textures/Structures/Machines/limbgrower.rsi/limbgrower_idleoff.png create mode 100644 Resources/Textures/Structures/Machines/limbgrower.rsi/limbgrower_idleon.png create mode 100644 Resources/Textures/Structures/Machines/limbgrower.rsi/limbgrower_openpanel.png create mode 100644 Resources/Textures/Structures/Machines/limbgrower.rsi/limbgrower_panelopen.png create mode 100644 Resources/Textures/Structures/Machines/limbgrower.rsi/limbgrower_unfill.png create mode 100644 Resources/Textures/Structures/Machines/limbgrower.rsi/meta.json diff --git a/Content.Client/Body/Systems/BodySystem.cs b/Content.Client/Body/Systems/BodySystem.cs deleted file mode 100644 index bab785525b0..00000000000 --- a/Content.Client/Body/Systems/BodySystem.cs +++ /dev/null @@ -1,7 +0,0 @@ -using Content.Shared.Body.Systems; - -namespace Content.Client.Body.Systems; - -public sealed class BodySystem : SharedBodySystem -{ -} diff --git a/Content.Client/Hands/Systems/HandsSystem.cs b/Content.Client/Hands/Systems/HandsSystem.cs index 68800a2afe5..18e4540e153 100644 --- a/Content.Client/Hands/Systems/HandsSystem.cs +++ b/Content.Client/Hands/Systems/HandsSystem.cs @@ -4,6 +4,7 @@ using Content.Client.Examine; using Content.Client.Strip; using Content.Client.Verbs.UI; +using Content.Shared.Body.Part; using Content.Shared.Hands; using Content.Shared.Hands.Components; using Content.Shared.Hands.EntitySystems; @@ -40,7 +41,6 @@ public sealed class HandsSystem : SharedHandsSystem public event Action? OnPlayerItemRemoved; public event Action? OnPlayerHandBlocked; public event Action? OnPlayerHandUnblocked; - public override void Initialize() { base.Initialize(); @@ -51,6 +51,8 @@ public override void Initialize() SubscribeLocalEvent(OnHandsShutdown); SubscribeLocalEvent(HandleComponentState); SubscribeLocalEvent(OnVisualsChanged); + SubscribeLocalEvent(HandleBodyPartRemoved); // _CorvaxNext: surgery + SubscribeLocalEvent(HandleBodyPartDisabled); // _CorvaxNext: surgery OnHandSetActive += OnHandActivated; } @@ -238,8 +240,40 @@ public void UIHandAltActivateItem(string handName) RaisePredictiveEvent(new RequestHandAltInteractEvent(handName)); } + #region pulling + + #endregion + #region visuals + // start-_CorvaxNext: surgery + private void HideLayers(EntityUid uid, HandsComponent component, Entity part, SpriteComponent? sprite = null) + { + if (part.Comp.PartType != BodyPartType.Hand || !Resolve(uid, ref sprite, logMissing: false)) + return; + + var location = part.Comp.Symmetry switch + { + BodyPartSymmetry.None => HandLocation.Middle, + BodyPartSymmetry.Left => HandLocation.Left, + BodyPartSymmetry.Right => HandLocation.Right, + _ => throw new ArgumentOutOfRangeException(nameof(part.Comp.Symmetry)) + }; + + if (component.RevealedLayers.TryGetValue(location, out var revealedLayers)) + { + foreach (var key in revealedLayers) + sprite.RemoveLayer(key); + + revealedLayers.Clear(); + } + } + + private void HandleBodyPartRemoved(EntityUid uid, HandsComponent component, ref BodyPartRemovedEvent args) => HideLayers(uid, component, args.Part); + + private void HandleBodyPartDisabled(EntityUid uid, HandsComponent component, ref BodyPartDisabledEvent args) => HideLayers(uid, component, args.Part); + // end-_CorvaxNext: surgery + protected override void HandleEntityInserted(EntityUid uid, HandsComponent hands, EntInsertedIntoContainerMessage args) { base.HandleEntityInserted(uid, hands, args); @@ -264,6 +298,7 @@ protected override void HandleEntityRemoved(EntityUid uid, HandsComponent hands, if (!hands.Hands.TryGetValue(args.Container.ID, out var hand)) return; + UpdateHandVisuals(uid, args.Entity, hand); _stripSys.UpdateUi(uid); diff --git a/Content.Client/HealthAnalyzer/UI/HealthAnalyzerBoundUserInterface.cs b/Content.Client/HealthAnalyzer/UI/HealthAnalyzerBoundUserInterface.cs index baea03c8923..e2c75c4b391 100644 --- a/Content.Client/HealthAnalyzer/UI/HealthAnalyzerBoundUserInterface.cs +++ b/Content.Client/HealthAnalyzer/UI/HealthAnalyzerBoundUserInterface.cs @@ -1,6 +1,7 @@ using Content.Shared.MedicalScanner; +using Content.Shared._CorvaxNext.Targeting; using JetBrains.Annotations; -using Robust.Client.UserInterface; +using Robust.Client.GameObjects; namespace Content.Client.HealthAnalyzer.UI { @@ -17,10 +18,13 @@ public HealthAnalyzerBoundUserInterface(EntityUid owner, Enum uiKey) : base(owne protected override void Open() { base.Open(); - - _window = this.CreateWindow(); - - _window.Title = EntMan.GetComponent(Owner).EntityName; + _window = new HealthAnalyzerWindow + { + Title = EntMan.GetComponent(Owner).EntityName, + }; + _window.OnClose += Close; + _window.OnBodyPartSelected += SendBodyPartMessage; + _window.OpenCentered(); } protected override void ReceiveMessage(BoundUserInterfaceMessage message) @@ -33,5 +37,22 @@ protected override void ReceiveMessage(BoundUserInterfaceMessage message) _window.Populate(cast); } + + private void SendBodyPartMessage(TargetBodyPart? part, EntityUid target) => SendMessage(new HealthAnalyzerPartMessage(EntMan.GetNetEntity(target), part ?? null)); + + protected override void Dispose(bool disposing) + { + base.Dispose(disposing); + if (!disposing) + return; + + if (_window != null) + { + _window.OnClose -= Close; + _window.OnBodyPartSelected -= SendBodyPartMessage; + } + + _window?.Dispose(); + } } } diff --git a/Content.Client/HealthAnalyzer/UI/HealthAnalyzerWindow.xaml b/Content.Client/HealthAnalyzer/UI/HealthAnalyzerWindow.xaml index aae8785b1fe..0a0b5ac89e7 100644 --- a/Content.Client/HealthAnalyzer/UI/HealthAnalyzerWindow.xaml +++ b/Content.Client/HealthAnalyzer/UI/HealthAnalyzerWindow.xaml @@ -1,8 +1,8 @@ - + MinWidth="350">