# Hytopia Model Particles v2.1.0 - Advanced Effects Configuration

# Templates for inheritance
templates:
  base_magic:
    lifetime: 3000
    physics:
      mass: 0.1
      friction: 0.5
      useGravity: false
    visual:
      scaleOverTime:
        start: 0.5
        end: 1.5
        curve: easeOut
      opacityOverTime:
        start: 1.0
        end: 0.0
        curve: easeIn

  base_physical:
    lifetime: 5000
    physics:
      mass: 0.5
      friction: 0.3
      bounciness: 0.4
      useGravity: true
      gravityScale: 1.0

# Effect definitions
effects:
  # Fire burst with color animation
  fire_burst:
    extends: base_magic
    model: models/particle_flame.fbx
    count: 40
    pattern: explosion
    patternModifiers:
      intensity: 1.5
      spread: 2.0
    visual:
      colorOverTime:
        type: smooth
        keyframes:
          - time: 0
            color: { r: 255, g: 255, b: 200 }
          - time: 0.3
            color: { r: 255, g: 200, b: 50 }
          - time: 0.7
            color: { r: 255, g: 100, b: 20 }
          - time: 1.0
            color: { r: 100, g: 20, b: 10 }
      scaleOverTime:
        start: 0.3
        end: 1.2
        curve: easeOut

  # Ice spiral with rotation
  ice_spiral:
    model: models/particle_crystal.fbx
    lifetime: 4000
    count: 50
    pattern: spiral
    patternModifiers:
      radius: 2.5
      height: 5
      rotations: 4
      velocityScale: 0.7
    visual:
      colorOverTime:
        type: linear
        keyframes:
          - time: 0
            color: { r: 200, g: 220, b: 255 }
          - time: 0.5
            color: { r: 150, g: 200, b: 255 }
          - time: 1.0
            color: { r: 100, g: 150, b: 255 }
      rotationOverTime:
        velocity: 90
        acceleration: 20
      scaleOverTime:
        start: 0.2
        end: 0.6

  # Energy wave
  energy_wave:
    model: models/particle_energy.fbx
    lifetime: 2000
    count: 60
    pattern: wave
    patternModifiers:
      wavelength: 5
      amplitude: 2
      spread: 8
      waves: 4
    visual:
      colorOverTime:
        type: smooth
        keyframes:
          - time: 0
            color: { r: 50, g: 255, b: 200 }
          - time: 0.5
            color: { r: 100, g: 200, b: 255 }
          - time: 1.0
            color: { r: 150, g: 150, b: 255 }
      scaleOverTime:
        start: 0.4
        end: 0.1
        curve: linear

  # Shield ring
  shield_ring:
    model: models/particle_shield.fbx
    lifetime: 1500
    count: 40
    pattern: ring
    patternModifiers:
      radius: 3
      expansionSpeed: 6
      rings: 3
      wobble: 0.3
    visual:
      opacityOverTime:
        start: 0.8
        end: 0.0
        curve: easeOut
      colorOverTime:
        type: linear
        keyframes:
          - time: 0
            color: { r: 100, g: 200, b: 255 }
          - time: 1.0
            color: { r: 50, g: 100, b: 200 }

  # Magical fountain
  magic_fountain:
    extends: base_physical
    model: models/particle_sparkle.fbx
    count: 150
    pattern: fountain
    patternModifiers:
      radius: 1.0
      height: 8
      spread: 30
      velocityMin: 3
      velocityMax: 7
    physics:
      gravityScale: 0.6
    visual:
      colorOverTime:
        type: smooth
        keyframes:
          - time: 0
            color: { r: 255, g: 200, b: 255 }
          - time: 0.3
            color: { r: 200, g: 150, b: 255 }
          - time: 0.7
            color: { r: 150, g: 100, b: 255 }
          - time: 1.0
            color: { r: 100, g: 50, b: 200 }
      scaleOverTime:
        start: 0.5
        end: 0.2
      opacityOverTime:
        start: 1.0
        end: 0.3

  # Lightning strike
  lightning_strike:
    model: models/particle_bolt.fbx
    lifetime: 800
    count: 20
    pattern: stream
    spread: 0.5
    velocityMin: { x: -1, y: -20, z: -1 }
    velocityMax: { x: 1, y: -10, z: 1 }
    visual:
      colorOverTime:
        type: linear
        keyframes:
          - time: 0
            color: { r: 255, g: 255, b: 255 }
          - time: 0.5
            color: { r: 200, g: 200, b: 255 }
          - time: 1.0
            color: { r: 100, g: 100, b: 255 }
      scaleOverTime:
        start: 1.0
        end: 0.3
        curve: easeIn
      opacityOverTime:
        start: 1.0
        end: 0.0
        curve: linear

# Pattern compositions
patterns:
  # Combine multiple patterns
  mega_explosion:
    type: composite
    patterns:
      - name: explosion
        weight: 0.6
      - name: ring
        weight: 0.4
    modifiers:
      count: 100
      spread: 3.0