actor SupremeFiend : BFGMastermind
{
//Creator: NaturalxCF
//Origin: Nexus Infinity
//Sprite: SPFN
//Title: "Supreme Fiend" 
    Health 7500
    Radius 40
    Height 95
    Speed 8
    PainChance 10
	Bloodcolor Red
    +NOGRAVITY
    +FLOAT
    +FLOATBOB
    +NORADIUSDMG
    +DONTMORPH
    +MISSILEMORE
    SeeSound "sfiend/see"
    DeathSound "spider/death"
    Obituary "%o was mangled by the Supreme Fiend."
	Tag "\c[l8]Supreme Fiend\c-"
    States
    {
  Spawn:
	TNT1 A 0 NoDelay A_PlaySound("sfiend/hover",7,1.0,1)
  Idle:
	SPFN A 4 A_Look
	Loop
  See:
	SPFN A 2 A_Chase
	Loop
  Missile:
	SPFN B 0 A_Jump(128,"BFG9K","Bombs","Railgun")
	SPFN B 8 bright A_FaceTarget
	SPFN B 8 bright A_FaceTarget
	SPFN F 2 bright A_CustomMissile("OverseerPlasma", 30, 0, 0)
	SPFN E 2 bright
	SPFN B 1 bright A_SpidRefire
	SPFN F 2 bright A_CustomMissile("OverseerPlasma", 30, 0, 0)
	SPFN E 2 bright
	SPFN B 1 bright A_SpidRefire
	SPFN F 2 bright A_CustomMissile("OverseerPlasma", 30, 0, 0)
	SPFN E 2 bright
	SPFN B 1 bright A_SpidRefire
	SPFN F 2 bright A_CustomMissile("OverseerPlasma", 30, 0, 0)
	SPFN E 2 bright
	SPFN B 1 bright A_SpidRefire
	SPFN F 2 bright A_CustomMissile("OverseerPlasma", 30, 0, 0)
	SPFN E 2 bright
	SPFN B 1 bright A_SpidRefire
	SPFN F 2 bright A_CustomMissile("OverseerPlasma", 30, 0, 0)
	goto Missile+2
  BFG9K:
	TNT1 A 0 A_PlaySound("weapons/bfgf")
	SPFN EEE 10 bright A_FaceTarget
	SPFN F 10 bright A_CustomMissile ("SpiderBFG9500Ball", 30, 0, 0)
	goto See
  Railgun:
	TNT1 A 0 A_PlaySound("weapons/rgcharge")
	SPFN EE 10 bright A_FaceTarget
	SPFN F 6 bright A_CustomMissile ("OverseerRail", 30, 0, 0)
	SPFN E 6 bright A_FaceTarget
	SPFN F 6 bright A_CustomMissile ("OverseerRail", 30, 0, 0)
	SPFN E 6 bright A_FaceTarget
	SPFN F 6 bright A_CustomMissile ("OverseerRail", 30, 0, 0)
	SPFN E 6 bright A_FaceTarget
	SPFN F 6 bright A_CustomMissile ("OverseerRail", 30, 0, 0)
	SPFN E 10 bright
	goto See
  Bombs:
	SPFN B 10 bright A_FaceTarget
	SPFN B 0 A_PlayWeaponSound("fiend/bomb")
	SPFN O 20 bright A_FaceTarget
	SPFN P 20 bright A_FaceTarget
	SPFN Q 20 bright A_FaceTarget
	SPFN Q 0 A_DualPainAttack ("RemoteBomb")
	SPFN Q 10 bright A_FaceTarget
	SPFN Q 0 A_DualPainAttack ("RemoteBomb")
	SPFN Q 10 bright A_FaceTarget
	SPFN Q 0 A_DualPainAttack ("RemoteBomb")
	SPFN Q 10 bright A_FaceTarget
	SPFN Q 0 A_DualPainAttack ("RemoteBomb")
	SPFN Q 10 bright A_FaceTarget
	SPFN Q 0 A_DualPainAttack ("RemoteBomb")
	SPFN Q 10 bright A_FaceTarget
	SPFN Q 0 A_DualPainAttack ("RemoteBomb")
	SPFN Q 10 bright A_FaceTarget
	SPFN Q 0 A_DualPainAttack ("RemoteBomb")
	SPFN Q 10 bright A_FaceTarget
	SPFN Q 0 A_DualPainAttack ("RemoteBomb")
	SPFN Q 10 bright A_FaceTarget
	SPFN Q 0 A_DualPainAttack ("RemoteBomb")
	SPFN Q 10 bright A_FaceTarget
	SPFN Q 0 A_DualPainAttack ("RemoteBomb")
	SPFN Q 10 bright A_FaceTarget
	SPFN Q 0 A_DualPainAttack ("RemoteBomb")
	SPFN Q 10 bright A_FaceTarget
	SPFN Q 0 A_DualPainAttack ("RemoteBomb")
	SPFN Q 10 bright A_FaceTarget
	SPFN Q 0 A_DualPainAttack ("RemoteBomb")
	SPFN Q 10 bright A_FaceTarget
	SPFN Q 0 A_DualPainAttack ("RemoteBomb")
	SPFN Q 10 bright A_FaceTarget
	SPFN Q 0 A_DualPainAttack ("RemoteBomb")
	SPFN Q 10 bright A_FaceTarget
	SPFN Q 0 A_DualPainAttack ("RemoteBomb")
	SPFN Q 10 bright A_FaceTarget
	SPFN Q 0 A_DualPainAttack ("RemoteBomb")
	SPFN Q 10 bright A_FaceTarget
	SPFN Q 0 A_DualPainAttack ("RemoteBomb")
	SPFN Q 0 A_PlayWeaponSound("fiend/bomb")
	SPFN Q 20 bright A_FaceTarget
	SPFN P 20 bright A_FaceTarget
	SPFN O 20 bright A_FaceTarget
	goto See
  Pain:
	SPFN B 10 A_Pain
	Goto See
  Death:
	TNT1 A 0 A_StopSound(7)
	SPFN G 0 A_ChangeFlag(FLOATBOB,0)
	SPFN G 20 A_Scream
	TNT1 A 0 A_Fall
    TNT1 AA 0 A_SpawnItemEx("GibbedGenerator",Random(10,-10),Random(10,-10),Random(20,60),0,0,0,0,128,0)	
	TNT1 AAA 0 A_CustomMissile("BigRedBloodCloud", random(10,80), 0, random(0,360), 2, random(0,360))	
	SPFN HHHHH 2 Bright A_CustomMissile("Kaboom", random(10,60), random(30,-30), random(0,360), 2, random(0,360))
    TNT1 AA 0 A_SpawnItemEx("GibbedGenerator",Random(10,-10),Random(10,-10),Random(20,60),0,0,0,0,128,0)	
	TNT1 AAA 0 A_CustomMissile("BigRedBloodCloud", random(10,80), 0, random(0,360), 2, random(0,360))	
	SPFN IIIII 2 Bright A_CustomMissile("Kaboom", random(10,60), random(30,-30), random(0,360), 2, random(0,360))
    TNT1 AA 0 A_SpawnItemEx("GibbedGenerator",Random(10,-10),Random(10,-10),Random(20,60),0,0,0,0,128,0)	
	TNT1 AAA 0 A_CustomMissile("BigRedBloodCloud", random(10,80), 0, random(0,360), 2, random(0,360))	
	SPFN JJJJJ 2 Bright A_CustomMissile("Kaboom", random(10,60), random(30,-30), random(0,360), 2, random(0,360))
    TNT1 AA 0 A_SpawnItemEx("GibbedGenerator",Random(10,-10),Random(10,-10),Random(20,60),0,0,0,0,128,0)	
	TNT1 AAA 0 A_CustomMissile("BigRedBloodCloud", random(10,80), 0, random(0,360), 2, random(0,360))	
	SPFN KKKKK 2 Bright A_CustomMissile("Kaboom", random(10,60), random(30,-30), random(0,360), 2, random(0,360))
	SPFN LM 10
	SPFN N -1 A_BossDeath
	Stop
    }
}

actor RemoteBomb
{
  obituary "%o was destroyed by a remote bomb."
  health 5
  radius 20
  height 20
  mass 20
  speed 15
  painchance 20
  seesound "prox/fire"
  attacksound "prox/beep"
  MONSTER
  +FLOAT
  +FLOATBOB
  +NOTARGETSWITCH
  +NOGRAVITY
  +LOOKALLAROUND
  +NOBLOOD
  Tag "Remote Bomb"
  states
  {
  Spawn:
    SPFB AABB 10 A_Look
    loop
  See:
    SPFB AABB 2 A_Chase
    SPFB A 0 A_PlaySound("bomb/beep")
    loop
  Melee:
    SPFB A 0 A_Die
    stop
  Pain:
    SPFB A 3
    SPFB A 3 A_Pain
    goto See
  Death:
    TNT1 A 0 A_Explode(200,200)
	TNT1 A 0 A_SpawnItemEx("OrangeParticleSpawner", 0, 0, 0, 0, 0, 0, 0, 128) 
	TNT1 AAA 0 A_CustomMissile("Kaboom", 0, 0, random(0,360), 2, random(0,360))
	TNT1 AAA 0 A_CustomMissile("SmokeFX2", 0, 0, random(0,360), 2, random(0,360))
	TNT1 AAAA 0 A_SpawnItemEx("Debris",0,0,0,Random(4,-4),Random(4,-4),Random(4,8),0,128)
	TNT1 A 1 A_SpawnItem("RocketEx")
    stop
  }
}


actor FiendPlasmaBall : PlasmaBall
{
  Decal ArachnotronScorch
  States
  {
  Spawn:
    APLS AB 6 Bright
    Loop
  Death:
    APBX ABCDE 4 Bright
    Stop
  }
}
