ACTOR PurpleCyberNoble : CyberNoble 
{ 
Health 2650
PainChance 50
Scale 1.2
Bloodcolor "Purple"
Obituary "%o was eradicated by an Phase Cyber-noble."
HitObituary "%o was pummeled by an Phase Cyber-noble."
SeeSound "cbaron/sight" 
PainSound "blooddemon/pain"
DeathSound "monster/brudth"
MeleeSound "baron/melee"
ActiveSound "cbaron/active"
DropItem "BossLifeEssence" 200 25
DropItem "BossArmorBonusMax" 200 1
DropItem "DemonAmmoBox" 128
DropItem "BFG10K " 50 
DropItem "DemonMagazine" 256
DropItem "PhaseRifle" 120
Species "Nobles"
Tag "\c[i9]Phase Cyber Noble"
  States 
  { 
Spawn: 
		PCYN A 7 A_Look
		Loop 
See:
		PCYN AABB 3 A_Chase
		TNT1 A 0 A_SpawnItem("HoofStep",0,0,0,0)
		PCYN CCDD 3 A_Chase
		TNT1 A 0 A_Playsound("monster/bruwlk")
		TNT1 A 0 A_Jump(80,"Phase")
		Loop
Phase:
		TNT1 A 0 A_PlaySound("phaseimp/teleport")
		PCYN A 2 A_FaceTarget
		PCYN A 1 A_SetTranslucent(0.75)
		PCYN A 1 A_SetTranslucent(0.55)
		PCYN A 1 A_SetTranslucent(0.35)
		PCYN A 1 A_SetTranslucent(0.20)
		Goto Phased
UnPhase:
		TNT1 A 0 A_PlaySound("phaseimp/teleport")
		PCYN A 1 A_SetTranslucent(0.15)
		PCYN A 1 A_SetTranslucent(0.35)
		PCYN A 1 A_SetTranslucent(0.55)
		PCYN A 1 A_SetTranslucent(0.75)
		TNT1 A 0 A_SetTranslucent(1)
		PCYN A 2 A_FaceTarget		
		Goto See	
Phased:
		PCYN AABBCCDDAABBCCDDAABBCCDDAABBCCDD 1 A_ExtChase(0,0)
		PCYN AABBCCDDAABBCCDD 1 A_Chase
		TNT1 A 0 A_Jump(200,"UnPhase")
		Goto Phased+32
Pause:
		PCYN E 10
		Goto See
Missile:
		TNT1 A 0 A_Jump(100,"Rocket","ESG")
		TNT1 A 0 A_Jump(50,"BFG10K","Railgun")
BurstBall:
		PCYN PQ 7 A_FaceTarget 
		PCYN R 3 Bright A_CustomMissile("PArchonComet3", 32, 0, 0)		
		TNT1 A 0 A_CustomMissile("PArchonComet3", 32, 0, 6)
		PCYN R 3 Bright A_CustomMissile("PArchonComet3", 32, 0, -6)
		TNT1 A 0 A_Jump(128,"Rocket")
		Goto See
ESG:
		PCYN E 14 A_FaceTarget
		TNT1 A 0 A_PlaySound("weapons/ExplosiveSG/fire",7)
		TNT1 A 0 A_SpawnItemEx("OrangeShellCasing", 32, 20, 0, Random(2, 6), 0, Random(1, 3), Random(-80, -90), 128)
		TNT1 AAAAA 0 A_CustomMissile("EnemyPhaseDTProjectile",32,0,Random(-20,20)*0.1,0,Random(-5,5)*0.1)
		PCYN F 4
		PCYN E 12
		TNT1 A 0 A_Jump(128,"See")
		TNT1 A 0 A_SpidRefire
		Goto ESG+1
Rocket:
		PCYN E 14 A_FaceTarget
		PCYN F 8 Bright A_CustomMissile("PhaseCyberRocket",32,20,0,0)
		PCYN E 10 A_FaceTarget
		PCYN F 8 Bright A_CustomMissile("PhaseCyberRocket",32,20,0,0)
		PCYN E 10 A_FaceTarget
		PCYN F 8 Bright A_CustomMissile("PhaseCyberRocket",32,20,0,0)
		PCYN E 10
		Goto See
BFG10K:
		TNT1 A 0 A_PlayWeaponSound("weapons/charge15k")
		PCYN E 25 A_FaceTarget
		TNT1 A 0 A_PlaySound("weapons/bfg15kfire")
		PCYN F 4 Bright A_CustomMissile("PhaseCyber15KBall",32,20,0,0)
		PCYN E 8 A_FaceTarget
		TNT1 A 0 A_PlaySound("weapons/bfg15kfire")
		PCYN F 4 Bright A_CustomMissile("PhaseCyber15KBall",32,20,0,0)
		PCYN E 8 A_FaceTarget
		TNT1 A 0 A_PlaySound("weapons/bfg15kfire")
		PCYN F 4 Bright A_CustomMissile("PhaseCyber15KBall",32,20,0,0)
		PCYN E 8 A_FaceTarget
		TNT1 A 0 A_PlaySound("weapons/bfg15kfire")
		PCYN F 4 Bright A_CustomMissile("PhaseCyber15KBall",32,20,0,0)
		PCYN E 8 A_FaceTarget
		TNT1 A 0 A_PlaySound("weapons/bfg15kfire")
		PCYN F 4 Bright A_CustomMissile("PhaseCyber15KBall",32,20,0,0)
		PCYN E 10 A_PlaySound("weapons/bfg15kcooldown",CHAN_AUTO)
		TNT1 A 0 A_Jump(128,"Rocket")
		Goto See
Railgun:
		TNT1 A 0 A_PlaySound("weapons/rgcharge")
		PCYN EE 20 A_FaceTarget
		PCYN F 5 Bright A_CustomMissile("PhaseCyberRail",32,20,0,0)
		PCYN EE 15 A_FaceTarget
		TNT1 A 0 A_Jump(128,"See","BFG10K")
		PCYN F 5 Bright A_CustomMissile("PhaseCyberRail",32,20,0,0)
		PCYN EE 15
		TNT1 A 0 A_Jump(64,"BFG10K")
		Goto See
Melee:
		PCYN PQ 7 A_FaceTarget
		PCYN R 7 A_MeleeAttack
		Goto See
Pain: 
		TNT1 A 0 A_Jump(87,"PainMissile")
		PCYN H 4 A_Pain
		Goto See
PainMissile:
		PCYN H 4 A_Pain
		Goto Missile	
Death:
		PCYN H 20 A_Scream
		TNT1 AA 0 A_SpawnItemEx("MutantGibbedGenerator",0,0,0,0,0,0,0,128,0)
		TNT1 AA 0 A_CustomMissile("SmokeFX2", 0, 0, random(0,360), 2, random(0,360))	
		PCYN IIII 2 Bright A_CustomMissile("PurpleKaboom", Random(10,50), 0, random(0,360), 2, random(0,360))
		PCYN JJJJ 2 Bright A_CustomMissile("PurpleKaboom", Random(10,50), 0, random(0,360), 2, random(0,360))
		TNT1 AA 0 A_SpawnItemEx("MutantGibbedGenerator",0,0,0,0,0,0,0,128,0)
		TNT1 AA 0 A_CustomMissile("SmokeFX2", 0, 0, random(0,360), 2, random(0,360))	
		PCYN KKKK 2 Bright A_CustomMissile("PurpleKaboom", Random(10,50), 0, random(0,360), 2, random(0,360))
		TNT1 AA 0 A_SpawnItemEx("MutantGibbedGenerator",0,0,0,0,0,0,0,128,0)
		TNT1 AA 0 A_CustomMissile("SmokeFX2", 0, 0, random(0,360), 2, random(0,360))	
		PCYN LLLL 2 Bright A_CustomMissile("PurpleKaboom", Random(10,50), 0, random(0,360), 2, random(0,360))
		TNT1 AA 0 A_SpawnItemEx("MutantGibbedGenerator",0,0,0,0,0,0,0,128,0)
		TNT1 AAAA 0 A_CustomMissile("SmokeFX2", 0, 0, random(0,360), 2, random(0,360))
		PCYN M 4 Bright A_NoBlocking
		PCYN N 3 Bright
		TNT1 A 0 A_BossDeath
		PCYN O -1
		Stop
Raise:
		TNT1 A 0
		TNT1 A 0 A_SpawnItemEx("VileHealEffect",0,0,0,0,0,0,0,SXF_NOCHECKPOSITION)
		PCYN N 5
		PCYN MLKJI 5
		Goto See
    } 
}

ACTOR PhaseDemonTechEx
{
RenderStyle Add
Alpha 0.75
Scale 0.5
PROJECTILE
+NOCLIP
States
{
Spawn:
PTXP ABCDEFGH 2 Bright A_FadeOut(0.1)
Stop
}
}

ACTOR PhaseDemonTechTrail : BFG9500Trail
{
Scale 0.04
Alpha 0.65
States
{
Spawn:
    TNT1 A 0
    TNT1 A 0 A_JumpIf(ACS_ExecuteWithResult(304) == 1, "Toaster")
	TNT1 A 2
    PTRI AAAAAABBBBBBBB 1 Bright A_FadeOut(0.05)
    Stop
    }
}

ACTOR PhaseDemonTechTrail2 : DemonTechTrail
{
States
{
Spawn:
    TNT1 A 0
    TNT1 A 0 A_JumpIf(ACS_ExecuteWithResult(304) == 1, "Toaster")
	TNT1 A 2
    PTRI AAAAAACCCCCCCC 1 Bright A_FadeOut(0.05)
    Stop
    }
}