# non-projectile / "gun" staves

# wand that gives lights an RGB effect.
- type: entity
  id: RGBStaff
  parent: BaseItem
  name: RGB staff
  description: Helps fix the underabundance of RGB gear on the station.
  components:
  - type: LimitedCharges
    maxCharges: 25
  - type: AutoRecharge
    rechargeDuration: 30
  - type: Sprite
    sprite: Objects/Weapons/Guns/Basic/staves.rsi
    layers:
    - state: nothing
    - state: nothing-unshaded
      shader: unshaded
  - type: ActionOnInteract
    requiresCharge: true
    actions:
    - ActionRgbLight
  - type: Item
    size: Normal
    inhandVisuals:
      left:
      - state: staff-inhand-left
      - state: staff-inhand-left-unshaded
        shader: unshaded
      right:
      - state: staff-inhand-right
      - state: staff-inhand-right-unshaded
        shader: unshaded
  - type: RgbLightController
  - type: PointLight
    enabled: true
    radius: 2

- type: entity
  id: AnimationStaff
  parent: [ BaseItem, BaseMagicalContraband ]
  name: staff of animation
  description: Brings inanimate objects to life!
  components:
  - type: LimitedCharges
    maxCharges: 5
  - type: AutoRecharge
    rechargeDuration: 30
  - type: Sprite
    sprite: Objects/Weapons/Guns/Basic/staves.rsi
    layers:
    - state: animation
  - type: ActionOnInteract
    requiresCharge: true
    actions:
    - ActionAnimateSpell
  - type: Item
    size: Normal
    inhandVisuals:
      left:
      - state: animation-inhand-left
      right:
      - state: animation-inhand-right
  - type: Tag
    tags:
    - WizardWand

- type: entity
  parent: BaseAction
  id: ActionRgbLight
  components:
  - type: TargetAction
  - type: EntityTargetAction
    whitelist: { components: [ PointLight ] }
    event: !type:ChangeComponentsSpellEvent
      toAdd:
      - type: RgbLightController
