//===========================================================================
// Imp Replacements
//===========================================================================


ACTOR ImpSpawner : RandomSpawner replaces DoomImp
{
	DropItem "ImpVanilla"
	DropItem "ImpVariant1"
	DropItem "ImpVariant2"
	DropItem "ImpVariant3"

}
//===========================================================================
//
// Imp (Variant 0)
//
// by id Software (New Sounds by Trent Reznor)
//
//===========================================================================

actor ImpVanilla //: DoomImp
{
      Health 60
	  Radius 18
	  Height 56
	  Mass 100
	  Speed 3
	  PainChance 200
	  PainChance "Sling", 255
	  Monster
	  +FLOORCLIP
	  Species "DoomImp"
	  obituary "%o was caught by a devilish Imp!"
	  HitObituary "%o's heart was clawed out by an Imp!"
	  SeeSound "xmimp/sight"
	  PainSound "xmimp/pain"
	  DeathSound "xmimp/death"
	  ActiveSound "xmimp/idle"
	  Painchance "Melee", 235
	  PainChance "Sling", 255
	  PainChance "GasShellDamagePlayer", 20
      States
      {
      Spawn:
	    TROO A 10 A_Look
		Loop
	  See:
	    TROO AAAAAABBBBBBCCCCCCDDDDDD 1 A_Chase
	    Loop
	  Melee:
		TROO EF 8 A_FaceTarget
		TROO G 6 A_TroopAttack
		Goto See
	  Missile:
		TROO E 0 A_Jump(140,"See")
		TROO EF 8 A_FaceTarget
		TROO G 6 A_TroopAttack
		Goto See
	  Pain:
		TROO H 2
		TROO H 2 A_Pain
		Goto See
	  Pain.Sling:
	    TNT1 A 0 HealThing(1)
		TNT1 A 0 A_FaceTarget
        TNT1 A 0 A_CustomMissile("MagSlingShot", 32, 0)
		Goto Pain.Melee
	  Pain.Melee:
	    TROO H 6
	    TROO H 8 A_Pain
	    Goto See
	  Death.Uppercut:
	    TNT1 A 0 A_FaceTarget
	    TNT1 A 0 Thrustthing(angle*256/360+192, random(3,4), 0, 0)
	    TNT1 A 0 Thrustthingz(0,27,0,1)
	    Goto Death
	  Death:
		TROO I 8
		TROO J 8 A_Scream
		TROO K 6
		TROO L 6 A_NoBlocking
		TROO M -1
		Stop
	  XDeath:
		TROO N 5
		TROO O 5 A_XScream
		TROO P 5
		TROO Q 5 A_NoBlocking
		TROO RST 5
		TROO U -1
		Stop
	  Raise:
		TROO MLKJI 8
		Goto See
	  }
}
	  
//===========================================================================
//
// Imp (Variant 1)
//
// by ItsNaturetoDie (modified by Marty Kirra)
// Sprites by Vader and ItsNaturetoDie
//
//===========================================================================

Actor ImpVariant1 //: DoomImp
{
    Health 50
    Radius 18
    Height 56
    Mass 100
    Speed 4
    PainChance 200
	PainChance "Sling", 255
    Monster
    +FLOORCLIP
	Species "DoomImp"
	SeeSound "xmimp/sight"
	PainSound "xmimp/pain"
	DeathSound "xmimp/death"
	ActiveSound "xmimp/idle"
	PainChance "Melee", 235
	PainChance "Sling", 255
	PainChance "GasShellDamagePlayer", 20
    obituary "%o was caught by a devilish Imp!"
	HitObituary "%o's heart was clawed out by an Imp!"
    States
    {
    Spawn:
	  IMV1 A 10 A_Look
	  Loop
	See:
	  IMV1 AAAAAABBBBBBCCCCCCDDDDDD 1 A_Chase
	  loop
    Melee:
      IMV1 EF 8 A_FaceTarget
	  IMV1 G 6 A_TroopAttack
	  Goto See
	Missile:
	  IMV1 E 0 A_Jump(140,"See")
	  IMV1 EF 8 A_FaceTarget
	  IMV1 G 6 A_TroopAttack
	  Goto See
    Pain:
	  IMV1 H 2
	  IMV1 H 2 A_Pain
	  Goto See
    Pain.Sling:
	  TNT1 A 0 HealThing(1)
	  TNT1 A 0 A_FaceTarget
      TNT1 A 0 A_CustomMissile("MagSlingShot", 32, 0)
	  Goto Pain.Melee
	Pain.Melee:
	  IMV1 H 6
	  IMV1 H 8 A_Pain
	  Goto See
    Death:
	  IMV1 I 8
	  IMV1 J 8 A_Scream
	  IMV1 K 6
	  IMV1 L 6 A_Fall
	  IMV1 M -1
	  Stop
	Death.Uppercut:
	  TNT1 A 0 A_FaceTarget
	  TNT1 A 0 Thrustthing(angle*256/360+192, random(3,4), 0, 0)
	  TNT1 A 0 Thrustthingz(0,27,0,1)
	  Goto Death
    Raise:
	  IMV1 ML 8
	  IMV1 KJI 6
	  Goto See
    }
}

//===========================================================================
//
// Imp (Variant 2)
//
// by ItsNaturetoDie (modified by Marty Kirra)
// Sprites by Vader and ItsNaturetoDie
//
//===========================================================================

Actor ImpVariant2 //: DoomImp
{
    Health 70
    Radius 18
    Height 56
    Mass 100
    Speed 3
    PainChance 200
	PainChance "Sling", 255
    Monster
    +FLOORCLIP
	Species "DoomImp"
	SeeSound "xmimp/sight"
	PainSound "xmimp/pain"
	DeathSound "xmimp/death"
	ActiveSound "xmimp/idle"
	PainChance "Melee", 235
	PainChance "Sling", 255
	PainChance "GasShellDamagePlayer", 20
    obituary "%o was caught by a devilish Imp!"
	HitObituary "%o's heart was clawed out by an Imp!"
    States
    {
    Spawn:
	  IMV2 A 10 A_Look
	  Loop
	See:
	  IMV2 AAAAAABBBBBBCCCCCCDDDDDD 1 A_Chase
	  loop
    Melee:
	  IMV2 EF 8 A_FaceTarget
	  IMV2 G 6 A_TroopAttack
	  Goto See
    Missile:
	  IMV2 E 0 A_Jump(140,"See")
	  IMV2 EF 8 A_FaceTarget
	  IMV2 G 6 A_TroopAttack
	  Goto See
    Pain:
	  IMV2 H 2
	  IMV2 H 2 A_Pain
	  Goto See
	Pain.Sling:
	  TNT1 A 0 HealThing(1)
	  TNT1 A 0 A_FaceTarget
      TNT1 A 0 A_CustomMissile("MagSlingShot", 32, 0)
	  Goto Pain.Melee
	Pain.Melee:
	  IMV2 H 6
	  IMV2 H 8 A_Pain
	  Goto See
    Death:
	  IMV2 I 8
	  IMV2 J 8 A_Scream
	  IMV2 K 6
	  IMV2 L 6 A_Fall
	  IMV2 M -1
	  Stop
	Death.Uppercut:
	  TNT1 A 0 A_FaceTarget
	  TNT1 A 0 Thrustthing(angle*256/360+192, random(3,4), 0, 0)
	  TNT1 A 0 Thrustthingz(0,27,0,1)
	  Goto Death
    Raise:
	  IMV2 ML 8
	  IMV2 KJI 6
	  Goto See
    }
}

//===========================================================================
//
// Imp (Variant 3)
//
// by Marty Kirra
// Sprites by ???
//
//===========================================================================

Actor ImpVariant3 //: DoomImp
{
    Health 40
    Radius 18
    Height 56
    Mass 100
    Speed 6
    PainChance 200
	PainChance "Sling", 255
    Monster
    +FLOORCLIP
	Species "DoomImp"
	SeeSound "xmimp/sight"
	PainSound "xmimp/pain"
	DeathSound "xmimp/death"
	ActiveSound "xmimp/idle"
	PainChance "Melee", 235
	PainChance "Sling", 255
	PainChance "GasShellDamagePlayer", 20
    obituary "%o was caught by a devilish Imp!"
	HitObituary "%o's heart was clawed out by an Imp!"
    States
    {
    Spawn:
	  IMV3 A 10 A_Look
	  Loop
	See:
	  IMV3 AAAAAABBBBBBCCCCCCDDDDDD 1 A_Chase
	  loop
    Melee:
	  IMV3 EF 8 A_FaceTarget
	  IMV3 G 6 A_TroopAttack
	  Goto See
    Missile:
	  IMV3 E 0 A_Jump(140,"See")
	  IMV3 EF 8 A_FaceTarget
	  IMV3 G 6 A_TroopAttack
	  Goto See
    Pain:
	  IMV3 H 2
	  IMV3 H 2 A_Pain
	  Goto See
	Pain.Sling:
	  TNT1 A 0 HealThing(1)
	  TNT1 A 0 A_FaceTarget
      TNT1 A 0 A_CustomMissile("MagSlingShot", 32, 0)
	  Goto Pain.Melee
    Pain.Melee:
	  IMV3 H 6
	  IMV3 H 8 A_Pain
	  Goto See
    Death:
	  IMV3 I 8
	  IMV3 J 8 A_Scream
	  IMV3 K 6
	  IMV3 L 6 A_Fall
	  IMV3 M -1
	  Stop
	Death.Uppercut:
	  TNT1 A 0 A_FaceTarget
	  TNT1 A 0 Thrustthing(angle*256/360+192, random(3,4), 0, 0)
	  TNT1 A 0 Thrustthingz(0,27,0,1)
	  Goto Death
	XDeath:
	  IMV3 N 5
	  IMV3 O 5 A_XScream
	  IMV3 P 5
	  IMV3 Q 5 A_NoBlocking
	  IMV3 RST 5
	  IMV3 U -1
	  Stop
    Raise:
	  IMV3 ML 8
	  IMV3 KJI 6
	  Goto See
    }
}