# SPDX-FileCopyrightText: 2021 Paul Ritter <ritter.paul1@googlemail.com>
# SPDX-FileCopyrightText: 2021 Vera Aguilera Puerto <6766154+Zumorica@users.noreply.github.com>
# SPDX-FileCopyrightText: 2021 wrexbe <81056464+wrexbe@users.noreply.github.com>
# SPDX-FileCopyrightText: 2022 20kdc <asdd2808@gmail.com>
# SPDX-FileCopyrightText: 2022 EmoGarbage404 <98561806+EmoGarbage404@users.noreply.github.com>
# SPDX-FileCopyrightText: 2022 Kara <lunarautomaton6@gmail.com>
# SPDX-FileCopyrightText: 2022 Morb <14136326+Morb0@users.noreply.github.com>
# SPDX-FileCopyrightText: 2022 Pieter-Jan Briers <pieterjan.briers+git@gmail.com>
# SPDX-FileCopyrightText: 2022 mirrorcult <lunarautomaton6@gmail.com>
# SPDX-FileCopyrightText: 2023 Alzore <140123969+Blackern5000@users.noreply.github.com>
# SPDX-FileCopyrightText: 2023 Checkraze <71046427+Cheackraze@users.noreply.github.com>
# SPDX-FileCopyrightText: 2023 Nim <128169402+Nimfar11@users.noreply.github.com>
# SPDX-FileCopyrightText: 2023 T-Stalker <43253663+DogZeroX@users.noreply.github.com>
# SPDX-FileCopyrightText: 2023 brainfood1183 <113240905+brainfood1183@users.noreply.github.com>
# SPDX-FileCopyrightText: 2023 deltanedas <39013340+deltanedas@users.noreply.github.com>
# SPDX-FileCopyrightText: 2023 deltanedas <@deltanedas:kde.org>
# SPDX-FileCopyrightText: 2023 metalgearsloth <comedian_vs_clown@hotmail.com>
# SPDX-FileCopyrightText: 2024 Emisse <99158783+Emisse@users.noreply.github.com>
# SPDX-FileCopyrightText: 2024 Nemanja <98561806+EmoGarbage404@users.noreply.github.com>
# SPDX-FileCopyrightText: 2025 Aiden <28298836+Aidenkrz@users.noreply.github.com>
#
# SPDX-License-Identifier: AGPL-3.0-or-later
# NOTE! All mobs that come out of this should have Salvage rulesets.
# These rulesets exist because Salvage mobs kept harassing the station and going out of control.

- type: entity
  name: Salvage Material Crate Spawner
  id: SalvageMaterialCrateSpawner
  parent: MarkerBase
  components:
    - type: Sprite
      layers:
        - state: red
        - sprite: Structures/Storage/Crates/generic.rsi
          state: icon
    - type: RandomSpawner
      rarePrototypes:
        - SalvageHumanCorpse
        - CrateMaterialPlasteel
        - CrateMaterialWood
        - CrateMaterialPlastic
        - CrateSalvageEquipment
        - CrateMaterialSteel
        - CrateMaterialGlass
        - CrateServiceJanitorialSupplies
        - CrateHydroponicsSeedsMedicinal
        - CrateEmergencyInternals
        - CrateFoodMRE
        - CrateMaterialTextiles
        - CrateMedicalSupplies
        - CrateEngineeringCableBulk
        - CrateMaterialCardboard
        - CrateServiceBooks
        - CrateServiceSmokeables
        - CrateTrashCartFilled
        - ClosetMaintenanceFilledRandom
        - ClosetEmergencyFilledRandom
      rareChance: 0.4
      prototypes:
        - CrateSalvageAssortedGoodies
      chance: 0.9
      offset: 0.0

- type: entity
  name: salvage loot spawner
  id: SalvageLootSpawner
  parent: MarkerBase
  components:
    - type: Sprite
      layers:
        - state: red
        - sprite: Objects/Weapons/Melee/crusher.rsi
          state: icon
    - type: RandomSpawner
      prototypes:
      - WeaponCrusher
      - WeaponCrusherDagger
      - WeaponCrusherGlaive
      - MiningDrill
      offset: 0.0

- type: entity
  name: Salvage Mob Spawner
  id: SalvageMobSpawner
  parent: MarkerBase
  suffix: 25
  components:
    - type: Sprite
      layers:
        - state: red
        - sprite: Mobs/Aliens/Carps/space.rsi
          state: icon
    - type: RandomSpawner
      rarePrototypes:
      - MobSharkSalvage
      rareChance: 0.2
      prototypes:
        - MobCarpSalvage
        - MobCarpSalvage
        - MobCarpSalvage
        - MobCarpSalvage
        - MobCarpSalvage
        - MobTickSalvage
        - MobTickSalvage
        - MobTickSalvage
        - PlushieCarp
        - DehydratedSpaceCarp
      chance: 0.25
      offset: 0.2

- type: entity #I made this in case someone decided to make a terrifying space tick swarm for salvage. that someone may be me -EG404
  name: Salvage Space Tick Spawner
  id: SpaceTickSpawner
  parent: MarkerBase
  suffix: 100
  components:
    - type: Sprite
      layers:
        - state: red
        - sprite: Mobs/Aliens/Xenos/spacetick.rsi
          state: icon
    - type: ConditionalSpawner
      prototypes:
        - MobTickSalvage

- type: entity
  name: Salvage Space Bear Spawner
  id: SpawnMobBearSalvage
  parent: MarkerBase
  components:
  - type: Sprite
    layers:
    - state: green
    - state: bear
      sprite: Mobs/Animals/bear.rsi
  - type: ConditionalSpawner
    prototypes:
    - MobBearSpaceSalvage

- type: entity
  id: SalvageMobSpawner75
  parent: SalvageMobSpawner
  suffix: 75
  components:
  - type: RandomSpawner
    rarePrototypes:
    - MobSharkSalvage
    rareChance: 0.2
    prototypes:
    - MobCarpSalvage
    - MobCarpSalvage
    - MobCarpSalvage
    - MobCarpSalvage
    - MobCarpSalvage
    - MobTickSalvage
    - MobTickSalvage
    - MobTickSalvage
    - PlushieCarp
    - DehydratedSpaceCarp
    chance: 0.75
    offset: 0.2

- type: entity
  name: Salvage Space Kangaroo Spawner
  id: SpawnMobKangarooSalvage
  parent: MarkerBase
  components:
  - type: Sprite
    layers:
    - state: green
    - state: kangaroo-space
      sprite: Mobs/Animals/kangaroo.rsi
  - type: ConditionalSpawner
    prototypes:
    - MobKangarooSpaceSalvage

- type: entity
  name: Salvage Space Spider Spawner
  id: SpawnMobSpiderSalvage
  parent: MarkerBase
  components:
  - type: Sprite
    layers:
    - state: green
    - state: spacespider
      sprite: Mobs/Animals/spacespider.rsi
  - type: ConditionalSpawner
    prototypes:
    - MobSpiderSpaceSalvage

- type: entity
  name: Salvage Space Cobra Spawner
  id: SpawnMobCobraSalvage
  parent: MarkerBase
  components:
  - type: Sprite
    layers:
      - state: green
      - state: spacecobra
        sprite: Mobs/Animals/spacecobra.rsi
  - type: ConditionalSpawner
    prototypes:
    - MobCobraSpaceSalvage

- type: entity
  name: Salvage Flesh Spawner
  id: SalvageFleshSpawner
  parent: SalvageMobSpawner
  suffix: 100
  components:
    - type: Sprite
      layers:
        - state: red
        - sprite: Mobs/Aliens/flesh.rsi
          state: jared
    - type: RandomSpawner
      rarePrototypes:
      - MobSharkSalvage
      rareChance: 0
      prototypes:
      - MobFleshJaredSalvage
      - MobFleshGolemSalvage
      - MobFleshGolemSalvage
      - MobFleshClampSalvage
      - MobFleshClampSalvage
      - MobFleshLoverSalvage
      - MobFleshLoverSalvage
      chance: 1
      offset: 0.2