# Base

- type: entity
  parent: FoodInjectableBase
  id: FoodEggBase
  description: An egg!
  abstract: true
  components:
  - type: Tag
    tags:
      - Egg
  - type: Food
    trash: Eggshells
  - type: Sprite
    sprite: Objects/Consumable/Food/egg.rsi
  - type: Item
    sprite: Objects/Consumable/Food/egg.rsi
    netsync: false
    size: 1
  - type: SolutionContainerManager
    solutions:
      food:
        maxVol: 6
        reagents:
        - ReagentId: Egg
          Quantity: 5
  - type: DamageOnLand
    damage:
      types:
        Blunt: 1
  - type: DamageOtherOnHit
    damage:
      types:
        Blunt: 1
       #Dignity: 25
  - type: DamageOnHighSpeedImpact
    minimumSpeed: 0.1
    damage:
      types:
        Blunt: 1
  - type: Damageable
    damageContainer: Biological
  - type: Destructible
    thresholds:
    - trigger:
        !type:DamageTrigger
        damage: 1
      behaviors:
      - !type:PlaySoundBehavior
        sound:
          collection: desecration
      - !type:SpawnEntitiesBehavior
        spawn:
          Eggshells:
            min: 1
            max: 1
          PuddleEgg:
            min: 1
            max: 2
          # Wow double-yolk you're so lucky!
      - !type:DoActsBehavior
        acts: [ "Destruction" ]

# Splat

- type: entity
  name: egg
  id: PuddleEgg
  parent: PuddleBase
  description: If the floor was a little hotter this would fry.
  components:
  - type: Sprite
    sprite: Fluids/egg_splat.rsi
    state: egg-0
    netsync: false
  - type: Puddle
  - type: SolutionContainerManager
    solutions:
      puddle:
        reagents:
        - ReagentId: Egg
          Quantity: 2
  - type: Evaporation
  - type: Appearance
    visuals:
    - type: PuddleVisualizer

- type: entity
  name: eggshells
  parent: BaseItem
  id: Eggshells
  description: You're walkin' on 'em bud.
  components:
  - type: Food
  - type: Sprite
    sprite: Objects/Consumable/Food/egg.rsi
    state: eggshells
    netsync: false
  - type: Item
    size: 1
  - type: SolutionContainerManager
    solutions:
      food:
        maxVol: 2
        reagents:
        - ReagentId: Egg
          Quantity: 1
  - type: Tag
    tags:
    - Egg
    - Trash
  - type: Recyclable

# Egg

- type: entity
  parent: FoodEggBase
  id: FoodEgg
  name: egg
  components:
  - type: Sprite
    sprite: Objects/Consumable/Food/egg.rsi
    state: icon
  - type: RandomSpriteState
    spriteStates:
      - icon
      - white
