# SPDX-FileCopyrightText: 2023 Kara <lunarautomaton6@gmail.com>
# SPDX-FileCopyrightText: 2024 Aidenkrz <aiden@djkraz.com>
# SPDX-FileCopyrightText: 2024 Cojoke <83733158+Cojoke-dot@users.noreply.github.com>
# SPDX-FileCopyrightText: 2024 CookieMasterT <124045269+CookieMasterT@users.noreply.github.com>
# SPDX-FileCopyrightText: 2024 Ed <96445749+TheShuEd@users.noreply.github.com>
# SPDX-FileCopyrightText: 2024 Emisse <99158783+Emisse@users.noreply.github.com>
# SPDX-FileCopyrightText: 2024 Errant <35878406+Errant-4@users.noreply.github.com>
# SPDX-FileCopyrightText: 2024 IProduceWidgets <107586145+IProduceWidgets@users.noreply.github.com>
# SPDX-FileCopyrightText: 2024 JustCone <141039037+JustCone14@users.noreply.github.com>
# SPDX-FileCopyrightText: 2024 Mervill <mervills.email@gmail.com>
# SPDX-FileCopyrightText: 2024 MilenVolf <63782763+MilenVolf@users.noreply.github.com>
# SPDX-FileCopyrightText: 2024 Milon <plmilonpl@gmail.com>
# SPDX-FileCopyrightText: 2024 Mr. 27 <45323883+Dutch-VanDerLinde@users.noreply.github.com>
# SPDX-FileCopyrightText: 2024 Naive817 <lyx2020@sjtu.edu.cn>
# SPDX-FileCopyrightText: 2024 Nemanja <98561806+EmoGarbage404@users.noreply.github.com>
# SPDX-FileCopyrightText: 2024 PJBot <pieterjan.briers+bot@gmail.com>
# SPDX-FileCopyrightText: 2024 Pieter-Jan Briers <pieterjan.briers+git@gmail.com>
# SPDX-FileCopyrightText: 2024 Piras314 <p1r4s@proton.me>
# SPDX-FileCopyrightText: 2024 PopGamer46 <yt1popgamer@gmail.com>
# SPDX-FileCopyrightText: 2024 ScarKy0 <106310278+ScarKy0@users.noreply.github.com>
# SPDX-FileCopyrightText: 2024 ScarKy0 <scarky0@onet.eu>
# SPDX-FileCopyrightText: 2024 Spessmann <156740760+Spessmann@users.noreply.github.com>
# SPDX-FileCopyrightText: 2024 The Canned One <greentopcan@gmail.com>
# SPDX-FileCopyrightText: 2024 Winkarst <74284083+Winkarst-cpu@users.noreply.github.com>
# SPDX-FileCopyrightText: 2024 coolboy911 <85909253+coolboy911@users.noreply.github.com>
# SPDX-FileCopyrightText: 2024 deltanedas <39013340+deltanedas@users.noreply.github.com>
# SPDX-FileCopyrightText: 2024 deltanedas <@deltanedas:kde.org>
# SPDX-FileCopyrightText: 2024 gluesniffler <159397573+gluesniffler@users.noreply.github.com>
# SPDX-FileCopyrightText: 2024 liltenhead <104418166+liltenhead@users.noreply.github.com>
# SPDX-FileCopyrightText: 2024 lunarcomets <140772713+lunarcomets@users.noreply.github.com>
# SPDX-FileCopyrightText: 2024 lzk <124214523+lzk228@users.noreply.github.com>
# SPDX-FileCopyrightText: 2024 marbow <152051971+marboww@users.noreply.github.com>
# SPDX-FileCopyrightText: 2024 metalgearsloth <31366439+metalgearsloth@users.noreply.github.com>
# SPDX-FileCopyrightText: 2024 saintmuntzer <47153094+saintmuntzer@users.noreply.github.com>
# SPDX-FileCopyrightText: 2025 Aiden <28298836+Aidenkrz@users.noreply.github.com>
# SPDX-FileCopyrightText: 2025 Aiden <aiden@djkraz.com
# SPDX-FileCopyrightText: 2025 BeBright <98597725+be1bright@users.noreply.github.com>
# SPDX-FileCopyrightText: 2025 BeBright <98597725+bebr3ght@users.noreply.github.com>
# SPDX-FileCopyrightText: 2025 GoobBot <uristmchands@proton.me>
# SPDX-FileCopyrightText: 2025 Ilya246 <57039557+Ilya246@users.noreply.github.com>
# SPDX-FileCopyrightText: 2025 Ilya246 <ilyukarno@gmail.com>
#
# SPDX-License-Identifier: AGPL-3.0-or-later

- type: entity
  id: BorgChassisSelectable
  parent: BaseBorgChassisNT
  components:
  - type: Sprite
    layers:
    - state: robot
      map: ["enum.BorgVisualLayers.Body", "movement"]
    - state: robot_e_r
      map: ["enum.BorgVisualLayers.Light"]
      shader: unshaded
      visible: false
    - state: robot_l
      shader: unshaded
      map: ["light","enum.BorgVisualLayers.LightStatus"]
      visible: false
  - type: BorgChassis
    # Default borg can take no modules until selected type.
    maxModules: 0
    hasMindState: robot_e
    noMindState: robot_e_r
  - type: BorgTransponder
    sprite:
      sprite: Mobs/Silicon/chassis.rsi
      state: robot
    name: cyborg
  - type: InteractionPopup
    interactSuccessString: petting-success-generic-cyborg
    interactFailureString: petting-failure-generic-cyborg
  - type: BorgSwitchableType
    inherentRadioChannels:
    - Common
    # - Binary # Goobstation - replaced with collective mind
  - type: BorgSwitchableSubtype # Goobstation
    # - Binary # Goobstation - replaced with collective mind


- type: entity
  id: BorgChassisGeneric
  parent: BorgChassisSelectable
  name: generic cyborg
  suffix: type picked
  components:
  - type: BorgSwitchableType
    selectedBorgType: generic
  - type: BorgSwitchableSubtype # Goobstation
    borgSubtype: generic_default

- type: entity
  id: BorgChassisMining
  parent: BorgChassisSelectable
  name: salvage cyborg
  components:
  - type: BorgSwitchableType
    selectedBorgType: mining
  - type: BorgSwitchableSubtype # Goobstation
    borgSubtype: mining_default

- type: entity
  id: BorgChassisEngineer
  parent: BorgChassisSelectable
  name: engineer cyborg
  components:
  - type: BorgSwitchableType
    selectedBorgType: engineering
  - type: BorgSwitchableSubtype # Goobstation
    borgSubtype: engineer_default

- type: entity
  id: BorgChassisJanitor
  parent: BorgChassisSelectable
  name: janitor cyborg
  components:
  - type: BorgSwitchableType
    selectedBorgType: janitor
  - type: BorgSwitchableSubtype # Goobstation
    borgSubtype: janitor_default

- type: entity
  id: BorgChassisMedical
  parent: BorgChassisSelectable
  name: medical cyborg
  components:
  - type: BorgSwitchableType
    selectedBorgType: medical
  - type: BorgSwitchableSubtype # Goobstation
    borgSubtype: default_medical

- type: entity
  id: BorgChassisService
  parent: BorgChassisSelectable
  name: service cyborg
  components:
  - type: BorgSwitchableType
    selectedBorgType: service
  - type: BorgSwitchableSubtype # Goobstation
    borgSubtype: default_service

- type: entity
  id: BorgChassisSyndicateAssault
  parent: BaseBorgChassisSyndicate
  name: syndicate assault cyborg
  description: A lean, mean killing machine with access to a variety of deadly modules.
  components:
    - type: Sprite
      layers:
        - state: synd_sec
        - state: synd_sec_e
          map: ["enum.BorgVisualLayers.Light"]
          shader: unshaded
          visible: false
        - state: synd_sec_l
          shader: unshaded
          map: ["light"]
          visible: false
    - type: BorgChassis
      maxModules: 3
      moduleWhitelist:
        tags:
          - BorgModuleGeneric
          - BorgModuleSyndicate
          - BorgModuleSyndicateAssault
      hasMindState: synd_sec_e
      noMindState: synd_sec
    - type: InteractionPopup
      interactSuccessString: petting-success-syndicate-cyborg
      interactFailureString: petting-failure-syndicate-cyborg
      interactSuccessSound:
        path: /Audio/Ambience/Objects/periodic_beep.ogg

- type: entity
  id: BorgChassisSyndicateMedical
  parent: [BaseBorgChassisSyndicate, ShowMedicalIcons]
  name: syndicate medical cyborg
  description: A combat medical cyborg. Has limited offensive potential, but makes more than up for it with its support capabilities.
  components:
    - type: Sprite
      layers:
        - state: synd_medical
        - state: synd_medical_e
          map: ["enum.BorgVisualLayers.Light"]
          shader: unshaded
          visible: false
        - state: synd_medical_l
          shader: unshaded
          map: ["light"]
          visible: false
    - type: BorgChassis
      maxModules: 3
      moduleWhitelist:
        tags:
          - BorgModuleGeneric
          - BorgModuleMedical
          - BorgModuleSyndicate
      hasMindState: synd_medical_e
      noMindState: synd_medical
    - type: ShowHealthBars
    - type: InteractionPopup
      interactSuccessString: petting-success-syndicate-cyborg
      interactFailureString: petting-failure-syndicate-cyborg
      interactSuccessSound:
        path: /Audio/Ambience/Objects/periodic_beep.ogg
    - type: SolutionScanner
    - type: FootstepModifier
      footstepSoundCollection:
        collection: FootstepHoverBorg
        params:
          volume: -6

- type: entity
  id: BorgChassisSyndicateSaboteur
  parent: BaseBorgChassisSyndicate
  name: syndicate saboteur cyborg
  description: A streamlined engineering cyborg, equipped with covert modules. Its chameleon projector lets it disguise itself as a Nanotrasen cyborg.
  components:
    - type: Sprite
      layers:
        - state: synd_engi
        - state: synd_engi_e
          map: ["enum.BorgVisualLayers.Light"]
          shader: unshaded
          visible: false
        - state: synd_engi_l
          shader: unshaded
          map: ["light"]
          visible: false
    - type: BorgChassis
      maxModules: 3
      moduleWhitelist:
        tags:
          - BorgModuleGeneric
          - BorgModuleEngineering
          - BorgModuleSyndicate
      hasMindState: synd_engi_e
      noMindState: synd_engi
    - type: ShowHealthBars
      damageContainers:
      - Inorganic
      - Silicon
      - SiliconRadiation # Goobstation - Make IPCs take radiation
    - type: InteractionPopup
      interactSuccessString: petting-success-syndicate-cyborg
      interactFailureString: petting-failure-syndicate-cyborg
      interactSuccessSound:
        path: /Audio/Ambience/Objects/periodic_beep.ogg

- type: entity
  id: BorgChassisDerelict
  parent: BaseBorgChassisDerelict
  name: derelict cyborg
  description: A man-machine hybrid that assists in station activity. This one is in a state of great disrepair.
  components:
  - type: Sprite
    layers:
    - state: derelict
    - state: derelict_e_r
      map: ["enum.BorgVisualLayers.Light"]
      shader: unshaded
      visible: false
    - state: derelict_l
      shader: unshaded
      map: ["light"]
      visible: false
  - type: BorgChassis
    maxModules: 5 # the sixth one broke lol
    moduleWhitelist:
      tags:
      - BorgModuleGeneric
    hasMindState: derelict_e
    noMindState: derelict_e_r
  - type: Construction
    node: derelictcyborg
  - type: InteractionPopup
    interactSuccessString: petting-success-derelict-cyborg
    interactFailureString: petting-failure-derelict-cyborg
    interactSuccessSound:
      path: /Audio/Ambience/Objects/periodic_beep.ogg
