//------------------------------------------------------------------------------
actor Korax 10200
{
	Game Hexen
	Health 5000
	Radius 65
	Height 115
	Mass 2000
	Speed 10
	PainChance 20
	Damage 15
	Monster
	+FloorClip
	+Telestomp
	+Boss
	+NoTarget
	+FullVolActive
	+NoIceDeath
	SeeSound "KoraxSight"
	ActiveSound "KoraxActive"
	AttackSound "KoraxAttack"
	PainSound "KoraxPain"
	DeathSound "KoraxDeath"
	Obituary "$ob_korax"

	action native A_KoraxChase();
	action native A_KoraxDecide();
	action native A_KoraxMissile();
	action native A_KoraxCommand();
	action native A_KoraxBonePop();

	states
	{
	Spawn:
		KORX A 5 A_Look
		Loop
	See:
		KORX A 0 A_PlaySoundEx("KoraxStep", "Body", 0, 1)
		KORX A 3 A_Chase
		KORX AAA 3 A_KoraxChase
		KORX B 3 A_Chase
		KORX BBB 3 A_KoraxChase
		KORX C 0 A_PlaySoundEx("KoraxStep", "Body", 0, 1)
		KORX C 3 A_Chase
		KORX CCC 3 A_KoraxChase
		KORX D 3 A_Chase
		KORX DDD 3 A_KoraxChase
		Loop
	Pain:
		KORX H 5 A_Pain
		KORX H 5
		Goto See+1
	Missile:
		KORX E 2 Bright A_FaceTarget
		KORX E 5 Bright A_KoraxDecide
		Wait
	Attack:
		KORX E 4 Bright A_FaceTarget
		KORX F 8 Bright A_KoraxMissile
		KORX E 8 Bright
		Goto See+1
	Command:
		KORX E 5 Bright A_FaceTarget
		KORX W 10 Bright A_FaceTarget
		KORX G 15 Bright A_KoraxCommand
		KORX W 10 Bright
		KORX E 5 Bright
		Goto See+1
	Death:
		KORX I 5
		KORX J 5 A_FaceTarget
		KORX K 5 A_Scream
		KORX LMNOP 5
		KORX Q 10
		KORX R 5 A_KoraxBonePop
		KORX S 5 A_NoBlocking
		KORX TU 5
		KORX V -1
		Stop
	}
}

//------------------------------------------------------------------------------
actor KoraxBolt
{
	RenderStyle Add
	Radius 15
	Height 35
	Projectile
	-ActivateImpact
	-ActivatePCross

	action native A_KBoltRaise();
	action native A_KBolt();

	states
	{
	Spawn:
		MLFX I 2 Bright
		MLFX J 2 Bright A_KBoltRaise
		MLFX IJKLM 2 Bright A_KBolt
		Goto Spawn+2
	}
}

//------------------------------------------------------------------------------
actor KoraxSpirit
{
	Speed 8
	RenderStyle Translucent
	Alpha 0.4
	Projectile
	-ActivateImpact
	-ActivatePCross
	+NoClip

	action native A_KSpiritRoam();

	states
	{
	Spawn:
		SPIR AB 5 A_KSpiritRoam
		Loop
	Death:
		SPIR DEFGHI 5
		Stop
	}
}
