
// ------------------------------------------------------------
//   Baron Of Hell
// ------------------------------------------------------------

ACTOR HellPrince : BaronOfHell replaces BaronofHell
{
	maxtargetrange 65536
	RadiusDamageFactor 0.3
	+missileevenmore
	BloodColor "44 99 22"
	damagefactor "Thermal", 0.8
	damagefactor "SmallArms0", 0.86
	damagefactor "SmallArms1", 0.95
	damagefactor "Balefire", 0.3
	meleedamage 12
	meleerange 58
	health 1200
	meleesound "baron/melee"
	speed 4
	painchance 2
	Obituary "%o was sauteed by a baron of hell."
	HitObituary "%o was shredded by a baron of hell."
	States
	{
	See:
		TNT1 A 0 A_AlertMonsters
		TNT1 A 0 HealThing(random(1,2))
		TNT1 A 0 A_ChangeFlag ("frightened",0)
		BOSS AAABBBCCCDDD 2 A_Chase
		TNT1 A 0 A_JumpIfTargetInLOS (1)
		goto Roam
		TNT1 A 0 A_Jump(96,1)
		loop
	Roam:
		TNT1 A 0 A_AlertMonsters
		TNT1 A 0 HealThing(random(16,32))
		TNT1 A 0 A_JumpIfTargetInLOS ("See")
		TNT1 A 0 A_ChangeFlag ("frightened",0)
		TNT1 A 0 A_Jump (192,2)
		TNT1 A 0 A_ChangeFlag ("frightened",1)
		BOSS AAABBBCCCDDD 2 A_Chase
		loop
	Missile:
		BOSS E 0 A_Jump (64,2)
		BOSS E 0 A_JumpIfCloser(420, "Pain2")

		BOSS H 12 A_FaceTarget
		//BOSS H 0 BRIGHT A_SetInvulnerable
		BOSS H 6 BRIGHT A_CustomMissile ("BelphPreShot", 28, 0, 0, 0, 0)
		BOSS H 0 BRIGHT A_CustomMissile ("MiniBBall", 46, 0, 9, 2, 0)
		BOSS H 6 BRIGHT A_CustomMissile ("MiniBBall", 46, 0, -9, 2, 0)
		BOSS H 0 BRIGHT A_CustomMissile ("MiniBBall", 56, 0, 17, 2, 4)
		BOSS H 6 BRIGHT A_CustomMissile ("MiniBBall", 56, 0, -17, 2, 4)
		BOSS H 0 BRIGHT A_CustomMissile ("MiniBBall", 66, 0, 24, 2, 7)
		//BOSS H 0 BRIGHT A_CustomMissile ("BelphBall", 28, 0, 0, 0, 0)
		BOSS H 6 BRIGHT A_CustomMissile ("MiniBBall", 66, 0, -24, 2, 7)
		//BOSS H 0 BRIGHT A_UnSetInvulnerable
		BOSS H 6
		Goto See
		
	Pain:
		BOSS H 6 A_Pain
		BOSS H 3 A_Jump (116,"See")
	Pain2:
		BOSS E 6 A_FaceTarget
		BOSS E 2 BRIGHT A_CustomMissile ("MiniBBall", 56, 6, -10)
		BOSS F 2 A_FaceTarget
		BOSS F 2 BRIGHT A_CustomMissile ("MiniBBall", 46, 4, -5)
		BOSS F 2 A_FaceTarget
		BOSS G 2 BRIGHT A_CustomMissile ("MiniBBall", 38, 0, 0)
		BOSS G 2 A_FaceTarget
		BOSS G 2 BRIGHT A_CustomMissile ("MiniBBall", 32, 0, 5)
		BOSS G 2 A_FaceTarget
		BOSS GG 2 BRIGHT A_CustomMissile ("MiniBBall", 32, 0, 10)
		BOSS G 6
		Goto See
	Melee:
		BOSS E 6 A_FaceTarget
		BOSS F 6
		BOSS G 6 A_MeleeAttack
		BOSS F 6
		goto See
	Death:
		TNT1 A 0 A_GivetoTarget("HDKillCount",1)
		TNT1 A 0 ACS_ExecuteAlways(558,0,0,1,35)
		BOSS I 8 A_SpawnItemEx ("tempshieldgreen", 0,0,0, velx,vely,velz, 0,40)
		BOSS J 8 A_Scream
		BOSS K 8 A_SpawnItemEx ("tempshield2green", 0,0,0, velx,vely,velz, 0,40)
		BOSS L 8 A_NoBlocking
		BOSS M 8
		BOSS N 8
		BOSS O -1 A_BossDeath
	}
}

ACTOR BelphPreShot
{
	PROJECTILE
	+nointeraction
	Renderstyle add
	Scale 0.6
	Radius 12
	Height 13
	Speed 4
	SeeSound "prince/attack"
	DeathSound "bakaslave/death"
	States
	{
	Spawn:
		SKUL JIHGF 3 BRIGHT
		Goto Death
	Death:
		SKUL E 4 BRIGHT
		TNT1 A 0 A_SpawnItemEx ("BelphBall",0,0,0,velx*16,vely*16,velz*16,0,40|SXF_TRANSFERPOINTERS,0)
		Stop
	}
}

ACTOR BelphBall : FastProjectile
{
	damagetype "Thermal"
	Decal "BigScorch"
	+forcexybillboard
	Renderstyle add
	Scale 0.6
	Radius 12
	Height 13
	Speed 64
	Damage 8
	SeeSound "skull/melee"
	DeathSound "bakaslave/death"
	States
	{
	Spawn:
		SKUL F 0 BRIGHT
		Goto See
	See:
		SKUL C 2 BRIGHT
		SKUL C 1 BRIGHT A_SpawnItemEx ("DrunkImpBallTail", -6, 0, 12, 18, 0, 0, 0, 160)
		SKUL D 2 BRIGHT
		SKUL D 1 BRIGHT A_SpawnItemEx ("DrunkImpBallTail", -6, 0, 12, 16, 0, 0, 0, 160)
		Loop
	Death:
		SKUL F 4 BRIGHT
		SKUL FFF 0 A_SpawnItemEx ("HDSmoke", random(-12,12),random(-12,12),random(-4,8), 0,0,0, 0,160)
		SKUL G 4 BRIGHT A_Explode (56, 256, 1)
		SKUL GGGGGG 0 A_SpawnItemEx ("BigWallChunk", random(-4,4),random(-4,4),random(-4,4), random(-10,10),random(-10,10),random(-2,10), random(0,360), 160)
		SKUL HIJ 4 BRIGHT A_FadeOut (0.2)
		Stop
	}
}

ACTOR MiniBBallTail
{
	+nointeraction
	+forcexybillboard
	renderstyle add
	alpha 0.6
	scale 0.7
	radius 4
	height 6
	States
	{
	Spawn:
		BAL7 EE 4 BRIGHT A_FadeOut (0.1)
		loop
	}
}

ACTOR MiniBBall
{
	damagetype "Balefire"
	PROJECTILE
	+SEEKERMISSILE
	+forcexybillboard
	Renderstyle add
	Decal "DoomImpScorch"
	Alpha 0.8
	Scale 0.6
	Radius 4
	Height 6
	Speed 16
	Damage 6
	SeeSound "prince/attack"
	DeathSound "prince/shotx"
	States
	{
	Spawn:
		BAL7 EDC 1 BRIGHT
		BAL7 ABABA 2 BRIGHT
		BAL7 BAB 3 BRIGHT
	Spawn2:
		BAL7 A 2 BRIGHT A_SeekerMissile (5, 9)
		BAL7 B 2 BRIGHT A_SpawnItemEx ("MiniBBallTail", -3, 0, 3, 3, 0, random(1,2), 0, 161, 0)
		BAL7 A 2 BRIGHT A_SeekerMissile (5, 9)
		BAL7 B 2 BRIGHT A_SpawnItemEx ("MiniBBallTail", -3, 0, 3, 3, 0, random(1,2), 0, 161, 0)
		BAL7 A 2 BRIGHT A_SeekerMissile (5, 9)
		BAL7 B 2 BRIGHT A_SpawnItemEx ("MiniBBallTail", -3, 0, 3, 3, 0, random(1,2), 0, 161, 0)
		BAL7 A 2 BRIGHT A_SeekerMissile (5, 9)
		BAL7 B 2 BRIGHT A_SpawnItemEx ("MiniBBallTail", -3, 0, 3, 3, 0, random(1,2), 0, 161, 0)
	Spawn3:
		BAL7 A 3 BRIGHT A_SeekerMissile (3, 6)
		BAL7 B 3 BRIGHT A_SpawnItemEx ("MiniBBallTail", -3, 0, 3, 3, 0, random(1,2), 0, 161, 0)
		Loop
	Death:
		BAL7 CDE 4 BRIGHT A_FadeOut (0.2)
		Stop
	}
}


// ------------------------------------------------------------
//   Hell Knight
// ------------------------------------------------------------

ACTOR HellKnave : HellKnight replaces HellKnight
{
	+missilemore
	+MISSILEEVENMORE
	damagefactor "Balefire", 0.3
	damagefactor "Thermal", 0.8
	damagefactor "SmallArms0", 0.9
	BloodColor "44 99 22"
	Height 64
	Scale 0.8
	speed 6
	meleedamage 10
	meleerange 56
	meleesound "baron/melee"
	Obituary "%o didn't get quite medieval enough on a hell knight's ass."
	HitObituary "%o had %p loins tendered by sir knight."
	States
	{
	See:
		TNT1 A 0 A_AlertMonsters
		TNT1 A 0 HealThing(random(2,4))
		BOS2 AAABBBCCCDDD 2 A_Chase
		loop
	Missile:
		BOS2 E 0 A_JumpIfCloser(260, 9)

		BOS2 H 12 A_FaceTarget
		BOS2 H 1 BRIGHT A_CustomMissile ("MiniBBall", 46, 0, 0, 2, 0)
		BOS2 H 7 BRIGHT A_CustomMissile ("MiniBBall", 46, 0, 0, 2, 0)
		BOS2 H 0 BRIGHT A_CustomMissile ("MiniBBall", 32, 0, 6, 2, 3)
		BOS2 H 8 BRIGHT A_CustomMissile ("MiniBBall", 32, 0, -6, 2, 3)
		BOS2 H 0 BRIGHT A_CustomMissile ("MiniBBall", 42, 0, 12, 2, 6)
		BOS2 H 8 BRIGHT A_CustomMissile ("MiniBBall", 42, 0, -12, 2, 6)
		BOS2 H 8
		Goto See

		BOS2 E 8 A_FaceTarget
		BOS2 E 5 BRIGHT A_CustomMissile ("MiniBBall", 36, 4, -5)
		BOS2 F 4 A_FaceTarget
		BOS2 F 5 BRIGHT A_CustomMissile ("MiniBBall", 32, 2, 0)
		BOS2 G 4 A_FaceTarget
		BOS2 G 5 BRIGHT A_CustomMissile ("MiniBBall", 28, 0, 5)
		BOS2 G 6
		Goto See
	Melee:
		BOS2 E 8 A_FaceTarget
		BOS2 F 6
		BOS2 G 8 A_MeleeATtack
		BOS2 F 6
		goto See
	Death:
		TNT1 A 0 A_GivetoTarget("HDKillCount",1)
		TNT1 A 0 ACS_ExecuteAlways(558,0,0,1,23)
		BOS2 I 8 A_SpawnItemEx ("tempshieldgreen", 0,0,0, velx,vely,velz, 0,40)
		BOS2 J 8 A_Scream
		BOS2 K 8 A_SpawnItemEx ("tempshield2green", 0,0,0, velx,vely,velz, 0,40)
		BOS2 L 8 A_NoBlocking
		BOS2 M 8
		BOS2 N 8
		BOS2 O -1 A_BossDeath
	}
}


ACTOR BaleBall : MiniBBall
{
	Decal "GooScorch"
	Speed 18
	Damage 8
	Scale 1.0
	Radius 6
	Height 8
	States
	{
	Spawn:
		BAL7 A 1 BRIGHT A_SeekerMissile (2, 4)
		BAL7 A 2 BRIGHT A_SpawnItemEx ("MiniBBallTail", -3, 0, 3, 3, random(-1,1),  random(1,2), 0, 161, 0)
		BAL7 B 1 BRIGHT A_SeekerMissile (2, 4)
		BAL7 B 2 BRIGHT A_SpawnItemEx ("MiniBBallTail", -3, 0, 3, 3, random(-1,1),  random(1,2), 0, 161, 0)
		Loop
	}
}

