metadata { type "declarate" version "1.0.0" }

//===========================================================================
//
// Boss Brain
//
//===========================================================================

sound BrainSight    { prefix lump "BOSSIT" }
sound BrainPain     { prefix lump "BOSPN" }
sound BrainDeath    { prefix lump "BOSDTH" }
sound BrainSpit     { prefix lump "BOSPIT" }
sound BrainCube     { prefix lump "BOSCUB" }
sound BrainCubeboom { prefix lump "FIRXPL" }

thing BossBrain 88 native
{
    Health 250
    Mass 10000000
    PainChance 255
    +SOLID
    +SHOOTABLE
    PainSound BrainPain
    DeathSound BrainDeath
    States
    {
    BrainExplode:
        MISL BC 10 Bright
        MISL D 10 A_BrainExplode
        Stop
    Spawn:
        BBRN A -1
        Stop
    Pain:
        BBRN B 36 A_BrainPain
        Goto Spawn
    Death:
        BBRN A 100 A_BrainScream
        BBRN AA 10
        BBRN A -1 A_BrainDie
        Stop
    }
}

//===========================================================================
//
// Boss Eye
//
//===========================================================================

thing BossEye 89 native
{
    Height 32
    +NOBLOCKMAP
    +NOSECTOR
    States
    {
    Spawn:
        SSWV A 10 A_Look
        Loop
    See:
        SSWV A 181 A_BrainAwake
        SSWV A 150 A_BrainSpit
        Wait
    }
}

//===========================================================================
//
// Boss Target
//
//===========================================================================

thing BossTarget 87 native
{
    Height 32
    +NOBLOCKMAP
    +NOSECTOR
}

//===========================================================================
//
// Spawn shot
//
//===========================================================================

thing SpawnShot native
{
    Radius 6
    Height 32
    Speed 10
    Damage 3
    PROJECTILE
    +NOCLIP
    SeeSound BrainSpit
    DeathSound BrainCubeboom
    States
    {
    Spawn:
        BOSF A 3 BRIGHT A_SpawnSound
        BOSF BCD 3 BRIGHT A_SpawnFly
        Loop
    }
}

//===========================================================================
//
// Spawn fire
//
//===========================================================================

thing SpawnFire native
{
    Height 78
    +NOBLOCKMAP
    +NOGRAVITY
    //RenderStyle "Add"
    States
    {
    Spawn:
        FIRE ABCDEFGH 4 Bright A_Fire
        Stop
    }
}
