Actor HeavyRailgunner : CyborgShotgunner
{
//Creator: Titanium
//Origin: Nexus Infinity
//Sprite: SRZM
//Title: "Heavy Railgunner"
DropItem "NewCell", 200
DropItem "NewCellPack", 25
DropItem "HealthFlask", 180
DropItem "MineAmmo", 50, 1
DropItem "PortableMedkit", 130
DropItem "BackPack", 75
DropItem "ArmorPlate", 120
DropItem "AmmoPack", 100
DropItem "HandGrenadeAmmo", 200, 1
DropItem "MineAmmo", 100, 1
DropItem "Railgun ", 45, 1
DropItem "MarineBeacon" 25 1
DropItem "HellsMediumContract", 110
DropItem "SuperChargedWeaponEnhancerModuleGiver" 50
MaxStepHeight 32
MaxDropOffHeight 32
Obituary "%o was exploded at the sight by a Heavy Railgunner."
Tag "\c[d9]Heavy \c[x2]Railgunner\c-"
States
{
 Spawn:
	SRZM AA 10 A_Look
	Loop
 See:
	TNT1 A 0 A_ChangeFlag("FRIGHTENED",0)
	TNT1 A 0 A_JumpIfCloser(128,"SeePanic")
	SRZM AA 4 A_Chase
	SRZM A 0 A_PlaySound("Monsters/NBWalk")
	SRZM BBCC 4 A_Chase
	TNT1 A 0 A_JumpIfCloser(128,"SeePanic")
	SRZM CC 0 A_PlaySound("Monsters/NBWalk")
	SRZM DD 4 A_Chase
	Loop
 SeePanic:
	TNT1 A 0 A_ChangeFlag("FRIGHTENED",1)
	SRZM AA 2 A_Chase
	SRZM A 0 A_PlaySound("Monsters/NBWalk")
	SRZM BBCC 2 A_Chase
	SRZM CC 0 A_PlaySound("Monsters/NBWalk")
	SRZM DD 2 A_Chase
	TNT1 A 0 A_JumpIfCloser(128,"SeePanic")
	TNT1 A 0 A_ChangeFlag("FRIGHTENED",0)
	Goto See
  Missile:
	TNT1 A 0 A_Changeflag(NOPAIN,1)
	TNT1 A 0 A_PlaySound("weapons/rgcharge")
	SRZM EEEEE 5 A_FaceTarget
	SRZM F 5 Bright A_CustomMissile("ZombieRail",30,0,0)
	TNT1 A 0 A_Changeflag(NOPAIN,0)
	SRZM E 20
	Goto See
  Pain:
    TNT1 A 0
    TNT1 A 0 A_Jump(128,"PainMissile")
    SRZM G 4
    SRZM G 4 A_Pain
    Goto See
  PainMissile: 
    SRZM G 4
    SRZM G 4 A_Pain
    Goto Missile
  Death:
    SRZM H 5
    SRZM I 5 A_ScreamAndUnBlock
	SRZM J 5 A_SpawnItem("BodyCrash",0,0,0,0)
    SRZM KLM 5
	SRZM N -1
  XDeath:
	SRZM O 3 A_SpawnItemEx("GibbedGenerator",0,0,0,0,0,0,0,128,0)
    SRZM P 3 A_XScream
	SRZM Q 3 A_Fall
    SRZM RSTUV 3
    SRZM W -1 
    Stop	
  Raise:
	TNT1 A 0
	TNT1 A 0 A_SpawnItemEx("VileHealEffect",0,0,0,0,0,0,0,SXF_NOCHECKPOSITION)
    SRZM NMLKJIH 5
    Goto See	
}
}

ACTOR ZombieRail : CardinalRail
{
DamageType "EMGEx"
MissileType "CardinalRailTrail"
States
{
  Spawn:
    DCRP A 1 Bright
    Loop
  Death:
    TNT1 A 0
	TNT1 A 0 A_SpawnItemEx("BFGShockwaveRed", 0, 0, 0, 0, 0, 0, 0, 128)
	TNT1 AAA 0 A_CustomMissile("Kaboom14", 0, 0, random(0,360), 2, random(0,360))
	TNT1 A 1 A_SpawnItem("RailgunImpactEffectRed")
	Stop
	}
}