actor BloodSatyr : DnD_BaseHybridMonster {
    Health 0x7FFFFFFF
	GibHealth -100
    Radius 24
    Height 64
    Scale 1.1
    PainChance 64
	Tag "Blood Satyr"
	Species "HK"
	+DONTHARMSPECIES
	Obituary "%o was drained of all life by a blood satyr."
    HitObituary "%o was mauled by a blood satyr."
	Translation "0:255=%[0.00,0.00,0.00]:[1.10,0.13,0.13]", "3:8=3:8", "16:47=16:47", "80:111=80:111", "168:191=168:191"
    Speed 8
    Mass 350
    SeeSound "Satyr/See"
    PainSound "Satyr/Hit"
    DeathSound "Satyr/Die"
    ActiveSound "Satyr/Act"
    MeleeSound "baron/melee"
	+ISMONSTER
	+DONTHURTSPECIES	
	States {
		SetInfo:
			TNT1 A 0 A_SetArg(4, DND_BLOODSATYR)
		Goto SpawnSetup

		IdleState:
			STYR AB 10 A_GiveInventory("DnD_SightChecker", 1)
		Loop
		SeeState:
			STYR AABBCCDD 3 Fast A_Chase
		Goto See
		MeleeState:
			STYR E 2 Fast A_FaceTarget
			TNT1 A 0 A_Recoil(-1.6)
			STYR E 3 Fast A_FaceTarget
			TNT1 A 0 A_Recoil(-2.0)
			STYR F 2 Fast A_FaceTarget
			TNT1 A 0 A_Recoil(-2.4)
			STYR F 3 Fast A_FaceTarget
			TNT1 A 0 A_Recoil(-2.8)
			STYR G 5 Fast A_CustomMeleeAttack(random(18, 36), "baron/melee")
			TNT1 A 0 A_Stop
			STYR P 2 Fast A_FaceTarget
			TNT1 A 0 A_Recoil(-1.6)
			STYR P 3 Fast A_FaceTarget
			TNT1 A 0 A_Recoil(-2.0)
			STYR Q 2 Fast A_FaceTarget
			TNT1 A 0 A_Recoil(-2.4)
			STYR Q 3 Fast A_FaceTarget
			TNT1 A 0 A_Recoil(-2.8)
			STYR R 5 Fast A_CustomMeleeAttack(random(18, 36), "baron/melee")
		Goto See
		MissileState:
			STYR EF 4 Fast A_FaceTarget
			STYR G 5 Fast A_CustomMissile("BloodSatyrMissile", 34)
			TNT1 A 0 A_CustomMissile("BloodSatyrMissile")
			STYR PQ 4 Fast A_FaceTarget
			STYR R 5 Fast A_CustomMissile("BloodSatyrMissile", 34)
			STYR R 0 A_CustomMissile("BloodSatyrMissile")
		Goto See
		PainState:
			STYR H 3 Fast
			STYR H 3 Fast A_Pain
		Goto See
		XDeathState:
			TNT1 A 0 A_SpawnItemEx("GenericGibber_Medium", 0, 0, 0, 0, 0, 0, 0, SXF_USEBLOODCOLOR)
		DeathState:	
			STYR I 5
			STYR J 5 A_Scream
			STYR K 6
			STYR L 7 A_Fall
			STYR M 4
			STYR N 4
			STYR O -1
		Stop
		RaiseState:
			STYR ONMLKJI 8
		Goto See
    }
}

Actor BloodSatyrMissileTrail {
	+NOINTERACTION
	+CLIENTSIDEONLY
	Scale 0.25
	States {
		Spawn:
			TNT1 A 2
			TNT1 A 0 A_Jump(256, "A", "B", "C", "D", "E", "F")
		A:
			FGOR A 4
		Stop
		B:
			FGOR B 4
		Stop
		C:
			FGOR C 4
		Stop
		D:
			FGOR D 4
		Stop
		E:
			FGOR E 4
		Stop
		F:
			FGOR F 4
		Stop
	}
}

Actor BloodSatyrMissile {
	PROJECTILE
	Speed 24
	Radius 4
	Height 8
	Damage (random(2, 16))
	+NODAMAGETHRUST
	DamageType "MagicalRed"
	Stamina 8
	SeeSound "BloodSatyr/Fire"
	DeathSound "ClericCStaffHitThing"
	Obituary "%o was drained of all life by a blood satyr."
	States {
		Spawn:
			TNT1 A 0 NoDelay ACS_NamedExecuteAlways("DnD Pierce Check")
		SpawnLoop:
			FGOR A 2 A_SpawnItem("BloodSatyrMissileTrail")
			TNT1 AA 0 A_BishopMissileWeave
			FGOR B 2 A_SpawnItem("BloodSatyrMissileTrail")
			TNT1 AA 0 A_BishopMissileWeave
			FGOR C 2 A_SpawnItem("BloodSatyrMissileTrail")
			TNT1 AA 0 A_BishopMissileWeave
			FGOR D 2 A_SpawnItem("BloodSatyrMissileTrail")
			TNT1 AA 0 A_BishopMissileWeave
			FGOR E 2 A_SpawnItem("BloodSatyrMissileTrail")
			TNT1 AA 0 A_BishopMissileWeave
			FGOR F 2 A_SpawnItem("BloodSatyrMissileTrail")
			TNT1 AA 0 A_BishopMissileWeave
		Loop
		XDeath:
			FGOR G 3
			FGOR HIJ 3
		Stop
		Death:
			FGOR GHIJ 3
		Stop
	}
}

Actor SatyrMissile : BaronBall {
	Projectile
	Radius 8
	Height 16
	Speed 22
	Damage (4*random(3,7))
	DamageType "MagicalYellow"
	Stamina 8
	Scale 0.75
	RenderStyle Add
	Translation "193:201=160:167", "202:208=165:168"
	Decal PlasmaScorchLower
	States {
		Spawn:
			TNT1 A 0 NoDelay ACS_NamedExecuteAlways("DnD Pierce Check")
		SpawnLoop:
			ANFB ABC 3 Bright
		Loop
		Death:
			TNT1 A 0 A_SpawnItemEx("OrangeParticleSpawner", 0, 0, 0, 0, 0, 0, 0, 128)
			TNT1 AAA 0 A_SpawnItemEx("ExplosionFX2", 0, 0, 0, frandom(-1, 1), frandom(-1, 1), frandom(-1, 1))
			TNT1 AAA 0 A_CustomMissile("FireballSmoke", 0, 0, random(0,360), 2, random(0,360))
			ANFB DEFG 3 Bright
		Stop
	}
}

Actor HellWarrior : DnD_BaseHybridMonster {
	Health 0x7FFFFFFF
	GibHealth -100
	Speed 8
	Radius 24
	Height 64
	PainChance 50
	Mass 1000
	SeeSound "knight/sight"
	PainSound "HellKnight/Pain"
	DeathSound "knight/death"
	ActiveSound "knight/active"
	MeleeSound "baron/melee"
	ReactionTime 8
	Species "HK"
	+ISMONSTER
	+DONTHURTSPECIES
	Obituary "%o was tagged by the hell warrior's fireball."
	HitObituary "%o was torn apart by a hell warrior."
	Tag "Hell Warrior"
	States {
		SetInfo:
			TNT1 A 0 A_SetArg(4, DND_HELLWARRIOR)
			TNT1 A 0 ACS_NamedExecuteWithResult("DnD Init Monster Data", DND_MWEIGHT_UNCOMMON)
		Goto SpawnSetup

		IdleState:
			HWAR AB 10 A_GiveInventory("DnD_SightChecker", 1)
		Loop
		SeeState: 
			TNT1 A 0 ACS_NamedExecuteWithResult("DnD Monster Trait Take", DND_ISBLOCKING, -1, -1, -1)
			HWAR AABBCCDD 3 Fast A_Chase
		Goto See
		MissileState:
			HWAR E 0 A_Jump(128, 4)
			HWAR EF 8 Fast A_FaceTarget
			HWAR G 8 Fast A_CustomComboAttack("HellWarriorBall", 32, 10 * random(1, 8), "baron/melee")
		Goto See
			HWAR H 0 A_Jump(128, 6)
			HWAR H 0 ACS_NamedExecuteWithResult("DnD Monster Trait Give", DND_ISBLOCKING, -1, -1, -1)
			HWAR H 6 Fast A_FaceTarget
			HWAR I 4 Fast Bright A_Custommissile("HellWarriorBall2", 25, 0, 0)
			HWAR H 6 Fast A_FaceTarget
			HWAR H 0 ACS_NamedExecuteWithResult("DnD Monster Trait Take", DND_ISBLOCKING, -1, -1, -1)
		Goto See
			HWAR H 0 ACS_NamedExecuteWithResult("DnD Monster Trait Give", DND_ISBLOCKING, -1, -1, -1)
			TNT1 A 0 A_ChangeFlag("NOBLOOD", 1)
			HWAR H 6 Fast A_FaceTarget
			HWAR I 4 Fast Bright A_Custommissile("HellWarriorBall2", 25, 0, 0)
			HWAR H 16 Fast A_SpidRefire
			HWAR I 4 Fast Bright A_Custommissile("HellWarriorBall2", 25, 0, 0)
			HWAR H 6 Fast A_FaceTarget
			TNT1 A 0 A_ChangeFlag("NOBLOOD", 0)
			HWAR H 0 ACS_NamedExecuteWithResult("DnD Monster Trait Take", DND_ISBLOCKING, -1, -1, -1)
		Goto See  
		MeleeState: 
			HWAR EF 8 Fast A_FaceTarget 
			HWAR G 8 Fast A_CustomComboAttack("HellWarriorBall", 32, 10 * random(1, 8), "baron/melee") 
		Goto See 
		PainState:
			TNT1 A 0 A_ChangeFlag("NOBLOOD", 0)
			HWAR J 6 Fast A_Pain 
			HWAR H 0 ACS_NamedExecuteWithResult("DnD Monster Trait Give", DND_ISBLOCKING, -1, -1, -1)
			TNT1 A 0 A_ChangeFlag("NOBLOOD", 1)
			HWAR HHHHHHH 6 Fast A_FaceTarget 
			HWAR H 0 ACS_NamedExecuteWithResult("DnD Monster Trait Take", DND_ISBLOCKING, -1, -1, -1)
			HWAR H 0 A_ChangeFlag("NOBLOOD", 0)
		Goto See 
		XDeathState:
			TNT1 A 0 A_SpawnItemEx("GenericGibber_Medium", 0, 0, 0, 0, 0, 0, 0, SXF_USEBLOODCOLOR)
		DeathState: 
			HWAE K 0 A_FaceTarget
			HWAR K 5 A_SpawnItemEx("HellWarriorShield", 0, 0, 25, 6, 0, 0, 60, 128)
			HWAR L 5 A_Scream
			HWAR M 5
			HWAR N 5 A_NoBlocking 
			HWAR OPQRS 5  
			HWAR T -1 
		Stop
		RaiseState: 
			HWAR QPONMLK 5 
		Goto See
	}
}

Actor HellWarriorBall {
	Radius 6
	Height 8
	Speed 14
	Damage (8 * random(1, 8))
	+DONTBLAST
	DamageType "MagicalYellow"
	Stamina 8
	Projectile
	RenderStyle Add
	Alpha 0.7
	SeeSound "imp/attack"
	DeathSound "imp/shotx"
	Decal BaronScorch
	Translation "112:112=231:231", "113:119=161:167", "120:120=44:44", "121:121=78:79", "122:122=239:239", "123:126=5:8"
	States {
		Spawn:
			TNT1 A 0 NoDelay ACS_NamedExecuteAlways("DnD Pierce Check")
		SpawnLoop:
			BAL7 AABB 2 Bright A_SpawnItem("HellWarriorBallTrail")
		Loop
		Death:
			TNT1 A 0 A_SpawnItemEx("YellowParticleSpawner", 0, 0, 0, 0, 0, 0, 0, 128)
			TNT1 AAA 0 A_CustomMissile("ExplosionFX9", 0, 0, random(0,360), 2, random(0,360))
			TNT1 AAA 0 A_CustomMissile("FireballSmoke", 0, 0, random(0,360), 2, random(0,360))
			BAL7 CDE 5 Bright
		Stop
	}
}

Actor HellWarriorBallTrail {
	+CLIENTSIDEONLY
	+NOINTERACTION
	+NOGRAVITY
	Renderstyle Add
	Alpha 0.75
	Translation "112:112=231:231", "113:119=161:167", "120:120=44:44", "121:121=78:79", "122:122=239:239", "123:126=5:8"
	States {
		Spawn:
			BAL7 AB 2 Bright A_FadeOut(0.15)
		Loop
	}
}

Actor HellWarriorBall2 {
	Radius 6
	Height 8
	Speed 8
	Damage (2 * random(1, 8))
	+DONTBLAST
	DamageType "MagicalYellow"
	Stamina 8
	Projectile
	RenderStyle Add
	+Randomize
	+Ripper
	Alpha 0.8
	Scale 0.4
	SeeSound "imp/attack"
	DeathSound "imp/shotx"
	States {
		Spawn:
			TNT1 A 0 NoDelay ACS_NamedExecuteAlways("DnD Pierce Check")
		SpawnLoop:
			GRBA ABCDEFGH 2 Bright A_SpawnItem("HellWarriorBall2Trail")
		Loop
		Death:
			GRBA AIJKLMN 3 Bright
		Stop
	}
}

Actor HellWarriorBall2Trail {
	+CLIENTSIDEONLY
	+NOINTERACTION
	+NOGRAVITY
	Renderstyle Add
	Alpha 0.75
	Scale 0.75
	States {
		Spawn:
			GRBA ABCDEFGH 2 Bright A_FadeOut(0.075)
		Loop
	}
}

Actor HellWarriorShield {
	Radius 8
	Height 8
	Speed 6
	+DoomBounce
	+DropOff
	+Missile
	+CLIENTSIDEONLY
	States {
		Spawn:
			HWSH ABCDEFGH 3
		Loop
		Death:
			HWSH I -1
		Loop
	}
}

Actor HellsFury : DnD_BaseHybridMonster {
	//$Category Monsters
	Health 0x7FFFFFFF
	GibHealth -100
	Radius 24
	Height 64
	Speed 9
	PainChance 50
	Mass 1000
	SeeSound "baron/sight"
	ActiveSound "baron/active"
	PainSound "baron/pain"
	DeathSound "baron/death"
	Obituary "%o felt the wrath of Hell's Fury."
	HitObituary "%o got ripped apart by Hell's Fury."
	Tag "Hell's Fury"
	Species "HK"
	+ISMONSTER
	+MISSILEMORE
	+DONTHURTSPECIES
	States {
		SetInfo:
			TNT1 A 0 A_SetArg(4, DND_HELLSFURY)
			TNT1 A 0 ACS_NamedExecuteWithResult("DnD Init Monster Data", DND_MWEIGHT_UNCOMMON)
		Goto SpawnSetup

		IdleState:
			HFRY AB 10 A_GiveInventory("DnD_SightChecker", 1)
		Loop
		SeeState:
			HFRY AABBCCDD 4 Fast A_Chase
		Goto See
		MissileState:
			HFRY E 0 A_Jump(108, "Missile2")
			HFRY EF 8 Fast A_FaceTarget
			HFRY G 8 Fast A_CustomComboAttack("HellsFuryBall", 32, 11 * random(1, 8), "baron/melee")
			HFRY RS 8 Fast A_FaceTarget
			HFRY T 8 Fast A_CustomComboAttack("HellsFuryBall", 32, 11 * random(1, 8), "baron/melee")
		Goto See
		Missile2:
			TNT1 A 0 ACS_NamedExecuteAlways("DnD Create Blind FX", 0, DND_BLIND_HEAVY, 384)
			HFRY P 8 Fast A_FaceTarget
			TNT1 A 0 A_CustomMissile("SoulHarvesterBall", 60, 0, -45)
			TNT1 A 0 A_CustomMissile("SoulHarvesterBall", 60, 0, 0)
			TNT1 A 0 A_CustomMissile("SoulHarvesterBall", 60, 0, 45)
			HFRY Q 24 Fast A_FaceTarget
			TNT1 A 0 A_GiveInventory("DnD_BlindCastCooldown", 1)
			HFRY Q 2 Fast ACS_NamedExecuteWithResult("DnD Monster Blind Cast", 105 | (DND_BLIND_HEAVY << 16), (144 << 8) | (144 << 16), 100, 384)
			HFRY Q 0 A_Jump(192, "Combo")
		Goto See
		Combo:
			HFRY EF 8 Fast A_FaceTarget
			HFRY G 8 Fast A_CustomComboAttack("HellsFuryBall", 32, 11 * random(1, 8), "baron/melee")
			HFRY RS 7 Fast A_FaceTarget
			HFRY T 7 Fast A_CustomComboAttack("HellsFuryBall", 32, 11 * random(1, 8), "baron/melee")
			HFRY EF 6 Fast A_FaceTarget
			HFRY G 6 Fast A_CustomComboAttack("HellsFuryBall", 32, 11 * random(1, 8), "baron/melee")
			HFRY RS 5 Fast A_FaceTarget
			HFRY T 5 Fast A_CustomComboAttack("HellsFuryBall", 32, 11 * random(1, 8), "baron/melee")
		Goto See
		MeleeState:
			HFRY EF 8 Fast A_FaceTarget
			HFRY G 8 Fast A_CustomComboAttack("HellsFuryBall", 32, 11 * random(1, 8), "baron/melee")
		Goto See
		PainState:
			HFRY H 2 Fast ACS_NamedExecuteWithResult("DnD Monster Blind Cancel CS")
			HFRY H 2 Fast A_Pain
		Goto See
		XDeathState:
			TNT1 A 0 A_SpawnItemEx("GenericGibber_Medium", 0, 0, 0, 0, 0, 0, 0, SXF_USEBLOODCOLOR)
		DeathState:
			HFRY I 8 A_Scream
			TNT1 A 0 A_FaceTarget
			TNT1 A 0 A_SpawnItemEx("HellsFurySkull", 0, 0, 60, 5, 0, 0, 10 * random(-2, 2), 128)
			HFRY J 8 
			HFRY K 8
			HFRY L 8 A_Fall
			HFRY MN 8
			HFRY O -1
		Stop
		RaiseState:
			HFRY NMLKJI 8
		Goto See
	}
}

Actor HellsFuryBall {
	Radius 6
	Height 8
	Speed 14
	Damage (8 * random(1, 8))
	+DONTBLAST
	DamageType "MagicalRed"
	Stamina 8
	Projectile
	RenderStyle Add
	Alpha 0.7
	SeeSound "imp/attack"
	DeathSound "imp/shotx"
	Translation "112:122=175:188", "112:113=175:175", "123:123=44:44", "124:127=191:191"
	Decal BaronScorch
	States {
		Spawn:
			TNT1 A 0 NoDelay ACS_NamedExecuteAlways("DnD Pierce Check")
		SpawnLoop:
			BAL7 AABB 2 Bright A_SpawnItem("HellsFuryBallTrail")
		Loop
		Death:
			TNT1 A 0 A_SpawnItemEx("RedParticleSpawner", 0, 0, 0, 0, 0, 0, 0, 128)
			TNT1 AAA 0 A_SpawnItemEx("ExplosionFX8", 0, 0, 0, frandom(-1, 1), frandom(-1, 1), frandom(-1, 1))
			TNT1 AAA 0 A_CustomMissile("FireballSmoke", 0, 0, random(0,360), 2, random(0,360))
			BAL7 CDE 6 Bright
		Stop
	}
}

Actor HellsFuryBallTrail : HellWarriorBallTrail {
	Translation "112:122=175:188", "112:113=175:175", "123:123=44:44", "124:127=191:191"
	States {
		Spawn:
			BAL7 AB 2 Bright A_FadeOut(0.15)
		Loop
	}
}

Actor HellsFurySkull {
	Radius 5
	Height 5
	Speed 5
	Mass 5000
	+DropOff
	+DoomBounce
	+Missile
	+CLIENTSIDEONLY
	States {
		Spawn:
			FSKL ABCDEFGHIJK 2
		Loop
		Death:
			FSKL L -1
		Loop
	}
}

Actor ArchonOfHell : DnD_BaseHybridMonster { 
	Health 0x7FFFFFFF
	GibHealth -100
	Radius 24 
	Height 64 
	Mass 1000 
	Speed 8 
	PainChance 20 
	Obituary "%o was no match for an archon of hell."
	HitObituary "%o was ripped apart by an archon of hell."
	BloodColor "20 60 20"
	+ISMONSTER
	+NoTarget
	+MissileMore
	Species "HK"
	+DONTHURTSPECIES  
	SeeSound "monster/ar2sit" 
	PainSound "baron/pain" 
	DeathSound "monster/ar2dth"
	MeleeSound "baron/melee"
	Tag "Archon of Hell"
	States {
		SetInfo:
			TNT1 A 0 A_SetArg(4, DND_ARCHON)
			TNT1 A 0 ACS_NamedExecuteWithResult("DnD Init Monster Data", DND_MWEIGHT_RARE2)
		Goto SpawnSetup
	
		IdleState:
			BOS4 AB 10 A_GiveInventory("DnD_SightChecker", 1) 
		Loop 
		SeeState:
			BOS4 AABBCCDD 3 Fast A_Chase 
		Goto See 
		MissileState:
			BOS4 B 0 A_Jump(128,15)
			BOS4 EF 8 Fast Bright A_FaceTarget 
			BOS4 G 0 Bright A_CustomMissile("BaronBall",28,0,0,0)
			BOS4 G 0 Bright A_CustomMissile("BaronBall",28,0,-4,0)
			BOS4 G 3 Fast Bright A_CustomMissile("BaronBall",28,0,4,0)
			BOS4 H 3 Fast Bright
			BOS4 H 0 A_Jump(64,8)
			BOS4 IJ 8 Fast Bright A_FaceTarget 
			BOS4 K 0 Bright A_CustomMissile("BaronBall",28,0,0,0)
			BOS4 K 0 Bright A_CustomMissile("BaronBall",28,0,-4,0)
			BOS4 K 3 Fast Bright A_CustomMissile("BaronBall",28,0,4,0)
			BOS4 L 3 Fast Bright
			BOS4 L 0 A_Jump(64,1)
		Goto See
			BOS4 MN 8 Fast Bright A_FaceTarget
			BOS4 O 0 Bright A_Jump(128,3)
			BOS4 O 4 Fast Bright A_CustomMissile("ArchonComet",28,0,0,0)
			BOS4 P 4 Fast Bright
		Goto See
			BOS4 O 0 A_CustomMissile("BaronBall",28,0,-6,0)
			BOS4 O 0 A_CustomMissile("BaronBall",28,0,-4,0)
			BOS4 O 0 A_CustomMissile("BaronBall",28,0,-2,0)
			BOS4 O 0 A_CustomMissile("BaronBall",28,0,2,0)
			BOS4 O 0 A_CustomMissile("BaronBall",28,0,4,0)
			BOS4 O 3 Fast Bright A_CustomMissile("BaronBall",28,0,6,0)
			BOS4 P 3 Fast Bright
		Goto See
		MeleeState:
			BOS4 EF 8 Fast Bright A_FaceTarget 
			BOS4 G 3 Fast Bright A_CustomMeleeAttack(10 * random(1, 8), "baron/melee")
			BOS4 H 3 Fast Bright
			BOS4 H 0 A_Jump(128,1)
		Goto See
			BOS4 IJ 8 Fast Bright A_FaceTarget 
			BOS4 K 3 Fast Bright A_CustomMeleeAttack(10 * random(1, 8), "baron/melee")
			BOS4 L 3 Fast Bright
			BOS4 L 0 A_Jump(64,1)
		Goto See
			BOS4 MN 8 Fast Bright A_FaceTarget
			BOS4 O 3 Fast Bright A_CustomMeleeAttack(20 * random(1, 8), "baron/melee")
			BOS4 P 3 Fast Bright
		Goto See
		PainState: 
			BOS4 Q 2 Fast 
			BOS4 Q 2 Fast A_Pain 
		Goto See 
		XDeathState:
			TNT1 A 0 A_SpawnItemEx("GenericGibber_Medium", 0, 0, 0, 0, 0, 0, 0, SXF_USEBLOODCOLOR)
		DeathState:
			BOS4 R 6 Bright 
			BOS4 S 6 Bright A_Scream 
			BOS4 T 6 Bright
			TNT1 A 0 A_SpawnItemEx("GenericGibber_Medium", 0, 0, 0, 0, 0, 0, 0, SXF_USEBLOODCOLOR)
			BOS4 U 6 Bright A_NoBlocking 
			BOS4 VW 6 Bright 
			BOS4 X 6 Bright A_CustomMissile("ArchonSoul",86,0,0,2,90)
			BOS4 YZ 6 Bright 
			BOS4 [ 6 Bright
		Stop
	} 
}

Actor ArchonExp : BaseExplosionDamage {
	DamageType "MagicalGreen"
	Stamina 8
	Obituary "%o was no match for an archon of hell."
	States {
		Spawn:
			TNT1 A 0 NoDelay ACS_NamedExecuteAlways("DnD Pierce Check")
			TNT1 A 1 A_Explode(32, 128, 0)
		Stop
	}
}

Actor ArchonComet {
	Radius 8
	Height 12
	Speed 24
	Damage (6 * random(1, 8))
	DamageType "MagicalGreen"
	Stamina 8
	Scale 1.0
	Projectile
	+ThruGhost
	+DONTBLAST
	SeeSound "weapons/firbfi"
	DeathSound "weapons/hellex"
	DontHurtShooter
	States {
		Spawn: 
			TNT1 A 0 NoDelay ACS_NamedExecuteAlways("DnD Pierce Check")
		SpawnLoop:
			ARCB AAAABBBBCCCC 1 Bright A_SpawnItemEx("ArchonCometTrail",0,0,0,0,0,0,0,128)
		Loop
		Death:
			TNT1 AA 0 A_SpawnItemEx("GreenParticleSpawner", 0, 0, 0, 0, 0, 0, 0, 128)
			TNT1 AAA 0 A_SpawnItemEx("ExplosionFX4", 0, 0, 0, frandom(-1, 1), frandom(-1, 1), frandom(-1, 1))
			TNT1 AAA 0 A_CustomMissile("FireballSmoke", 0, 0, random(0,360), 2, random(0,360))
			TNT1 A 0 A_SetTranslucent (0.67,1)
			ARCB J 3 Bright
			ARCB K 3 Bright A_SpawnItem("ArchonExp")
			ARCB LMN 3 Bright
		Stop
	}
}

Actor ArchonSoul {  
	Radius 1
	Height 1
	Speed 3
	Projectile
	RenderStyle Add
	Alpha 0.80
	+CLIENTSIDEONLY
	States {
		Spawn:
			BFX1 ABCD 6 Bright
		Stop 
	}
}

Actor ArchonCometTrail {
	Radius 3
	Height 3
	Scale 0.75
	Speed 0
	Projectile
	RenderStyle Add
	Alpha 0.67
	+CLIENTSIDEONLY
	States {
		Spawn:
			TNT1 A 3 Bright
			ARCB DEFGHI 3 Bright
		Stop 
	}
}

Actor WarlordOfHell : DnD_BaseHybridMonster { 
	Health 0x7FFFFFFF
	GibHealth -100
	Radius 24
	Height 64 
	Speed 10 
	PainChance 50
	Scale 1.1
	Mass 1000
	BloodColor "39 59 9F"
	Species "HK"
	+ISMONSTER
	+NoRadiusDmg
	Obituary "%o was extinguished by the warlord of hell." 
	SeeSound "warlord/sight" 
	PainSound "warlord/pain" 
	DeathSound "warlord/death" 
	ActiveSound "warlord/active" 
	Translation "1:2=8:0", "13:15=5:7", "48:64=90:110", "64:70=109:112", "70:83=5:10", "110:123=196:207", "80:111=80:111", "124:127=242:245", "128:141=102:111", "143:149=104:114", "142:143=5:5", "148:151=5:7"
	Tag "Warlord of Hell"
	States {
		SetInfo:
			TNT1 A 0 A_SetArg(4, DND_WARLORD)
			TNT1 A 0 ACS_NamedExecuteWithResult("DnD Init Monster Data", DND_MWEIGHT_RARE1)
		Goto SpawnSetup

		IdleState:
			BOS2 AB 10 A_GiveInventory("DnD_SightChecker", 1) 
		Loop 
		SeeState: 
			BOS2 AABBCCDD 4 Fast A_Chase 
		Goto See
		MeleeState:
			BOS2 E 6 Fast A_FaceTarget 
			BOS2 F 6 Fast A_FaceTarget 
			BOS2 G 6 Fast A_CustomComboAttack("WarlordOfHellBall", 32, 10 * random(1, 8), "baron/melee")
		Goto See
		MissileState: 
			BOS2 E 0 A_JumpIfHealthLower(ACS_ExecuteWithResult(961, 7) / 3, "Missile3") 
			BOS2 E 0 A_JumpIfHealthLower(2 * ACS_ExecuteWithResult(961, 7) / 3, "Missile2")
			BOS2 E 6 Fast A_FaceTarget 
			BOS2 F 6 Fast A_FaceTarget 
			BOS2 G 6 Fast A_Custommissile("WarlordOfHellBall", 32, 0, 0)
		Goto See
		Missile2:
			BOS2 E 6 Fast A_FaceTarget 
			BOS2 F 6 Fast A_FaceTarget 
			BOS2 G 0 A_Custommissile("WarlordOfHellBall", 32, 0, 8) 
			BOS2 G 6 Fast A_Custommissile("WarlordOfHellBall", 32, 0, 0)
			BOS2 X 6 Fast A_FaceTarget 
			BOS2 Y 6 Fast A_FaceTarget 
			BOS2 R 0 A_Custommissile("WarlordOfHellBall", 32, 0, 0) 
			BOS2 Z 6 Fast A_Custommissile("WarlordOfHellBall", 32, 0, -8)
		Goto See 
		Missile3:
			BOS2 E 6 Fast A_FaceTarget 
			BOS2 F 6 Fast A_FaceTarget 
			BOS2 G 0 A_Custommissile("WarlordOfHellBall", 32, 0, -20) 
			BOS2 G 6 Fast A_Custommissile("WarlordOfHellBall", 32, 0, 0) 
			BOS2 X 6 Fast A_FaceTarget 
			BOS2 Y 6 Fast A_FaceTarget 
			BOS2 R 0 A_Custommissile("WarlordOfHellBall", 32, 0, 20) 
			BOS2 Z 6 Fast A_Custommissile("WarlordOfHellBall", 32, 0, 0) 
			BOS2 E 6 Fast A_FaceTarget 
			BOS2 F 6 Fast A_FaceTarget 
			BOS2 G 0 A_Custommissile("WarlordOfHellBall", 32, 0, -12) 
			BOS2 G 6 Fast A_Custommissile("WarlordOfHellBall", 32, 0, 12) 
		Goto See 
		PainState: 
			BOS2 H 5 Fast 
			BOS2 H 5 Fast A_Pain 
		Goto See 
		XDeathState:
			TNT1 A 0 A_SpawnItemEx("GenericGibber_Medium", 0, 0, 0, 0, 0, 0, 0, SXF_USEBLOODCOLOR)
		DeathState: 
			BOS2 I 12 
			BOS2 J 12 A_Scream 
			BOS2 K 6
			BOS2 K 6 A_Fall
			BOS2 LMN 12 
			BOS2 O -1 
		Stop 	
		RaiseState: 
			BOS2 ONMLKJI 5 
		Goto See
	} 
}

Actor WarlordOfHellBall {
	Radius 6
	Height 8
	Speed 20
	Damage (8 * random(1, 8))
	Projectile
	SeeSound "imp/attack"
	DeathSound "imp/shotx"
	Damagetype "FireBlue"
	Stamina 8
	Decal BaronScorch
	Translation "111:123=197:207", "124:127=242:245"
	+DONTBLAST
	States {
		Spawn:
			TNT1 A 0 NoDelay ACS_NamedExecuteAlways("DnD Pierce Check")
		SpawnLoop:
			BAL7 AAAABBBB 1 Bright A_SpawnItem("WarlordBallTrail")
		Loop
		Death:
			TNT1 A 0 A_SpawnItemEx("BlueParticleSpawner", 0, 0, 0, 0, 0, 0, 0, 128)
			TNT1 AAA 0 A_SpawnItemEx("ExplosionFX5", 0, 0, 0, frandom(-1, 1), frandom(-1, 1), frandom(-1, 1))
			TNT1 AAA 0 A_CustomMissile("FireballSmoke", 0, 0, random(0,360), 2, random(0,360))
			BAL7 CDE 6 Bright
		Stop
	}
}

Actor WarlordBallTrail {
	+NOBLOCKMAP
	+NOGRAVITY
	+CLIENTSIDEONLY
	Height 2
	Radius 2
	Renderstyle Add
	Alpha 0.75
	Translation "111:123=197:207", "124:127=242:245"
	States {
		Spawn:
			TNT1 A 0
			TNT1 A 0 A_Jump(128, "Type2")
		SpawnLoop:
			BAL7 A 1 A_FadeOut(0.15)
		Loop
		Type2:
			BAL7 B 1 A_FadeOut(0.15)
		Loop
	}
}

ACTOR ShadowBeast : DnD_BaseRangedMonster {
	OBITUARY "%o was killed by a shadow beast."
	Bloodcolor "70 AC 00"
	Health 0x7FFFFFFF
	GibHealth -100
	Radius 24
	Height 64
	Mass 500
	Speed 12
	MeleeRange 96
	GibHealth -75
	PainChance 144
	SEESOUND "shadowbeast/sight"
	PAINSOUND "shadowbeast/pain"
	DEATHSOUND "shadowbeast/death"
	ACTIVESOUND "shadowbeast/active"
	Species "HK"
	Tag "Shadow Beast"
	+ISMONSTER
	+DONTHURTSPECIES
	states {
		SetInfo:
			TNT1 A 0 A_SetArg(4, DND_SHADOWBEAST)
			TNT1 A 0 ACS_NamedExecuteWithResult("DnD Init Monster Data", DND_MWEIGHT_RARE1)
		Goto SpawnSetup

		IdleState:
			BDEM AB 10 A_GiveInventory("DnD_SightChecker", 1)
		Loop
		SeeState:
			TNT1 A 0 A_JumpIfHealthLower (ACS_ExecuteWithResult(961, 7) / 2, "Run") 
			BDEM ABCDEF 6 Fast A_Chase
		Goto See
		Run:
			TNT1 A 0 A_PlaySound("shadowbeast/sight")
			BDEM AABBCCDDEEFF 2 Fast A_Chase("Spit","Missile")
			BDEM AABBCCDDEEFF 2 Fast A_Chase("Spit","Missile")
			BDEM AABBCCDDEEFF 2 Fast A_Chase("Spit","Missile")
		Goto Missile
		MissileState:
			TNT1 A 0 A_JumpIfHealthLower (ACS_ExecuteWithResult(961, 7) / 2, "Missile2") 
			TNT1 A 0 A_Jump(90, 5)
			BDEM H 6 Fast A_FaceTarget
			BDEM I 0 A_CustomMissile ("ShadowBeast_Ball1", 56, 0, -8)
			BDEM I 6 Fast A_CustomMissile ("ShadowBeast_Ball1", 56, 0, 8)
			BDEM I 0 A_CustomMissile ("ShadowBeast_Ball1", 56, 0, 0)
		Goto See
			BDEM H 4 Fast A_FaceTarget
			BDEM I 4 Fast A_CustomMissile ("ShadowBeast_Ball2", 56, 0, -16)
			BDEM I 0 A_FaceTarget
			BDEM I 4 Fast A_CustomMissile ("ShadowBeast_Ball2", 56, 0, -8)
			BDEM I 0 A_FaceTarget
			BDEM I 4 Fast A_CustomMissile ("ShadowBeast_Ball2", 56, 0, 0)
			BDEM I 0 A_FaceTarget
			BDEM I 4 Fast A_CustomMissile ("ShadowBeast_Ball2", 56, 0, 8)
			BDEM I 0 A_FaceTarget
			BDEM I 4 Fast A_CustomMissile ("ShadowBeast_Ball2", 56, 0, 16)
			BDEM I 0 A_FaceTarget
			BDEM I 4 Fast A_CustomMissile ("ShadowBeast_Ball2", 56, 0, 32)
		Goto See
		Missile2:
			TNT1 A 0 A_Jump(90, 15)
		Spit:
			BDEM H 6 Fast A_FaceTarget
			BDEM I 2 Fast A_CustomMissile ("ShadowBeast_BallFire", 56, 0, random(-8,8))
			BDEM I 2 Fast A_CustomMissile ("ShadowBeast_BallFire", 56, 0, random(-8,8))
			BDEM I 2 Fast A_CustomMissile ("ShadowBeast_BallFire", 56, 0, random(-8,8))
			BDEM I 2 Fast A_CustomMissile ("ShadowBeast_BallFire", 56, 0, random(-8,8))
			BDEM I 2 Fast A_CustomMissile ("ShadowBeast_BallFire", 56, 0, random(-8,8))
			BDEM I 2 Fast A_CustomMissile ("ShadowBeast_BallFire", 56, 0, random(-8,8))
			BDEM I 2 Fast A_CustomMissile ("ShadowBeast_BallFire", 56, 0, random(-8,8))
			BDEM I 2 Fast A_CustomMissile ("ShadowBeast_BallFire", 56, 0, random(-8,8))
			BDEM I 2 Fast A_CustomMissile ("ShadowBeast_BallFire", 56, 0, random(-8,8))
			BDEM I 2 Fast A_CustomMissile ("ShadowBeast_BallFire", 56, 0, random(-8,8))
			BDEM I 2 Fast A_CustomMissile ("ShadowBeast_BallFire", 56, 0, random(-8,8))
			BDEM I 2 Fast A_CustomMissile ("ShadowBeast_BallFire", 56, 0, random(-8,8))
			BDEM I 2 Fast A_CustomMissile ("ShadowBeast_BallFire", 56, 0, random(-8,8))
		Goto See
			BDEM H 16 Fast A_FaceTarget
			BDEM I 0 A_CustomMissile ("ShadowBeast_Ball3", 56, 0, -64)
			BDEM I 0 A_CustomMissile ("ShadowBeast_Ball3", 56, 0, 64)
			BDEM I 0 A_CustomMissile ("ShadowBeast_Ball3", 56, 0, -56)
			BDEM I 0 A_CustomMissile ("ShadowBeast_Ball3", 56, 0, 56)
			BDEM I 0 A_CustomMissile ("ShadowBeast_Ball3", 56, 0, -48)
			BDEM I 0 A_CustomMissile ("ShadowBeast_Ball3", 56, 0, 48)    
			BDEM I 0 A_CustomMissile ("ShadowBeast_Ball3", 56, 0, -40)
			BDEM I 0 A_CustomMissile ("ShadowBeast_Ball3", 56, 0, 40)    
			BDEM I 0 A_CustomMissile ("ShadowBeast_Ball3", 56, 0, -32)
			BDEM I 0 A_CustomMissile ("ShadowBeast_Ball3", 56, 0, 32)
			BDEM I 0 A_CustomMissile ("ShadowBeast_Ball3", 56, 0, -24)
			BDEM I 0 A_CustomMissile ("ShadowBeast_Ball3", 56, 0, 24)
			BDEM I 0 A_CustomMissile ("ShadowBeast_Ball3", 56, 0, -16)
			BDEM I 0 A_CustomMissile ("ShadowBeast_Ball3", 56, 0, 16)    
			BDEM I 0 A_CustomMissile ("ShadowBeast_Ball3", 56, 0, -8)
			BDEM I 0 A_CustomMissile ("ShadowBeast_Ball3", 56, 0, 8)    
			BDEM I 6 Fast A_CustomMissile ("ShadowBeast_Ball3", 56, 0, 0)
		Goto See
		PainState:
			BDEM G 4 Fast A_Pain
		Goto See
		DeathState:
			BDEM R 8
			BDEM S 8 A_Scream
			TNT1 A 0 A_NoBlocking
			BDEM TUVWX 6
			BDEM Y 6
			BDEM Z -1
		Stop
		XDeathState:
			BDEM J 6 A_SpawnItemEx("GenericGibber_Medium", 0, 0, 0, 0, 0, 0, 0, SXF_USEBLOODCOLOR)
			BDEM K 6 A_Scream
			TNT1 A 0 A_NoBlocking
			BDEM LMNOPQ 6
		Stop
		RaiseState:
			BDEM YXWVUTSR 5
		Goto See
	}
}

ACTOR ShadowBeast_BallFire {
	Alpha 1.0  
	Renderstyle Add
	Speed 15
	Radius 10
	Height 6
	Damage (2 * random(1, 8))
	DamageType "FireGreen"
	Stamina 8
	Projectile
	+SPAWNSOUNDSOURCE
	+RIPPER
	+DONTBLAST
	RenderStyle Add
	SeeSound "shadowbeast/pr1death"
	Decal MummyScorch
	States {
		Spawn:
			TNT1 A 0 NoDelay ACS_NamedExecuteAlways("DnD Pierce Check")
		SpawnLoop:
			BDP2 DEFGH 5 Bright
		Goto Death
		Death:
			TNT1 A 1
		Stop
	}
}

ACTOR ShadowBeast_Ball1 {
	Alpha 1.0  
	Renderstyle Add
	Speed 15
	Radius 10
	Height 6
	Damage (5*random(2,5))
	DamageType "FireGreen"
	Stamina 8
	Projectile
	+SPAWNSOUNDSOURCE
	+DONTBLAST
	RenderStyle Add
	SeeSound "shadowbeast/pr1sight"
	DeathSound "shadowbeast/pr1death"
	States {
		Spawn:
			TNT1 A 0 NoDelay ACS_NamedExecuteAlways("DnD Pierce Check")
		SpawnLoop:
			BDP2 ABC 4 Bright
		Loop
		Death:
			TNT1 A 0 A_SpawnItemEx("GreenParticleSpawner", 0, 0, 0, 0, 0, 0, 0, 128)
			TNT1 AAA 0 A_SpawnItemEx("ExplosionFX4", 0, 0, 0, frandom(-1, 1), frandom(-1, 1), frandom(-1, 1))
			TNT1 AAA 0 A_CustomMissile("FireballSmoke", 0, 0, random(0,360), 2, random(0,360))
			BDP2 DE 4 Bright
			BDP2 FGH 3 Bright
		Stop
	}
}

ACTOR ShadowBeast_Ball2 {
	Alpha 1.0
	Renderstyle Add
	Radius 8
	Height 6
	Damage (2 * random(1, 8))
	Damagetype "FireGreen"
	Stamina 8
	Speed 16
	PROJECTILE
	+Randomize
	+DONTBLAST
	SeeSound "shadowbeast/pr2sight"
	DeathSound "shadowbeast/pr2death"
	Decal PlasmaScorchLower
	States {
		Spawn:
			TNT1 A 0 NoDelay ACS_NamedExecuteAlways("DnD Pierce Check")
		SpawnLoop:
			BDP1 D 1 A_BishopMissileWeave
			BDP1 E 1 A_BishopMissileWeave
		loop
		Death:
			BDP1 FGHI 3
		Stop
	}
}

ACTOR ShadowBeast_Ball3 {
	Alpha 1.0
	Scale 1.4
	Renderstyle Add
	Radius 8
	Height 6
	Damage (5 * random(1, 8))
	DamageType "FireGreen"
	Stamina 8
	Speed 20
	PROJECTILE
	+DONTBLAST
	+Randomize
	SeeSound "shadowbeast/pr2sight"
	DeathSound "shadowbeast/pr2death"
	Decal PlasmaScorchLower
	States {
		Spawn:
			TNT1 A 0 NoDelay ACS_NamedExecuteAlways("DnD Pierce Check")
		SpawnLoop:
			BDP1 DEDEDEDED 2 A_BishopMissileWeave
			BDP1 ED 2 A_BishopMissileWeave
			TNT1 A 0 A_FadeOut(0.20)
		Goto Spawn+9
		Death:
			BDP1 FGHI 3
		Stop
	}
}

actor BlackKnight : DnD_BaseHybridMonster {
	Health 0x7FFFFFFF
	Radius 24
	Height 64
	PainChance 100
	Mass 0x7FFFFFFF
	MeleeRange 96
	MaxStepHeight 32
	Speed 9
	Scale 1.2
	Species "HK"
	Tag "Black Knight"
	+ISMONSTER
	+NOBLOOD
	+DONTRIP
	+DONTHURTSPECIES
	SeeSound "dknight/sight"
	ActiveSound "dknight/active"
	MeleeSound "dknight/melee"
	PainSound "dknight/pain"
	DeathSound "dknight/death"
	HitObituary "%o was sliced by a black knight."
	Obituary "%o was burned from a black knight's dark magic."
	States {
		SetInfo:
			TNT1 A 0 A_SetArg(4, DND_BLACKKNIGHT)
			TNT1 A 0 ACS_NamedExecuteWithResult("DnD Init Monster Data", DND_MWEIGHT_RARE1)
		Goto SpawnSetup

		IdleState:
			TM04 A 5 A_GiveInventory("DnD_SightChecker", 1)
		Loop
		SeeState:
			TNT1 A 0 ACS_NamedExecuteWithResult("DnD Monster Trait Take", 0, DND_ISBLOCKING)
			TM04 AABBCCDD 2 Fast A_Chase
		Goto See
		MeleeState:
			TM04 E 3 Fast A_FaceTarget
			TM04 F 2 Fast A_FaceTarget
			TM04 F 0 A_PlaySound("dknight/swing")
			TM04 F 2 Fast
			TM04 G 3 Fast A_CustomMeleeAttack(4 * random(1, 8), "dknight/melee")
			TM04 H 4 Fast A_CustomMeleeAttack(4 * random(1, 8), "dknight/melee")
			TM04 H 1 Fast
		Goto See
		MissileState:
			TNT1 A 0 A_Jump(96, "Charge")
			TM04 I 4 Fast A_FaceTarget
			TM04 I 3 Fast A_FaceTarget
			TM04 J 3 Fast A_CustomMissile("KFireBall",60,-9,12)
			TM04 J 3 Fast A_CustomMissile("KFireBall",54,-7,8)
			TM04 J 3 Fast A_CustomMissile("KFireBall",48,-5,4)
			TM04 K 3 Fast A_CustomMissile("KFireBall",42,-3,0)
			TM04 K 3 Fast A_CustomMissile("KFireBall",36,-1,-4)
			TM04 K 3 Fast A_CustomMissile("KFireBall",32,0,-8)
			TM04 K 3 Fast A_CustomMissile("KFireBall",32,0,-12)
			TM04 L 5 Fast
		Goto See
		Charge:
			TNT1 A 0 A_PlaySound("dknight/sight")
			TNT1 A 0 A_FaceTarget
			TNT1 A 0 ACS_ExecuteAlways(971, 0, 14) // script sets velocity, ensures no dropoff
			TNT1 A 0 A_ChangeFlag("SKULLFLY", 1)
			TNT1 A 0 ACS_NamedExecuteWithResult("DnD Monster Trait Give", DND_ISBLOCKING, -1, -1, -1)
		ChargeLoop:
			TNT1 A 0 ACS_ExecuteAlways(971, 0, 14)
			TM04 MNOP 3 A_FaceTarget
		Loop
		PainState:
			TNT1 A 0 ACS_NamedExecuteWithResult("DnD Monster Trait Take", DND_ISBLOCKING, -1, -1, -1)
			TM04 Q 3 Fast A_Pain
			TM04 Q 3 Fast
		Goto See
		RaiseState:
			TM04 YXWVUTSR 4
		Goto See
		XDeathState:
		DeathState:
			TM04 R 6 A_Scream
			TM04 ST 5
			TNT1 A 0 A_NoBlocking
			TM04 UVWXY 4
			TM04 Z -1
		Stop
	}
}
       
ACTOR KFireBall {
	Radius 8
	Height 8
	Speed 18
	Damage (random(6, 16))
	DamageType "MagicalFire"
	Stamina 40
	PROJECTILE
	SeeSound "monster/dkball"
	+DONTBLAST
	States {
		Spawn:
			TNT1 A 0 NoDelay ACS_NamedExecuteAlways("DnD Pierce Check")
		SpawnLoop:
			TNT1 A 0 A_CustomMissile("KBallTrail",0,0,-90,0)
			KATK E 2 Bright A_CustomMissile("KBallTrail",0,0,90,0)
		Loop
		Death:
			TNT1 A 0 A_SpawnItemEx("OrangeParticleSpawner", 0, 0, 0, 0, 0, 0, 0, 128)
			TNT1 AAA 0 A_CustomMissile("FireballSmoke", 0, 0, random(0,360), 2, random(0,360))
			KATK HIJ 5 Bright
		Stop
	}
}

ACTOR KBallTrail {
	Radius 1
	Height 1
	Speed 1
	Damage 0
	Scale 1.4
	PROJECTILE
	+CLIENTSIDEONLY
	+NOGRAVITY
	States {
		Spawn:
			KATK FG 14 BRIGHT
		Stop
	}
}

Actor SkullWizard : DnD_BaseHybridMonster {
	Obituary "%o succumbed to a Skull Wizard's magic."
	Health 0x7FFFFFFF
	Radius 21
	Height 64
	Mass 120
	Speed 6
	PainChance 48
	MeleeRange 96
	MeleeDamage 4
	MissileType "SkullWizardProjectile"
	SeeSound "H2SkullWizard/Sight"
	PainSound "H2SkullWizard/Pain"
	DeathSound "H2SkullWizard/Death"
	ActiveSound "H2SkullWizard/Sight"
	MeleeSound "H2SkullWizard/Melee"
	Species "HK"
	Tag "Skull Wizard"
	+ISMONSTER
	+DontHurtSpecies
	+MissileMore
	States {
		SetInfo:
			TNT1 A 0 A_SetArg(4, DND_SKULLWIZARD)
			TNT1 A 0 ACS_NamedExecuteWithResult("DnD Init Monster Data", DND_MWEIGHT_RARE1)
		Goto SpawnSetup

		IdleState:
			SKWZ A 1 A_GiveInventory("DnD_SightChecker", 1)
		Loop
		SeeState:
			SKWZ AAAAAABBBBBBB 4 Fast A_Chase
		Goto See
		MeleeState:
			SKWZ C 6 Fast Bright A_FaceTarget
			TNT1 A 0 A_FaceTarget
			TNT1 A 0 A_CustomMeleeAttack(10, "", "")
			TNT1 A 0 A_CustomMissile("SkullWizardPush", 40)
			SKWZ D 6 Fast Bright A_FaceTarget
		Goto See
		MissileState:
			SKWZ C 0 A_Jump(128, "Teleport")
		Attack:
			SKWZ C 8 Fast A_FaceTarget
			SKWZ D 8 Fast Bright A_FaceTarget
			SKWZ D 8 Fast Bright A_CustomMissile("SkullWizardProjectile", 40, 0, 0)
			SKWZ D 0 Bright A_Jump(80, 2)
			SKWZ D 0 Bright A_SpidReFire
		Loop
			SKWZ D 0
		Goto See
		Teleport:
			SKWZ C 0 A_JumpIfCloser(512, 1)
		Goto See
			SKWZ C 8 Fast A_PlaySoundEx("H2SkullWizard/Teleport", "SoundSlot7", 0)
			SKWZ DEF 8 Fast Bright
			TNT1 A 0 A_Stop
			TNT1 A 0 A_StopSoundEx("SoundSlot7")
			TNT1 A 0 A_SpawnItemEx("SkullWizardTeleport", 0, 0, 0, 0, 0, 0, 0, 128) //Remove the 33 for Doom
			TNT1 A 0 A_ChangeFlag("NoTeleport", 1)
			TNT1 A 0 A_ChangeFlag("NoDropOff", 0)
			TNT1 A 0 A_ChangeFlag(Invulnerable, 1)
			TNT1 A 0 A_UnSetShootable
			TNT1 AAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAA 0 A_Wander
			TNT1 AAA 3 Fast A_Wander
			TNT1 AAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAA 0 A_Wander
			TNT1 AAA 3 Fast A_Wander
			TNT1 AAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAA 0 A_Wander
			TNT1 AAA 3 Fast A_Wander
			TNT1 AAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAA 0 A_Wander
			TNT1 AAA 3 Fast A_Wander
			SKWZ A 0 A_ChangeFlag(Invulnerable, 0)
			SKWZ A 0 A_SetShootable
			TNT1 A 0 A_PlaySound("Wizard/Appear", 7)
			SKWZ A 0 A_SpawnItemEx("SkullWizardTeleport", 0, 0, 0, 0, 0, 0, 0, 128)
			SKWZ A 0 A_ChangeFlag("NoDropOff", 1)
			SKWZ A 0 A_ChangeFlag("NoTeleport", 0)
			SKWZ A 0 A_Jump(128, "Attack")
		Goto See
		PainState:
			SKWZ A 3 Fast
			SKWZ A 3 Fast A_Pain
			SKWZ A 0 A_Jump(96, "Teleport")
		Goto See
		XDeathState:
		DeathState:
			SKWZ G 5 A_Scream
			SKWZ HIJ 5 bright
			SKWZ K 5 bright
			SKWZ LM 5 bright
			SKWZ N 5
			SKWZ O 0 A_NoBlocking
			TNT1 A 0 A_SpawnItem("DissipationEffect")
			SKWZ O 5 Bright
			SKWZ P -1
		Stop
		RaiseState:
			SKWZ ON 5
			SKWZ MLKJIH 5 Bright
			SKWZ G 5
		Goto See
	}
}

Actor SkullWizardPush {
	radius 5
	height 5
	speed 48
	DamageType "Magical"
	Stamina 8
	damage (random(1, 2))
	DeathSound "Wizard/Push"
	PROJECTILE
	+HITTRACER
	+SEEKERMISSILE
	+DONTBLAST
	+THRUGHOST
	States {
		spawn:
			TNT1 A 0 NoDelay ACS_NamedExecuteAlways("DnD Pierce Check")
			TNT1 AA 1 A_SeekerMissile(90, 90, SMF_PRECISE)
			stop
		death:
			TNT1 A 1 ACS_NamedExecuteWithResult("DnD Projectile Push", 20)
			TNT1 A 1
		stop
	}
}

Actor SkullWizardProjectile {
    PROJECTILE
    +SEEKERMISSILE
	+NoDamageThrust
	+DONTBLAST
	Damagetype "MagicalFire"
	Stamina 40
    Speed 16
    Damage (random(3, 7) * 5)
    Radius 6
    Height 8
    RenderStyle Add
    Scale 0.6
    SeeSound "H2SkullWizard/Fire"
    DeathSound "H2SkullWizard/Hit"
    States {
		Spawn:
			TNT1 A 0 NoDelay ACS_NamedExecuteAlways("DnD Pierce Check")
		SpawnLoop:
			IFX1 A 1 Bright A_SpawnItemEx("SkullSpellTrail2",0,0,0,0,random(2,-2),random(2,-2),0,0)
			IFX1 A 1 Bright A_SpawnItemEx("SkullSpellTrail2",0,0,0,0,random(2,-2),random(2,-2),0,0)
			IFX1 B 1 Bright A_SpawnItemEx("SkullSpellTrail2",0,0,0,0,random(2,-2),random(2,-2),0,0)
			IFX1 B 1 Bright A_SpawnItemEx("SkullSpellTrail2",0,0,0,0,random(2,-2),random(2,-2),0,0)
			TNT1 A 0 A_SeekerMissile(1,1)
		Loop
		Death:
			TNT1 A 0 A_SpawnItemEx("OrangeParticleSpawner", 0, 0, 0, 0, 0, 0, 0, 128)
			TNT1 AAA 0 A_SpawnItemEx("ExplosionFX2", 0, 0, 0, frandom(-1, 1), frandom(-1, 1), frandom(-1, 1))
			TNT1 AAA 0 A_CustomMissile("FireballSmoke", 0, 0, random(0,360), 2, random(0,360))
			IFX1 IJKL 4 Bright
		Stop
    }
}

Actor SkullSpellTrail2 {
    PROJECTILE
    +NOCLIP
	+CLIENTSIDEONLY
	+NOINTERACTION
    Speed 0
    RenderStyle Add
    Alpha 0.6
    Scale 1.0
    States {
		Spawn:
			TNT1 A 1
			IFX1 CDEFGH 2 Bright
		Stop
    }
}

Actor SkullWizardTeleport {
	RenderStyle Translucent
	Alpha 0.25
	Height 2
	Radius 2
	+NOGRAVITY
	+CLIENTSIDEONLY
	+NOINTERACTION
	States {
		Spawn:
			SWZT ABCDEFG 1 Bright A_FadeIn(0.045)
			SWZT HIJKLMNOP 1 Bright
			SWZT QRSTUVWXYZ 1 Bright A_FadeOut(0.045)
		Stop
	}
}

Actor CyborgWarrior : DnD_BaseHybridMonster { 
	Health 0x7FFFFFFF
	Radius 24 
	Height 64 
	Mass 1000 
	Speed 9
	Obituary "%o was blown to bits by a Cyborg Warrior."
	HitObituary "%o was smashed by a Cyborg Warrior."
	+ISMONSTER
	+MissileMore
	+NOBLOOD
	+NOPAIN
	+DONTRIP
	Species "HK"
	+DONTHURTSPECIES
	+DONTHARMSPECIES
	SeeSound "CyborgWarrior/See" 
	DeathSound "CyborgWarrior/Die"
	Tag "Cyborg Warrior"
	States  { 
		SetInfo:
			TNT1 A 0 A_SetArg(4, DND_CYBORGWARRIOR)
			TNT1 A 0 ACS_NamedExecuteWithResult("DnD Init Monster Data", DND_MWEIGHT_RARE2)
		Goto SpawnSetup

		IdleState:
			QQMN AB 10 A_GiveInventory("DnD_SightChecker", 1) 
		Loop 
		SeeState:
			QQMN A 1 Fast
			QQMN A 2 Fast A_Chase
			QQMN A 3 Fast A_Chase
			QQMN BB 3 Fast A_Chase
			QQMN C 1 Fast
			QQMN C 2 Fast A_Chase
			QQMN C 3 Fast A_Chase 
			QQMN DD 3 Fast A_Chase
		Goto See 
		MissileState:
			TNT1 A 0 A_Jump(96, "Missile2")
			QQMN E 8 Fast A_FaceTarget 
			QQMN O 4 Fast Bright A_CustomMissile("CyborgPlasma1",38,15,0,0)
			QQMN E 4 Fast A_FaceTarget
			QQMN O 4 Fast Bright A_CustomMissile("CyborgPlasma1",38,15,0,0)
			QQMN E 4 Fast A_FaceTarget
			QQMN O 4 Fast Bright A_CustomMissile("CyborgPlasma1",38,15,0,0)
		Goto See
		Missile2:
			QQMN E 8 Fast A_FaceTarget 
			QQMN F 6 Fast Bright A_CustomMissile("CyborgPlasma2",38,15,0,0)
			QQMN E 5 Fast A_FaceTarget
		Goto See
		MeleeState:
			TNT1 A 0 A_PlaySound("CyborgWarrior/Attack")
			QQMN GH 8 Fast A_FaceTarget
			QQMN I 8 Fast A_CustomMeleeAttack(40, "weapons/vblhit", "")
			QQMN A 2 Fast
		Goto See 
		XDeathState:
			TNT1 A 0 A_SpawnItemEx("GenericGibber_Medium", 0, 0, 0, 0, 0, 0, 0, SXF_USEBLOODCOLOR)
		DeathState: 
			QQMN J 6 A_Scream
			TNT1 A 0 A_NoBlocking
			QQMN KL 5
			QQMN M 4
			QQMN N -1
		Stop 
		RaiseState:
			QQMN MLKJ 6
		Goto See
	} 
}

Actor CyborgPlasma1 {
	PROJECTILE
	Translation "0:255=%[0.00,0.00,0.00]:[1.07,2.00,1.96]"
	Height 8
	Radius 4
	Renderstyle Add
	Alpha 0.875
	Damage (4 * random(1, 8))
	DamageType "EnergyCyan"
	Stamina 16
	Speed 30
	+FORCEXYBILLBOARD
	+DONTBLAST
    SeeSound "CyborgWarrior/Plasma1"
    DeathSound "weapons/firex5"
	States {
		Spawn: 
			TNT1 A 0 NoDelay ACS_NamedExecuteAlways("DnD Pierce Check")
			BMIS A -1 Bright 
		Stop
		Death:
			TNT1 AAA 0 A_CustomMissile("FireballSmoke", 0, 0, random(0,360), 2, random(0,360))
			TNT1 A 0 A_SpawnItemEx("BlueParticleSpawner", 0, 0, 0, 0, 0, 0, 0, 128)
			IMFX QRSTUVW 3 Bright
		stop
	}
}

Actor CyborgPlasma2 {
	Radius 8
	Height 10
	Speed 24
	Damage (5 * random(5, 8))
	DamageType "EnergyVoid"
	Stamina 16
	Scale 1.0
	Alpha 0.9
	RENDERSTYLE Add
	SEESOUND "HFSpid/See" 
	DEATHSOUND "HFSpid/Die"
	PROJECTILE
	Decal PlasmaScorchLower
	Scale 0.825
	+SEEKERMISSILE
	+DONTBLAST
	States {
		Spawn:
			TNT1 A 0 NoDelay ACS_NamedExecuteAlways("DnD Pierce Check")
		SpawnLoop:
			ESPJ A 1 Bright
			TNT1 A 0 A_SpawnItem("CyborgPlasma2Trail", 0, 0)
			ESPJ A 1 Bright A_SeekerMissile(4, 4, SMF_CURSPEED)
			TNT1 A 0 A_SpawnItem("CyborgPlasma2Trail", 0, 0)
			ESPJ B 1 Bright
			TNT1 A 0 A_SpawnItem("CyborgPlasma2Trail", 0, 0)
			ESPJ B 1 Bright A_SeekerMissile(4, 4, SMF_CURSPEED)
			TNT1 A 0 A_SpawnItem("CyborgPlasma2Trail", 0, 0)
		Loop
		Death:
			TNT1 A 0 A_SpawnItemEx("PurpleParticleSpawner", 0, 0, 0, 0, 0, 0, 0, 128)
			TNT1 AAA 0 A_SpawnItemEx("ExplosionFX3", 0, 0, 0, frandom(-1, 1), frandom(-1, 1), frandom(-1, 1))
			TNT1 AAA 0 A_CustomMissile("FireballSmoke", 0, 0, random(0,360), 2, random(0,360))
			TNT1 A 0 A_SpawnItem("HellForgeSpiderExp")
			ESPJ CDEFGHI 2 Bright
		Stop
	}
}

Actor CyborgPlasma2Trail {
	+CLIENTSIDEONLY
	+NOGRAVITY
	+NOINTERACTION
	Renderstyle Add
	Alpha 0.75
	Scale 0.75
	States {
		Spawn:
			TNT1 A 1
		SpawnLoop:
			ESPJ AABB 1 Bright A_FadeOut(0.15)
		Loop
	}
}

ACTOR ChaosSerpent : DnD_BaseHybridMonster {
	Health 0x7FFFFFFF
	GibHealth -100
	PainChance 64
	Speed 12
	Radius 24
	Height 64
	Mass 640
	Species "HK"
	+DONTHURTSPECIES
	SeeSound "ChaosSerpent/See"
	AttackSound "ChaosSerpent/Melee"
	PAINSOUND "Beast/pain"
	DeathSound "ChaosSerpent/Die"
	ActiveSound "ChaosSerpent/See"
	Obituary "%o was destroyed by a Chaos Serpent."
	const int ChunkFlags = SXF_TRANSFERTRANSLATION|SXF_ABSOLUTEVELOCITY;
	Tag "Chaos Serpent"
	+ISMONSTER
	States {
		SetInfo:
			TNT1 A 0 A_SetArg(4, DND_CHAOSSERPENT)
			TNT1 A 0 ACS_NamedExecuteWithResult("DnD Init Monster Data", DND_MWEIGHT_RARE2)
		Goto SpawnSetup
	
		IdleState:
			DEMN AA 10 A_GiveInventory("DnD_SightChecker", 1)
		Loop
		SeeState:
			DEMN ABCD 4 Fast A_Chase
		Goto See
		PainState:
			DEMN E 4 Fast
			DEMN E 4 Fast A_Pain
		Goto See
		MeleeState:
			DEMN E 6 Fast A_FaceTarget
			DEMN F 8 Fast A_FaceTarget
			DEMN G 6 Fast A_CustomMeleeAttack(random[DemonAttack1](8, 16) * 2)
		Goto See
		MissileState:
			TNT1 A 0 A_Jump(128, "Belch")
			DEMN E 5 Fast A_FaceTarget
			DEMN F 6 Fast A_FaceTarget
			DEMN G 5 Fast A_CustomMissile("ChaosSerpentFireball", 62, 0)
		Goto See
		Belch:
			DEMN GG 5 Fast A_FaceTarget
			DEMN F 7 Fast A_FaceTarget
			DEMN E 5 Fast A_FaceTarget
			TNT1 A 0 A_FaceTarget
			DEMN GGG 2 Fast A_CustomMissile("ChaosSerpentFireball", 62, 0, frandom(-4.8, 4.8), CMF_AIMDIRECTION, frandom(-3.2, 0))
			DEMN GGG 2 Fast A_CustomMissile("ChaosSerpentFireball", 62, 0, frandom(-4.8, 4.8), 0, frandom(-3.2, 0))
		Goto See
		XDeathState:
			TNT1 A 0 A_SpawnItemEx("GenericGibber_Medium", 0, 0, 0, 0, 0, 0, 0, SXF_USEBLOODCOLOR)
		DeathState:
			DEMN H 6
			DEMN I 0 A_SpawnItemEx("Demon1Chunk1C", 0, 0, 45, frandom[DemonChunks](1, 4.984375)*cos(angle+90),
					   frandom[DemonChunks](1, 4.984375)*sin(angle+90), 8, 90, ChunkFlags)
			DEMN I 0 A_SpawnItemEx("Demon1Chunk2C", 0, 0, 45, frandom[DemonChunks](1, 4.984375)*cos(angle-90),
					   frandom[DemonChunks](1, 4.984375)*sin(angle-90), 8, 270, ChunkFlags)
			DEMN I 0 A_SpawnItemEx("Demon1Chunk3C", 0, 0, 45, frandom[DemonChunks](1, 4.984375)*cos(angle-90),
					   frandom[DemonChunks](1, 4.984375)*sin(angle-90), 8, 270, ChunkFlags)
			DEMN I 0 A_SpawnItemEx("Demon1Chunk4C", 0, 0, 45, frandom[DemonChunks](1, 4.984375)*cos(angle-90),
					   frandom[DemonChunks](1, 4.984375)*sin(angle-90), 8, 270, ChunkFlags)
			DEMN I 6 A_SpawnItemEx("Demon1Chunk5C", 0, 0, 45, frandom[DemonChunks](1, 4.984375)*cos(angle-90),
					   frandom[DemonChunks](1, 4.984375)*sin(angle-90), 8, 270, ChunkFlags)
			DEMN J 1
			DEMN J 5 A_Scream
			DEMN K 6 A_NoBlocking
			DEMN L 6 A_QueueCorpse
			DEMN MNO 6
			DEMN P -1
		Stop
		RaiseState:
			DEMN PONMLKJIH 5
		Goto See
	}
}

Actor ChaosSerpentFireball {
	Radius 6
	Height 8
	Speed 24
	PROJECTILE
	Damage (5 * random(4, 8))
	DamageType "Fire"
	Stamina 32
	SeeSound "Beast/Attack"
	DeathSound "weapons/phoenixhit"
	+DONTBLAST
	States {
		Spawn:
			TNT1 A 0 NoDelay ACS_NamedExecuteAlways("DnD Pierce Check")
		SpawnLoop:
			FX14 ABC 4 Bright
		Loop
		Death:
			TNT1 A 0 A_SpawnItemEx("OrangeParticleSpawner", 0, 0, 0, 0, 0, 0, 0, 128)
			TNT1 AAA 0 A_SpawnItemEx("ExplosionFX2", 0, 0, 0, frandom(-1, 1), frandom(-1, 1), frandom(-1, 1))
			TNT1 AAA 0 A_CustomMissile("FireballSmoke", 0, 0, random(0,360), 2, random(0,360))
			FX14 DE 6 Bright
			FX14 FGH 4 Bright
		Stop
	}
}

Actor Demon1Chunk1C : Demon1Chunk1 {
	+CLIENTSIDEONLY
	+MOVEWITHSECTOR
}

Actor Demon1Chunk2C : Demon1Chunk2 {
	+CLIENTSIDEONLY
	+MOVEWITHSECTOR
}

Actor Demon1Chunk3C : Demon1Chunk3 {
	+CLIENTSIDEONLY
	+MOVEWITHSECTOR
}
Actor Demon1Chunk4C : Demon1Chunk4 {
	+CLIENTSIDEONLY
	+MOVEWITHSECTOR
}

Actor Demon1Chunk5C : Demon1Chunk5 {
	+CLIENTSIDEONLY
	+MOVEWITHSECTOR
}

Actor MoonSatyr : DnD_BaseHybridMonster {
    Health 0x7FFFFFFF
	GibHealth -100
    Radius 24
    Height 64
    Scale 1.1
    PainChance 64
	Speed 8
	Mass 640
    HitObituary "%o was mauled by a moon satyr."
	Obituary "%o didn't notice the sky crashing on him, thanks to a moon satyr."
	Translation "0:255=%[0.00,0.00,0.00]:[1.12,1.20,1.57]", "3:8=3:8", "16:47=16:47", "80:111=80:111", "168:191=168:191"
	+ISMONSTER
	+NODAMAGETHRUST
	Species "HK"
	+DONTHARMSPECIES
	+DONTMORPH
	Tag "Moon Satyr"
	MaxTargetRange 512
    SeeSound "Satyr/See"
    PainSound "Satyr/Hit"
    DeathSound "Satyr/Die"
    ActiveSound "Satyr/Act"
    MeleeSound "baron/melee"
    States {
		SetInfo:
			TNT1 A 0 A_SetArg(4, DND_MOONSATYR)
			TNT1 A 0 ACS_NamedExecuteWithResult("DnD Init Monster Data", DND_MWEIGHT_RARE2)
		Goto SpawnSetup
	
		IdleState:
			STYR AB 10 A_GiveInventory("DnD_SightChecker", 1)
		Loop
		SeeState:
			STYR AABBCCDD 3 Fast A_Chase
		Goto See
		MeleeState:
			STYR E 2 Fast A_FaceTarget
			TNT1 A 0 A_Recoil(-1.6)
			STYR E 3 Fast A_FaceTarget
			TNT1 A 0 A_Recoil(-2.0)
			STYR F 2 Fast A_FaceTarget
			TNT1 A 0 A_Recoil(-2.4)
			STYR F 3 Fast A_FaceTarget
			TNT1 A 0 A_Recoil(-2.8)
			STYR G 5 Fast A_CustomMeleeAttack(random(26, 46), "baron/melee")
			TNT1 A 0 A_Stop
			STYR P 2 Fast A_FaceTarget
			TNT1 A 0 A_Recoil(-1.6)
			STYR P 3 Fast A_FaceTarget
			TNT1 A 0 A_Recoil(-2.0)
			STYR Q 2 Fast A_FaceTarget
			TNT1 A 0 A_Recoil(-2.4)
			STYR Q 3 Fast A_FaceTarget
			TNT1 A 0 A_Recoil(-2.8)
			STYR R 5 Fast A_CustomMeleeAttack(random(26, 46), "baron/melee")
		Goto See
		MissileState:
			TNT1 A 0 A_Jump(128, "Other")
			STYR EF 4 Fast A_FaceTarget
			STYR G 5 Fast A_CustomBulletAttack(0, 0, 1, 0, "MoonSatyrMeteorSpawner")
			STYR GGGGGGGGG 4 Fast A_FaceTarget
		Goto See
		Other:
			STYR PQ 4 Fast A_FaceTarget
			STYR R 5 Fast A_CustomBulletAttack(0, 0, 1, 0, "MoonSatyrMeteorSpawner")
			STYR RRRRRRRRR 4 Fast A_FaceTarget
		Goto See
		PainState:
			STYR H 3 Fast
			STYR H 3 Fast A_Pain
		Goto See
		XDeathState:
			TNT1 A 0 A_SpawnItemEx("GenericGibber_Medium", 0, 0, 0, 0, 0, 0, 0, SXF_USEBLOODCOLOR)
		DeathState:
			STYR I 5
			STYR J 5 A_Scream
			STYR K 6
			STYR L 7 A_Fall
			STYR M 4
			STYR N 4
			STYR O -1
		Stop
		RaiseState:
			STYR ONMLKJI 8
		Goto See
    }
}

Actor MoonSatyrMeteorMarker {
	+NOINTERACTION
	+CLIENTSIDEONLY
	Renderstyle Add
	Alpha 0.8
	Scale 1.15
	States {
		Spawn:
			CJFX ABCDEFGHIJK 3
		Stop
	}
}

Actor MoonSatyrMeteorMarkerSpawner {
	+NOINTERACTION
	+CLIENTSIDEONLY
	States {
		Spawn:
			TNT1 A 0
			TNT1 A 0 A_PlaySound("MoonSatyr/MoonFall")
			TNT1 AAA 7 A_SpawnItemEx("MoonSatyrMeteorMarker", 0, 0, 0, 0, 0, 0, 0, SXF_NOCHECKPOSITION)
			TNT1 A 0 A_PlaySound("MoonSatyr/MoonFall")
			TNT1 AAAA 7 A_SpawnItemEx("MoonSatyrMeteorMarker", 0, 0, 0, 0, 0, 0, 0, SXF_NOCHECKPOSITION)
		Stop
	}
}

Actor MoonSatyrMeteorSpawner : BulletPuff {
	Renderstyle None
	VSpeed 0
	Speed 0
	+DONTBLAST
	+ALWAYSPUFF
	+PUFFONACTORS
	+PUFFGETSOWNER
	+BLOODLESSIMPACT
	+MISSILE
	States {
		Spawn:
			TNT1 A 0
			TNT1 A 70 A_SpawnItem("MoonSatyrMeteorMarkerSpawner", 0, -z + floorz)
			TNT1 A 1 A_CustomMissile("MoonSatyrMeteor", ceilingz - z - 32, 0, 0, CMF_TRACKOWNER)
		Stop
	}
}

Actor MoonSatyrMeteorExplosion : BaseExplosionDamage {
	DamageType "Magical"
	Stamina 8
	States {
		Spawn:
			TNT1 A 0 NoDelay ACS_NamedExecuteAlways("DnD Pierce Check")
			TNT1 A 1 A_Explode(128, 160, 0, 0, 72)
		Stop
	}
}

Actor MoonSatyrMeteor {
	PROJECTILE
	Height 8
	Radius 4
	Damage (50)
	DamageType "Magical"
	Stamina 8
	+NODAMAGETHRUST
	Deathsound "MoonSatyr/MeteorExplode"
	Scale 1.75
	Speed 0
	States {
		Spawn:
			TNT1 A 0 NoDelay ACS_NamedExecuteAlways("DnD Pierce Check")
		SpawnLoop:
			MSX0 AAABBBCCC 1 Bright ThrustThingZ(0, 90, 1, 0)
		Loop
		Death:
			TNT1 A 0 A_SpawnItem("MoonSatyrMeteorExplosion")
			TNT1 AAAAA 0 A_CustomMissile("RocketSmoke", 0, 0, random(0, 360), 2, random(0, 180))
			TNT1 AAAAAAAA 0 A_CustomMissile("RocketSmoke", 0, 0, random(0, 360), 2, random(0, 360))
			TNT1 AAAAAAAAAAAAAAAA 0 A_SpawnItemEx("BlueParticleNoGravityFastVanish",Random(-12,12),Random(-12,12),Random(-12,12),Random(-6,6),Random(-6,6),Random(-6,6),Random(-20,20),128)
			TNT1 A 0 A_SetTranslucent(1,1)
			MSX0 DEFGHI 2 Bright
		Stop
	}
}

Actor IceGolem : DnD_BaseHybridMonster { 
    Health 0x7FFFFFFF
    Speed 6
	Scale 1.2
    Height 64
    Radius 24
    Mass 4096
    PainChance 48
    SeeSound "EarthGolem/See"
    PainSound "EarthGolem/Pain"
    DeathSound "EarthGolem/Death"
    ActiveSound "EarthGolem/Act"
    Obituary "%o wass destroyed by a Crystal Golem." 
	+ISMONSTER
	Species "HK"
	Tag "Crystal Golem"
	MeleeRange 76
	MaxTargetRange 640
	RenderStyle Add
	Alpha 0.525
	+DONTHURTSPECIES
	+DONTRIP
	+NOBLOOD
	+NODROPOFF
    States { 
		SetInfo:
			TNT1 A 0 ACS_NamedExecuteAlways("DnD Translucency Weave")
			TNT1 A 0 ACS_NamedExecuteAlways("DnD Monster Health Regen Script", 0, DND_MHR_PERIODIC, ACS_NamedExecuteWithResult("DnD Monster Heal Potency", 3), 2)
			TNT1 A 0 A_SetArg(4, DND_ICEGOLEM)
			TNT1 A 0 ACS_NamedExecuteWithResult("DnD Init Monster Data", DND_MWEIGHT_VERYRARE)
		Goto SpawnSetup
			
		IdleState:
		   GOL3 AB 10 A_GiveInventory("DnD_SightChecker", 1)
	    Loop 
		SeeState:
			TNT1 A 0 A_TakeInventory("MonsterRegenPause", 1)
			GOL3 AABBCCDD 2 Fast A_Chase
	    Goto See 
		MeleeState:
			TNT1 A 0 A_GiveInventory("MonsterRegenPause", 1)
			TNT1 A 0 A_PlaySound("Golem/Swing")
			TNT1 A 0 A_Jump(128, "OtherMelee")
			GOL3 E 6 Fast A_FaceTarget
			GOL3 F 3 Fast A_FaceTarget
			TNT1 A 0 A_CustomMeleeAttack(6 * random(6, 10), "Golem/Hit")
			GOL3 FG 5 Fast 
		Goto See
		OtherMelee:
			GOL3 H 6 Fast A_FaceTarget
			GOL3 I 3 Fast A_FaceTarget
			TNT1 A 0 A_CustomMeleeAttack(6 * random(6, 10), "Golem/Hit")
			GOL3 IJ 5 Fast 
		Goto See
		MissileState:
			TNT1 A 0 A_GiveInventory("MonsterRegenPause", 1)
			TNT1 A 0 A_JumpIf(160, "Dash")
		Spikes:
			TNT1 A 0 A_FaceTarget
			GOL3 K 2 Fast A_CustomMissile("CrystalSpike", 44 + random(-6, 10), random(-6, 6), frandom(-8, 8), CMF_OFFSETPITCH, frandom(-2.4, 2.4))
			GOL3 K 0 A_MonsterRefire(160, "See")
		Loop
		Dash:
			TNT1 A 0 A_JumpIfCloser(320, "ContinueDash")
		Goto Spikes
		ContinueDash:
			GOL3 G 1 A_FaceTarget
			TNT1 A 0 A_PlaySound("Golem/Slide")
			TNT1 A 0 ACS_ExecuteAlways(971, 0, 27) // script sets velocity
			GOL3 G 3 A_JumpIfTargetInLos("DashFinish", 90, JLOSF_DEADNOJUMP, 80)
			TNT1 A 0 A_SpawnItemEx("GrenadeSmoke", -8, -12, 0, 0, -2.5, 1)
			TNT1 A 0 A_SpawnItemEx("GrenadeSmoke", -8, 12, 0, 0, 2.5, 1)
			GOL3 G 3 A_JumpIfTargetInLos("DashFinish", 90, JLOSF_DEADNOJUMP, 80)
			TNT1 A 0 A_SpawnItemEx("GrenadeSmoke", -8, -12, 0, 0, -2.5, 1)
			TNT1 A 0 A_SpawnItemEx("GrenadeSmoke", -8, 12, 0, 0, 2.5, 1)
			GOL3 G 3 A_JumpIfTargetInLos("DashFinish", 90, JLOSF_DEADNOJUMP, 80)
			TNT1 A 0 A_SpawnItemEx("GrenadeSmoke", -8, -12, 0, 0, -2.5, 1)
			TNT1 A 0 A_SpawnItemEx("GrenadeSmoke", -8, 12, 0, 0, 2.5, 1)
			TNT1 A 0 A_JumpIf(velx == 0 || vely == 0, "See")
			GOL3 G 3 A_JumpIfTargetInLos("DashFinish", 90, JLOSF_DEADNOJUMP, 80)
			TNT1 A 0 A_SpawnItemEx("GrenadeSmoke", -8, -12, 0, 0, -2.5, 1)
			TNT1 A 0 A_SpawnItemEx("GrenadeSmoke", -8, 12, 0, 0, 2.5, 1)
			GOL3 G 3 A_JumpIfTargetInLos("DashFinish", 90, JLOSF_DEADNOJUMP, 80)
			TNT1 A 0 A_SpawnItemEx("GrenadeSmoke", -8, -12, 0, 0, -2.5, 1)
			TNT1 A 0 A_SpawnItemEx("GrenadeSmoke", -8, 12, 0, 0, 2.5, 1)
			GOL3 G 3 A_JumpIfTargetInLos("DashFinish", 90, JLOSF_DEADNOJUMP, 80)
			TNT1 A 0 A_SpawnItemEx("GrenadeSmoke", -8, -12, 0, 0, -2.5, 1)
			TNT1 A 0 A_SpawnItemEx("GrenadeSmoke", -8, 12, 0, 0, 2.5, 1)
			GOL3 G 3 A_JumpIfTargetInLos("DashFinish", 90, JLOSF_DEADNOJUMP, 80)
			GOL3 G 0 A_SpawnItemEx("GrenadeSmoke", -8, -12, 0, 0, -2.5, 1)
			GOL3 G 0 A_SpawnItemEx("GrenadeSmoke", -8, 12, 0, 0, 2.5, 1)
		Goto See
		DashFinish:
			GOL3 F 3 Fast A_FaceTarget
			TNT1 A 0 A_CustomMeleeAttack(6 * random(6, 10), "Golem/Hit")
			GOL3 F 3 Fast A_FaceTarget
			TNT1 A 0 A_CustomMissile("CrystalGolemBash")
			GOL3 E 5 Fast
			GOL3 E 1 Fast A_Jump(128, "Spikes")
		Goto See
		PainState:
			TNT1 A 0 A_GiveInventory("MonsterRegenPause", 1)
			GOL3 L 5 Fast A_Stop
			TNT1 AAAA 0 A_SpawnItemEx("WhiteParticleSpawner", 0, 0, 32, 0, 0, 0, 0, 128)
			GOL3 L 5 Fast A_Pain
		Goto See
		XDeathState:
		DeathState: 
			GOL3 L 1 A_NoBlocking
			TNT1 AAAAA 0 A_SpawnItemEx("WhiteParticleSpawner", 0, 0, 32, 0, 0, 0, 0, 128)
			TNT1 AAAAAAAAAAA 0 A_CustomMissile("ExplosionFX10", 32, random(-16, 16), random(0,360), 2, random(0,360))
			TNT1 A 0 A_SpawnItem("IceBurst")
			TNT1 A 0 A_PlaySound("IceGuyShatter")
			TNT1 A 0 A_SpawnDebris("IceChunkDebris")
			TNT1 A -1
		   Stop
		RaiseState: 
			TNT1 A 0 A_ChangeFlag("NOPAIN", 1)
			TNT1 A 0 ACS_NamedExecuteAlways("DnD Monster Health Regen Script", 0, DND_MHR_PERIODIC, ACS_NamedExecuteWithResult("DnD Monster Heal Potency", 3), 2)
			GOL3 L 1 A_SetScale(0.05, 0.05)
			GOL3 L 1 A_SetScale(0.1, 0.1)
			GOL3 L 1 A_SetScale(0.15, 0.15)
			GOL3 L 1 A_SetScale(0.2, 0.2)
			GOL3 L 1 A_SetScale(0.25, 0.25)
			GOL3 L 1 A_SetScale(0.3, 0.3)
			GOL3 L 1 A_SetScale(0.35, 0.35)
			GOL3 L 1 A_SetScale(0.4, 0.4)
			GOL3 L 1 A_SetScale(0.45, 0.45)
			GOL3 L 1 A_SetScale(0.5, 0.5)
			GOL3 L 1 A_SetScale(0.55, 0.55)
			GOL3 L 1 A_SetScale(0.6, 0.6)
			GOL3 L 1 A_SetScale(0.65, 0.65)
			GOL3 L 1 A_SetScale(0.7, 0.7)
			GOL3 L 1 A_SetScale(0.75, 0.75)
			GOL3 L 1 A_SetScale(0.8, 0.8)
			GOL3 L 1 A_SetScale(0.85, 0.85)
			GOL3 L 1 A_SetScale(0.9, 0.9)
			GOL3 L 1 A_SetScale(0.95, 0.95)
			GOL3 L 1 A_SetScale(1.0, 1.0)
			TNT1 A 0 A_ChangeFlag("NOPAIN", 0)
		Goto See
    } 
}

Actor IceGolemAlphaWeaver : DnD_Activator {
	States {
		Pickup:
			TNT1 A 0 ACS_NamedExecuteAlways("DnD Translucency Weave")
		Stop
	}
}

Actor CrystalSpike {
	PROJECTILE
	+THRUGHOST
	+DONTBLAST
	Speed 24
	Damage (random(6, 10))
	DamageType "Ice"
	Stamina 64
	Radius 6
	Height 10
	Alpha 0.8
	RenderStyle Add
	SeeSound "Armors/NecroShard"
	DeathSound "Armors/NecroShardHit"
	States {
		Spawn:
			TNT1 A 0 NoDelay ACS_NamedExecuteAlways("DnD Pierce Check")
		SpawnLoop:
			GOL3 S 1 A_Weave(1.0, 0.5, 3.0, 1.5)
		Loop
		Death:
			TNT1 AAA 0 A_CustomMissile("FireballSmoke", 0, 0, random(0,360), 2, random(0,360))
			GOL3 MNOPQR 3
		Stop
	}
}

Actor CrystalGolemBash {
	radius 5
	height 5
	speed 38
	DamageType "Physical"
	Stamina 1
	damage (15 * random(1, 2))
	deathsound "weapons/vblhit"
	PROJECTILE
	+HITTRACER
	+SEEKERMISSILE
	+DONTBLAST
	States {
		spawn:
			TNT1 A 0 NoDelay ACS_NamedExecuteAlways("DnD Pierce Check")
		SpawnLoop:
			TNT1 AA 1 A_SeekerMissile(90, 90, SMF_PRECISE)
			stop
		death:
			TNT1 A 0 A_Quake(4, 17, 0, 256)
			TNT1 A 1 ACS_NamedExecuteWithResult("DnD Projectile Push", 24)
			TNT1 A 1
		stop
	}
}

Actor Gladiator : DnD_BaseHybridMonster {
	Health 0x7FFFFFFF
	GibHealth -100
	Radius 24
	Height 64
	Speed 11
	PainChance 64
	Mass 1000
	SeeSound "Gladiator/See"
	ActiveSound "Gladiator/Act"
	PainSound "Gladiator/Pain"
	DeathSound "Gladiator/Die"
	Obituary "%o didn't expect trickery from a Gladiator."
	HitObituary "%o lost the fight against a Gladiator."
	+ISMONSTER
	Tag "Gladiator"
	Species "HK"
	+DONTHURTSPECIES  
	States {
		SetInfo:
			TNT1 A 0 A_SetArg(4, DND_GLADIATOR)
			TNT1 A 0 ACS_NamedExecuteWithResult("DnD Init Monster Data", DND_MWEIGHT_VERYRARE)
		Goto SpawnSetup

		IdleState:
			GLAD AB 10 A_GiveInventory("DnD_SightChecker", 1)
		Loop
		SeeState:
			TNT1 A 0 A_JumpIfCloser(288, "FastSee")
			GLAD AABBCCDD 4 Fast A_Chase
		Goto See
		FastSee:
			GLAD AABBCCDD 3 Fast A_Chase
		Goto See
		MissileState:
			TNT1 A 0 A_JumpIfCloser(288, "FastMissile")
			GLAD EF 8 Fast A_FaceTarget
			TNT1 A 0 A_PlaySound("Gladiator/Attack")
			GLAD G 8 Fast A_CustomComboAttack("GladiatorFireBall_Explode", 32, 9 * random(4, 6), "baron/melee")
		Goto See
		FastMissile:
			GLAD EF 6 Fast A_FaceTarget
			TNT1 A 0 A_PlaySound("Gladiator/Attack")
			GLAD G 1 Fast A_SetAngle(angle + frandom(-12.0, 12.0))
			GLAD G 5 Fast A_CustomComboAttack("GladiatorFireBall_Explode", 32, 10 * random(5, 8), "baron/melee")
		Goto See
		MeleeState:
			TNT1 A 0 A_PlaySound("Gladiator/Attack")
			GLAD E 2 Fast A_FaceTarget
			TNT1 A 0 A_Recoil(-1.6)
			GLAD E 3 Fast A_FaceTarget
			TNT1 A 0 A_Recoil(-2.0)
			GLAD F 2 Fast A_FaceTarget
			TNT1 A 0 A_Recoil(-2.4)
			GLAD F 3 Fast A_FaceTarget
			TNT1 A 0 A_Recoil(-2.8)
			GLAD G 5 Fast A_CustomComboAttack("GladiatorFireBall", 32, 10 * random(5, 8), "baron/melee")
		Goto See
		PainState:
			GLAD H 2 Fast
			GLAD H 2 Fast A_Pain
		Goto See
		XDeathState:
			TNT1 A 0 A_SpawnItemEx("GenericGibber_Medium", 0, 0, 0, 0, 0, 0, 0, SXF_USEBLOODCOLOR)
		DeathState:
			GLAD I 6 A_Scream
			TNT1 A 0 A_FaceTarget
			GLAD J 5 
			GLAD K 4
			GLAD L 3 A_Fall
			GLAD MN 3
			GLAD O -1
		Stop
		RaiseState:
			GLAD NMLKJI 4
		Goto See
	}
}

Actor GladiatorFireBall {
	Radius 5
	Height 10
	Speed 24
	PROJECTILE
	Damage (5 * random(4, 6))
	DamageType "Fire"
	Stamina 32
	DeathSound "weapons/phoenixhit"
	Scale 0.85
	+DONTBLAST
	States {
		Spawn:
			TNT1 A 0 NoDelay ACS_NamedExecuteAlways("DnD Pierce Check")
		SpawnLoop:
			FX14 ABC 4 Bright
		Loop
		Death:
			TNT1 A 0 A_SpawnItemEx("OrangeParticleSpawner", 0, 0, 0, 0, 0, 0, 0, 128)
			TNT1 AAA 0 A_SpawnItemEx("ExplosionFX2", 0, 0, 0, frandom(-1, 1), frandom(-1, 1), frandom(-1, 1))
			TNT1 AAA 0 A_CustomMissile("FireballSmoke", 0, 0, random(0,360), 2, random(0,360))
			FX14 DE 6 Bright
			FX14 FGH 4 Bright
		Stop
	}
}

Actor GladiatorFireBall_Explode : GladiatorFireBall {
	States {
		Spawn:
			TNT1 A 0 NoDelay ACS_NamedExecuteAlways("DnD Pierce Check")
		SpawnLoop:
			TNT1 AA 0 A_SpawnItemEx("GladiatorExplosionFX", 0, 0, 0, frandom(-3, 3), frandom(-3, 3), frandom(-3, 3))
			FX14 A 2 Bright A_SpawnItem("GladiatorExp")
			TNT1 AA 0 A_SpawnItemEx("GladiatorExplosionFX", 0, 0, 0, frandom(-3, 3), frandom(-3, 3), frandom(-3, 3))
			FX14 A 2 Bright A_SpawnItem("GladiatorExp")
			TNT1 AA 0 A_SpawnItemEx("GladiatorExplosionFX", 0, 0, 0, frandom(-3, 3), frandom(-3, 3), frandom(-3, 3))
			FX14 B 2 Bright A_SpawnItem("GladiatorExp")
			TNT1 AA 0 A_SpawnItemEx("GladiatorExplosionFX", 0, 0, 0, frandom(-3, 3), frandom(-3, 3), frandom(-3, 3))
			FX14 B 2 Bright A_SpawnItem("GladiatorExp")
			TNT1 AA 0 A_SpawnItemEx("GladiatorExplosionFX", 0, 0, 0, frandom(-3, 3), frandom(-3, 3), frandom(-3, 3))
			FX14 C 2 Bright A_SpawnItem("GladiatorExp")
			TNT1 AA 0 A_SpawnItemEx("GladiatorExplosionFX", 0, 0, 0, frandom(-3, 3), frandom(-3, 3), frandom(-3, 3))
			FX14 C 2 Bright A_SpawnItem("GladiatorExp")
		Loop
	}
}

Actor GladiatorExplosionFX {
	Scale 0.65
	Renderstyle Add
	Alpha 0.85
	+CLIENTSIDEONLY
	+NOINTERACTION
	States {
		Spawn:
			FX14 DE 4 Bright
			FX14 FGH 2 Bright
		Stop
	}
}

Actor GladiatorExp : BaseExplosionDamage {
	DamageType "Fire"
	Stamina 32
	Obituary "%o didn't expect trickery from a Gladiator."
	States {
		Spawn:
			TNT1 A 0 NoDelay ACS_NamedExecuteAlways("DnD Pierce Check")
			TNT1 A 1 A_Explode(12, 56, 0)
		Stop
	}
}

Actor Putrefier : DnD_BaseHybridMonster {
	Health 0x7FFFFFFF
	PainChance 84
	Speed 8
	Radius 24
	Height 64
	Mass 768
	Species "HK"
	MaxDropOffHeight 32
	MinMissileChance 200
	SeeSound "Putrefier/sight"
	PainSound "Putrefier/pain"
	DeathSound "Putrefier/death"
	ActiveSound "Putrefier/active"
	HitObituary "%o was clawed by a Putrefier."
	Obituary "%o was vaporized by a Putrefier."
	Renderstyle Translucent
	+ISMONSTER
	+NOBLOOD
	+NOINFIGHTING
	+DONTHARMSPECIES
	States {
		SetInfo:
			TNT1 A 0 A_SetArg(4, DND_Putrefier)
			TNT1 A 0 ACS_NamedExecuteWithResult("DnD Init Monster Data", DND_MWEIGHT_VERYRARE)
		Goto SpawnSetup
	
		IdleState:
			TNT1 A 0 A_SetTranslucent(1.0, 0)
		IdleLoop:
			9TRF A 7 A_GiveInventory("DnD_SightChecker", 1)
		Loop
		SeeState:
			TNT1 A 0 A_SetTranslucent(1.0, 0)
		SeeLoop:
			9TRF AABBCCDD 3 Fast A_Chase
		Loop
		MeleeState:
			TNT1 A 0 A_SetTranslucent(1.0, 0)
			9TRF E 8 Fast A_FaceTarget
			9TRF F 8 Fast A_CustomMeleeAttack(random(4, 8) * 5, "reaver/blade", "", "Putrefier_Poison")
		Goto See
		MissileState:
			TNT1 A 0 A_Jump(160, "Cloak")
		MissileGo:
			TNT1 A 0 A_SetTranslucent(1.0, 0)
			9TRF G 8 Fast Bright A_FaceTarget
			TNT1 A 0 A_PlaySound("Putrefier/attack", CHAN_WEAPON)
			TNT1 AAAA 0 A_CustomMissile("PutrefierBullet", 36, 9, frandom(-11.25, 11.25), 0, frandom(-8.25, 8.25))
			9TRF H 16 Fast Bright A_CustomMissile("PutrefierBullet", 36, 9, frandom(-11.25, 11.25), 0, frandom(-8.25, 8.25))
		Goto See
		PainState:
			9TRF A 2 Fast
			9TRF A 2 Fast A_Pain
			TNT1 A 0 A_Jump(64, "Cloak")
		Goto See
		Cloak:
			TNT1 A 0 A_JumpIfCloser(384, "DoCloak")
		Goto MissileGo
		DoCloak:
			9TRF A 1
			TNT1 A 0 A_PlaySound("Putrefier/Cloak", CHAN_BODY)
			9TRF AAAAAAAAAA 1 A_SetTranslucent(alpha - 0.1, 1)
			TNT1 AAAAAAAAAA 0 A_Wander
			TNT1 AAAA 2 A_Chase("", "", CHF_NOPLAYACTIVE)
			TNT1 A 0 A_PlaySound("Putrefier/UnCloak", CHAN_BODY)
			9TRF AAAAA 1 A_SetTranslucent(alpha + 0.1, 1)
			TNT1 A 0 A_FaceTarget
			9TRF GGGGG 1 Bright A_SetTranslucent(alpha + 0.1, 1)
			TNT1 A 0 A_PlaySound("Putrefier/attack", CHAN_WEAPON)
			TNT1 AAAA 0 A_CustomMissile("PutrefierBullet", 36, 9, frandom(-11.25, 11.25), 0, frandom(-8.25, 8.25))
			9TRF H 5 Bright A_CustomMissile("PutrefierBullet", 36, 9, frandom(-11.25, 11.25), 0, frandom(-8.25, 8.25))
			TNT1 A 0 A_SetTranslucent(1.0, 0)
			TNT1 A 0 A_Jump(192, "See")
		Loop
		XDeathState:
		DeathState:
			TNT1 A 0 A_SetTranslucent(1.0, 0)
			TNT1 A 0 A_SpawnItemEx("PutrefierExplosion", frandom(-16, 16), frandom(-16, 16), frandom(32, 56), 0, 0, 0, SXF_NOCHECKPOSITION)
			9TRF I 4 A_SpawnItemEx("MetalScrap_More", 0, 0, 32)
			TNT1 A 0 A_SpawnItemEx("PutrefierExplosion", frandom(-16, 16), frandom(-16, 16), frandom(32, 56), 0, 0, 0, SXF_NOCHECKPOSITION)
			9TRF J 4 A_Scream
			TNT1 A 0 A_SpawnItemEx("PutrefierExplosion", frandom(-16, 16), frandom(-16, 16), frandom(32, 56), 0, 0, 0, SXF_NOCHECKPOSITION)
			9TRF K 4 A_SpawnItemEx("MetalScrap_More", 0, 0, 24)
			9TRF L 4 A_NoBlocking
			9TRF MN 4 A_SpawnItemEx("PutrefierExplosion", frandom(-16, 16), frandom(-16, 16), frandom(32, 56), 0, 0, 0, SXF_NOCHECKPOSITION)
			9TRF O 4 A_SpawnItemEx("MetalScrap_More", 0, 0, 18)
			9TRF "PQRSTUVWXYZ[" 4
			9TRF "]" -1
		Stop
		RaiseState:
			9TRF "[ZYXWVUTSRQP" 4
			9TRF ONMLKJI 4
		Goto See
	}
}

ACTOR PutrefierBullet : FastProjectile {
	Radius 1
	Height 2
	Damage (random(6, 8))
	DamageType "Poison"
	Stamina 128
	Speed 128
	Scale 0.1
	RenderStyle Add
	Alpha 0.85
	PROJECTILE
	+FORCEXYBILLBOARD
	+BLOODSPLATTER
	States {
		Spawn:
			TNT1 A 0
			TNT1 A 0 A_ChangeVelocity(velx / 50.0, vely / 50.0, velz / 50.0, CVF_REPLACE)
			TNT1 A 1
			TNT1 A 0 A_ChangeVelocity(velx * 50.0, vely * 50.0, velz * 50.0, CVF_REPLACE)
			TRAC A -1 Bright
		Stop
		Death:
		XDeath:
			TNT1 A 1 A_SpawnItem("PutrefierPuff")
			TNT1 A 1
		Stop
	}
}

ACTOR PutrefierPuff : BulletPuff {
	+NOINTERACTION
	+CLIENTSIDEONLY
	VSpeed 0
	States {
		Spawn:
			5PRF AB 5
			5PRF CDEFG 4
		Stop
	}
}

Actor PutrefierExplosion : ReaverExplosion {
	States {
		Spawn:
			TNT1 A 0 NoDelay ACS_NamedExecuteAlways("DnD Pierce Check")
			TNT1 A 0 A_Explode(6, 72, 0)
			11PF ABCDE 5 Bright
		Stop
	}
}