# SPDX-FileCopyrightText: 2020 DmitriyRubetskoy <75271456+DmitriyRubetskoy@users.noreply.github.com>
# SPDX-FileCopyrightText: 2020 DmitriyRubetskoy <rubetskoy234@mail.ru>
# SPDX-FileCopyrightText: 2020 GlassEclipse <32942106+GlassEclipse@users.noreply.github.com>
# SPDX-FileCopyrightText: 2020 GlassEclipse <tsymall5@gmail.com>
# SPDX-FileCopyrightText: 2020 Hugo Laloge <hugo.laloge@gmail.com>
# SPDX-FileCopyrightText: 2020 Paul Ritter <ritter.paul1@googlemail.com>
# SPDX-FileCopyrightText: 2020 Pieter-Jan Briers <pieterjan.briers+git@gmail.com>
# SPDX-FileCopyrightText: 2020 Remie Richards <remierichards@gmail.com>
# SPDX-FileCopyrightText: 2020 Vera Aguilera Puerto <6766154+Zumorica@users.noreply.github.com>
# SPDX-FileCopyrightText: 2020 Víctor Aguilera Puerto <6766154+Zumorica@users.noreply.github.com>
# SPDX-FileCopyrightText: 2020 Ygg01 <daniel.fath7@gmail.com>
# SPDX-FileCopyrightText: 2021 Galactic Chimp <GalacticChimpanzee@gmail.com>
# SPDX-FileCopyrightText: 2021 Leon Friedrich <60421075+ElectroJr@users.noreply.github.com>
# SPDX-FileCopyrightText: 2021 Metal Gear Sloth <metalgearsloth@gmail.com>
# SPDX-FileCopyrightText: 2021 Peptide90 <78795277+Peptide90@users.noreply.github.com>
# SPDX-FileCopyrightText: 2021 Swept <sweptwastaken@protonmail.com>
# SPDX-FileCopyrightText: 2021 Tarlan2 <76408146+Tarlan2@users.noreply.github.com>
# SPDX-FileCopyrightText: 2021 and_a <and_a@DESKTOP-RJENGIR>
# SPDX-FileCopyrightText: 2022 DrSmugleaf <DrSmugleaf@users.noreply.github.com>
# SPDX-FileCopyrightText: 2022 Kara <lunarautomaton6@gmail.com>
# SPDX-FileCopyrightText: 2022 Visne <39844191+Visne@users.noreply.github.com>
# SPDX-FileCopyrightText: 2022 ZeroDayDaemon <60460608+ZeroDayDaemon@users.noreply.github.com>
# SPDX-FileCopyrightText: 2022 metalgearsloth <31366439+metalgearsloth@users.noreply.github.com>
# SPDX-FileCopyrightText: 2022 metalgearsloth <metalgearsloth@gmail.com>
# SPDX-FileCopyrightText: 2022 mirrorcult <lunarautomaton6@gmail.com>
# SPDX-FileCopyrightText: 2023 Moony <moony@hellomouse.net>
# SPDX-FileCopyrightText: 2023 Whisper <121047731+QuietlyWhisper@users.noreply.github.com>
# SPDX-FileCopyrightText: 2023 moonheart08 <moonheart08@users.noreply.github.com>
# SPDX-FileCopyrightText: 2024 AJCM-git <60196617+AJCM-git@users.noreply.github.com>
# SPDX-FileCopyrightText: 2024 BombasterDS <115770678+BombasterDS@users.noreply.github.com>
# SPDX-FileCopyrightText: 2024 I.K <45953835+notquitehadouken@users.noreply.github.com>
# SPDX-FileCopyrightText: 2024 Nairod <110078045+Nairodian@users.noreply.github.com>
# SPDX-FileCopyrightText: 2024 Skye <57879983+Rainbeon@users.noreply.github.com>
# SPDX-FileCopyrightText: 2024 Verm <32827189+Vermidia@users.noreply.github.com>
# SPDX-FileCopyrightText: 2024 Winkarst <74284083+Winkarst-cpu@users.noreply.github.com>
# SPDX-FileCopyrightText: 2024 beck-thompson <107373427+beck-thompson@users.noreply.github.com>
# SPDX-FileCopyrightText: 2024 deltanedas <39013340+deltanedas@users.noreply.github.com>
# SPDX-FileCopyrightText: 2024 deltanedas <@deltanedas:kde.org>
# SPDX-FileCopyrightText: 2024 lzk <124214523+lzk228@users.noreply.github.com>
# SPDX-FileCopyrightText: 2024 slarticodefast <161409025+slarticodefast@users.noreply.github.com>
# SPDX-FileCopyrightText: 2025 Aiden <28298836+Aidenkrz@users.noreply.github.com>
# SPDX-FileCopyrightText: 2025 Aviu00 <93730715+Aviu00@users.noreply.github.com>
# SPDX-FileCopyrightText: 2025 ColonicAcid <claudiomota1990@googlemail.com>
# SPDX-FileCopyrightText: 2025 GoobBot <uristmchands@proton.me>
# SPDX-FileCopyrightText: 2025 Piras314 <p1r4s@proton.me>
# SPDX-FileCopyrightText: 2025 RedBookcase <crazykid1590@gmail.com>
# SPDX-FileCopyrightText: 2025 Solstice <solsticeofthewinter@gmail.com>
# SPDX-FileCopyrightText: 2025 Ted Lukin <66275205+pheenty@users.noreply.github.com>
# SPDX-FileCopyrightText: 2025 gluesniffler <159397573+gluesniffler@users.noreply.github.com>
# SPDX-FileCopyrightText: 2025 pheenty <fedorlukin2006@gmail.com>
#
# SPDX-License-Identifier: AGPL-3.0-or-later
# Base

- type: entity
  parent: BaseItem
  id: BaseToolSurgery
  abstract: true
  components:
  - type: Sprite
  - type: StaticPrice
    price: 60
  - type: Tag
    tags:
    - SurgeryTool
  - type: SurgeryTool

# Cautery

- type: entity
  name: cautery
  id: Cautery
  parent: BaseToolSurgery
  description: A surgical tool used to cauterize open wounds.
  components:
  - type: Sprite
    sprite: _Shitmed/Objects/Specific/Medical/Surgery/cautery.rsi
    state: cautery
  - type: Item
    sprite: _Shitmed/Objects/Specific/Medical/Surgery/cautery.rsi
    storedRotation: 90
  - type: MeleeWeapon
    damage:
       types:
        Heat: 5
    soundHit:
      path: /Audio/Effects/lightburn.ogg
  # Shitmed Change
  - type: SurgeryTool
    startSound:
      path: /Audio/_Shitmed/Medical/Surgery/cautery1.ogg
    endSound:
      path: /Audio/_Shitmed/Medical/Surgery/cautery2.ogg
  - type: Cautery
  - type: AlwaysHot # Goob

# Drill

- type: entity
  name: drill
  id: Drill
  parent: BaseToolSurgery
  description: A surgical drill for making holes into hard material.
  components:
  - type: Sprite
    sprite: _Shitmed/Objects/Specific/Medical/Surgery/drill.rsi
    state: drill
  - type: Item
    sprite: _Shitmed/Objects/Specific/Medical/Surgery/drill.rsi
    shape:
    - 0,0,1,0
    - 1,1,1,1
  - type: MeleeWeapon
    damage:
      types:
        Piercing: 10
    soundHit:
      path: /Audio/Items/drill_hit.ogg
  - type: StaticPrice
    price: 40
  # Shitmed Change
  - type: SurgeryTool
    startSound:
      path: /Audio/_Shitmed/Medical/Surgery/saw.ogg
  - type: Drill

# Scalpel

- type: entity
  name: scalpel
  id: Scalpel
  parent: BaseToolSurgery
  description: A surgical tool used to make incisions into flesh.
  components:
  - type: Sharp
    butcherDelayModifier: 1.5 # Butchering with a scalpel, regardless of the type, will take 50% longer
  - type: Tool
    qualities:
    - Slicing
    speedModifier: 0.66 # pretend the sixes go on forever :)
  - type: Utensil
    types:
      - Knife
  - type: Sprite
    sprite: _Shitmed/Objects/Specific/Medical/Surgery/scalpel.rsi
    state: scalpel
  - type: Item
    sprite: _Shitmed/Objects/Specific/Medical/Surgery/scalpel.rsi
    storedRotation: 90
  - type: MeleeWeapon
    wideAnimationRotation: 90
    swingLeft: true
    attackRate: 1.5
    damage:
      types:
        Slash: 8
    soundHit:
      path: /Audio/Weapons/bladeslice.ogg
  # Shitmed Change
  - type: SurgeryTool
    startSound:
      path: /Audio/_Shitmed/Medical/Surgery/scalpel1.ogg
    endSound:
      path: /Audio/_Shitmed/Medical/Surgery/scalpel2.ogg
  - type: Scalpel
  - type: Tag # Goobstation
    tags:
    - SurgeryTool
    - Knife

- type: entity
  name: shiv
  id: ScalpelShiv
  parent: Scalpel
  description: A pointy piece of glass, abraded to an edge and wrapped in tape for a handle. # Could become a decent tool or weapon with right tool mods.
  components:
  - type: Sprite
    sprite: Objects/Specific/Medical/Surgery/scalpel.rsi
    state: shiv
  - type: Item
    sprite: Objects/Specific/Medical/Surgery/scalpel.rsi
    storedRotation: 90
    heldPrefix: shiv

- type: entity
  name: advanced scalpel
  id: ScalpelAdvanced
  parent: Scalpel
  description: Made of more expensive materials, sharper and generally more reliable.
  components:
  - type: Sprite
    sprite: Objects/Specific/Medical/Surgery/scalpel.rsi
    state: advanced
  - type: Item
    sprite: Objects/Specific/Medical/Surgery/scalpel.rsi
    storedRotation: 90
    heldPrefix: advanced
  - type: MeleeWeapon
    damage:
      types:
        Slash: 12
  - type: Scalpel # Shitmed
    speed: 1.35

- type: entity
  name: laser scalpel
  id: ScalpelLaser
  parent: Scalpel
  description: A scalpel which uses a directed laser to slice instead of a blade, for more precise surgery while also cauterizing as it cuts.
  components:
  - type: Sprite
    sprite: Objects/Specific/Medical/Surgery/scalpel.rsi
    state: laser
  - type: Item
    sprite: Objects/Specific/Medical/Surgery/scalpel.rsi
    storedRotation: 90
    heldPrefix: laser
  - type: Scalpel # Shitmed
    speed: 1.75
  # TODO: prevent bleeding from incisions

# Retractor

- type: entity
  name: retractor
  id: Retractor
  parent: BaseToolSurgery
  description: A surgical tool used to hold open incisions.
  components:
  - type: Sprite
    sprite: _Shitmed/Objects/Specific/Medical/Surgery/retractor.rsi
    state: retractor
  - type: Item
    sprite: _Shitmed/Objects/Specific/Medical/Surgery/retractor.rsi
    storedRotation: 90
  # Shitmed Change
  - type: SurgeryTool
    startSound:
      path: /Audio/_Shitmed/Medical/Surgery/retractor1.ogg
    endSound:
      path: /Audio/_Shitmed/Medical/Surgery/retractor2.ogg
  - type: Retractor

# Hemostat

- type: entity
  name: hemostat
  id: Hemostat
  parent: BaseToolSurgery # Shitmed Change
  description: A surgical tool used to compress blood vessels to prevent bleeding.
  components:
  - type: Sprite
    sprite: _Shitmed/Objects/Specific/Medical/Surgery/hemostat.rsi # Shitmed Change
    state: hemostat
  - type: Item
    heldPrefix: hemostat
    sprite: _Shitmed/Objects/Specific/Medical/Surgery/hemostat.rsi # Shitmed Change
    storedRotation: 90
  # Shitmed Change
  - type: SurgeryTool
    startSound:
      path: /Audio/_Shitmed/Medical/Surgery/retractor1.ogg
    endSound:
      path: /Audio/_Shitmed/Medical/Surgery/hemostat1.ogg
  - type: Hemostat
  - type: Tweezers # Shitmed
  - type: Tending # Shitmed

# Saws

- type: entity
  name: metal saw
  id: Saw
  parent: BaseToolSurgery
  description: For cutting wood and other objects to pieces. Or sawing bones, in case of emergency.
  components:
  - type: Sharp
  - type: Utensil
    types:
      - Knife
  - type: Sprite
    sprite: Objects/Specific/Medical/Surgery/saw.rsi
    state: saw
  - type: Item
    size: Normal
    sprite: Objects/Specific/Medical/Surgery/saw.rsi
    storedRotation: 90
  - type: Tool
    qualities:
      - Sawing
  # Shitmed Change
  - type: BoneSaw
  - type: SurgeryTool
    startSound:
      path: /Audio/_Shitmed/Medical/Surgery/bone_saw.ogg
# No melee for regular saw because have you ever seen someone use a band saw as a weapon? It's dumb.

- type: entity
  name: choppa
  id: SawImprov
  parent: Saw
  description: A wicked serrated blade made of whatever nasty sharp things you could find. # It would make a pretty decent weapon, given there are more space for some tool mods too.
  components:
  - type: Sprite
    state: improv
  - type: Item
    size: Small
    heldPrefix: improv
  - type: MeleeWeapon
    damage:
      groups:
        Brute: 10
    soundHit:
      path: /Audio/Weapons/bladeslice.ogg
  - type: Tool
    speedModifier: 0.5
  - type: BoneSaw # Shitmed
    speed: 0.5

- type: entity
  name: circular saw
  id: SawElectric
  parent: Saw
  description: For heavy duty cutting.
  components:
  - type: Sprite
    sprite: _Shitmed/Objects/Specific/Medical/Surgery/circular-saw.rsi
    state: circular-saw
  - type: Item
    size: Normal
    sprite: _Shitmed/Objects/Specific/Medical/Surgery/circular-saw.rsi
  - type: MeleeWeapon
    damage:
      groups:
        Brute: 15
    soundHit:
      path: /Audio/Items/drill_hit.ogg
  - type: Tool
    speedModifier: 1.5
  - type: BoneSaw # Shitmed
    speed: 1.5
  - type: SurgeryTool
    startSound:
      path: /Audio/_Shitmed/Medical/Surgery/saw.ogg

- type: entity
  name: advanced circular saw
  id: SawAdvanced
  parent: [ SawElectric ]
  description: You think you can cut anything with it.
  components:
  - type: Sprite
    sprite: Objects/Specific/Medical/Surgery/saw.rsi
    state: advanced
  - type: Item
    size: Normal
    sprite: Objects/Specific/Medical/Surgery/saw.rsi
    storedRotation: 90
    heldPrefix: advanced
  - type: MeleeWeapon
    attackRate: 1.5
  - type: Tool
    speedModifier: 2.0
  - type: BoneSaw # Shitmed
    speed: 2
