# SPDX-FileCopyrightText: 2023 Alekshhh <44923899+Alekshhh@users.noreply.github.com>
# SPDX-FileCopyrightText: 2023 DrSmugleaf <DrSmugleaf@users.noreply.github.com>
# SPDX-FileCopyrightText: 2023 DrSmugleaf <drsmugleaf@gmail.com>
# SPDX-FileCopyrightText: 2023 I.K <45953835+notquitehadouken@users.noreply.github.com>
# SPDX-FileCopyrightText: 2023 Leon Friedrich <60421075+ElectroJr@users.noreply.github.com>
# SPDX-FileCopyrightText: 2023 Nemanja <98561806+EmoGarbage404@users.noreply.github.com>
# SPDX-FileCopyrightText: 2023 Vordenburg <114301317+Vordenburg@users.noreply.github.com>
# SPDX-FileCopyrightText: 2023 brainfood1183 <113240905+brainfood1183@users.noreply.github.com>
# SPDX-FileCopyrightText: 2023 lzk <124214523+lzk228@users.noreply.github.com>
# SPDX-FileCopyrightText: 2023 metalgearsloth <31366439+metalgearsloth@users.noreply.github.com>
# SPDX-FileCopyrightText: 2023 metalgearsloth <comedian_vs_clown@hotmail.com>
# SPDX-FileCopyrightText: 2023 notquitehadouken <1isthisameme>
# SPDX-FileCopyrightText: 2024 Alzore <140123969+Blackern5000@users.noreply.github.com>
# SPDX-FileCopyrightText: 2024 Ed <96445749+TheShuEd@users.noreply.github.com>
# SPDX-FileCopyrightText: 2025 Aiden <28298836+Aidenkrz@users.noreply.github.com>
# SPDX-FileCopyrightText: 2025 Aidenkrz <aiden@djkraz.com>
# SPDX-FileCopyrightText: 2025 Aineias1 <dmitri.s.kiselev@gmail.com>
# SPDX-FileCopyrightText: 2025 FaDeOkno <143940725+FaDeOkno@users.noreply.github.com>
# SPDX-FileCopyrightText: 2025 GoobBot <uristmchands@proton.me>
# SPDX-FileCopyrightText: 2025 McBosserson <148172569+McBosserson@users.noreply.github.com>
# SPDX-FileCopyrightText: 2025 Milon <plmilonpl@gmail.com>
# SPDX-FileCopyrightText: 2025 Piras314 <p1r4s@proton.me>
# SPDX-FileCopyrightText: 2025 Rouden <149893554+Roudenn@users.noreply.github.com>
# SPDX-FileCopyrightText: 2025 TheBorzoiMustConsume <197824988+TheBorzoiMustConsume@users.noreply.github.com>
# SPDX-FileCopyrightText: 2025 Unlumination <144041835+Unlumy@users.noreply.github.com>
# SPDX-FileCopyrightText: 2025 coderabbitai[bot] <136622811+coderabbitai[bot]@users.noreply.github.com>
# SPDX-FileCopyrightText: 2025 deltanedas <39013340+deltanedas@users.noreply.github.com>
# SPDX-FileCopyrightText: 2025 deltanedas <@deltanedas:kde.org>
# SPDX-FileCopyrightText: 2025 gluesniffler <159397573+gluesniffler@users.noreply.github.com>
# SPDX-FileCopyrightText: 2025 gluesniffler <linebarrelerenthusiast@gmail.com>
# SPDX-FileCopyrightText: 2025 thebiggestbruh <marcus2008stoke@gmail.com>
# SPDX-FileCopyrightText: 2025 username <113782077+whateverusername0@users.noreply.github.com>
# SPDX-FileCopyrightText: 2025 whateverusername0 <whateveremail>
#
# SPDX-License-Identifier: AGPL-3.0-or-later

- type: entity
  parent: [ SimpleMobBase, MobCombat ]
  id: BaseMobFlesh
  name: aberrant flesh
  description: A shambling mass of flesh, animated through anomalous energy.
  abstract: true
  components:
  - type: HTN
    rootTask:
      task: SimpleHostileCompound
    blackboard:
      NavClimb: !type:Bool
        true
      NavSmash: !type:Bool
        true
  - type: NPCImprintingOnSpawnBehaviour
    spawnFriendsSearchRadius: 10
    whitelist:
      components:
      - Anomaly # Friendly to inner anomaly host
  - type: NpcFactionMember
    factions:
    - SimpleHostile
  - type: Tag
    tags:
    - DoorBumpOpener
    - Flesh
  - type: Sprite
    drawdepth: Mobs
    sprite: Mobs/Aliens/flesh.rsi
  - type: MovementAlwaysTouching
  - type: MovementSpeedModifier
    baseWalkSpeed: 1
    baseSprintSpeed: 1.5
  - type: MobState
    allowedStates:
    - Alive
    - Dead
  - type: MobThresholds
    thresholds:
      0: Alive
      75: Dead
  - type: Stamina
    critThreshold: 50
    animationThreshold: 25
  - type: Butcherable
    spawned:
    - id: FoodMeat
      amount: 1
  - type: Bloodstream
    bloodMaxVolume: 100
  - type: CombatMode
  - type: MeleeWeapon
    soundHit:
      path: /Audio/Weapons/Xeno/alien_claw_flesh3.ogg
    angle: 0
    animation: WeaponArcClaw
    damage:
      types:
        Slash: 6
  - type: ReplacementAccent
    accent: genericAggressive

- type: entity
  parent: BaseMobFlesh
  id: MobFleshJared
  components:
  - type: Sprite
    layers:
    - map: [ "enum.DamageStateVisualLayers.Base" ]
      state: jared
  - type: DamageStateVisuals
    states:
      Alive:
        Base: jared
      Critical:
        Base: dead
      Dead:
        Base: dead
  - type: MeleeWeapon
    soundHit:
        path: /Audio/Weapons/Xeno/alien_claw_flesh3.ogg
    angle: 0
    animation: WeaponArcClaw
    damage:
      types:
        Slash: 8

- type: entity
  parent: BaseMobFlesh
  id: MobFleshGolem
  components:
  - type: Sprite
    layers:
    - map: [ "enum.DamageStateVisualLayers.Base" ]
      state: golem
  - type: DamageStateVisuals
    states:
      Alive:
        Base: golem
      Critical:
        Base: dead
      Dead:
        Base: dead
  - type: MobThresholds
    thresholds:
      0: Alive
      50: Dead
  - type: MeleeWeapon
    soundHit:
        path: /Audio/Weapons/Xeno/alien_claw_flesh3.ogg
    angle: 0
    animation: WeaponArcClaw
    damage:
      types:
        Slash: 8

- type: entity
  parent: BaseMobFlesh
  id: MobFleshClamp
  components:
  - type: Sprite
    layers:
    - map: [ "enum.DamageStateVisualLayers.Base" ]
      state: clamp
  - type: DamageStateVisuals
    states:
      Alive:
        Base: clamp
      Critical:
        Base: dead
      Dead:
        Base: dead
  - type: MobThresholds
    thresholds:
      0: Alive
      30: Dead
  - type: MovementSpeedModifier
    baseWalkSpeed: 2
    baseSprintSpeed: 2.5

- type: entity
  parent: BaseMobFlesh
  id: MobFleshLover
  components:
  - type: Sprite
    layers:
    - map: [ "enum.DamageStateVisualLayers.Base" ]
      state: lover
  - type: DamageStateVisuals
    states:
      Alive:
        Base: lover
      Critical:
        Base: dead
      Dead:
        Base: dead
  - type: MobThresholds
    thresholds:
      0: Alive
      30: Dead
  - type: MovementSpeedModifier
    baseWalkSpeed: 2
    baseSprintSpeed: 2.5

- type: entity
  parent: BaseMobFlesh
  id: MobAbomination
  name: abomination
  description: A rejected clone, in constant pain and seeking revenge.
  components:
  - type: Sprite
    drawdepth: Mobs
    sprite: Mobs/Demons/abomination.rsi
    layers:
    - map: ["enum.DamageStateVisualLayers.Base"]
      state: abomination
  - type: DamageStateVisuals
    states:
      Alive:
        Base: abomination
      Dead:
        Base: dead
  - type: MobState
    allowedStates:
    - Alive
    - Dead
  - type: MobThresholds
    thresholds:
      0: Alive
      100: Dead
  - type: MovementSpeedModifier
    baseWalkSpeed: 1.5
    baseSprintSpeed: 2.5
  - type: MeleeWeapon
    soundHit:
        path: /Audio/Weapons/Xeno/alien_claw_flesh3.ogg
    angle: 0
    animation: WeaponArcClaw
    damage:
      types:
        Blunt: 10

- type: entity
  parent: [ SimpleSpaceMobBase, MobCombat ]
  id: BaseMobFleshSalvage #This one is immune to space!
  name: aberrant flesh
  suffix: "Salvage Ruleset"
  description: A shambling mass of flesh, animated through anomalous energy.
  abstract: true
  components:
  - type: HTN
    rootTask:
      task: SimpleHostileCompound
    blackboard:
      NavClimb: !type:Bool
        true
      NavSmash: !type:Bool
        true
  - type: NpcFactionMember
    factions:
    - SimpleHostile
  - type: Tag
    tags:
    - DoorBumpOpener
    - Flesh
  - type: Sprite
    drawdepth: Mobs
    sprite: Mobs/Aliens/flesh.rsi
  - type: MovementAlwaysTouching
  - type: MovementSpeedModifier
    baseWalkSpeed: 1
    baseSprintSpeed: 1.5
  - type: MobState
    allowedStates:
    - Alive
    - Dead
  - type: MobThresholds
    thresholds:
      0: Alive
      75: Dead
  - type: Stamina
    critThreshold: 50
    animationThreshold: 25
  - type: Butcherable
    spawned:
    - id: FoodMeat
      amount: 1
  - type: Bloodstream
    bloodMaxVolume: 100
  - type: CombatMode
  - type: MeleeWeapon
    soundHit:
      path: /Audio/Weapons/Xeno/alien_claw_flesh3.ogg
    angle: 0
    animation: WeaponArcClaw
    damage:
      types:
        Slash: 6
  - type: ReplacementAccent
    accent: genericAggressive
  - type: SalvageMobRestrictions

- type: entity
  parent: BaseMobFleshSalvage
  id: MobFleshJaredSalvage
  components:
  - type: Sprite
    layers:
    - map: [ "enum.DamageStateVisualLayers.Base" ]
      state: jared
  - type: DamageStateVisuals
    states:
      Alive:
        Base: jared
      Critical:
        Base: dead
      Dead:
        Base: dead
  - type: MeleeWeapon
    soundHit:
        path: /Audio/Weapons/Xeno/alien_claw_flesh3.ogg
    angle: 0
    animation: WeaponArcClaw
    damage:
      types:
        Slash: 8

- type: entity
  parent: BaseMobFleshSalvage
  id: MobFleshGolemSalvage
  components:
  - type: Sprite
    layers:
    - map: [ "enum.DamageStateVisualLayers.Base" ]
      state: golem
  - type: DamageStateVisuals
    states:
      Alive:
        Base: golem
      Critical:
        Base: dead
      Dead:
        Base: dead
  - type: MobThresholds
    thresholds:
      0: Alive
      50: Dead
  - type: MeleeWeapon
    soundHit:
        path: /Audio/Weapons/Xeno/alien_claw_flesh3.ogg
    angle: 0
    animation: WeaponArcClaw
    damage:
      types:
        Slash: 8

- type: entity
  parent: BaseMobFleshSalvage
  id: MobFleshClampSalvage
  components:
  - type: Sprite
    layers:
    - map: [ "enum.DamageStateVisualLayers.Base" ]
      state: clamp
  - type: DamageStateVisuals
    states:
      Alive:
        Base: clamp
      Critical:
        Base: dead
      Dead:
        Base: dead
  - type: MobThresholds
    thresholds:
      0: Alive
      30: Dead
  - type: MovementSpeedModifier
    baseWalkSpeed: 2
    baseSprintSpeed: 2.5

- type: entity
  parent: BaseMobFleshSalvage
  id: MobFleshLoverSalvage
  components:
  - type: Sprite
    layers:
    - map: [ "enum.DamageStateVisualLayers.Base" ]
      state: lover
  - type: DamageStateVisuals
    states:
      Alive:
        Base: lover
      Critical:
        Base: dead
      Dead:
        Base: dead
  - type: MobThresholds
    thresholds:
      0: Alive
      30: Dead
  - type: MovementSpeedModifier
    baseWalkSpeed: 2
    baseSprintSpeed: 2.5
