
ACTOR sfTeamDemon
{
	Health 150
	PainChance 180
	Speed 10
	Radius 15
	Height 56
	Mass 400
	Monster
	+FLOORCLIP +FASTER +FASTMELEE +FRIENDLY -ISMONSTER
	renderstyle add
	SeeSound "demon/sight"
	AttackSound "demon/melee"
	PainSound "demon/pain"
	DeathSound "demon/death"
	ActiveSound "demon/active"
	Obituary "$OB_DEMONHIT" // "%o was bit by a demon."
	
	//Protect from marine damage
	DamageFactor "MarineFire", 0.0
	DamageFactor "MarineFire2", 0.0
	DamageFactor "MarineFire3", 0.0
        DamageFactor "BFGSplash", 0.0
        DamageFactor "BFGSpray", 0.0
	
	states
	{
		Spawn:
			SARG AB 10 A_Look
			goto Spawn
		See:
			SARG AABBCCDD 2 A_Chase
			goto See
		Melee:
			SARG EF 8 A_FaceTarget
			SARG G 8 A_SargAttack
			goto See
		Pain:
			SARG H 2
			SARG H 2 A_Pain
			goto See
		Death:
			SARG I 2
			SARG I 8 ACS_ExecuteAlways(500, 0, 1, 0)
			SARG J 8 A_Scream
			SARG K 4
			SARG L 4 A_NoBlocking
			SARG M 4
			SARG N 650
		DeathFade:
			SARG N 2 A_FadeOut(0.1)
			goto DeathFade
		Raise:
			SARG N 5
			SARG MLKJI 5
			goto See
	}
}

ACTOR sfTeamBaronOfHell
{
	obituary "%o was bruised by a Baron of Hell."
	hitobituary "%o was ripped open by a Baron of Hell."
	health 1100
	radius 24
	height 64
	mass 1000
	speed 10
	painchance 50
	seesound "baron/sight"
	painsound "baron/pain"
	deathsound "baron/death"
	activesound "baron/active"
	MONSTER
	+FLOORCLIP
	+BOSSDEATH
	+FRIENDLY
	-ISMONSTER
	renderstyle add
	
	//Protect from marine damage
	DamageFactor "MarineFire", 0.0
	DamageFactor "MarineFire2", 0.0
	DamageFactor "MarineFire3", 0.0
        DamageFactor "BFGSplash", 0.0
        DamageFactor "BFGSpray", 0.0
	
	states
	{
		Spawn:
			BOSS AB 10 A_Look
			goto Spawn
		See:
			BOSS AABBCCDD 3 A_Chase
			goto See
		Melee:
		Missile:
			BOSS EF 8 A_FaceTarget
			BOSS G 8 A_CustomMissile("FriendlyBaronBall")
			goto See
		Pain:
			BOSS H 2
			BOSS H 2 A_Pain
			goto See
		Death:
			BOSS I 2
			NULL A 0 A_SpawnItemEx("ClassicCreditBoom", 0, 0, 0, 0, 0, 0, 0, 0, 235)
			BOSS I 8 ACS_ExecuteAlways(500, 0, 4, 0)
			BOSS J 8 A_Scream
			BOSS K 8
			BOSS L 8 A_NoBlocking
			BOSS MN 8
			BOSS O 1 A_BossDeath
			BOSS O 650
		DeathFade:
			BOSS O 2 A_FadeOut(0.1)
			goto DeathFade
		Raise:
			BOSS ONMLKJI 8
			goto See
	}
}

ACTOR sfTeamHellKnight
{
	obituary "%o was splayed by a Hell Knight."
	hitobituary "%o was gutted by a Hell Knight."
	health 500
	radius 24
	height 64
	mass 1000
	speed 8
	painchance 50
	seesound "knight/sight"
	painsound "knight/pain"
	deathsound "knight/death"
	activesound "knight/active"
	MONSTER
	-ISMONSTER
	+FLOORCLIP
	+FRIENDLY
	renderstyle add
	
	//Protect from marine damage
	DamageFactor "MarineFire", 0.0
	DamageFactor "MarineFire2", 0.0
	DamageFactor "MarineFire3", 0.0
        DamageFactor "BFGSplash", 0.0
        DamageFactor "BFGSpray", 0.0
	
	states
	{
		Spawn:
			BOS2 AB 10 A_Look
			goto Spawn
		See:
			BOS2 AABBCCDD 3 A_Chase
			goto See
		Melee:
		Missile:
			BOS2 EF 8 A_FaceTarget
			BOS2 G 8 A_CustomMissile("FriendlyBaronBall")
			goto See
		Pain:
			BOS2 H 2
			BOS2 H 2 A_Pain
			goto See
		Death:
			BOS2 I 2
			BOS2 I 8 ACS_ExecuteAlways(500, 0, 5, 0)
			BOS2 J 8 A_Scream
			BOS2 K 8
			BOS2 L 8 A_NoBlocking
			BOS2 MN 8
			BOS2 O 0 A_BossDeath
			BOS2 O 650
		DeathFade:
			BOS2 O 2 A_FadeOut(0.1)
			goto DeathFade
		Raise:
			BOS2 ONMLKJI 8
			goto See
	}
}

ACTOR sfTeamCyberdemon
{
	obituary "%o was splattered by a cyberdemon."
	health 5000
	radius 40
	height 110
	mass 1000
	speed 17
	painchance 20
	seesound "cyber/sight"
	painsound "cyber/pain"
	deathsound "cyber/death"
	activesound "cyber/active"
	MONSTER
	-ISMONSTER
	+BOSS
	+FLOORCLIP
	+NORADIUSDMG
	+DONTMORPH
	+MISSILEMORE
	+FRIENDLY
	renderstyle add
	
	//Protect from marine damage
	DamageFactor "MarineFire", 0.0
	DamageFactor "MarineFire2", 0.0
	DamageFactor "MarineFire3", 0.0
        DamageFactor "BFGSplash", 0.0
        DamageFactor "BFGSpray", 0.0
	
	
	states
	{
		Spawn:
			CYBR AB 10 A_Look
			goto Spawn
		See:
			CYBR A 3 A_Hoof
			CYBR ABBCC 3 A_Chase
			CYBR D 3 A_Metal
			CYBR D 3
			goto See
		Missile:
			CYBR E 6 A_FaceTarget
			CYBR F 12 A_CustomMissile("FriendlyRocket")
			CYBR E 12 A_FaceTarget
			CYBR F 12 A_CustomMissile("FriendlyRocket")
			CYBR E 12 A_FaceTarget
			CYBR F 12 A_CustomMissile("FriendlyRocket")
			goto See
		Pain:
			CYBR G 10 A_Pain
			goto See
		Death:
			CYBR H 2
			CYBR H 10 
			CYBR I 10 A_Scream
			CYBR JKL 10
			CYBR M 10 A_NoBlocking
			CYBR NO 10
			CYBR P 30
			CYBR P -1 A_BossDeath
	}
}

ACTOR sfTeamLostSoul
{
	spawnid 110
	obituary "%o was spooked by a lost soul."
	health 100
	radius 16
	height 56
	mass 50
	speed 8
	damage 3
	painchance 256
	renderstyle SoulTrans
	attacksound "skull/melee"
	painsound "skull/pain"
	deathsound "skull/death"
	activesound "skull/active"
	MONSTER
	Species "DemonSide"
	+FLOAT
	+NOGRAVITY
	+NOICEDEATH
	+MISSILEMORE
	+DONTFALL
	+FRIENDLY
	-ISMONSTER
	renderstyle add
	
	//Protect from marine damage
	DamageFactor "MarineFire", 0.0
	DamageFactor "MarineFire2", 0.0
	DamageFactor "MarineFire3", 0.0
        DamageFactor "BFGSplash", 0.0
        DamageFactor "BFGSpray", 0.0

	states
	{
		Spawn:
			SKUL AB 10 bright A_Look
			goto Spawn
		See:
			SKUL AB 6 bright A_Chase
			goto See
		Missile:
			SKUL C 10 bright A_FaceTarget
			SKUL D 4 bright A_SkullAttack
			SKUL CD 4 bright
			goto Missile+2
		Pain:
			SKUL E 3 bright
			SKUL E 3 bright A_Pain
			goto See
		Death:
			SKUL F 2 bright
			SKUL F 6 bright 
			SKUL G 6 bright A_Scream
			SKUL H 6 bright
			SKUL I 6 bright A_NoBlocking
			SKUL JK 6
			stop
	}
}

ACTOR sfTeamRevenant
{
	obituary "%o couldn't evade a revenant's fireball."
	hitobituary "%o was punched by a revenant."
	health 300
	radius 20
	height 56
	mass 500
	speed 10
	painchance 100
	seesound "skeleton/sight"
	painsound "skeleton/pain"
	deathsound "skeleton/death"
	activesound "skeleton/active"
	
	MONSTER
	-ISMONSTER
	+FLOORCLIP
	+LONGMELEERANGE
	+MISSILEMORE
	+FRIENDLY
	renderstyle add
	
	//Protect from marine damage
	DamageFactor "MarineFire", 0.0
	DamageFactor "MarineFire2", 0.0
	DamageFactor "MarineFire3", 0.0
        DamageFactor "BFGSplash", 0.0
        DamageFactor "BFGSpray", 0.0

	states
	{
		Spawn:
			SKEL AB 10 A_Look
			goto Spawn
		See:
			SKEL AABBCCDDEEFF 2 A_Chase
			goto See
		Melee:
			SKEL G 0 A_FaceTarget
			SKEL G 6 A_SkelWhoosh
			SKEL H 6 A_FaceTarget
			SKEL I 6 A_SkelFist
			goto See
		Missile:
			SKEL J 0 bright A_FaceTarget
			SKEL J 10 bright A_FaceTarget
			SKEL K 10 A_CustomMissile("FriendlyRevenantTracer")
			SKEL K 10 A_FaceTarget
			goto See
		Pain:
			SKEL L 5
			SKEL L 5 A_Pain
			goto See
		Death:
			SKEL L 2
			SKEL LM 7 
			SKEL N 7 A_Scream
			SKEL O 7 A_NoBlocking
			SKEL P 7
			SKEL Q 650
		DeathFade:
			SKEL Q 2 A_FadeOut(0.1)
			goto DeathFade
		Raise:
			SKEL QPONML 5
			goto See
	}
}

//Preventing team-killing

actor FriendlyBaronBall : BaronBall { DamageType "MarineFire" }

actor FriendlyRocket : Rocket { DamageType "MarineFire" }

actor FriendlyRevenantTracer : RevenantTracer { DamageType "MarineFire" }

