actor StoneDemon : FPlus_Monster
{
spawnid 249
  +FLOORCLIP
  +NOBLOOD
  +DROPOFF
  Scale 1.1
  HitObituary "%o was smashed by a stone demon."
  obituary "%o was rocked by a Stone Demon's boulder." // lol
  Health 600
  PainChance 100
  Speed 8
  Radius 15
  Height 56
  Mass 9999999
  MissileType StoneDemonBoulder
  MissileHeight 24
  SeeSound "stone/sight"
  AttackSound "demon/melee"
  PainSound "demon/pain"
  DeathSound "stone/death"
  ActiveSound "demon/active"
	
	meleerange 64
	
  States
  {
  Spawn:
    STON AB 10 A_Look
    goto Spawn
  See:
    STON AABBCCDD 2 A_Chase
    goto See
	/*
  Missile:
    STON EF 6 A_FaceTarget
    STON E 6 A_MissileAttack
    Goto See
	
  
  Melee:
    STON EF 8 A_FaceTarget
    STON G 0 A_SargAttack
    STON GGG 2 A_SargAttack
    STON EF 8 A_FaceTarget
    STON GGG 2 A_SargAttack
    Goto See
	*/
  Missile:
	TNT1 A 0 A_JumpIfCloser(300, "Melee")
	TNT1 A 0 A_JumpIfCloser(800, "Missile.ThrowRock")
	goto See
  Missile.ThrowRock:
	STON EF 6 A_FaceTarget
    STON E 6 A_MissileAttack
    goto See
  Melee:
	STON E 8 A_FaceTarget
	TNT1 A 0 ThrustThingZ(0,16,0,0)
	TNT1 A 0 A_Recoil(-16)
	TNT1 A 0 A_FaceTarget
	TNT1 A 0 A_Playsound("demon/melee", CHAN_AUTO)
	STON F 4 A_CustomMeleeAttack(random(8, 30))
	TNT1 A 0 A_Recoil(-5)
	TNT1 A 0 A_FaceTarget
	STON F 4 A_CustomMeleeAttack(random(8, 30))
	TNT1 A 0 A_Recoil(-5)
	TNT1 A 0 A_FaceTarget
	STON G 4 A_CustomMeleeAttack(random(8, 30))
	TNT1 A 0 A_Recoil(-2)
	TNT1 A 0 A_FaceTarget
	STON G 4 A_CustomMeleeAttack(random(8, 30))
	goto See
  Pain:
    STON H 3
    STON H 3 A_Pain
    Goto See

	
  MonDeath:
    //STON IIIIIIIIII 0 A_CustomMissile("StoneDemonMiniBoulder",16,0,random(0,359),2,random(0,40))
    STON I 5
    STON J 5 A_Scream
    STON K 5
    STON L 5 A_NoBlocking
    STON MN 5
    STON OP 4
    STON Q 1
	goto Super::FadeOut
	
  MonRaise:
    STON NMLKJI 5
    Goto See
  }
}

actor StoneDemonStatue : SwitchableDecoration 8190
{
  +SOLID
  Scale 1.1
  Radius 30
  Height 56
  Mass 9999999
  States
  {
  Spawn:
  Inactive:
    STON A 10
    goto Inactive
  Active:
    TNT1 A 1 A_SpawnItemEx("StoneDemon",0,0,0,0,0,0,0,32)
    Stop
  }
}

actor StoneDemonBoulder
{
  PROJECTILE
  -NOGRAVITY
  +DOOMBOUNCE
  +BOUNCEONACTORS
  +STRIFEDAMAGE
  +mthruspecies
  SeeSound "stone/bounce"
  Radius 6
  Height 6
  Scale 0.7
  Speed 40
  VSpeed 3
  Damage 6
  States
  {
  Spawn:
    STNB ABCDEFGH 3
    goto Spawn
  Death:
    STNB H 200
    Stop
  }
}

actor StoneDemonMiniBoulder : StoneDemonBoulder
{
  Damage 1
  Scale 0.35
  SeeSound ""
}