# SPDX-License-Identifier: AGPL-3.0-or-later

- type: entity
  parent: BaseAction
  id: ActionCosmicSiphon
  name: Siphon Entropy
  description: Silently siphon entropy from your target.
  components:
  - type: Action
    useDelay: 30
    itemIconStyle: NoItem
    icon:
      sprite: _DV/CosmicCult/Icons/cosmiccult_abilities.rsi
      state: siphon
  - type: TargetAction
  - type: EntityTargetAction
    whitelist:
      components:
      - HumanoidAppearance
    blacklist:
      components:
      - CosmicCult
      - BibleUser
    event: !type:EventCosmicSiphon {}

- type: entity
  parent: BaseAction
  id: ActionCosmicBlank
  name: Shunt Subjectivity
  description: Shunt your target's mind out of their body and unto the cosmic dark, temporarily rendering their body mindless.
  components:
  - type: Action
    useDelay: 120
    itemIconStyle: NoItem
    icon:
      sprite: _DV/CosmicCult/Icons/cosmiccult_abilities.rsi
      state: blank
  - type: TargetAction
  - type: EntityTargetAction
    canTargetSelf: true
    whitelist:
      components:
      - HumanoidAppearance
    blacklist:
      components:
      - CosmicCult
      - BibleUser
    event: !type:EventCosmicBlank {}

- type: entity
  parent: BaseAction
  id: ActionCosmicPlaceMonument
  name: Beckon The Monument
  description: Call forth The Monument into realspace. Keep it hidden and safe from non-cultists!
  components:
  - type: Action
    useDelay: 999
    itemIconStyle: NoItem
    icon:
      sprite: _DV/CosmicCult/Icons/cosmiccult_abilities.rsi
      state: monument
  - type: ConfirmableAction
    popup: cosmicability-monument-spawn-confirm
    primeTime: 10 #increased to give you more time to figure out where you want to put it
  - type: InstantAction
    event: !type:EventCosmicPlaceMonument {}
  - type: MonumentPlacementPreview
    tier: 1

- type: entity
  parent: BaseAction
  id: ActionCosmicMoveMonument
  name: Relocate The Monument
  description: Your work is imperative, and the end is inevitable. Ensure that it is completed under your watch.
  components:
  - type: Action
    useDelay: 600 # Goobstation
    itemIconStyle: NoItem
    icon:
      sprite: _DV/CosmicCult/Icons/cosmiccult_abilities.rsi
      state: monument-relocate
  - type: ConfirmableAction
    popup: cosmicability-monument-move-confirm
    primeTime: 10 #increased to give you more time to figure out where you want to put it
  - type: InstantAction
    event: !type:EventCosmicMoveMonument
  - type: MonumentPlacementPreview
    tier: 2

- type: entity
  parent: BaseAction
  id: ActionCosmicReturn
  name: Return
  description: Dissipate your astral projection and return to your body.
  components:
  - type: Action
    checkCanInteract: false
    itemIconStyle: NoItem
    useDelay: 0
    icon:
      sprite: _DV/CosmicCult/Icons/cosmiccult_abilities.rsi
      state: return
  - type: InstantAction
    event: !type:EventCosmicReturn {}

- type: entity
  parent: BaseAction
  id: ActionCosmicLapse
  name: Abberant Lapse
  description: Lapse your target's corporeal form, temporarily rendering it immutable, impassible, and frozen in place.
  components:
  - type: Action
    useDelay: 45
    itemIconStyle: NoItem
    icon:
      sprite: _DV/CosmicCult/Icons/cosmiccult_abilities.rsi
      state: lapse
  - type: TargetAction
  - type: EntityTargetAction
    canTargetSelf: true
    whitelist:
      components:
      - HumanoidAppearance
    blacklist:
      components:
      - BibleUser
    event: !type:EventCosmicLapse {}

- type: entity
  parent: BaseAction
  id: ActionCosmicGlare
  name: Null Glare
  description: Emit a horrific pulse of cosmic light, slowing and disorienting everyone around you. Its effects are amplified against silicon-based entities.
  components:
  - type: Action
    useDelay: 60
    checkCanInteract: false
    itemIconStyle: NoItem
    icon:
      sprite: _DV/CosmicCult/Icons/cosmiccult_abilities.rsi
      state: glare
  - type: ConfirmableAction
    popup: cosmicability-glare-confirm
    confirmDelay: 0.1
    primeTime: 5 #increased to give you more time to figure out where you want to put it
  - type: InstantAction
    event: !type:EventCosmicGlare {}

- type: entity
  parent: BaseAction
  id: ActionCosmicIngress
  name: Force Ingress
  description: Use a concentrated blast of power to force a secure doorway open.
  components:
  - type: Action
    useDelay: 15
    itemIconStyle: NoItem
    icon:
      sprite: _DV/CosmicCult/Icons/cosmiccult_abilities.rsi
      state: ingress
  - type: TargetAction
  - type: EntityTargetAction
    whitelist:
      components:
      - Door
    event: !type:EventCosmicIngress {}

- type: entity
  parent: BaseAction
  id: ActionCosmicImposition
  name: Vacuous Imposition
  description: You negate any incoming damage for a short time.
  components:
  - type: Action
    useDelay: 80
    checkCanInteract: false
    itemIconStyle: NoItem
    icon:
      sprite: _DV/CosmicCult/Icons/cosmiccult_abilities.rsi
      state: entropic
  - type: InstantAction
    event: !type:EventCosmicImposition {}

- type: entity
  parent: BaseAction
  id: ActionCosmicNova
  name: Astral Nova
  description: Hurl a large and disruptive blast of astral energy.
  components:
  - type: Action
    useDelay: 60
    itemIconStyle: NoItem
    icon:
      sprite: _DV/CosmicCult/Icons/cosmiccult_abilities.rsi
      state: nova
  - type: TargetAction
    range: 6000 # You're just picking a direction anyways
  - type: WorldTargetAction
    event: !type:EventCosmicNova {}

- type: entity
  parent: BaseAction
  id: ActionCosmicFragmentation
  name: Null Fragmentation
  description: Transfer your malign empowerment into a digital system, such as an AI Upload Console or Cyborg, corrupting it in the process. Doing so will expend your empowerment.
  components:
  - type: Action
    useDelay: 25
    itemIconStyle: NoItem
    icon:
      sprite: _DV/CosmicCult/Icons/cosmiccult_abilities.rsi
      state: corruption
  - type: TargetAction
  - type: EntityTargetAction
    whitelist:
      components:
      - BorgChassis
      - SiliconLawUpdater
    event: !type:EventCosmicFragmentation {}
  - type: LimitedCharges
    maxCharges: 1

## COLOSSUS ACTIONS

- type: entity
  parent: BaseAction
  id: ActionCosmicColossusSunder
  name: Entropic Sunder
  description: Warp to the target location and unleash a cascading detonation of malign energy.
  components:
  - type: Action
    useDelay: 18
    itemIconStyle: NoItem
    icon:
      sprite: _DV/CosmicCult/Icons/cosmiccult_abilities.rsi
      state: sunder
  - type: TargetAction
    range: 7
  - type: WorldTargetAction
    event: !type:EventCosmicColossusSunder

- type: entity
  parent: BaseAction
  id: ActionCosmicColossusIngress
  name: Colossal Ingress
  description: Use your colossal strength to force open a doorway.
  components:
  - type: Action
    useDelay: 8
    itemIconStyle: NoItem
    icon:
      sprite: _DV/CosmicCult/Icons/cosmiccult_abilities.rsi
      state: ingress
  - type: TargetAction
    range: 2
  - type: EntityTargetAction
    whitelist:
      components:
      - Door
    event: !type:EventCosmicColossusIngress

- type: entity
  parent: BaseAction
  id: ActionCosmicColossusHibernate
  name: Slumber Shell
  description: Slumber your body for a period of time to regenerate integrity. Must be done on stable ground.
  components:
  - type: Action
    useDelay: 180
    checkCanInteract: false
    itemIconStyle: NoItem
    icon:
      sprite: _DV/CosmicCult/Icons/cosmiccult_abilities.rsi
      state: slumber
  - type: ConfirmableAction
    popup: cosmicability-hibernate-confirm
    confirmDelay: 0.1
    primeTime: 5
  - type: InstantAction
    event: !type:EventCosmicColossusHibernate {}

- type: entity
  id: ActionCosmicColossusEffigy
  name: Beckon an Effigy
  description: Draw out an Effigy of Entropy into realspace.
  components:
  - type: Action
    useDelay: 999
    itemIconStyle: NoItem
    icon:
      sprite: _DV/CosmicCult/Icons/cosmiccult_abilities.rsi
      state: nova
  - type: InstantAction
    event: !type:EventCosmicColossusEffigy {}
