# SPDX-FileCopyrightText: 2022 AJCM-git <60196617+AJCM-git@users.noreply.github.com>
# SPDX-FileCopyrightText: 2022 EmoGarbage404 <98561806+EmoGarbage404@users.noreply.github.com>
# SPDX-FileCopyrightText: 2022 Flipp Syder <76629141+vulppine@users.noreply.github.com>
# SPDX-FileCopyrightText: 2022 Pieter-Jan Briers <pieterjan.briers+git@gmail.com>
# SPDX-FileCopyrightText: 2022 Rane <60792108+Elijahrane@users.noreply.github.com>
# SPDX-FileCopyrightText: 2022 keronshb <54602815+keronshb@users.noreply.github.com>
# SPDX-FileCopyrightText: 2022 metalgearsloth <metalgearsloth@gmail.com>
# SPDX-FileCopyrightText: 2023 Alex Evgrashin <aevgrashin@yandex.ru>
# SPDX-FileCopyrightText: 2023 Arendian <137322659+Arendian@users.noreply.github.com>
# SPDX-FileCopyrightText: 2023 Gotimanga <127038462+Gotimanga@users.noreply.github.com>
# SPDX-FileCopyrightText: 2023 LordCarve <27449516+LordCarve@users.noreply.github.com>
# SPDX-FileCopyrightText: 2023 Nemanja <98561806+EmoGarbage404@users.noreply.github.com>
# SPDX-FileCopyrightText: 2023 Tony <73495699+carteblanche4me@users.noreply.github.com>
# SPDX-FileCopyrightText: 2023 Visne <39844191+Visne@users.noreply.github.com>
# SPDX-FileCopyrightText: 2023 deltanedas <user@zenith>
# SPDX-FileCopyrightText: 2023 metalgearsloth <31366439+metalgearsloth@users.noreply.github.com>
# SPDX-FileCopyrightText: 2023 mhamster <81412348+mhamsterr@users.noreply.github.com>
# SPDX-FileCopyrightText: 2024 Aiden <aiden@djkraz.com>
# SPDX-FileCopyrightText: 2024 Aidenkrz <aiden@djkraz.com>
# SPDX-FileCopyrightText: 2024 Aviu00 <93730715+Aviu00@users.noreply.github.com>
# SPDX-FileCopyrightText: 2024 Brandon Hu <103440971+Brandon-Huu@users.noreply.github.com>
# SPDX-FileCopyrightText: 2024 CatMagic <135462166+CatMagic1@users.noreply.github.com>
# SPDX-FileCopyrightText: 2024 DrSmugleaf <DrSmugleaf@users.noreply.github.com>
# SPDX-FileCopyrightText: 2024 FoxxoTrystan <45297731+FoxxoTrystan@users.noreply.github.com>
# SPDX-FileCopyrightText: 2024 Ilya246 <57039557+Ilya246@users.noreply.github.com>
# SPDX-FileCopyrightText: 2024 Jay <67732946+DuskyJay@users.noreply.github.com>
# SPDX-FileCopyrightText: 2024 Just-a-Unity-Dev <67359748+Just-a-Unity-Dev@users.noreply.github.com>
# SPDX-FileCopyrightText: 2024 Kara <lunarautomaton6@gmail.com>
# SPDX-FileCopyrightText: 2024 Killerqu00 <47712032+Killerqu00@users.noreply.github.com>
# SPDX-FileCopyrightText: 2024 Kira Bridgeton <161087999+Verbalase@users.noreply.github.com>
# SPDX-FileCopyrightText: 2024 Leon Friedrich <60421075+ElectroJr@users.noreply.github.com>
# SPDX-FileCopyrightText: 2024 Morb <14136326+Morb0@users.noreply.github.com>
# SPDX-FileCopyrightText: 2024 Pspritechologist <naaronn@gmail.com>
# SPDX-FileCopyrightText: 2024 VMSolidus <evilexecutive@gmail.com>
# SPDX-FileCopyrightText: 2024 Whisper <121047731+QuietlyWhisper@users.noreply.github.com>
# SPDX-FileCopyrightText: 2024 Wrexbe (Josh) <81056464+wrexbe@users.noreply.github.com>
# SPDX-FileCopyrightText: 2024 brainfood1183 <113240905+brainfood1183@users.noreply.github.com>
# SPDX-FileCopyrightText: 2024 deathride58 <deathride58@users.noreply.github.com>
# SPDX-FileCopyrightText: 2024 deltanedas <39013340+deltanedas@users.noreply.github.com>
# SPDX-FileCopyrightText: 2024 deltanedas <@deltanedas:kde.org>
# SPDX-FileCopyrightText: 2024 metalgearsloth <comedian_vs_clown@hotmail.com>
# SPDX-FileCopyrightText: 2024 nikthechampiongr <32041239+nikthechampiongr@users.noreply.github.com>
# SPDX-FileCopyrightText: 2024 wrexbe <wrexbe@protonmail.com>
# SPDX-FileCopyrightText: 2024 yglop <95057024+yglop@users.noreply.github.com>
# SPDX-FileCopyrightText: 2025 Aiden <28298836+Aidenkrz@users.noreply.github.com>
# SPDX-FileCopyrightText: 2025 GoobBot <uristmchands@proton.me>
# SPDX-FileCopyrightText: 2025 Zachary Higgs <compgeek223@gmail.com>
# SPDX-FileCopyrightText: 2025 lzk <124214523+lzk228@users.noreply.github.com>
# SPDX-FileCopyrightText: 2025 pheenty <fedorlukin2006@gmail.com>
# SPDX-FileCopyrightText: 2025 psykana <36602558+psykana@users.noreply.github.com>
# SPDX-FileCopyrightText: 2025 slarticodefast <161409025+slarticodefast@users.noreply.github.com>
#
# SPDX-License-Identifier: AGPL-3.0-or-later
# base actions

# base prototype for all action entities
- type: entity
  abstract: true
  id: BaseAction
  components:
  - type: Action

# an action that is done all in le head and cant be prevented by any means
- type: entity
  abstract: true
  parent: BaseAction
  id: BaseMentalAction
  components:
  - type: Action
    checkCanInteract: false
    checkConsciousness: false

- type: entity
  abstract: true
  parent: BaseMentalAction
  id: BaseSuicideAction
  components:
  - type: ConfirmableAction
    popup: suicide-action-popup

- type: entity
  abstract: true
  parent: BaseAction
  id: BaseImplantAction
  components:
  - type: InstantAction
    event: !type:ActivateImplantEvent

- type: entity
  abstract: true
  parent: BaseAction
  id: BaseToggleAction
  components:
  - type: InstantAction
    event: !type:ToggleActionEvent

# actions

- type: entity
  parent: BaseAction
  id: ActionScream
  name: Scream
  description: AAAAAAAAAAAAAAAAAAAAAAAAA
  components:
  - type: Action
    useDelay: 10
    icon: Interface/Actions/scream.png
    checkCanInteract: false
  - type: InstantAction
    event: !type:ScreamActionEvent

- type: entity
  parent: BaseMentalAction
  id: ActionTurnUndead
  name: Turn Undead
  description: Succumb to your infection and become a zombie.
  components:
  - type: Action
    icon: Interface/Actions/zombie-turn.png
  - type: InstantAction
    event: !type:ZombifySelfActionEvent

- type: entity
  parent: BaseToggleAction
  id: ActionToggleLight
  name: Toggle Light
  description: Turn the light on and off.
  components:
  - type: Action
    useDelay: 1
    icon: { sprite: Objects/Tools/flashlight.rsi, state: flashlight }
    iconOn: { sprite: Objects/Tools/flashlight.rsi, state: flashlight-on }

- type: entity
  parent: BaseAction
  id: ActionOpenStorageImplant
  name: Toggle Storage Implant
  description: Opens or closes the storage implant embedded under your skin
  components:
  - type: Action
    itemIconStyle: BigAction
    priority: -20
    icon:
      sprite: Clothing/Back/Backpacks/backpack.rsi
      state: icon
    useDelay: 1
  - type: InstantAction
    event: !type:OpenStorageImplantEvent

- type: entity
  parent: [BaseSuicideAction, BaseImplantAction]
  id: ActionActivateMicroBomb
  name: Activate Microbomb
  description: Activates your internal microbomb, completely destroying you and your equipment
  components:
  - type: Action
    itemIconStyle: BigAction
    priority: -20
    icon:
      sprite: Actions/Implants/implants.rsi
      state: explosive

- type: entity
  parent: [BaseSuicideAction, BaseImplantAction]
  id: ActionActivateDeathAcidifier
  name: Activate Death-Acidifier
  description: Activates your death-acidifier, completely melting you and your equipment
  components:
  - type: Action
    itemIconStyle: BigAction
    priority: -20
    icon:
      sprite: Objects/Magic/magicactions.rsi
      state: gib

- type: entity
  parent: BaseAction
  id: ActionActivateFreedomImplant
  name: Break Free
  description: Activating your freedom implant will free you from any hand restraints
  components:
  - type: Action
    useDelay: 10 # Goob - useful freedom
    checkCanInteract: false
    itemIconStyle: BigAction
    priority: -20
    icon:
      sprite: Actions/Implants/implants.rsi
      state: freedom
  - type: InstantAction
    event: !type:UseFreedomImplantEvent

- type: entity
  parent: BaseAction
  id: ActionOpenUplinkImplant
  name: Open Uplink
  description: Opens the syndicate uplink embedded under your skin
  components:
  - type: Action
    itemIconStyle: BigAction
    priority: -20
    icon:
      sprite: Objects/Devices/communication.rsi
      state: radio
  - type: InstantAction
    event: !type:OpenUplinkImplantEvent

- type: entity
  parent: BaseImplantAction
  id: ActionActivateEmpImplant
  name: Activate EMP
  description: Triggers a small EMP pulse around you
  components:
  - type: Action
    checkCanInteract: false
    useDelay: 30
    itemIconStyle: BigAction
    priority: -20
    icon:
      sprite: Objects/Weapons/Grenades/empgrenade.rsi
      state: icon

- type: entity
  parent: BaseAction
  id: ActionActivateScramImplant
  name: SCRAM!
  description: Randomly teleports you within a large distance.
  components:
  - type: LimitedCharges
    maxCharges: 3
  - type: Action
    checkCanInteract: false
    useDelay: 30 # Goobstation
    itemIconStyle: BigAction
    priority: -20
    icon:
      sprite: Structures/Specific/anomaly.rsi
      state: anom4
  - type: InstantAction
    event: !type:UseScramImplantEvent

- type: entity
  parent: BaseAction
  id: ActionActivateDnaScramblerImplant
  name: Scramble DNA
  description:  Randomly changes your name and appearance.
  components:
  - type: ConfirmableAction
    popup: dna-scrambler-action-popup
  - type: LimitedCharges
    maxCharges: 1
  - type: Action
    itemIconStyle: BigAction
    priority: -20
    icon:
      sprite: Clothing/OuterClothing/Hardsuits/lingspacesuit.rsi
      state: icon
  - type: InstantAction
    event: !type:UseDnaScramblerImplantEvent

- type: entity
  parent: BaseAction
  id: ActionToggleSuitPiece
  name: Toggle Suit Piece
  description: Remember to equip the important pieces of your suit before going into action.
  components:
  - type: Action
    itemIconStyle: BigItem
    useDelay: 1 # equip noise spam.
  - type: InstantAction
    event: !type:ToggleClothingEvent

- type: entity
  parent: BaseMentalAction
  id: ActionCombatModeToggle
  name: "[color=red]Combat Mode[/color]"
  description: Enter combat mode
  components:
  - type: Action
    icon: Interface/Actions/harmOff.png
    iconOn: Interface/Actions/harm.png
    priority: -100
  - type: InstantAction
    event: !type:ToggleCombatActionEvent

- type: entity
  parent: ActionCombatModeToggle
  id: ActionCombatModeToggleOff
  components:
  - type: Action
    enabled: false
    autoPopulate: false

- type: entity
  parent: BaseAction
  id: ActionChangeVoiceMask
  name: Set name
  description: Change the name others hear to something else.
  components:
  - type: Action
    icon: { sprite: Interface/Actions/voice-mask.rsi, state: icon }
  - type: InstantAction
    event: !type:VoiceMaskSetNameEvent

- type: entity
  parent: BaseAction
  id: ActionVendingThrow
  name: Dispense Item
  description: Randomly dispense an item from your stock.
  components:
  - type: Action
    useDelay: 30
  - type: InstantAction
    event: !type:VendingMachineSelfDispenseEvent

- type: entity
  parent: BaseToggleAction
  id: ActionToggleBlock
  name: Block
  description: Raise or lower your shield.
  components:
  - type: Action
    icon: { sprite: Objects/Weapons/Melee/shields.rsi, state: teleriot-icon }
    iconOn: { sprite: Objects/Weapons/Melee/shields.rsi, state: teleriot-on }

- type: entity
  parent: BaseMentalAction
  id: ActionClearNetworkLinkOverlays
  name: Clear network link overlays
  description: Clear network link overlays.
  components:
  - type: Action
    clientExclusive: true
    temporary: true
    icon: { sprite: Objects/Tools/multitool.rsi, state: icon }
  - type: InstantAction
    event: !type:ClearAllOverlaysEvent

- type: entity
  parent: BaseAction
  id: ActionAnimalLayEgg
  name: Lay egg
  description: Uses hunger to lay an egg.
  components:
  - type: Action
    icon: { sprite: Objects/Consumable/Food/egg.rsi, state: icon }
    useDelay: 60
  - type: InstantAction
    event: !type:EggLayInstantActionEvent

- type: entity
  parent: BaseMentalAction
  id: ActionSleep
  name: Sleep
  description: Go to sleep.
  components:
  - type: Action
    icon: { sprite: Clothing/Head/Hats/pyjamasyndicatered.rsi, state: icon }
  - type: InstantAction
    event: !type:SleepActionEvent

- type: entity
  parent: BaseMentalAction
  id: ActionWake
  name: Wake up
  description: Stop sleeping.
  components:
  - type: Action
    startDelay: true
    useDelay: 2
    icon: { sprite: Clothing/Head/Hats/pyjamasyndicatered.rsi, state: icon }
  - type: InstantAction
    event: !type:WakeActionEvent

- type: entity
  parent: BaseImplantAction
  id: ActionActivateHonkImplant
  name: Honk
  description: Activates your honking implant, which will produce the signature sound of the clown.
  components:
  - type: Action
    icon: { sprite: Objects/Fun/bikehorn.rsi, state: icon }
    useDelay: 1

- type: entity
  parent: BaseAction
  id: ActionFireStarter
  name: Ignite
  description: Ignites enemies in a radius around you.
  components:
  - type: Action
    priority: -1
    useDelay: 30
    icon: Interface/Actions/firestarter.png
  - type: InstantAction
    event: !type:FireStarterActionEvent

- type: entity
  parent: BaseMentalAction
  id: ActionToggleEyes
  name: Open/Close eyes
  description: Close your eyes to protect your peepers, or open your eyes to enjoy the pretty lights.
  components:
  - type: Action
    icon: Interface/Actions/eyeopen.png
    iconOn: Interface/Actions/eyeclose.png
    useDelay: 1 # so u cant give yourself and observers eyestrain by rapidly spamming the action
  - type: InstantAction
    event: !type:ToggleEyesActionEvent

- type: entity
  parent: BaseToggleAction
  id: ActionToggleWagging
  name: Wagging Tail
  description: Start or stop wagging your tail.
  components:
  - type: Action
    icon: { sprite: Mobs/Customization/reptilian_parts.rsi, state: tail_smooth_behind }
    iconOn: { sprite: Mobs/Customization/reptilian_parts.rsi, state: tail_smooth_behind }
    itemIconStyle: NoItem
    useDelay: 1 # emote spam
    checkCanInteract: false

- type: entity
  parent: BaseAction
  id: FakeMindShieldToggleAction
  name: '[color=green]Toggle Fake Mindshield[/color]'
  description: Turn the Fake Mindshield implant's transmission on/off
  components:
  - type: Action
    icon: { sprite: Interface/Actions/actions_fakemindshield.rsi, state: icon }
    iconOn: { sprite: Interface/Actions/actions_fakemindshield.rsi, state: icon-on }
    itemIconStyle: NoItem
    useDelay: 1
  - type: InstantAction
    event: !type:FakeMindShieldToggleEvent
  - type: Tag
    tags:
    - FakeMindShieldImplant

# Goob - merge this
# - type: entity
#   parent: BaseToggleAction
#   id: ActionToggleParamedicSiren
#   name: Toggle Paramedic Siren
#   description: Toggles the paramedic siren on and off.
#   components:
#   - type: Action
#     icon:
#       sprite: Clothing/OuterClothing/Hardsuits/paramed.rsi
#       state: icon-siren
#     useDelay: 1
#     itemIconStyle: BigAction

- type: entity
  parent: BaseAction
  id: ActionGravityJump
  name: Jump
  description: Activating the advanced propulsion system, you propel yourself a short distance in the direction of your gaze.
  components:
  - type: Action
    useDelay: 8
    icon:
      sprite: Interface/Actions/jump.rsi
      state: icon
  - type: InstantAction
    event: !type:GravityJumpEvent {}

- type: entity
  parent: BaseToggleAction
  id: ActionToggleRootable
  name: Rootable
  description: Begin or stop being rooted to the floor.
  components:
  - type: Action
    icon: Interface/Actions/rooting.png
    iconOn: Interface/Actions/rooting.png
    itemIconStyle: NoItem
    useDelay: 1

- type: entity
  id: ActionChameleonController
  name: Control clothing
  description: Change your entire outfit fast!
  components:
  - type: Action
    priority: -20
    icon: { sprite: Actions/Implants/implants.rsi, state: chameleon }
    itemIconStyle: BigAction
  - type: InstantAction
    event: !type:ChameleonControllerOpenMenuEvent
