//////////////////////////////////////////////////// Spawners
Actor BasicFlaskRandomSpawner : RandomSpawner
{
	Dropitem "ArtiGreenFlask"
	DropItem "ArtiRedFlask"
	DropItem "ArtiYellowFlask"
}

//////////////////////////////////////////////////// Empty

ACTOR ArtiEmptyFlask : CustomInventory
{
	+FLOATBOB
	+INVENTORY.INVBAR
	+INVENTORY.PICKUPFLASH
	+INVENTORY.FANCYPICKUPSOUND
	+INVENTORY.BIGPOWERUP
	Inventory.MaxAmount 0x7FFFFFFF
	Inventory.Icon "ARTIFLA0"
	Inventory.PickupSound "pickup/flask"
	Inventory.PickupMessage "Empty Flask"
	Tag "Empty Flask"
	Inventory.InterHubAmount 0x7FFFFFFF
	//+KEEPDEPLETED
	States
	{
	Spawn:
		FLA0 A -1
		Stop
	Failed:
		TNT1 A 0
		Fail
	Use:
		TNT1 A 0 A_Print ("this is a empty flask, use reagents to fill this.")
		Fail
	}
}

//////////////////////////////////////////////////// Green poison cloud

ACTOR ArtiGreenFlask : ArtiEmptyFlask
{
	Inventory.DefMaxAmount
	Inventory.Icon "ARTIFLA1"
	Inventory.PickupMessage "Green Flask"
	Tag "Green Flask"

	States
	{
	Spawn:
		FLA1 A -1
		Stop
	Pickup:
		TNT1 A 0 A_JumpIfInventory("ArtiGreenFlask", ACS_ExecuteWithResult(WOC_DECORATE,STATS,ITEMCAP,ACTIVATOR),"Failed")
		TNT1 A 0 ACS_ExecuteWithResult(WOC_DECORATE,STATS,ITEMCAP,ACTIVATOR)
		Stop
	Failed:
		TNT1 A 0
		Fail
	Use:
		TNT1 A 0 A_GiveInventory("ShadowWalkAttackCheck",1)
		TNT1 A 0 A_SpawnItemEx ("NewPoisonBag", 16.0, 0.0, 8.0, 0.0, 0.0, 0.0, 0.0, 32, 0)
		TNT1 A 0 A_SpawnItemEx ("NewPoisonCloud", 16.0, 0.0, 36.0, 0.0, 0.0, 0.0, 0.0, 32, 0)
		Stop
	}
}

ACTOR NewPoisonBag
{
  Radius 5
  Height 5
  +NOBLOCKMAP
  +NOGRAVITY
  States
  {
  Spawn:
    PSBG A 18 Bright
    PSBG B 4 Bright
    PSBG C 3
    PSBG C 1 //A_PoisonBagInit
    Stop
  }
}

Actor NewPoisonCloud
{
	Radius 20
	Height 30
	Mass 0x7fffffff
	+NOBLOCKMAP
	+NOGRAVITY
	+DROPOFF
	+NODAMAGETHRUST +DONTBLAST
	+DONTSPLASH
	+FOILINVUL
	+CANBLAST
	+BLOODLESSIMPACT
	+FLOATBOB
	//+MISSILE
	+RIPPER
	+BLOODLESSIMPACT
	+DONTBLAST
	+FORCERADIUSDMG
	DamageType "Poison"
	PoisonDamagetype "PoisonTime"
	RenderStyle Translucent
	Alpha 0.6
	DeathSound "PoisonShroomDeath"
	States
	{
	Spawn:
		TNT1 A 25
		PSBG D 1 A_ChangeFlag("DONTBLAST", 0)
		PSBG D 1 A_Scream
		PSBG D 0 A_JumpIfInTargetInventory("PhilosopherStoneTracker",1,"Powered")
		PSBG DEEEFFFGGGHHHIIIEEEFFFGGGHHHIIIEEEFFFGGGHHHIIIEEEFFFGGGHHHIII 2 A_Explode (ACS_NamedExecuteWithResult("WOC Player Scale", 3, CURRENTLEVEL, 0, WOCTARGET), 40, 1, 0, 40)
		PSBG EEEFFFGGGHHHIIIEEEFFFGGGHHHIIIEEEFFFGGGHHHIIIEEEFFFGGGHHHIII 2 A_Explode (ACS_NamedExecuteWithResult("WOC Player Scale", 3, CURRENTLEVEL, 0, WOCTARGET), 40, 1, 0, 40)
		PSBG EEEFFFGGGHHHIIIEEEFFFGGGHHHIIIEEEFFFGGGHHHIIIEEEFFFGGGHHHIII 2 A_Explode (ACS_NamedExecuteWithResult("WOC Player Scale", 3, CURRENTLEVEL, 0, WOCTARGET), 40, 1, 0, 40)
		PSBG EEEFFFGGGHHHIIIEEEFFFGGGHHHIIIEEEFFFGGGHHHIIIEEEFFFGGGHHHIII 2 A_Explode (ACS_NamedExecuteWithResult("WOC Player Scale", 3, CURRENTLEVEL, 0, WOCTARGET), 40, 1, 0, 40)
		PSBG EEEFFFGGGHHHIIIEEEFFFGGGHHHIIIEEEFFFGGGHHHIIIEEEFFFGGGHHHIII 2 A_Explode (ACS_NamedExecuteWithResult("WOC Player Scale", 3, CURRENTLEVEL, 0, WOCTARGET), 40, 1, 0, 40)
		PSBG EEEFFFGGGHHHIIIEEEFFFGGGHHHIIIEEEFFFGGGHHHIII 2 A_Explode (ACS_NamedExecuteWithResult("WOC Player Scale", 3, CURRENTLEVEL, 0, WOCTARGET), 40, 1, 0, 40)
		Goto Death
	Powered:
		PSBG DEEEFFFGGGHHHIIIEEEFFFGGGHHHIIIEEEFFFGGGHHHIIIEEEFFFGGGHHHIII 2 A_Explode (ACS_NamedExecuteWithResult("WOC Player Scale", 4, CURRENTLEVEL, 0, WOCTARGET), 40, 1, 0, 40)
		PSBG EEEFFFGGGHHHIIIEEEFFFGGGHHHIIIEEEFFFGGGHHHIIIEEEFFFGGGHHHIII 2 A_Explode (ACS_NamedExecuteWithResult("WOC Player Scale", 4, CURRENTLEVEL, 0, WOCTARGET), 40, 1, 0, 40)
		PSBG EEEFFFGGGHHHIIIEEEFFFGGGHHHIIIEEEFFFGGGHHHIIIEEEFFFGGGHHHIII 2 A_Explode (ACS_NamedExecuteWithResult("WOC Player Scale", 4, CURRENTLEVEL, 0, WOCTARGET), 40, 1, 0, 40)
		PSBG EEEFFFGGGHHHIIIEEEFFFGGGHHHIIIEEEFFFGGGHHHIIIEEEFFFGGGHHHIII 2 A_Explode (ACS_NamedExecuteWithResult("WOC Player Scale", 4, CURRENTLEVEL, 0, WOCTARGET), 40, 1, 0, 40)
		PSBG EEEFFFGGGHHHIIIEEEFFFGGGHHHIIIEEEFFFGGGHHHIIIEEEFFFGGGHHHIII 2 A_Explode (ACS_NamedExecuteWithResult("WOC Player Scale", 4, CURRENTLEVEL, 0, WOCTARGET), 40, 1, 0, 40)
		PSBG EEEFFFGGGHHHIIIEEEFFFGGGHHHIIIEEEFFFGGGHHHIII 2 A_Explode (ACS_NamedExecuteWithResult("WOC Player Scale", 4, CURRENTLEVEL, 0, WOCTARGET), 40, 1, 0, 40)
		Goto Death
	Death:
    	PSBG HG 7
    	PSBG FD 6
    	Stop
	}
}
//////////////////////////////////////////////////// Red explosive timebomb

ACTOR ArtiRedFlask : ArtiEmptyFlask
{
	Inventory.Icon "ARTIFLA2"
	Inventory.DefMaxAmount
	Inventory.PickupMessage "Red Flask"
	Tag "Red Flask"
	States
	{
	Spawn:
		FLA2 A -1
		Stop
	Pickup:
		TNT1 A 0 A_JumpIfInventory("ArtiRedFlask", ACS_ExecuteWithResult(WOC_DECORATE,STATS,ITEMCAP,ACTIVATOR),"Failed")
		TNT1 A 0 ACS_ExecuteWithResult(WOC_DECORATE,STATS,ITEMCAP,ACTIVATOR)
		Stop
	Failed:
		TNT1 A 0
		Fail
	Use:
		TNT1 A 0 A_GiveInventory("ShadowWalkAttackCheck",1)
		TNT1 A 0 A_SpawnItemEx ("zActivatedTimeBomb", 16.0, 0.0, 8.0, 0.0, 0.0, 0.0, 0.0, 32, 0)
		TNT1 A 0 A_SpawnItemEx ("zActivatedTimeBombBoom", 16.0, 0.0, 40.0, 0.0, 0.0, 0.0, 0.0, 32, 0)
		Stop
	}
}

actor zActivatedTimeBomb //: ActivatedTimeBomb replaces ActivatedTimeBomb
{
   DamageType "Fire"
   +NOGRAVITY
   +FOILINVUL
   //RenderStyle Add
   //Alpha 0.4
   DeathSound "FlechetteExplode"
	States
	{
   Spawn:
     FBMB ABCD 10
     FBMB E 6 A_Scream
	 //XPL1 A 0 A_SetTranslucent(0.4, 1)
     //XPL1 A 4 BRIGHT A_Explode (128+2*(acs_executewithresult(WOC_DECORATE,STATS,CURRENTLEVEL,WOCTARGET)), 128, 1)
     //XPL1 BCDEF 4 BRIGHT
     Stop
	}
}

actor zActivatedTimeBombBoom
{
   DamageType "Fire"
   +NOGRAVITY
   Projectile
   +RIPPER
   +BLOODLESSIMPACT
   +PAINLESS
   +FOILINVUL
   +DONTBLAST
   +FORCERADIUSDMG
   //RenderStyle Add
   DeathSound "FlechetteExplode"
   States
   {
	Spawn:
     TNT1 AAAA 10
     TNT1 A 6 A_Scream
	 XPL1 A 0 A_SetTranslucent(1, 1)
	 XPL1 A 0 A_ChangeFlag("Painless", 0)
	 XPL1 A 0 Bright A_AlertMonsters
	 XPL1 A 0 Bright A_JumpIfInTargetInventory("PhilosopherStoneTracker",1,"Powered")
     XPL1 A 4 BRIGHT A_Explode (ACS_NamedExecuteWithResult("WOC Player Scale", 128, CURRENTLEVEL, 0, WOCTARGET), 128, 1)
     XPL1 BCDEF 4 BRIGHT
     Stop
	Powered:
	 XPL1 A 4 BRIGHT A_Explode (ACS_NamedExecuteWithResult("WOC Player Scale", 160, CURRENTLEVEL, 0, WOCTARGET), 128, 1)
     XPL1 BCDEF 4 BRIGHT
     Stop
	}
}

//////////////////////////////////////////////////// Yellow grenade bomb

ACTOR ArtiYellowFlask : ArtiEmptyFlask
{
	Inventory.Icon "ARTIFLA3"
	Inventory.DefMaxAmount
	Inventory.PickupMessage "Yellow Flask"
	Tag "Yellow Flask"
	States
	{
	Spawn:
		FLA3 A -1
		Stop
	Pickup:
		TNT1 A 0 A_JumpIfInventory("ArtiYellowFlask", ACS_ExecuteWithResult(WOC_DECORATE,STATS,ITEMCAP,ACTIVATOR),"Failed")
		TNT1 A 0 ACS_ExecuteWithResult(WOC_DECORATE,STATS,ITEMCAP,ACTIVATOR)
		Stop
	Failed:
		TNT1 A 0
		Fail
	Use:
		TNT1 A 0 A_GiveInventory("ShadowWalkAttackCheck",1)
		TNT1 A 0 A_FireCustomMissile ("YellowBomb", 0, 0, 0, 5)
		Stop
	}
}

ACTOR YellowBomb : ThrowingBomb
{
	Speed 28
	+WINDTHRUST
   +THRUGHOST
   +MTHRUSPECIES /*+NODAMAGETHRUST*/ +DONTBLAST
   +FOILINVUL
   +FORCERADIUSDMG
	States
	{
	Spawn:
		THRW A 4 A_CheckThrowBomb
		THRW BCDE 3 A_CheckThrowBomb
		THRW F 3 A_CheckThrowBomb2
		Loop
		THRW G 6 A_CheckThrowBomb
		THRW I 4 A_CheckThrowBomb
		THRW H 6 A_CheckThrowBomb
		THRW I 4 A_CheckThrowBomb
		THRW G 6 A_CheckThrowBomb
		THRW I 3 A_CheckThrowBomb
		Wait
	Death:
		CFCF Q 0 Bright A_AlertMonsters
		CFCF Q 0 Bright A_SetTranslucent(1,1)
		CFCF Q 0 Bright A_JumpIfInTargetInventory("PhilosopherStoneTracker",1,"Powered")
		CFCF Q 0 Bright A_Explode (ACS_NamedExecuteWithResult("WOC Player Scale", 128, CURRENTLEVEL, 0, WOCTARGET), 128, 1)
		CFCF Q 1 Bright A_NoGravity
		CFCF QQQ 1 Bright A_SpawnItemEx("FlailPuffParticleFXSpawner")
		CFCF R 0 Bright A_Scream
		CFCF RRR 1 Bright A_SpawnItemEx("FlailPuffParticleFXSpawner")
		CFCF SSSS 1 Bright A_SpawnItemEx("FlailPuffParticleFXSpawner")
		CFCF T 3 Bright
		CFCF U 4 Bright
		CFCF W 3 Bright
		CFCF X 4 Bright
		CFCF Z 3 Bright
		Stop
	Powered:
		CFCF Q 0 Bright A_Explode (ACS_NamedExecuteWithResult("WOC Player Scale", 160, CURRENTLEVEL, 0, WOCTARGET), 128, 1)
		CFCF Q 1 Bright A_NoGravity
		CFCF QQQ 1 Bright A_SpawnItemEx("FlailPuffParticleFXSpawner")
		CFCF R 0 Bright A_Scream
		CFCF RRR 1 Bright A_SpawnItemEx("FlailPuffParticleFXSpawner")
		CFCF SSSS 1 Bright A_SpawnItemEx("FlailPuffParticleFXSpawner")
		CFCF T 3 Bright
		CFCF U 4 Bright
		CFCF W 3 Bright
		CFCF X 4 Bright
		CFCF Z 3 Bright
		Stop
	}
}

//////////////////////////////////////////////////// Blue ice cloud

ACTOR ArtiBlueFlask : ArtiEmptyFlask
{
	Inventory.Icon "ARTIFLA4"
	Inventory.DefMaxAmount
	Inventory.PickupMessage "Blue Flask"
	Tag "Blue Flask"
	States
	{
	Spawn:
		FLA4 A -1
		Stop
	Pickup:
		TNT1 A 0 A_JumpIfInventory("ArtiBlueFlask", ACS_ExecuteWithResult(WOC_DECORATE,STATS,ITEMCAP,ACTIVATOR),"Failed")
		TNT1 A 0 ACS_ExecuteWithResult(WOC_DECORATE,STATS,ITEMCAP,ACTIVATOR)
		Stop
	Failed:
		TNT1 A 0
		Fail
	Use:
		TNT1 A 0 A_GiveInventory("ShadowWalkAttackCheck",1)
		TNT1 A 0 A_SpawnItemEx ("IceBag", 16.0, 0.0, 8.0, 0.0, 0.0, 0.0, 0.0, 32, 0)
		TNT1 A 0 A_SpawnItemEx ("IceCloud", 16.0, 0.0, 36.0, 0.0, 0.0, 0.0, 0.0, 32, 0)
		Stop
	}
}

ACTOR IceBag
{
  Radius 5
  Height 5
  +NOBLOCKMAP
  +NOGRAVITY

  States
  {
  Spawn:
    FLA4 A 18 Bright
    FLA4 B 4 Bright
    FLA4 C 3
    FLA4 C 1 //A_SpawnItemEx ("IceCloud", 0.0, 0.0, 28.0, 0.0, 0.0, 0.0, 0.0, 32, 0)
    Stop
  }
}

ACTOR IceCloud
{
  Radius 20
  Height 30
  Mass 1000
  +NOBLOCKMAP
  +NOGRAVITY
  +DROPOFF
  +NODAMAGETHRUST +DONTBLAST
  +DONTSPLASH
  +FOILINVUL
  -CANBLAST
  +BLOODLESSIMPACT
  +WINDTHRUST
  +NOTELEPORT
  +MISSILE
  +NOEXPLODEFLOOR
  +RIPPER
  +FORCEXYBILLBOARD
  +DOOMBOUNCE
  +DONTBLAST
  BounceFactor 1.0
  RenderStyle Translucent
  Alpha 0.8
  DeathSound "PoisonShroomDeath"
  DamageType Ice
  reactiontime 60

  States
  {
  Spawn:
	TNT1 A 25
    FLA4 D 1 A_ChangeFlag("DontBlast", 0)
    FLA4 D 1 A_Scream
	FLA4 D 0 A_JumpIfInTargetInventory("PhilosopherStoneTracker",1,"PoweredRain")
    Goto Rain
  Rain:
    FLA4 D 2
    FLA4 E 2 A_Countdown
    FLA4 E 2 A_SpawnItemEx ("IceDrop", 0.0, 0.0, 0.0, frandom(0,2), frandom(0,2), 0.0, frandom(0,359), 32, 128)
    FLA4 EF 2
    FLA4 F 2 A_SpawnItemEx ("IceDrop", 0.0, 0.0, 0.0, frandom(0,2), frandom(0,2), 0.0, frandom(0,359), 32, 96)
    FLA4 FG 2
    FLA4 G 2 A_SpawnItemEx ("IceDrop", 0.0, 0.0, 0.0, frandom(0,2), frandom(0,2), 0.0, frandom(0,359), 32, 64)
    FLA4 GH 2
    FLA4 H 2 A_SpawnItemEx ("IceDrop", 0.0, 0.0, 0.0, frandom(0,2), frandom(0,2), 0.0, frandom(0,359), 32, 32)
    FLA4 HI 2
    FLA4 I 2 A_SpawnItemEx ("IceDrop", 0.0, 0.0, 0.0, frandom(0,2), frandom(0,2), 0.0, frandom(0,359), 32, 0)
    FLA4 I 2 A_SpawnItemEx ("IceDrop", 0.0, 0.0, 0.0, frandom(0,2), frandom(0,2), 0.0, frandom(0,359), 32, 64)
    FLA4 I 1 A_JumpIf ((ceilingz - z > 80.0),"Up") //Too far from the ceiling
    FLA4 I 0 ThrustThingZ(0, 1, 1, 1) //Slowdown
    Goto Rain+1
  Up:
    FLA4 I 0 A_JumpIf ((ceilingz - z < 8.0),"Rain")
    FLA4 I 1 ThrustThingZ(0, 2, 0, 0)
    Goto Rain+1
  PoweredRain:
    FLA4 D 2
    FLA4 E 2 A_Countdown
    FLA4 E 2 A_SpawnItemEx ("IceDropPowered", 0.0, 0.0, 0.0, frandom(0,2), frandom(0,2), 0.0, frandom(0,359), 32, 128)
    FLA4 EF 2
    FLA4 F 2 A_SpawnItemEx ("IceDropPowered", 0.0, 0.0, 0.0, frandom(0,2), frandom(0,2), 0.0, frandom(0,359), 32, 96)
    FLA4 FG 2
    FLA4 G 2 A_SpawnItemEx ("IceDropPowered", 0.0, 0.0, 0.0, frandom(0,2), frandom(0,2), 0.0, frandom(0,359), 32, 64)
    FLA4 GH 2
    FLA4 H 2 A_SpawnItemEx ("IceDropPowered", 0.0, 0.0, 0.0, frandom(0,2), frandom(0,2), 0.0, frandom(0,359), 32, 32)
    FLA4 HI 2
    FLA4 I 2 A_SpawnItemEx ("IceDropPowered", 0.0, 0.0, 0.0, frandom(0,2), frandom(0,2), 0.0, frandom(0,359), 32, 0)
    FLA4 I 2 A_SpawnItemEx ("IceDropPowered", 0.0, 0.0, 0.0, frandom(0,2), frandom(0,2), 0.0, frandom(0,359), 32, 64)
    FLA4 I 1 A_JumpIf ((ceilingz - z > 80.0),"PoweredUp") //Too far from the ceiling
    FLA4 I 0 ThrustThingZ(0, 1, 1, 1) //Slowdown
    Goto PoweredRain+1
  PoweredUp:
    FLA4 I 0 A_JumpIf ((ceilingz - z < 8.0),"PoweredRain")
    FLA4 I 1 ThrustThingZ(0, 2, 0, 0)
    Goto PoweredRain+1
  Death:
    FLA4 HG 7
    FLA4 FD 6
    Stop
  }
}

ACTOR IceDrop : FrostMissile
{
  DamageType "Ice"
  -NOGRAVITY
  -ACTIVATEIMPACT
  -ACTIVATEPCROSS
  +THRUGHOST
  +WINDTHRUST
  +MTHRUSPECIES +NODAMAGETHRUST +DONTBLAST
  +FOILINVUL
  +DONTREFLECT
  Mass 5
  Renderstyle Add
  Damage (frandom(3,24)*0.025*(40+acs_executewithresult(WOC_DECORATE,STATS,CURRENTLEVEL,WOCTARGET)))
  States
  {
  Spawn:
    IDRP ABC 3 Bright
    Loop
  }
}

Actor IceDropPowered : IceDrop
{
	Damage ((frandom(3,24)*0.025*(40+acs_executewithresult(WOC_DECORATE,STATS,CURRENTLEVEL,WOCTARGET)))*1.25)
}

//////////////////////////////////////////////////// White solid cloud

ACTOR ArtiWhiteFlask : ArtiEmptyFlask
{
	Inventory.Icon "ARTIFLA5"
	Inventory.DefMaxAmount
	Inventory.PickupMessage "White Flask"
	Tag "White Flask"
	States
	{
	Spawn:
		FLA5 A -1
		Stop
	Pickup:
		TNT1 A 0 A_JumpIfInventory("ArtiWhiteFlask", ACS_ExecuteWithResult(WOC_DECORATE,STATS,ITEMCAP,ACTIVATOR),"Failed")
		TNT1 A 0 ACS_ExecuteWithResult(WOC_DECORATE,STATS,ITEMCAP,ACTIVATOR)
		Stop
	Failed:
		TNT1 A 0
		Fail
	Use:
		TNT1 A 0 A_GiveInventory("ShadowWalkAttackCheck",1)
		TNT1 A 0 A_SpawnItemEx ("WhiteBag", 16.0, 0.0, 8.0, 0.0, 0.0, 0.0, 0.0, 32, 0)
		TNT1 A 0 A_SpawnItemEx ("WhiteCloud", 16.0, 8.0, 36.0, 0.0, 0.0, 0.0, 0.0, 32, 0)
		TNT1 A 0 A_SpawnItemEx ("WhiteCloud", 24.0, 0.0, 36.0, 0.0, 0.0, 0.0, 0.0, 32, 0)
		TNT1 A 0 A_SpawnItemEx ("WhiteCloud", 16.0,-8.0, 36.0, 0.0, 0.0, 0.0, 0.0, 32, 0)
		Stop
	}
}

ACTOR WhiteBag
{
  Radius 5
  Height 5
  +NOBLOCKMAP
  +NOGRAVITY

  States
  {
  Spawn:
    FLA5 A 18 Bright
    FLA5 B 4 Bright
    FLA5 C 3
    //FLA5 C 0 A_SpawnItemEx ("WhiteCloud", 0.0, 8.0, 28.0, 0.0, 0.0, 0.0, 0.0, 32, 0)
    //FLA5 C 0 A_SpawnItemEx ("WhiteCloud", 8.0, 0.0, 28.0, 0.0, 0.0, 0.0, 0.0, 32, 0)
    FLA5 C 1// A_SpawnItemEx ("WhiteCloud", 0.0,-8.0, 28.0, 0.0, 0.0, 0.0, 0.0, 32, 0)
    Stop
  }
}

ACTOR WhiteCloud
{
  Radius 20
  Height 30
  Mass 0x7FFFFFFF
  scale 1
  +NOGRAVITY
  +DROPOFF
  +RIPPER
  +MISSILE
  +NODAMAGETHRUST +DONTBLAST
  +DONTSPLASH
  +FOILINVUL
  -CANBLAST
  +BLOODLESSIMPACT
  +WINDTHRUST
  +NOTELEPORT
  +FORCEXYBILLBOARD
  +DONTBLAST
  +CANTSEEK
  +NODAMAGE
  +NOBLOOD
  +THRUSPECIES
  +FORCERADIUSDMG
  Species "Player"
  RenderStyle Translucent
  Alpha 0.4
  DeathSound "PoisonShroomDeath"
  Damagetype "Holy"

  States
  {
  Spawn:
	TNT1 A 25
    FLA5 D 1 A_ChangeFlag("DontBlast", 0)
    FLA5 D 1 A_Scream
    FLA5 DEEEFFFGGGHHHII 2
    FLA5 I 2 A_SetTranslucent (0.4, 0)
    FLA5 I 1
    FLA5 EEEFFFGGGHHHII 2
    FLA5 I 2 A_SetTranslucent (0.6, 0)
    FLA5 I 1
    FLA5 EEEFFFGGGHHHII 2
    FLA5 I 2 A_SetTranslucent (0.8, 0)
    FLA5 I 1
    FLA5 EEEFFFGGGHHHII 2
    FLA5 I 2 A_SetTranslucent (1.0, 0)
    FLA5 I 0 A_SetSolid
	FLA5 I 0 A_SetShootable
    FLA5 I 0 A_Jump (256,"SolidA","SolidB","SolidC","SolidD") //Random Frame
    Goto SolidA
  SolidA:
    FLA5 I 350
    Goto Death
  SolidB:
    FLA5 H 350
    Goto Death
  SolidC:
    FLA5 G 350
    Goto Death
  SolidD:
    FLA5 F 350
    Goto Death
  Death:
	FLA5 H 0 A_JumpIfInTargetInventory("PhilosopherStoneTracker",1,"Powered")
    FLA5 HG 7 A_Explode(ACS_NamedExecuteWithResult("WOC Player Scale", 320, CURRENTLEVEL, 0, WOCTARGET),32)
    FLA5 FD 6
    Stop
  Powered:
	FLA5 HG 7 A_Explode(ACS_NamedExecuteWithResult("WOC Player Scale", 400, CURRENTLEVEL, 0, WOCTARGET),32)
    FLA5 FD 6
    Stop
  }
}

//////////////////////////////////////////////////// Black knight archer summon

ACTOR ArtiBlackFlask : ArtiEmptyFlask
{
	Inventory.Icon "ARTIFLA6"
	Inventory.DefMaxAmount
	Inventory.PickupMessage "Black Flask"
	Tag "Black Flask"
	States
	{
	Spawn:
		FLA6 A -1
		Stop
	Pickup:
		TNT1 A 0 A_JumpIfInventory("ArtiBlackFlask", ACS_ExecuteWithResult(WOC_DECORATE,STATS,ITEMCAP,ACTIVATOR),"Failed")
		TNT1 A 0 ACS_ExecuteWithResult(WOC_DECORATE,STATS,ITEMCAP,ACTIVATOR)
		Stop
	Failed:
		TNT1 A 0
		Fail
	Use:
		TNT1 A 0 A_GiveInventory("ShadowWalkAttackCheck",1)
		TNT1 A 0 A_SpawnItemEx ("BlackBag", 16.0, 0.0, 8.0, 0.0, 0.0, 0.0, 0.0, 32, 0)
		TNT1 A 0 A_SpawnItemEx ("BlackCloud", 16.0, 0.0, 36.0, 0.0, 0.0, 0.0, 0.0, 32, 0)
		Stop
	}
}

ACTOR BlackBag
{
  Radius 5
  Height 5
  +NOBLOCKMAP
  +NOGRAVITY

  States
  {
  Spawn:
    FLA6 A 18 Bright
    FLA6 B 4 Bright
    FLA6 C 3
    FLA6 C 1 //A_SpawnItemEx ("BlackCloud", 0.0, 0.0, 28.0, 0.0, 0.0, 0.0, 0.0, 32, 0)
    Stop
  }
}

ACTOR BlackCloud
{
  Radius 20
  Height 30
  Mass 1000
  scale 1
  +NOGRAVITY
  +DROPOFF
  +RIPPER
  +MISSILE
  +NODAMAGETHRUST +DONTBLAST
  +DONTSPLASH
  +FOILINVUL
  -CANBLAST
  +BLOODLESSIMPACT
  +NOTELEPORT
  +FORCEXYBILLBOARD
  +DONTBLAST
  RenderStyle Translucent
  Alpha 0.75
  DeathSound "PoisonShroomDeath"
  reactiontime 2

  States
  {
  Spawn:
	TNT1 A 25
    FLA6 D 1
    FLA6 D 3 A_Scream
	FLA6 D 0 A_JumpIfInTargetInventory("PhilosopherStoneTracker",1,"PoweredCast")
    Goto Cast
  Cast:
    FLA6 D 0 A_Countdown
    FLA6 DEEEFFF 2
    FLA6 G 2 A_SpawnItemEx ("KnightArcherAlly", 0.0, 0.0, 0.0, 4.0, 0.0, 0.0, 0.0, SXF_NOCHECKPOSITION, 0, PET5TID+ACS_ExecuteWithResult(WOC_DECORATE,STATS,PLAYERNUM,WOCTARGET))
    FLA6 GGHHHII 2
    FLA6 I 2
    FLA6 I 1
    Goto Cast
  PoweredCast:
    FLA6 D 0 A_Countdown
    FLA6 DEEEFFF 2
    FLA6 G 2 A_SpawnItemEx ("KnightArcherAllyPowered", 0.0, 0.0, 0.0, 4.0, 0.0, 0.0, 0.0, SXF_NOCHECKPOSITION, 0, PET5TID+ACS_ExecuteWithResult(WOC_DECORATE,STATS,PLAYERNUM,WOCTARGET))
    FLA6 GGHHHII 2
    FLA6 I 2
    FLA6 I 1
    Goto Cast
  Death:
    FLA6 HG 7
    FLA6 FD 6
    Stop
  }
}

actor KnightArcherAlly : WoC_FriendlyMon
{
    Health 200
    Radius 20
    Height 56
    Speed 14
    PainChance 32
	Mass 100
    MONSTER
    +FRIENDLY
	+NEVERFAST
	+NODROPOFF
	+QUICKTORETALIATE
	-COUNTKILL
	+NOBLOCKMONST
	Species "Player"
    +THRUSPECIES
	+FLOORCLIP
	+DONTHARMSPECIES
	RadiusDamageFactor 0.25
	MinMissileChance 10
	SeeSound "archer/sight"
    AttackSound "archer/attack"
    PainSound "archer/pain"
    DeathSound "archer/death"
    ActiveSound "archer/growl"
    Obituary "%o was pierced by a Knight Archer."
	Tag "Knight Archer"
    States
    {
    Spawn:
		KNTA A 0
		KNTA A 0 A_GiveInventory("ImAPet",1)
		KNTA A 0 ACS_NamedExecuteAlways("WOC Monster Init",0,64,WOC_ALLYSUMMON)
	Idle:
        KNTA AB 10 A_Look
        Loop
	GiveUp:
		KNTA A 0 A_ClearTarget
    See:
		KNTA A 0 A_JumpIfTargetinLOS(2, 140)
		KNTA A 0 A_Jump(50, "Giveup")
        KNTA A 2 A_FastChase
		KNTA A 3 A_FastChase
		KNTA B 2 A_FastChase
		KNTA B 3 A_FastChase
		KNTA C 2 A_FastChase
		KNTA C 3 A_FastChase
		KNTA D 2 A_FastChase
		KNTA D 3 A_FastChase
		Loop
	Missile:
		KNTA E 0 A_SpawnItemEx("PetAlert")
		KNTA E 0 A_Jump(96,"Missile2")
        KNTA E 3 A_PlaySound("archer/draw")
        KNTA E 4 A_FaceTarget
        KNTA F 5 bright A_CustomMissile("ArcherArrowAlly",32,5)
		KNTA E 5
		KNTA E 0 A_JumpIfCloser(500, "TooClose")
        Goto See
	Missile2:
        KNTA E 3 A_PlaySound("archer/draw")
        KNTA E 4 A_FaceTarget
        KNTA G 5 bright A_CustomMissile("ArcherArrow2Ally",32,5)
		KNTA E 5
		KNTA E 0 A_JumpIfCloser(500, "TooClose")
        Goto See
	TooClose:
		KNTA A 0 A_ChangeFlag("FRIGHTENED", 1)
		KNTA A 1
		KNTA A 2 A_Chase("","",CHF_FASTCHASE)
		KNTA B 3 A_Chase("","",CHF_FASTCHASE)
		KNTA C 1
		KNTA C 2 A_Chase("","",CHF_FASTCHASE)
		KNTA D 3 A_Chase("","",CHF_FASTCHASE)
		KNTA A 1
		KNTA A 2 A_Chase("","",CHF_FASTCHASE)
		KNTA B 3 A_Chase("","",CHF_FASTCHASE)
		KNTA C 1
		KNTA C 2 A_Chase("","",CHF_FASTCHASE)
		KNTA D 3 A_Chase("","",CHF_FASTCHASE)
		KNTA A 0 A_ChangeFlag("FRIGHTENED", 0)
		Goto See
    Pain:
		KNTA H 0
    	KNTA H 3 A_ChangeFlag("FRIGHTENED", 0)
        KNTA H 3 A_Pain
    	Goto See
    Death:
        KNTA I 5 A_Scream
        KNTA J 5 A_NoBlocking
        KNTA KLMN 5
        KNTA N -1
        Stop
    XDeath:
		KNTA O 0 A_SpawnItem("GIBBER")
        KNTA O 5 A_PlaySound("archer/gib")
        KNTA P 5 A_NoBlocking
        KNTA QRSTUVWX 5
        KNTA X -1
        Stop
    }
}

Actor KnightArcherAllyPowered : KnightArcherAlly
{
	Health 250
	States
	{
	Spawn:
		KNTA A 0
		KNTA A 0 A_GiveInventory("ImAPet",1)
		KNTA A 0 ACS_NamedExecuteAlways("WOC Monster Init",0,64,WOC_ALLYSUMMON)
	Idle:
        KNTA AB 10 A_Look
        Loop
	}
}

actor ArcherArrowAlly
{
   Radius 5
   Height 12
   Speed 40
   Damage (ACS_NamedExecuteWithResult("WOC Player Scale", FRandom(20,40), CHARISMA, 0, WOCTARGET))
   Damagetype "Physical"
   PROJECTILE
   +NOGRAVITY
   +MTHRUSPECIES /*+NODAMAGETHRUST*/ +DONTBLAST
   /*+NODAMAGETHRUST*/ +DONTBLAST
   +FOILINVUL
   +DONTREFLECT
   renderstyle add
   alpha 0.8
   scale 0.5
   SeeSound "archer/attack"
   DeathSound "archer/hit"
   States
   {
   Spawn:
      VEKF A 1 bright A_SpawnItemEx("ArcherArrowTrail",  -(MomX/1.2), -(MomY/1.2), (MomZ/1.2*-1), (MomX/1.2), (MomY/1.2), (MomZ/1.2), 0, 138)
      Loop
   Death:
      VEKF FGHI 3 bright
	Stop
   }
}


actor ArcherArrowTrail
{
	PROJECTILE
	+NOGRAVITY
	+CLIENTSIDEONLY
	+DONTSPLASH
	Radius 1
    Height 1
	renderstyle add
	alpha 0.5
	States
	{
		Spawn:
		VEKF AABCDE 3 A_FadeOut(0.1)
		loop
	}
}

actor ArcherArrow2Ally : ArcherArrowAlly
{
   Damage (ACS_NamedExecuteWithResult("WOC Player Scale", FRandom(40,80), CHARISMA, 0, WOCTARGET))
   Damagetype "Physical"
   /*+NODAMAGETHRUST*/ +DONTBLAST
   SeeSound "archer/attackboss"
   States
   {
   Spawn:
      VEKG A 1 bright A_SpawnItemEx("ArcherArrowTrail2",  -(MomX/1.2), -(MomY/1.2), (MomZ/1.2*-1), (MomX/1.2), (MomY/1.2), (MomZ/1.2), 0, 138)
      Loop
   Death:
      VEKG FGHI 3 bright
	Stop
   }
}

actor ArcherArrowTrail2 : ArcherArrowTrail
{
	+CLIENTSIDEONLY
	States
	{
		Spawn:
		VEKG AABCDE 3 A_FadeOut(0.1)
		loop
	}
}

//////////////////////////////////////////////////// Purple morphing cloud

ACTOR ArtiPurpleFlask : ArtiEmptyFlask
{
	Inventory.Icon "ARTIFLA7"
	Inventory.DefMaxAmount
	Inventory.PickupMessage "Purple Flask"
	Tag "Purple Flask"
	States
	{
	Spawn:
		FLA7 A -1
		Stop
	Pickup:
		TNT1 A 0 A_JumpIfInventory("ArtiPurpleFlask", ACS_ExecuteWithResult(WOC_DECORATE,STATS,ITEMCAP,ACTIVATOR),"Failed")
		TNT1 A 0 ACS_ExecuteWithResult(WOC_DECORATE,STATS,ITEMCAP,ACTIVATOR)
		Stop
	Failed:
		TNT1 A 0
		Fail
	Use:
		TNT1 A 0 A_GiveInventory("ShadowWalkAttackCheck",1)
		TNT1 A 0 A_SpawnItemEx ("PurpleCloud", 16.0, 0.0, 36.0, 0.0, 0.0, 0.0, 0.0, 32, 0)
		TNT1 A 0 A_SpawnItemEx ("PurpleBag", 16.0, 0.0, 8.0, 0.0, 0.0, 0.0, 0.0, 32, 0)
		Stop
	}
}

ACTOR PurpleBag
{
  Radius 5
  Height 5
  +NOBLOCKMAP
  +NOGRAVITY

  States
  {
  Spawn:
    FLA7 A 18 Bright
    FLA7 B 4 Bright
    FLA7 C 3
    FLA7 C 1 //A_SpawnItemEx ("PurpleCloud", 0.0, 0.0, 28.0, 0.0, 0.0, 0.0, 0.0, 32, 0)
    Stop
  }
}

ACTOR PurpleCloud
{
  Radius 20
  Height 30
  Mass 1000
  scale 1
  +NOGRAVITY
  +MISSILE
  +RIPPER
  +DROPOFF
  +NODAMAGETHRUST +DONTBLAST
  +DONTSPLASH
  +FOILINVUL
  -CANBLAST
  +BLOODLESSIMPACT
  +NOTELEPORT
  +FORCEXYBILLBOARD
  +DONTBLAST
  RenderStyle Translucent
  Alpha 0.6
  DeathSound "PoisonShroomDeath"
  reactiontime 30

  States
  {
  Spawn:
	TNT1 A 25
    FLA7 D 1 A_ChangeFlag("DontBlast", 0)
    FLA7 D 3 A_Scream
	FLA7 D 0 A_JumpIfInTargetInventory("PhilosopherStoneTracker",1,"PoweredCast")
    Goto Cast
  Cast:
    FLA7 D 0 A_Countdown
    FLA7 EE 2
    FLA7 EF 2 A_CustomMissile ("PurpleShot", 8.0, 4.0, frandom(0,359), 6, (5 - frandom(0,10)))
    FLA7 FFG 2
    FLA7 GG 2 A_CustomMissile ("PurpleShot", 8.0, 4.0, frandom(0,359), 6, (5 - frandom(0,10)))
    FLA7 HHH 2
    FLA7 II 2 A_CustomMissile ("PurpleShot", 8.0, 4.0, frandom(0,359), 6, (5 - frandom(0,10)))
    FLA7 I 2
    FLA7 I 1 A_CustomMissile ("PurpleShot", 8.0, 4.0, frandom(0,359), 6, (5 - frandom(0,10)))
    Goto Cast
  PoweredCast:
    FLA7 D 0 A_Countdown
    FLA7 EE 2
    FLA7 EF 2 A_CustomMissile ("PoweredPurpleShot", 8.0, 4.0, frandom(0,359), 6, (5 - frandom(0,10)))
    FLA7 FFG 2
    FLA7 GG 2 A_CustomMissile ("PoweredPurpleShot", 8.0, 4.0, frandom(0,359), 6, (5 - frandom(0,10)))
    FLA7 HHH 2
    FLA7 II 2 A_CustomMissile ("PoweredPurpleShot", 8.0, 4.0, frandom(0,359), 6, (5 - frandom(0,10)))
    FLA7 I 2
    FLA7 I 1 A_CustomMissile ("PoweredPurpleShot", 8.0, 4.0, frandom(0,359), 6, (5 - frandom(0,10)))
    Goto PoweredCast
  Death:
    FLA7 HG 7
    FLA7 FD 6
    Stop
  }
}

actor PurpleShot// : PorkFX
{
  Speed 16
  Height 14
  Radius 10
  Damage (ACS_NamedExecuteWithResult("WOC Player Scale", FRandom(2,16), CURRENTLEVEL, 0, WOCTARGET))
  Damagetype "Arcane"
  Projectile
  +MTHRUSPECIES /*+NODAMAGETHRUST*/ +DONTBLAST
  +FOILINVUL
  +DONTREFLECT
  +SEEKERMISSILE
  RenderStyle Add
  DeathSound "impwar/poison"
  reactiontime 4

  States
  {
  Spawn:
	FL7P AAAAAAA 0 A_SeekerMissile(90,90,SMF_LOOK|SMF_PRECISE)
  Looper:
    FL7P A 0 A_Countdown
    FL7P A 3 Bright A_PlaySoundEx("SerpentFXContinuous", "Body", 1)
    FL7P B 3 Bright
	FL7P A 3 Bright A_Countdown
	FL7P B 3 Bright
    Loop
  Death:
    FL7P C 4 Bright A_StopSoundEx("Body")
    FL7P DE 4 Bright
    Stop
  }
}

Actor PoweredPurpleShot : PurpleShot
{
	Damage (ACS_NamedExecuteWithResult("WOC Player Scale", FRandom(2,16)*0.25, CURRENTLEVEL, 0, WOCTARGET))
}

//////////////////////////////////////////////////// Aqua seeking killer water o_O

ACTOR ArtiAquaFlask : ArtiEmptyFlask
{
	Inventory.Icon "ARTIFLA8"
	Inventory.DefMaxAmount
	Inventory.PickupMessage "Aqua Flask"
	Tag "Aqua Flask"
	States
	{
	Spawn:
		FLA8 A -1
		Stop
	Pickup:
		TNT1 A 0 A_JumpIfInventory("ArtiAquaFlask", ACS_ExecuteWithResult(WOC_DECORATE,STATS,ITEMCAP,ACTIVATOR),"Failed")
		TNT1 A 0 ACS_ExecuteWithResult(WOC_DECORATE,STATS,ITEMCAP,ACTIVATOR)
		Stop
	Failed:
		TNT1 A 0
		Fail
	Use:
		TNT1 A 0 A_GiveInventory("ShadowWalkAttackCheck",1)
		TNT1 A 0 A_FireCustomMissile ("AquaBomb", 0, 0, 0, 5)
		Stop
	}
}

ACTOR AquaBomb : ThrowingBomb
{
  Speed 28
  +EXPLODEONWATER
  +WINDTHRUST
   +THRUGHOST
   +MTHRUSPECIES /*+NODAMAGETHRUST*/ +DONTBLAST
   +FOILINVUL
   +FORCERADIUSDMG
  States
  {
  Spawn:
    FTH8 A 4 A_CheckThrowBomb
    FTH8 BCDE 3 A_CheckThrowBomb
    FTH8 F 3 A_CheckThrowBomb2
    Loop
    FTH8 G 6 A_CheckThrowBomb
    FTH8 I 4 A_CheckThrowBomb
    FTH8 H 6 A_CheckThrowBomb
    FTH8 I 4 A_CheckThrowBomb
    FTH8 G 6 A_CheckThrowBomb
    FTH8 I 3 A_CheckThrowBomb
    Wait
  Death:
	CFCF Q 0 Bright A_AlertMonsters
	CFCF Q 0 Bright A_SetTranslucent(1,1)
	CFCF Q 0 Bright A_JumpIfInTargetInventory("PhilosopherStoneTracker",1,"Powered")
	CFCF Q 0 Bright A_Explode (ACS_NamedExecuteWithResult("WOC Player Scale", 128, CURRENTLEVEL, 0, WOCTARGET), 128, 1)
	CFCF Q 1 Bright A_NoGravity
	CFCF QQQ 1 Bright A_SpawnItemEx("FlailPuffParticleFXSpawner")
    CFCF R 0 Bright A_Scream
	CFCF RRR 1 Bright A_SpawnItemEx("FlailPuffParticleFXSpawner")
	CFCF S 0 Bright A_SpawnItemEx ("WaterSeeker", 0.0, 0.0, 0.0, 12.0, 0.0, 0.0,   0.0, 32, 0, PET5TID+ACS_ExecuteWithResult(WOC_DECORATE,STATS,PLAYERNUM,WOCTARGET)) //
    CFCF S 0 Bright A_SpawnItemEx ("WaterSeeker", 0.0, 0.0, 0.0, 12.0, 0.0, 0.0,  16.0, 32, 0, PET5TID+ACS_ExecuteWithResult(WOC_DECORATE,STATS,PLAYERNUM,WOCTARGET))
    CFCF S 0 Bright A_SpawnItemEx ("WaterSeeker", 0.0, 0.0, 0.0, 12.0, 0.0, 0.0,  32.0, 32, 0, PET5TID+ACS_ExecuteWithResult(WOC_DECORATE,STATS,PLAYERNUM,WOCTARGET)) //
    CFCF S 0 Bright A_SpawnItemEx ("WaterSeeker", 0.0, 0.0, 0.0, 12.0, 0.0, 0.0,  48.0, 32, 0, PET5TID+ACS_ExecuteWithResult(WOC_DECORATE,STATS,PLAYERNUM,WOCTARGET))
    CFCF S 0 Bright A_SpawnItemEx ("WaterSeeker", 0.0, 0.0, 0.0, 12.0, 0.0, 0.0,  64.0, 32, 0, PET5TID+ACS_ExecuteWithResult(WOC_DECORATE,STATS,PLAYERNUM,WOCTARGET)) //
    CFCF S 0 Bright A_SpawnItemEx ("WaterSeeker", 0.0, 0.0, 0.0, 12.0, 0.0, 0.0,  80.0, 32, 0, PET5TID+ACS_ExecuteWithResult(WOC_DECORATE,STATS,PLAYERNUM,WOCTARGET))
    CFCF S 0 Bright A_SpawnItemEx ("WaterSeeker", 0.0, 0.0, 0.0, 12.0, 0.0, 0.0,  96.0, 32, 0, PET5TID+ACS_ExecuteWithResult(WOC_DECORATE,STATS,PLAYERNUM,WOCTARGET)) //
    CFCF S 0 Bright A_SpawnItemEx ("WaterSeeker", 0.0, 0.0, 0.0, 12.0, 0.0, 0.0, 112.0, 32, 0, PET5TID+ACS_ExecuteWithResult(WOC_DECORATE,STATS,PLAYERNUM,WOCTARGET))
    CFCF S 0 Bright A_SpawnItemEx ("WaterSeeker", 0.0, 0.0, 0.0, 12.0, 0.0, 0.0, 128.0, 32, 0, PET5TID+ACS_ExecuteWithResult(WOC_DECORATE,STATS,PLAYERNUM,WOCTARGET)) //
    CFCF S 0 Bright A_SpawnItemEx ("WaterSeeker", 0.0, 0.0, 0.0, 12.0, 0.0, 0.0, 144.0, 32, 0, PET5TID+ACS_ExecuteWithResult(WOC_DECORATE,STATS,PLAYERNUM,WOCTARGET))
    CFCF S 0 Bright A_SpawnItemEx ("WaterSeeker", 0.0, 0.0, 0.0, 12.0, 0.0, 0.0, 160.0, 32, 0, PET5TID+ACS_ExecuteWithResult(WOC_DECORATE,STATS,PLAYERNUM,WOCTARGET)) //
    CFCF S 0 Bright A_SpawnItemEx ("WaterSeeker", 0.0, 0.0, 0.0, 12.0, 0.0, 0.0, 176.0, 32, 0, PET5TID+ACS_ExecuteWithResult(WOC_DECORATE,STATS,PLAYERNUM,WOCTARGET))
    CFCF S 0 Bright A_SpawnItemEx ("WaterSeeker", 0.0, 0.0, 0.0, 12.0, 0.0, 0.0, 192.0, 32, 0, PET5TID+ACS_ExecuteWithResult(WOC_DECORATE,STATS,PLAYERNUM,WOCTARGET)) //
    CFCF S 0 Bright A_SpawnItemEx ("WaterSeeker", 0.0, 0.0, 0.0, 12.0, 0.0, 0.0, 208.0, 32, 0, PET5TID+ACS_ExecuteWithResult(WOC_DECORATE,STATS,PLAYERNUM,WOCTARGET))
    CFCF S 0 Bright A_SpawnItemEx ("WaterSeeker", 0.0, 0.0, 0.0, 12.0, 0.0, 0.0, 224.0, 32, 0, PET5TID+ACS_ExecuteWithResult(WOC_DECORATE,STATS,PLAYERNUM,WOCTARGET)) //
    CFCF S 0 Bright A_SpawnItemEx ("WaterSeeker", 0.0, 0.0, 0.0, 12.0, 0.0, 0.0, 240.0, 32, 0, PET5TID+ACS_ExecuteWithResult(WOC_DECORATE,STATS,PLAYERNUM,WOCTARGET))
	CFCF SSSS 1 Bright A_SpawnItemEx("FlailPuffParticleFXSpawner")
    CFCF T 3 Bright
    CFCF U 4 Bright
    CFCF W 3 Bright
    CFCF X 4 Bright
    CFCF Z 3 Bright
    Stop
  Powered:
    CFCF Q 0 Bright A_Explode (ACS_NamedExecuteWithResult("WOC Player Scale", 160, CURRENTLEVEL, 0, WOCTARGET), 128, 1)
	CFCF Q 1 Bright A_NoGravity
	CFCF QQQ 1 Bright A_SpawnItemEx("FlailPuffParticleFXSpawner")
    CFCF R 0 Bright A_Scream
	CFCF RRR 1 Bright A_SpawnItemEx("FlailPuffParticleFXSpawner")
	CFCF S 0 Bright A_SpawnItemEx ("PoweredWaterSeeker", 0.0, 0.0, 0.0, 12.0, 0.0, 0.0,   0.0, 32, 0, PET5TID+ACS_ExecuteWithResult(WOC_DECORATE,STATS,PLAYERNUM,WOCTARGET)) //
    CFCF S 0 Bright A_SpawnItemEx ("PoweredWaterSeeker", 0.0, 0.0, 0.0, 12.0, 0.0, 0.0,  16.0, 32, 0, PET5TID+ACS_ExecuteWithResult(WOC_DECORATE,STATS,PLAYERNUM,WOCTARGET))
    CFCF S 0 Bright A_SpawnItemEx ("PoweredWaterSeeker", 0.0, 0.0, 0.0, 12.0, 0.0, 0.0,  32.0, 32, 0, PET5TID+ACS_ExecuteWithResult(WOC_DECORATE,STATS,PLAYERNUM,WOCTARGET)) //
    CFCF S 0 Bright A_SpawnItemEx ("PoweredWaterSeeker", 0.0, 0.0, 0.0, 12.0, 0.0, 0.0,  48.0, 32, 0, PET5TID+ACS_ExecuteWithResult(WOC_DECORATE,STATS,PLAYERNUM,WOCTARGET))
    CFCF S 0 Bright A_SpawnItemEx ("PoweredWaterSeeker", 0.0, 0.0, 0.0, 12.0, 0.0, 0.0,  64.0, 32, 0, PET5TID+ACS_ExecuteWithResult(WOC_DECORATE,STATS,PLAYERNUM,WOCTARGET)) //
    CFCF S 0 Bright A_SpawnItemEx ("PoweredWaterSeeker", 0.0, 0.0, 0.0, 12.0, 0.0, 0.0,  80.0, 32, 0, PET5TID+ACS_ExecuteWithResult(WOC_DECORATE,STATS,PLAYERNUM,WOCTARGET))
    CFCF S 0 Bright A_SpawnItemEx ("PoweredWaterSeeker", 0.0, 0.0, 0.0, 12.0, 0.0, 0.0,  96.0, 32, 0, PET5TID+ACS_ExecuteWithResult(WOC_DECORATE,STATS,PLAYERNUM,WOCTARGET)) //
    CFCF S 0 Bright A_SpawnItemEx ("PoweredWaterSeeker", 0.0, 0.0, 0.0, 12.0, 0.0, 0.0, 112.0, 32, 0, PET5TID+ACS_ExecuteWithResult(WOC_DECORATE,STATS,PLAYERNUM,WOCTARGET))
    CFCF S 0 Bright A_SpawnItemEx ("PoweredWaterSeeker", 0.0, 0.0, 0.0, 12.0, 0.0, 0.0, 128.0, 32, 0, PET5TID+ACS_ExecuteWithResult(WOC_DECORATE,STATS,PLAYERNUM,WOCTARGET)) //
    CFCF S 0 Bright A_SpawnItemEx ("PoweredWaterSeeker", 0.0, 0.0, 0.0, 12.0, 0.0, 0.0, 144.0, 32, 0, PET5TID+ACS_ExecuteWithResult(WOC_DECORATE,STATS,PLAYERNUM,WOCTARGET))
    CFCF S 0 Bright A_SpawnItemEx ("PoweredWaterSeeker", 0.0, 0.0, 0.0, 12.0, 0.0, 0.0, 160.0, 32, 0, PET5TID+ACS_ExecuteWithResult(WOC_DECORATE,STATS,PLAYERNUM,WOCTARGET)) //
    CFCF S 0 Bright A_SpawnItemEx ("PoweredWaterSeeker", 0.0, 0.0, 0.0, 12.0, 0.0, 0.0, 176.0, 32, 0, PET5TID+ACS_ExecuteWithResult(WOC_DECORATE,STATS,PLAYERNUM,WOCTARGET))
    CFCF S 0 Bright A_SpawnItemEx ("PoweredWaterSeeker", 0.0, 0.0, 0.0, 12.0, 0.0, 0.0, 192.0, 32, 0, PET5TID+ACS_ExecuteWithResult(WOC_DECORATE,STATS,PLAYERNUM,WOCTARGET)) //
    CFCF S 0 Bright A_SpawnItemEx ("PoweredWaterSeeker", 0.0, 0.0, 0.0, 12.0, 0.0, 0.0, 208.0, 32, 0, PET5TID+ACS_ExecuteWithResult(WOC_DECORATE,STATS,PLAYERNUM,WOCTARGET))
    CFCF S 0 Bright A_SpawnItemEx ("PoweredWaterSeeker", 0.0, 0.0, 0.0, 12.0, 0.0, 0.0, 224.0, 32, 0, PET5TID+ACS_ExecuteWithResult(WOC_DECORATE,STATS,PLAYERNUM,WOCTARGET)) //
    CFCF S 0 Bright A_SpawnItemEx ("PoweredWaterSeeker", 0.0, 0.0, 0.0, 12.0, 0.0, 0.0, 240.0, 32, 0, PET5TID+ACS_ExecuteWithResult(WOC_DECORATE,STATS,PLAYERNUM,WOCTARGET))
	CFCF SSSS 1 Bright A_SpawnItemEx("FlailPuffParticleFXSpawner")
    CFCF T 3 Bright
    CFCF U 4 Bright
    CFCF W 3 Bright
    CFCF X 4 Bright
    CFCF Z 3 Bright
    Stop
  }
}

ACTOR WaterSeeker
{
  +ISMONSTER
  +LOOKALLAROUND
  +DONTBLAST
  +DONTSPLASH
  +NODAMAGETHRUST +DONTBLAST
  +FOILINVUL
  +FRIENDLY
  -COUNTKILL
  +ICEDAMAGE
  -CANNOTPUSH
  Species "Player"
  height 8
  radius 8
  speed 24
  meleerange 32
  renderstyle Add
  alpha 0.5
  states
  {
  Spawn:
    WSSP A 0
    WSSP A 0 A_JumpIfInventory("WaterSeekerTimer",45,"Death")
	WSSP A 0 A_GiveInventory("WaterSeekerTimer",1)
	WSSP A 0 A_Look
    WSSP A 1 A_Wander
	WSSP B 0 A_Look
    WSSP B 1 A_Wander
	WSSP C 0 A_Look
    WSSP C 1 A_Wander
	WSSP D 0 A_Look
    WSSP D 1 A_Wander
	WSSP E 0 A_Look
    WSSP E 1 A_Wander
	WSSP F 0 A_Look
    WSSP F 1 A_Wander
	WSSP G 0 A_Look
    WSSP G 1 A_Wander
    loop
  See:
	WSSP A 0 A_JumpIfInventory("WaterSeekerTimer",45,"Death")
	WSSP A 0 A_GiveInventory("WaterSeekerTimer",1)
	WSSP ABCDEFG 1 A_Chase ("Attack", 0, 0)
    loop
  Attack:
    WSSP A 1 A_CustomMeleeAttack(ACS_NamedExecuteWithResult("WOC Player Scale", FRandom(1,2), CURRENTLEVEL, 0, MASTERPLAYER), "", "", "Ice")
    Goto See
  Death:
    TNT1 A 1
    stop
  }
}

Actor PoweredWaterSeeker : WaterSeeker
{
  states
  {
  Spawn:
    WSSP A 0
    WSSP A 0 A_JumpIfInventory("WaterSeekerTimer",45,"Death")
	WSSP A 0 A_GiveInventory("WaterSeekerTimer",1)
	WSSP A 0 A_Look
    WSSP A 1 A_Wander
	WSSP B 0 A_Look
    WSSP B 1 A_Wander
	WSSP C 0 A_Look
    WSSP C 1 A_Wander
	WSSP D 0 A_Look
    WSSP D 1 A_Wander
	WSSP E 0 A_Look
    WSSP E 1 A_Wander
	WSSP F 0 A_Look
    WSSP F 1 A_Wander
	WSSP G 0 A_Look
    WSSP G 1 A_Wander
    loop
  See:
	WSSP A 0 A_JumpIfInventory("WaterSeekerTimer",45,"Death")
	WSSP A 0 A_GiveInventory("WaterSeekerTimer",1)
	WSSP ABCDEFG 1 A_Chase ("Attack", 0, 0)
    loop
  Attack:
    WSSP A 1 A_CustomMeleeAttack((ACS_NamedExecuteWithResult("WOC Player Scale", FRandom(1,2), CURRENTLEVEL, 0, MASTERPLAYER))*1.25, "", "", "Ice")
    Goto See
  Death:
    TNT1 A 1
    stop
  }
}

Actor WaterSeekerTimer : Inventory { Inventory.MaxAmount 45 }

//////////////////////////////////////////////////// MAROON shootable explosive

ACTOR ArtiMaroonFlask : ArtiEmptyFlask
{
	Inventory.Icon "ARTIFLA9"
	Inventory.DefMaxAmount
	Inventory.PickupMessage "Maroon Flask"
	Tag "Maroon Flask"
	States
	{
	Spawn:
		FLA9 A -1
		Stop
	Pickup:
		TNT1 A 0 A_JumpIfInventory("ArtiMaroonFlask", ACS_ExecuteWithResult(WOC_DECORATE,STATS,ITEMCAP,ACTIVATOR),"Failed")
		TNT1 A 0 ACS_ExecuteWithResult(WOC_DECORATE,STATS,ITEMCAP,ACTIVATOR)
		Stop
	Failed:
		TNT1 A 0
		Fail
	Use:
		TNT1 A 0 A_GiveInventory("ShadowWalkAttackCheck",1)
		TNT1 A 0 A_SpawnItemEx ("MaroonBomb", 40.0, 0.0, 8.0, 0.0, 0.0, 0.0, 0.0, 32, 0)
		Stop
	}
}

ACTOR MaroonBomb
{
  Health 5
  Radius 8
  Height 12
  DamageType "Fire"
  Damage (1)
  +CANPASS
  +SLIDESONWALLS
  +DONTBLAST
  +MISSILE
  +NOGRAVITY
  +MTHRUSPECIES /*+NODAMAGETHRUST*/ +DONTBLAST
  +THRUGHOST
  +FOILINVUL
  +DONTREFLECT
  +FORCERADIUSDMG
  DeathSound "FlechetteExplode"
  Obituary "%o went boom."
  States
  {
  Spawn:
    FLA9 B -1
    Stop
  Death:
	CFCF Q 0 Bright A_AlertMonsters
	CFCF Q 0 Bright A_SetTranslucent(1,1)
	CFCF Q 0 Bright A_JumpIfInTargetInventory("PhilosopherStoneTracker",1,"Powered")
	CFCF Q 0 Bright A_Explode (ACS_NamedExecuteWithResult("WOC Player Scale", 128, CURRENTLEVEL, 0, WOCTARGET), 128, 1)
	CFCF Q 1 Bright A_NoGravity
	CFCF QQQ 1 Bright A_SpawnItemEx("FlailPuffParticleFXSpawner")
    CFCF R 0 Bright A_Scream
	CFCF RRR 1 Bright A_SpawnItemEx("FlailPuffParticleFXSpawner")
	CFCF SSSS 1 Bright A_SpawnItemEx("FlailPuffParticleFXSpawner")
    CFCF T 3 Bright
    CFCF U 4 Bright
    CFCF W 3 Bright
    CFCF X 4 Bright
    CFCF Z 3 Bright
    Stop
  Powered:
    CFCF Q 0 Bright A_Explode (ACS_NamedExecuteWithResult("WOC Player Scale", 160, CURRENTLEVEL, 0, WOCTARGET), 128, 1)
	CFCF Q 1 Bright A_NoGravity
	CFCF QQQ 1 Bright A_SpawnItemEx("FlailPuffParticleFXSpawner")
    CFCF R 0 Bright A_Scream
	CFCF RRR 1 Bright A_SpawnItemEx("FlailPuffParticleFXSpawner")
	CFCF SSSS 1 Bright A_SpawnItemEx("FlailPuffParticleFXSpawner")
    CFCF T 3 Bright
    CFCF U 4 Bright
    CFCF W 3 Bright
    CFCF X 4 Bright
    CFCF Z 3 Bright
    Stop
  }
}

//////////////////////////////////////////////////// Tan a catalyst potion (couldn't figure out anything D:)

ACTOR ArtiTanFlask : ArtiEmptyFlask
{
	Inventory.Icon "ARTIFL10"
	Inventory.DefMaxAmount
	Inventory.PickupMessage "Tan Flask"
	Tag "Tan Flask"
	States
	{
	Spawn:
		FL10 A -1
		Stop
	Pickup:
		TNT1 A 0 A_JumpIfInventory("ArtiTanFlask", ACS_ExecuteWithResult(WOC_DECORATE,STATS,ITEMCAP,ACTIVATOR),"Failed")
		TNT1 A 0 ACS_ExecuteWithResult(WOC_DECORATE,STATS,ITEMCAP,ACTIVATOR)
		Stop
	Failed:
		TNT1 A 0
		Fail
	Use:
		TNT1 A 0 A_GiveInventory("ShadowWalkAttackCheck",1)
		TNT1 A 0 A_FireCustomMissile ("TanBomb", 0, 0, 0, 5)
		Stop
	}
}

ACTOR TanBomb : ThrowingBomb
{
  Speed 28
  BounceCount 1
  +THRUGHOST
  +WINDTHRUST
  +MTHRUSPECIES +NODAMAGETHRUST +DONTBLAST
  +FOILINVUL
  States
  {
  Spawn:
    FT10 A 4 A_CheckThrowBomb
    FT10 BCDE 3 A_CheckThrowBomb
    FT10 F 3 A_CheckThrowBomb2
    Loop
    FT10 G 6 A_CheckThrowBomb
    FT10 F 4 A_CheckThrowBomb
    FT10 H 6 A_CheckThrowBomb
    FT10 F 4 A_CheckThrowBomb
    FT10 G 6 A_CheckThrowBomb
    FT10 F 3 A_CheckThrowBomb
    Wait
  Death:
	TNT1 A 0 Bright A_AlertMonsters
	TNT1 A 0 A_JumpIfInTargetInventory("PhilosopherStoneTracker",1,"Powered")
	TNT1 A 0 A_CustomMissile("GlassShard7",0,0,frandom(0,359),6,frandom(0,359))
	TNT1 AAA 0 A_CustomMissile("GlassShard6",0,0,frandom(0,359),6,frandom(0,359))
	TNT1 AAA 0 A_CustomMissile("GlassShard5",0,0,frandom(0,359),6,frandom(0,359))
	TNT1 AAA 0 A_CustomMissile("GlassShard4",0,0,frandom(0,359),6,frandom(0,359))
	TNT1 AAA 0 A_CustomMissile("GlassShard3",0,0,frandom(0,359),6,frandom(0,359))
	TNT1 AAA 0 A_CustomMissile("GlassShard2",0,0,frandom(0,359),6,frandom(0,359))
	TNT1 AAAA 0 A_CustomMissile("GlassShard1",0,0,frandom(0,359),6,frandom(0,359))
    Stop
  Powered:
    TNT1 A 0 A_CustomMissile("PoweredGlassShard7",0,0,frandom(0,359),6,frandom(0,359))
	TNT1 AAA 0 A_CustomMissile("PoweredGlassShard6",0,0,frandom(0,359),6,frandom(0,359))
	TNT1 AAA 0 A_CustomMissile("PoweredGlassShard5",0,0,frandom(0,359),6,frandom(0,359))
	TNT1 AAA 0 A_CustomMissile("PoweredGlassShard4",0,0,frandom(0,359),6,frandom(0,359))
	TNT1 AAA 0 A_CustomMissile("PoweredGlassShard3",0,0,frandom(0,359),6,frandom(0,359))
	TNT1 AAA 0 A_CustomMissile("PoweredGlassShard2",0,0,frandom(0,359),6,frandom(0,359))
	TNT1 AAAA 0 A_CustomMissile("PoweredGlassShard1",0,0,frandom(0,359),6,frandom(0,359))
    Stop
  }
}

ACTOR SlugShard
{
	radius 3
	height 6
	Alpha		1
	Mass		0  
	BounceFactor 0.55
	+missile
	+doombounce
	+FLOORCLIP
	+DONTSPLASH
	+NOTELEPORT
	-SOLID
	+CLIENTSIDEONLY
	Gravity 1
	Health 3
	Scale 0.3
	Speed .2
	RenderStyle Translucent
	States
	{
	Spawn:
		SHRD NLMNLMNLMNLMNLMNLMLMNLMNLMNLMNLMNLMNLM 2
		goto Death
	Death:
	    SHRD NLMNLMNLMN 1 A_FadeOut(0.1)
		TNT1 A 0
		Stop
	}
}

ACTOR GlassShard1
{
   Radius 5
   Height 5
   Damage (ACS_NamedExecuteWithResult("WOC Player Scale", FRandom(2,16), CURRENTLEVEL, 0, WOCTARGET))
   Damagetype "Physical"
   Obituary "%k flung glass into %o's face."
   SeeSound "flechette/caltink"
   Speed 11
   Scale 0.4
   Alpha 0.95
   RenderStyle Translucent
   +MISSILE
   +DOOMBOUNCE
   +THRUGHOST
   +WINDTHRUST
   +MTHRUSPECIES +NODAMAGETHRUST +DONTBLAST
   +FOILINVUL
   +DONTREFLECT
   States
   {
   Spawn:
	  GLAS A 0 A_PlaySound("godcan/silence")
      GLAS A 0 A_Gravity
      GLAS AA 5
      goto Spawn+1
   Death:
      GLAS AAAAAA 5 A_FadeOut(0.05)
      GLAS A 2 A_SpawnItem("GlassShard1Attack")
      Stop
   }
}

ACTOR GlassShard1Attack
{
   Radius 5
   Height 5
   Health 3
   Damage (ACS_NamedExecuteWithResult("WOC Player Scale", FRandom(2,16), CURRENTLEVEL, 0, WOCTARGET))
   Damagetype "Physical"
   Obituary "%k snared %o and left %h for dead."
   SeeSound "flechette/caltink"
   DeathSound "flechette/calbreak"
   Speed 0
   Scale 0.4
   Alpha 0.55
   RenderStyle Translucent
   +FIXMAPTHINGPOS
   +NOEXTREMEDEATH
   +DOOMBOUNCE
   +NORADIUSDMG
   +NOBLOOD
   +THRUGHOST
   +WINDTHRUST
   //+SHOOTABLE
   +WINDTHRUST
   +MTHRUSPECIES +NODAMAGETHRUST +DONTBLAST
   //+NOTELEFRAG
   +MISSILE
   +FOILINVUL
   +DONTREFLECT
   States
   {
   Spawn:
      //GLAS A 0 A_Gravity
      GLAS AAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAA 5 A_Gravity
	  Goto TimeUp
   Death:
      GLAS A 0
      GLAS A 5
      GLAS A 0 A_SpawnDebris("SlugShard")
      Stop
   TimeUp:
      GLAS AAAAAAAAAAA 1 A_FadeOut(0.05)
	  Stop
   }
}

ACTOR GlassShard2
{
   Radius 5
   Height 5
   Damage (ACS_NamedExecuteWithResult("WOC Player Scale", FRandom(2,16), CURRENTLEVEL, 0, WOCTARGET))
   Damagetype "Physical"
   Obituary "%k flung glass into %o's face."
   SeeSound "flechette/caltink"
   Speed 10
   Scale 0.4
   Alpha 0.95
   RenderStyle Translucent
   +MISSILE
   +DOOMBOUNCE
   +THRUGHOST
   +WINDTHRUST
   +MTHRUSPECIES +NODAMAGETHRUST +DONTBLAST
   +FOILINVUL
   +DONTREFLECT
   States
   {
   Spawn:
	  GLAS A 0 A_PlaySound("godcan/silence")
      GLAS B 0 A_Gravity
      GLAS BB 5
      goto Spawn+1
   Death:
      GLAS BBBBBB 5 A_FadeOut(0.05)
      GLAS B 2 A_SpawnItem("GlassShard2Attack")
      Stop
   }
}

ACTOR GlassShard2Attack
{
   Radius 5
   Height 5
   Health 3
   Damage (ACS_NamedExecuteWithResult("WOC Player Scale", FRandom(2,16), CURRENTLEVEL, 0, WOCTARGET))
   Damagetype "Physical"
   Obituary "%k snared %o and left %h for dead."
   SeeSound "flechette/caltink"
   DeathSound "flechette/calbreak"
   Speed 0
   Scale 0.4
   Alpha 0.55
   RenderStyle Translucent
   +FIXMAPTHINGPOS
   +NOEXTREMEDEATH
   +DOOMBOUNCE
   +NORADIUSDMG
   +NOBLOOD
   //+SHOOTABLE
   +WINDTHRUST
	+MTHRUSPECIES +NODAMAGETHRUST +DONTBLAST
   //+NOTELEFRAG
   +THRUGHOST
   +WINDTHRUST
   +MISSILE
   +FOILINVUL
   +DONTREFLECT
   States
   {
   Spawn:
      //GLAS B 0 A_Gravity
      GLAS BBBBBBBBBBBBBBBBBBBBBBBBBBBBBBBBBBBBBBBBBBBBBBBBBBBBBBBBBBBBBBBBBBBBBBBBBBBBBBBBBBBBBBBBBBBBBBBBBBBBBBBBBBBBBBBBBBBBBBBBBBBBBBBBBBBBBBBBBBBBBBBBBBBBBBBBBBBBBBBBBBBBBBBBBBBBBBBBBBBBBBBBBBBBBBBBBBBBBBBB 5 A_Gravity
	  Goto TimeUp
   Death:
      GLAS B 0
      GLAS B 5
      GLAS B 0 A_SpawnDebris("SlugShard")
      Stop
   TimeUp:
      GLAS BBBBBBBBBBB 1 A_FadeOut(0.05)
	  Stop
   }
}

ACTOR GlassShard3
{
   Radius 5
   Height 5
   Damage (ACS_NamedExecuteWithResult("WOC Player Scale", FRandom(2,16), CURRENTLEVEL, 0, WOCTARGET))
   Damagetype "Physical"
   Obituary "%k flung glass into %o's face."
   SeeSound "flechette/caltink"
   Speed 11
   Scale 0.4
   Alpha 0.95
   RenderStyle Translucent
   +MISSILE
   +DOOMBOUNCE
   +THRUGHOST
   +WINDTHRUST
   +MTHRUSPECIES +NODAMAGETHRUST +DONTBLAST
   +FOILINVUL
   +DONTREFLECT
   States
   {
   Spawn:
	  GLAS C 0 A_PlaySound("godcan/silence")
      GLAS C 0 A_Gravity
      GLAS CC 5
      goto Spawn+1
   Death:
      GLAS CCCCCC 5 A_FadeOut(0.05)
      GLAS C 2 A_SpawnItem("GlassShard3Attack")
      Stop
   }
}

ACTOR GlassShard3Attack
{
   Radius 5
   Height 5
   Health 3
   Damage (ACS_NamedExecuteWithResult("WOC Player Scale", FRandom(2,16), CURRENTLEVEL, 0, WOCTARGET))
   Damagetype "Physical"
   Obituary "%k snared %o and left %h for dead."
   SeeSound "flechette/caltink"
   DeathSound "flechette/calbreak"
   Speed 0
   Scale 0.4
   Alpha 0.55
   RenderStyle Translucent
   +FIXMAPTHINGPOS
   +NOEXTREMEDEATH
   +DOOMBOUNCE
   +NORADIUSDMG
   +NOBLOOD
   //+SHOOTABLE
   +WINDTHRUST
   +MTHRUSPECIES +NODAMAGETHRUST +DONTBLAST
   //+NOTELEFRAG
   +MISSILE
   +THRUGHOST
   +WINDTHRUST
   +FOILINVUL
   +DONTREFLECT
   States
   {
   Spawn:
      //GLAS C 0 A_Gravity
      GLAS CCCCCCCCCCCCCCCCCCCCCCCCCCCCCCCCCCCCCCCCCCCCCCCCCCCCCCCCCCCCCCCCCCCCCCCCCCCCCCCCCCCCCCCCCCCCCCCCCCCCCCCCCCCCCCCCCCCCCCCCCCCCCCCCCCCCCCCCCCCCCCCCCCCCCCCCCCCCCCCCCCCCCCCCCCCCCCCCCCCCCCCCCCCCCCCCCCCCCCCC 5 A_Gravity
	  Goto TimeUp
   Death:
      GLAS C 0
      GLAS C 5
      GLAS C 0 A_SpawnDebris("SlugShard")
      Stop
   TimeUp:
      GLAS CCCCCCCCCCC 1 A_FadeOut(0.05)
	  Stop
   }
}

ACTOR GlassShard4
{
   Radius 5
   Height 5
   Damage (ACS_NamedExecuteWithResult("WOC Player Scale", FRandom(2,16), CURRENTLEVEL, 0, WOCTARGET))
   Damagetype "Physical"
   Obituary "%k flung glass into %o's face."
   SeeSound "flechette/caltink"
   Speed 10
   Scale 0.4
   Alpha 0.95
   RenderStyle Translucent
   +MISSILE
   +DOOMBOUNCE
   +THRUGHOST
   +WINDTHRUST
   +MTHRUSPECIES +NODAMAGETHRUST +DONTBLAST
   +FOILINVUL
   +DONTREFLECT
   States
   {
   Spawn:
	  GLAS D 0 A_PlaySound("godcan/silence")
      GLAS D 0 A_Gravity
      GLAS DD 5
      goto Spawn+1
   Death:
      GLAS DDDDDD 5 A_FadeOut(0.05)
      GLAS D 2 A_SpawnItem("GlassShard4Attack")
      Stop
   }
}

ACTOR GlassShard4Attack
{
   Radius 5
   Height 5
   Health 3
   Damage (ACS_NamedExecuteWithResult("WOC Player Scale", FRandom(2,16), CURRENTLEVEL, 0, WOCTARGET))
   Damagetype "Physical"
   Obituary "%k snared %o and left %h for dead."
   SeeSound "flechette/caltink"
   DeathSound "flechette/calbreak"
   Speed 0
   Scale 0.4
   Alpha 0.55
   RenderStyle Translucent
   +FIXMAPTHINGPOS
   +NOEXTREMEDEATH
   +DOOMBOUNCE
   +NORADIUSDMG
   +NOBLOOD
   //+SHOOTABLE
   +WINDTHRUST
   +MTHRUSPECIES +NODAMAGETHRUST +DONTBLAST
   //+NOTELEFRAG
   +MISSILE
   +THRUGHOST
   +WINDTHRUST
   +FOILINVUL
   +DONTREFLECT
   States
   {
   Spawn:
      //GLAS D 0 A_Gravity
      GLAS DDDDDDDDDDDDDDDDDDDDDDDDDDDDDDDDDDDDDDDDDDDDDDDDDDDDDDDDDDDDDDDDDDDDDDDDDDDDDDDDDDDDDDDDDDDDDDDDDDDDDDDDDDDDDDDDDDDDDDDDDDDDDDDDDDDDDDDDDDDDDDDDDDDDDDDDDDDDDDDDDDDDDDDDDDDDDDDDDDDDDDDDDDDDDDDDDDDDDDDD 5 A_Gravity
	  Goto TimeUp
   Death:
      GLAS D 0
      GLAS D 5
      GLAS D 0 A_SpawnDebris("SlugShard")
      Stop
   TimeUp:
      GLAS DDDDDDDDDDD 1 A_FadeOut(0.05)
	  Stop
   }
}

ACTOR GlassShard5
{
   Radius 5
   Height 5
   Damage (ACS_NamedExecuteWithResult("WOC Player Scale", FRandom(2,16), CURRENTLEVEL, 0, WOCTARGET))
   Damagetype "Physical"
   Obituary "%k flung glass into %o's face."
   SeeSound "flechette/caltink"
   Speed 11
   Scale 0.4
   Alpha 0.95
   RenderStyle Translucent
   +MISSILE
   +DOOMBOUNCE
   +THRUGHOST
   +WINDTHRUST
   +MTHRUSPECIES +NODAMAGETHRUST +DONTBLAST
   +WINDTHRUST
   +FOILINVUL
   +DONTREFLECT
   States
   {
   Spawn:
	  GLAS E 0 A_PlaySound("godcan/silence")
      GLAS E 0 A_Gravity
      GLAS EE 5
      goto Spawn+1
   Death:
      GLAS EEEEEE 5 A_FadeOut(0.05)
      GLAS E 2 A_SpawnItem("GlassShard5Attack")
      Stop
   }
}

ACTOR GlassShard5Attack
{
   Radius 5
   Height 5
   Health 3
   Damage (ACS_NamedExecuteWithResult("WOC Player Scale", FRandom(2,16), CURRENTLEVEL, 0, WOCTARGET))
   Damagetype "Physical"
   Obituary "%k snared %o and left %h for dead."
   SeeSound "flechette/caltink"
   DeathSound "flechette/calbreak"
   Speed 0
   Scale 0.4
   Alpha 0.55
   RenderStyle Translucent
   +FIXMAPTHINGPOS
   +NOEXTREMEDEATH
   +DOOMBOUNCE
   +NORADIUSDMG
   +NOBLOOD
   //+SHOOTABLE
   +WINDTHRUST
   +MTHRUSPECIES +NODAMAGETHRUST +DONTBLAST
   //+NOTELEFRAG
   +MISSILE
   +THRUGHOST
   +WINDTHRUST
   +FOILINVUL
   +DONTREFLECT
   States
   {
   Spawn:
      //GLAS E 0 A_Gravity
      GLAS EEEEEEEEEEEEEEEEEEEEEEEEEEEEEEEEEEEEEEEEEEEEEEEEEEEEEEEEEEEEEEEEEEEEEEEEEEEEEEEEEEEEEEEEEEEEEEEEEEEEEEEEEEEEEEEEEEEEEEEEEEEEEEEEEEEEEEEEEEEEEEEEEEEEEEEEEEEEEEEEEEEEEEEEEEEEEEEEEEEEEEEEEEEEEEEEEEEEEEEE 5 A_Gravity
	  Goto TimeUp
   Death:
      GLAS E 0
      GLAS E 5
      GLAS E 0 A_SpawnDebris("SlugShard")
      Stop
   TimeUp:
      GLAS EEEEEEEEEEE 1 A_FadeOut(0.05)
	  Stop
   }
}

ACTOR GlassShard6
{
   Radius 5
   Height 5
   Damage (ACS_NamedExecuteWithResult("WOC Player Scale", FRandom(2,16), CURRENTLEVEL, 0, WOCTARGET))
   Damagetype "Physical"
   Obituary "%k flung glass into %o's face."
   SeeSound "flechette/caltink"
   Speed 10
   Scale 0.4
   Alpha 0.95
   RenderStyle Translucent
   +MISSILE
   +DOOMBOUNCE
   +THRUGHOST
   +WINDTHRUST
   +MTHRUSPECIES +NODAMAGETHRUST +DONTBLAST
   +WINDTHRUST
   +FOILINVUL
   +DONTREFLECT
   States
   {
   Spawn:
	  GLAS F 0 A_PlaySound("godcan/silence")
      GLAS F 0 A_Gravity
      GLAS FF 5
      goto Spawn+1
   Death:
      GLAS FFFFFF 5 A_FadeOut(0.05)
      GLAS F 2 A_SpawnItem("GlassShard6Attack")
      Stop
   }
}

ACTOR GlassShard6Attack
{
	Radius 5
	Height 5
	Health 3
	Damage (ACS_NamedExecuteWithResult("WOC Player Scale", FRandom(2,16), CURRENTLEVEL, 0, WOCTARGET))
	Damagetype "Physical"
	Obituary "%k snared %o and left %h for dead."
	SeeSound "flechette/caltink"
	DeathSound "flechette/calbreak"
	Speed 0
	Scale 0.4
	Alpha 0.55
	RenderStyle Translucent
	+FIXMAPTHINGPOS
	+NOEXTREMEDEATH
	+DOOMBOUNCE
	+NORADIUSDMG
	+NOBLOOD
	//+SHOOTABLE
	+WINDTHRUST
	+THRUGHOST
	+WINDTHRUST
	+MTHRUSPECIES +NODAMAGETHRUST +DONTBLAST
	//+NOTELEFRAG
	+MISSILE
	+FOILINVUL
	+DONTREFLECT
	States
	{
	Spawn:
		//GLAS F 0 A_Gravity
		GLAS FFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFF 5 A_Gravity
		Goto TimeUp
	Death:
		GLAS F 0
		GLAS F 5
		GLAS F 0 A_SpawnDebris("SlugShard")
		Stop
	TimeUp:
		GLAS FFFFFFFFFFF 1 A_FadeOut(0.05)
		Stop
	}
}

ACTOR GlassShard7
{
	Radius 5
	Height 5
	Damage (ACS_NamedExecuteWithResult("WOC Player Scale", FRandom(2,16), CURRENTLEVEL, 0, WOCTARGET))
	Damagetype "Physical"
	Obituary "%k flung glass into %o's face."
	SeeSound "flechette/caltink"
	Speed 9
	Scale 0.4
	Alpha 0.95
	RenderStyle Translucent
	+MISSILE
	+DOOMBOUNCE
	+THRUGHOST
	+WINDTHRUST
	+MTHRUSPECIES +NODAMAGETHRUST +DONTBLAST
	+WINDTHRUST
	+FOILINVUL
	+DONTREFLECT
	States
	{
	Spawn:
		GLAS G 0 A_PlaySound("godcan/silence")
		GLAS G 0 A_Gravity
		GLAS GG 5
		goto Spawn+1
	Death:
		GLAS GGGGGG 5 A_FadeOut(0.05)
		GLAS G 2 A_SpawnItem("GlassShard7Attack")
		Stop
	}
}

ACTOR GlassShard7Attack
{
	Radius 5
	Height 5
	Health 3
	Damage (ACS_NamedExecuteWithResult("WOC Player Scale", FRandom(2,16), CURRENTLEVEL, 0, WOCTARGET))
	Damagetype "Physical"
	Obituary "%k snared %o and left %h for dead."
	SeeSound "flechette/caltink"
	DeathSound "flechette/calbreak"
	Speed 0
	Scale 0.4
	Alpha 0.55
	RenderStyle Translucent
	+FIXMAPTHINGPOS
	+NOEXTREMEDEATH
	+DOOMBOUNCE
	+NORADIUSDMG
	+NOBLOOD
	//+SHOOTABLE
	+WINDTHRUST
	+THRUGHOST
	+WINDTHRUST
	+MTHRUSPECIES +NODAMAGETHRUST +DONTBLAST
	//+NOTELEFRAG
	+MISSILE
	+FOILINVUL
	+DONTREFLECT
	States
	{
	Spawn:
	//GLAS G 0 A_Gravity
		GLAS GGGGGGGGGGGGGGGGGGGGGGGGGGGGGGGGGGGGGGGGGGGGGGGGGGGGGGGGGGGGGGGGGGGGGGGGGGGGGGGGGGGGGGGGGGGGGGGGGGGGGGGGGGGGGGGGGGGGGGGGGGGGGGGGGGGGGGGGGGGGGGGGGGGGGGGGGGGGGGGGGGGGGGGGGGGGGGGGGGGGGGGGGGGGGGGGGGGGGGGG 5 A_Gravity
		Goto TimeUp
	Death:
		GLAS G 0
		GLAS G 5
		GLAS G 0 A_SpawnDebris("SlugShard")
		Stop
	TimeUp:
		GLAS GGGGGGGGGGG 1 A_FadeOut(0.05)
		Stop
	}
}

ACTOR PoweredGlassShard1
{
   Radius 5
   Height 5
   Damage ((ACS_NamedExecuteWithResult("WOC Player Scale", FRandom(2,16), CURRENTLEVEL, 0, WOCTARGET))*1.25)
   Damagetype "Physical"
   Obituary "%k flung glass into %o's face."
   SeeSound "flechette/caltink"
   Speed 11
   Scale 0.4
   Alpha 0.95
   RenderStyle Translucent
   +MISSILE
   +DOOMBOUNCE
   +THRUGHOST
   +WINDTHRUST
   +MTHRUSPECIES +NODAMAGETHRUST +DONTBLAST
   +FOILINVUL
   +DONTREFLECT
   States
   {
   Spawn:
	  GLAS A 0 A_PlaySound("godcan/silence")
      GLAS A 0 A_Gravity
      GLAS AA 5
      goto Spawn+1
   Death:
      GLAS AAAAAA 5 A_FadeOut(0.05)
      GLAS A 2 A_SpawnItem("PoweredGlassShard1Attack")
      Stop
   }
}

ACTOR PoweredGlassShard1Attack
{
   Radius 5
   Height 5
   Health 3
   Damage ((ACS_NamedExecuteWithResult("WOC Player Scale", FRandom(2,16), CURRENTLEVEL, 0, WOCTARGET))*1.25)
   Damagetype "Physical"
   Obituary "%k snared %o and left %h for dead."
   SeeSound "flechette/caltink"
   DeathSound "flechette/calbreak"
   Speed 0
   Scale 0.4
   Alpha 0.55
   RenderStyle Translucent
   +FIXMAPTHINGPOS
   +NOEXTREMEDEATH
   +DOOMBOUNCE
   +NORADIUSDMG
   +NOBLOOD
   +THRUGHOST
   +WINDTHRUST
   //+SHOOTABLE
   +WINDTHRUST
   +MTHRUSPECIES +NODAMAGETHRUST +DONTBLAST
   //+NOTELEFRAG
   +MISSILE
   +FOILINVUL
   +DONTREFLECT
   States
   {
   Spawn:
      //GLAS A 0 A_Gravity
      GLAS AAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAA 5 A_Gravity
	  Goto TimeUp
   Death:
      GLAS A 0
      GLAS A 5
      GLAS A 0 A_SpawnDebris("SlugShard")
      Stop
   TimeUp:
      GLAS AAAAAAAAAAA 1 A_FadeOut(0.05)
	  Stop
   }
}

ACTOR PoweredGlassShard2
{
   Radius 5
   Height 5
   Damage ((ACS_NamedExecuteWithResult("WOC Player Scale", FRandom(2,16), CURRENTLEVEL, 0, WOCTARGET))*1.25)
   Damagetype "Physical"
   Obituary "%k flung glass into %o's face."
   SeeSound "flechette/caltink"
   Speed 10
   Scale 0.4
   Alpha 0.95
   RenderStyle Translucent
   +MISSILE
   +DOOMBOUNCE
   +THRUGHOST
   +WINDTHRUST
   +MTHRUSPECIES +NODAMAGETHRUST +DONTBLAST
   +FOILINVUL
   +DONTREFLECT
   States
   {
   Spawn:
	  GLAS A 0 A_PlaySound("godcan/silence")
      GLAS B 0 A_Gravity
      GLAS BB 5
      goto Spawn+1
   Death:
      GLAS BBBBBB 5 A_FadeOut(0.05)
      GLAS B 2 A_SpawnItem("PoweredGlassShard2Attack")
      Stop
   }
}

ACTOR PoweredGlassShard2Attack
{
   Radius 5
   Height 5
   Health 3
   Damage ((ACS_NamedExecuteWithResult("WOC Player Scale", FRandom(2,16), CURRENTLEVEL, 0, WOCTARGET))*1.25)
   Damagetype "Physical"
   Obituary "%k snared %o and left %h for dead."
   SeeSound "flechette/caltink"
   DeathSound "flechette/calbreak"
   Speed 0
   Scale 0.4
   Alpha 0.55
   RenderStyle Translucent
   +FIXMAPTHINGPOS
   +NOEXTREMEDEATH
   +DOOMBOUNCE
   +NORADIUSDMG
   +NOBLOOD
   //+SHOOTABLE
   +WINDTHRUST
	+MTHRUSPECIES +NODAMAGETHRUST +DONTBLAST
   //+NOTELEFRAG
   +THRUGHOST
   +WINDTHRUST
   +MISSILE
   +FOILINVUL
   +DONTREFLECT
   States
   {
   Spawn:
      //GLAS B 0 A_Gravity
      GLAS BBBBBBBBBBBBBBBBBBBBBBBBBBBBBBBBBBBBBBBBBBBBBBBBBBBBBBBBBBBBBBBBBBBBBBBBBBBBBBBBBBBBBBBBBBBBBBBBBBBBBBBBBBBBBBBBBBBBBBBBBBBBBBBBBBBBBBBBBBBBBBBBBBBBBBBBBBBBBBBBBBBBBBBBBBBBBBBBBBBBBBBBBBBBBBBBBBBBBBBB 5 A_Gravity
	  Goto TimeUp
   Death:
      GLAS B 0
      GLAS B 5
      GLAS B 0 A_SpawnDebris("SlugShard")
      Stop
   TimeUp:
      GLAS BBBBBBBBBBB 1 A_FadeOut(0.05)
	  Stop
   }
}

ACTOR PoweredGlassShard3
{
   Radius 5
   Height 5
   Damage ((ACS_NamedExecuteWithResult("WOC Player Scale", FRandom(2,16), CURRENTLEVEL, 0, WOCTARGET))*1.25)
   Damagetype "Physical"
   Obituary "%k flung glass into %o's face."
   SeeSound "flechette/caltink"
   Speed 11
   Scale 0.4
   Alpha 0.95
   RenderStyle Translucent
   +MISSILE
   +DOOMBOUNCE
   +THRUGHOST
   +WINDTHRUST
   +MTHRUSPECIES +NODAMAGETHRUST +DONTBLAST
   +FOILINVUL
   +DONTREFLECT
   States
   {
   Spawn:
	  GLAS C 0 A_PlaySound("godcan/silence")
      GLAS C 0 A_Gravity
      GLAS CC 5
      goto Spawn+1
   Death:
      GLAS CCCCCC 5 A_FadeOut(0.05)
      GLAS C 2 A_SpawnItem("PoweredGlassShard3Attack")
      Stop
   }
}

ACTOR PoweredGlassShard3Attack
{
   Radius 5
   Height 5
   Health 3
   Damage ((ACS_NamedExecuteWithResult("WOC Player Scale", FRandom(2,16), CURRENTLEVEL, 0, WOCTARGET))*1.25)
   Damagetype "Physical"
   Obituary "%k snared %o and left %h for dead."
   SeeSound "flechette/caltink"
   DeathSound "flechette/calbreak"
   Speed 0
   Scale 0.4
   Alpha 0.55
   RenderStyle Translucent
   +FIXMAPTHINGPOS
   +NOEXTREMEDEATH
   +DOOMBOUNCE
   +NORADIUSDMG
   +NOBLOOD
   //+SHOOTABLE
   +WINDTHRUST
   +MTHRUSPECIES +NODAMAGETHRUST +DONTBLAST
   //+NOTELEFRAG
   +MISSILE
   +THRUGHOST
   +WINDTHRUST
   +FOILINVUL
   +DONTREFLECT
   States
   {
   Spawn:
      //GLAS C 0 A_Gravity
      GLAS CCCCCCCCCCCCCCCCCCCCCCCCCCCCCCCCCCCCCCCCCCCCCCCCCCCCCCCCCCCCCCCCCCCCCCCCCCCCCCCCCCCCCCCCCCCCCCCCCCCCCCCCCCCCCCCCCCCCCCCCCCCCCCCCCCCCCCCCCCCCCCCCCCCCCCCCCCCCCCCCCCCCCCCCCCCCCCCCCCCCCCCCCCCCCCCCCCCCCCCC 5 A_Gravity
	  Goto TimeUp
   Death:
      GLAS C 0
      GLAS C 5
      GLAS C 0 A_SpawnDebris("SlugShard")
      Stop
   TimeUp:
      GLAS CCCCCCCCCCC 1 A_FadeOut(0.05)
	  Stop
   }
}

ACTOR PoweredGlassShard4
{
   Radius 5
   Height 5
   Damage ((ACS_NamedExecuteWithResult("WOC Player Scale", FRandom(2,16), CURRENTLEVEL, 0, WOCTARGET))*1.25)
   Damagetype "Physical"
   Obituary "%k flung glass into %o's face."
   SeeSound "flechette/caltink"
   Speed 10
   Scale 0.4
   Alpha 0.95
   RenderStyle Translucent
   +MISSILE
   +DOOMBOUNCE
   +THRUGHOST
   +WINDTHRUST
   +MTHRUSPECIES +NODAMAGETHRUST +DONTBLAST
   +FOILINVUL
   +DONTREFLECT
   States
   {
   Spawn:
	  GLAS D 0 A_PlaySound("godcan/silence")
      GLAS D 0 A_Gravity
      GLAS DD 5
      goto Spawn+1
   Death:
      GLAS DDDDDD 5 A_FadeOut(0.05)
      GLAS D 2 A_SpawnItem("PoweredGlassShard4Attack")
      Stop
   }
}

ACTOR PoweredGlassShard4Attack
{
   Radius 5
   Height 5
   Health 3
   Damage ((ACS_NamedExecuteWithResult("WOC Player Scale", FRandom(2,16), CURRENTLEVEL, 0, WOCTARGET))*1.25)
   Damagetype "Physical"
   Obituary "%k snared %o and left %h for dead."
   SeeSound "flechette/caltink"
   DeathSound "flechette/calbreak"
   Speed 0
   Scale 0.4
   Alpha 0.55
   RenderStyle Translucent
   +FIXMAPTHINGPOS
   +NOEXTREMEDEATH
   +DOOMBOUNCE
   +NORADIUSDMG
   +NOBLOOD
   //+SHOOTABLE
   +WINDTHRUST
   +MTHRUSPECIES +NODAMAGETHRUST +DONTBLAST
   //+NOTELEFRAG
   +MISSILE
   +THRUGHOST
   +WINDTHRUST
   +FOILINVUL
   +DONTREFLECT
   States
   {
   Spawn:
      //GLAS D 0 A_Gravity
      GLAS DDDDDDDDDDDDDDDDDDDDDDDDDDDDDDDDDDDDDDDDDDDDDDDDDDDDDDDDDDDDDDDDDDDDDDDDDDDDDDDDDDDDDDDDDDDDDDDDDDDDDDDDDDDDDDDDDDDDDDDDDDDDDDDDDDDDDDDDDDDDDDDDDDDDDDDDDDDDDDDDDDDDDDDDDDDDDDDDDDDDDDDDDDDDDDDDDDDDDDDD 5 A_Gravity
	  Goto TimeUp
   Death:
      GLAS D 0
      GLAS D 5
      GLAS D 0 A_SpawnDebris("SlugShard")
      Stop
   TimeUp:
      GLAS DDDDDDDDDDD 1 A_FadeOut(0.05)
	  Stop
   }
}

ACTOR PoweredGlassShard5
{
   Radius 5
   Height 5
   Damage ((ACS_NamedExecuteWithResult("WOC Player Scale", FRandom(2,16), CURRENTLEVEL, 0, WOCTARGET))*1.25)
   Damagetype "Physical"
   Obituary "%k flung glass into %o's face."
   SeeSound "flechette/caltink"
   Speed 11
   Scale 0.4
   Alpha 0.95
   RenderStyle Translucent
   +MISSILE
   +DOOMBOUNCE
   +THRUGHOST
   +WINDTHRUST
   +MTHRUSPECIES +NODAMAGETHRUST +DONTBLAST
   +WINDTHRUST
   +FOILINVUL
   +DONTREFLECT
   States
   {
   Spawn:
	  GLAS E 0 A_PlaySound("godcan/silence")
      GLAS E 0 A_Gravity
      GLAS EE 5
      goto Spawn+1
   Death:
      GLAS EEEEEE 5 A_FadeOut(0.05)
      GLAS E 2 A_SpawnItem("PoweredGlassShard5Attack")
      Stop
   }
}

ACTOR PoweredGlassShard5Attack
{
   Radius 5
   Height 5
   Health 3
   Damage ((ACS_NamedExecuteWithResult("WOC Player Scale", FRandom(2,16), CURRENTLEVEL, 0, WOCTARGET))*1.25)
   Damagetype "Physical"
   Obituary "%k snared %o and left %h for dead."
   SeeSound "flechette/caltink"
   DeathSound "flechette/calbreak"
   Speed 0
   Scale 0.4
   Alpha 0.55
   RenderStyle Translucent
   +FIXMAPTHINGPOS
   +NOEXTREMEDEATH
   +DOOMBOUNCE
   +NORADIUSDMG
   +NOBLOOD
   //+SHOOTABLE
   +WINDTHRUST
   +MTHRUSPECIES +NODAMAGETHRUST +DONTBLAST
   //+NOTELEFRAG
   +MISSILE
   +THRUGHOST
   +WINDTHRUST
   +FOILINVUL
   +DONTREFLECT
   States
   {
   Spawn:
      //GLAS E 0 A_Gravity
      GLAS EEEEEEEEEEEEEEEEEEEEEEEEEEEEEEEEEEEEEEEEEEEEEEEEEEEEEEEEEEEEEEEEEEEEEEEEEEEEEEEEEEEEEEEEEEEEEEEEEEEEEEEEEEEEEEEEEEEEEEEEEEEEEEEEEEEEEEEEEEEEEEEEEEEEEEEEEEEEEEEEEEEEEEEEEEEEEEEEEEEEEEEEEEEEEEEEEEEEEEEE 5 A_Gravity
	  Goto TimeUp
   Death:
      GLAS E 0
      GLAS E 5
      GLAS E 0 A_SpawnDebris("SlugShard")
      Stop
   TimeUp:
      GLAS EEEEEEEEEEE 1 A_FadeOut(0.05)
	  Stop
   }
}

ACTOR PoweredGlassShard6
{
   Radius 5
   Height 5
   Damage ((ACS_NamedExecuteWithResult("WOC Player Scale", FRandom(2,16), CURRENTLEVEL, 0, WOCTARGET))*1.25)
   Damagetype "Physical"
   Obituary "%k flung glass into %o's face."
   SeeSound "flechette/caltink"
   Speed 10
   Scale 0.4
   Alpha 0.95
   RenderStyle Translucent
   +MISSILE
   +DOOMBOUNCE
   +THRUGHOST
   +WINDTHRUST
   +MTHRUSPECIES +NODAMAGETHRUST +DONTBLAST
   +WINDTHRUST
   +FOILINVUL
   +DONTREFLECT
   States
   {
   Spawn:
	  GLAS F 0 A_PlaySound("godcan/silence")
      GLAS F 0 A_Gravity
      GLAS FF 5
      goto Spawn+1
   Death:
      GLAS FFFFFF 5 A_FadeOut(0.05)
      GLAS F 2 A_SpawnItem("PoweredGlassShard6Attack")
      Stop
   }
}

ACTOR PoweredGlassShard6Attack
{
	Radius 5
	Height 5
	Health 3
	Damage ((ACS_NamedExecuteWithResult("WOC Player Scale", FRandom(2,16), CURRENTLEVEL, 0, WOCTARGET))*1.25)
	Damagetype "Physical"
	Obituary "%k snared %o and left %h for dead."
	SeeSound "flechette/caltink"
	DeathSound "flechette/calbreak"
	Speed 0
	Scale 0.4
	Alpha 0.55
	RenderStyle Translucent
	+FIXMAPTHINGPOS
	+NOEXTREMEDEATH
	+DOOMBOUNCE
	+NORADIUSDMG
	+NOBLOOD
	//+SHOOTABLE
	+WINDTHRUST
	+THRUGHOST
	+WINDTHRUST
	+MTHRUSPECIES +NODAMAGETHRUST +DONTBLAST
	//+NOTELEFRAG
	+MISSILE
	+FOILINVUL
	+DONTREFLECT
	States
	{
	Spawn:
		//GLAS F 0 A_Gravity
		GLAS FFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFF 5 A_Gravity
		Goto TimeUp
	Death:
		GLAS F 0
		GLAS F 5
		GLAS F 0 A_SpawnDebris("SlugShard")
		Stop
	TimeUp:
		GLAS FFFFFFFFFFF 1 A_FadeOut(0.05)
		Stop
	}
}

ACTOR PoweredGlassShard7
{
	Radius 5
	Height 5
	Damage ((ACS_NamedExecuteWithResult("WOC Player Scale", FRandom(2,16), CURRENTLEVEL, 0, WOCTARGET))*1.25)
	Damagetype "Physical"
	Obituary "%k flung glass into %o's face."
	SeeSound "flechette/caltink"
	Speed 9
	Scale 0.4
	Alpha 0.95
	RenderStyle Translucent
	+MISSILE
	+DOOMBOUNCE
	+THRUGHOST
	+WINDTHRUST
	+MTHRUSPECIES +NODAMAGETHRUST +DONTBLAST
	+WINDTHRUST
	+FOILINVUL
	+DONTREFLECT
	States
	{
	Spawn:
		GLAS G 0 A_PlaySound("godcan/silence")
		GLAS G 0 A_Gravity
		GLAS GG 5
		goto Spawn+1
	Death:
		GLAS GGGGGG 5 A_FadeOut(0.05)
		GLAS G 2 A_SpawnItem("PoweredGlassShard7Attack")
		Stop
	}
}

ACTOR PoweredGlassShard7Attack
{
	Radius 5
	Height 5
	Health 3
	Damage ((ACS_NamedExecuteWithResult("WOC Player Scale", FRandom(2,16), CURRENTLEVEL, 0, WOCTARGET))*1.25)
	Damagetype "Physical"
	Obituary "%k snared %o and left %h for dead."
	SeeSound "flechette/caltink"
	DeathSound "flechette/calbreak"
	Speed 0
	Scale 0.4
	Alpha 0.55
	RenderStyle Translucent
	+FIXMAPTHINGPOS
	+NOEXTREMEDEATH
	+DOOMBOUNCE
	+NORADIUSDMG
	+NOBLOOD
	//+SHOOTABLE
	+WINDTHRUST
	+THRUGHOST
	+WINDTHRUST
	+MTHRUSPECIES +NODAMAGETHRUST +DONTBLAST
	//+NOTELEFRAG
	+MISSILE
	+FOILINVUL
	+DONTREFLECT
	States
	{
	Spawn:
	//GLAS G 0 A_Gravity
		GLAS GGGGGGGGGGGGGGGGGGGGGGGGGGGGGGGGGGGGGGGGGGGGGGGGGGGGGGGGGGGGGGGGGGGGGGGGGGGGGGGGGGGGGGGGGGGGGGGGGGGGGGGGGGGGGGGGGGGGGGGGGGGGGGGGGGGGGGGGGGGGGGGGGGGGGGGGGGGGGGGGGGGGGGGGGGGGGGGGGGGGGGGGGGGGGGGGGGGGGGGG 5 A_Gravity
		Goto TimeUp
	Death:
		GLAS G 0
		GLAS G 5
		GLAS G 0 A_SpawnDebris("SlugShard")
		Stop
	TimeUp:
		GLAS GGGGGGGGGGG 1 A_FadeOut(0.05)
		Stop
	}
}

//////////////////////////////////////////////////// Orange spreading fire ball explosion throwing bomb

ACTOR ArtiOrangeFlask : ArtiEmptyFlask
{
	Inventory.Icon "ARTIFL11"
	Inventory.DefMaxAmount
	Inventory.PickupMessage "Orange Flask"
	Tag "Orange Flask"
	States
	{
	Spawn:
		FL11 A -1
		Stop
	Pickup:
		TNT1 A 0 A_JumpIfInventory("ArtiOrangeFlask", ACS_ExecuteWithResult(WOC_DECORATE,STATS,ITEMCAP,ACTIVATOR),"Failed")
		TNT1 A 0 ACS_ExecuteWithResult(WOC_DECORATE,STATS,ITEMCAP,ACTIVATOR)
		Stop
	Failed:
		TNT1 A 0
		Fail
	Use:
		TNT1 A 0 A_GiveInventory("ShadowWalkAttackCheck",1)
		TNT1 A 0 A_FireCustomMissile ("OrangeBomb", 0, 0, 0, 5)
		Stop
	}
}

ACTOR OrangeBomb : ThrowingBomb
{
	Speed 28
	+WINDTHRUST
	+THRUGHOST
	+MTHRUSPECIES /*+NODAMAGETHRUST*/ +DONTBLAST
	+FOILINVUL
	+FORCERADIUSDMG
	States
	{
	Spawn:
		FT11 A 4 A_CheckThrowBomb
		FT11 BCDE 3 A_CheckThrowBomb
		FT11 F 3 A_CheckThrowBomb2
		Loop
		FT11 G 6 A_CheckThrowBomb
		FT11 I 4 A_CheckThrowBomb
		FT11 H 6 A_CheckThrowBomb
		FT11 I 4 A_CheckThrowBomb
		FT11 G 6 A_CheckThrowBomb
		FT11 I 3 A_CheckThrowBomb
		Wait
	Death:
		CFCF Q 0 Bright A_AlertMonsters
		CFCF Q 0 Bright A_SetTranslucent(1,1)
		CFCF Q 0 Bright A_JumpIfInTargetInventory("PhilosopherStoneTracker",1,"Powered")
		CFCF Q 0 Bright A_SpawnItemEx ("zFireball", 0.0, 0.0, 0.0, 6.0, 0.0, 12.0,   0.0, 32, 0) //
		CFCF Q 0 Bright A_SpawnItemEx ("zFireball", 0.0, 0.0, 0.0, 6.0, 0.0, 12.0,  18.0, 32, 0)
		CFCF Q 0 Bright A_SpawnItemEx ("zFireball", 0.0, 0.0, 0.0, 6.0, 0.0, 12.0,  36.0, 32, 0) //
		CFCF Q 0 Bright A_SpawnItemEx ("zFireball", 0.0, 0.0, 0.0, 6.0, 0.0, 12.0,  54.0, 32, 0)
		CFCF Q 0 Bright A_SpawnItemEx ("zFireball", 0.0, 0.0, 0.0, 6.0, 0.0, 12.0,  72.0, 32, 0) //
		CFCF Q 0 Bright A_SpawnItemEx ("zFireball", 0.0, 0.0, 0.0, 6.0, 0.0, 12.0,  90.0, 32, 0)
		CFCF Q 0 Bright A_SpawnItemEx ("zFireball", 0.0, 0.0, 0.0, 6.0, 0.0, 12.0, 108.0, 32, 0) //
		CFCF Q 0 Bright A_SpawnItemEx ("zFireball", 0.0, 0.0, 0.0, 6.0, 0.0, 12.0, 126.0, 32, 0)
		CFCF Q 0 Bright A_SpawnItemEx ("zFireball", 0.0, 0.0, 0.0, 6.0, 0.0, 12.0, 144.0, 32, 0)
		CFCF Q 0 Bright A_SpawnItemEx ("zFireball", 0.0, 0.0, 0.0, 6.0, 0.0, 12.0, 162.0, 32, 0) //
		CFCF Q 0 Bright A_SpawnItemEx ("zFireball", 0.0, 0.0, 0.0, 6.0, 0.0, 12.0, 180.0, 32, 0)
		CFCF Q 0 Bright A_SpawnItemEx ("zFireball", 0.0, 0.0, 0.0, 6.0, 0.0, 12.0, 198.0, 32, 0) //
		CFCF Q 0 Bright A_SpawnItemEx ("zFireball", 0.0, 0.0, 0.0, 6.0, 0.0, 12.0, 216.0, 32, 0)
		CFCF Q 0 Bright A_SpawnItemEx ("zFireball", 0.0, 0.0, 0.0, 6.0, 0.0, 12.0, 234.0, 32, 0) //
		CFCF Q 0 Bright A_SpawnItemEx ("zFireball", 0.0, 0.0, 0.0, 6.0, 0.0, 12.0, 252.0, 32, 0)
		CFCF Q 0 Bright A_SpawnItemEx ("zFireball", 0.0, 0.0, 0.0, 6.0, 0.0, 12.0, 270.0, 32, 0)
		CFCF Q 0 Bright A_SpawnItemEx ("zFireball", 0.0, 0.0, 0.0, 6.0, 0.0, 12.0, 288.0, 32, 0)
		CFCF Q 0 Bright A_SpawnItemEx ("zFireball", 0.0, 0.0, 0.0, 6.0, 0.0, 12.0, 306.0, 32, 0)
		CFCF Q 0 Bright A_SpawnItemEx ("zFireball", 0.0, 0.0, 0.0, 6.0, 0.0, 12.0, 324.0, 32, 0)
		CFCF Q 0 Bright A_SpawnItemEx ("zFireball", 0.0, 0.0, 0.0, 6.0, 0.0, 12.0, 342.0, 32, 0)
		CFCF Q 0 Bright A_Explode (ACS_NamedExecuteWithResult("WOC Player Scale", 128, CURRENTLEVEL, 0, WOCTARGET), 128, 1)
		CFCF Q 1 Bright A_NoGravity
		CFCF QQQ 1 Bright A_SpawnItemEx("FlailPuffParticleFXSpawner")
		CFCF R 0 Bright A_Scream
		CFCF RRR 1 Bright A_SpawnItemEx("FlailPuffParticleFXSpawner")
		CFCF SSSS 1 Bright A_SpawnItemEx("FlailPuffParticleFXSpawner")
		CFCF T 3 Bright
		CFCF U 4 Bright
		CFCF W 3 Bright
		CFCF X 4 Bright
		CFCF Z 3 Bright
		Stop
	Powered:
		CFCF Q 0 Bright A_SpawnItemEx ("pFireBall", 0.0, 0.0, 0.0, 6.0, 0.0, 12.0,   0.0, 32, 0) //
		CFCF Q 0 Bright A_SpawnItemEx ("pFireBall", 0.0, 0.0, 0.0, 6.0, 0.0, 12.0,  18.0, 32, 0)
		CFCF Q 0 Bright A_SpawnItemEx ("pFireBall", 0.0, 0.0, 0.0, 6.0, 0.0, 12.0,  36.0, 32, 0) //
		CFCF Q 0 Bright A_SpawnItemEx ("pFireBall", 0.0, 0.0, 0.0, 6.0, 0.0, 12.0,  54.0, 32, 0)
		CFCF Q 0 Bright A_SpawnItemEx ("pFireBall", 0.0, 0.0, 0.0, 6.0, 0.0, 12.0,  72.0, 32, 0) //
		CFCF Q 0 Bright A_SpawnItemEx ("pFireBall", 0.0, 0.0, 0.0, 6.0, 0.0, 12.0,  90.0, 32, 0)
		CFCF Q 0 Bright A_SpawnItemEx ("pFireBall", 0.0, 0.0, 0.0, 6.0, 0.0, 12.0, 108.0, 32, 0) //
		CFCF Q 0 Bright A_SpawnItemEx ("pFireBall", 0.0, 0.0, 0.0, 6.0, 0.0, 12.0, 126.0, 32, 0)
		CFCF Q 0 Bright A_SpawnItemEx ("pFireBall", 0.0, 0.0, 0.0, 6.0, 0.0, 12.0, 144.0, 32, 0)
		CFCF Q 0 Bright A_SpawnItemEx ("pFireBall", 0.0, 0.0, 0.0, 6.0, 0.0, 12.0, 162.0, 32, 0) //
		CFCF Q 0 Bright A_SpawnItemEx ("pFireBall", 0.0, 0.0, 0.0, 6.0, 0.0, 12.0, 180.0, 32, 0)
		CFCF Q 0 Bright A_SpawnItemEx ("pFireBall", 0.0, 0.0, 0.0, 6.0, 0.0, 12.0, 198.0, 32, 0) //
		CFCF Q 0 Bright A_SpawnItemEx ("pFireBall", 0.0, 0.0, 0.0, 6.0, 0.0, 12.0, 216.0, 32, 0)
		CFCF Q 0 Bright A_SpawnItemEx ("pFireBall", 0.0, 0.0, 0.0, 6.0, 0.0, 12.0, 234.0, 32, 0) //
		CFCF Q 0 Bright A_SpawnItemEx ("pFireBall", 0.0, 0.0, 0.0, 6.0, 0.0, 12.0, 252.0, 32, 0)
		CFCF Q 0 Bright A_SpawnItemEx ("pFireBall", 0.0, 0.0, 0.0, 6.0, 0.0, 12.0, 270.0, 32, 0)
		CFCF Q 0 Bright A_SpawnItemEx ("pFireBall", 0.0, 0.0, 0.0, 6.0, 0.0, 12.0, 288.0, 32, 0)
		CFCF Q 0 Bright A_SpawnItemEx ("pFireBall", 0.0, 0.0, 0.0, 6.0, 0.0, 12.0, 306.0, 32, 0)
		CFCF Q 0 Bright A_SpawnItemEx ("pFireBall", 0.0, 0.0, 0.0, 6.0, 0.0, 12.0, 324.0, 32, 0)
		CFCF Q 0 Bright A_SpawnItemEx ("pFireBall", 0.0, 0.0, 0.0, 6.0, 0.0, 12.0, 342.0, 32, 0)
		CFCF Q 0 Bright A_Explode (ACS_NamedExecuteWithResult("WOC Player Scale", 160, CURRENTLEVEL, 0, WOCTARGET), 128, 1)
		CFCF Q 1 Bright A_NoGravity
		CFCF QQQ 1 Bright A_SpawnItemEx("FlailPuffParticleFXSpawner")
		CFCF R 0 Bright A_Scream
		CFCF RRR 1 Bright A_SpawnItemEx("FlailPuffParticleFXSpawner")
		CFCF SSSS 1 Bright A_SpawnItemEx("FlailPuffParticleFXSpawner")
		CFCF T 3 Bright
		CFCF U 4 Bright
		CFCF W 3 Bright
		CFCF X 4 Bright
		CFCF Z 3 Bright
		Stop
	}
}

ACTOR zFireball : FireBall
{
	Speed 24
	Damage (ACS_NamedExecuteWithResult("WOC Player Scale", FRandom(15,30), CURRENTLEVEL, 0, WOCTARGET))
	DamageType "Fire"
	-NOGRAVITY
	+MTHRUSPECIES /*+NODAMAGETHRUST*/ +DONTBLAST
	+FOILINVUL
	+DONTREFLECT
	Gravity 0.75
	RenderStyle Add
}

Actor pFireball : zFireball
{
	Damage ((ACS_NamedExecuteWithResult("WOC Player Scale", FRandom(15,30), CURRENTLEVEL, 0, WOCTARGET))*1.25)
}