actor Chargeman_W : BaseMM8BDMWep_CBM
{
tag "$TAGC_5F"
dropitem "ChargeKickWep"
Weapon.AmmoUse 3
Weapon.AmmoGive 0
Obituary "$OB_CHARGERAM"
weapon.ammotype "ChargeManIsEveryWhereAmmo"
+WEAPON.NOAUTOAIM
Weapon.KickBack 400
States
{
Spawn:
C_05 F 1
loop

Deselect:
CHAA A 0
goto DeselectSwap
Select:
CHAA A 0
goto SelectSwap

Ready:
CHAA A 0 ACS_NamedExecuteWithResult("core_weaponcolor",DYE_CHARGEMAN)
CHAA A 0 A_GiveInventory("ChargemanSpawnStart_P",1)
CHAA A 0 A_GunFlash("Flash.Start",1)
CHAA A 0 A_JumpIf(CallACS("CBM_IsBot"),"BotReady")
goto Ready1
Ready1:
CHAA A 2 A_GiveInventory("Chargeman_Ready_P")
CHAA A 0 A_GiveInventory("ChargeManIsEveryWhereAmmo",2)
loop

Flash.Start:
TNT1 A 0 //A_JumpIf(CallACS("core_checkmode",1)==1 && CallACS("cbm_FetchServerCVar",66)==0,"Flash.Train")
Flash:
TNT1 AAAAAAAAAAAAAA 1
TNT1 AAAAAAA 1 A_RailWait
TNT1 AAAAAAAAAAAAAA 1
TNT1 A 0 A_SpawnItemEx("TrainSteam",0,0,120,0,0,0,0,1)
loop
Flash.Train:
TNT1 AAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAA 1 A_SpawnItemEx("TrainGrabber",0,0,56,1,0,1)
TNT1 A 0 A_SpawnItemEx("TrainSteam",0,0,120,0,0,0,0,1)
loop

Fire:
CHAA A 0 ACS_NamedExecuteWithResult("cbm_NoHitStunplayer",0,true)
CHAA A 0 A_GiveInventory("VivifyCycle1",1)
CHAA A 0 A_ReFire("FireH0")
goto FireH0


FireH0:
CHAA B 1 Offset(0,39)A_GiveInventory("ChargeTrainDash_P")
CHAA C 0 A_ReFire(1)
CHAA C 1 Offset(0,48)A_GiveInventory("ChargeTrainDash_P")
CHAA D 0 A_ReFire(1)
CHAA D 1 Offset(0,59)A_GiveInventory("ChargeTrainDash_P")
CHAA E 0 A_ReFire("FireH1")
Goto FireEndRight
FireH1:
CHAA E 0 A_JumpIfNoAmmo("FireEndRight")
CHAA E 1 Offset(0,72)A_GiveInventory("ChargeTrainDash_P")
CHAA F 0 A_ReFire(1)
CHAA F 1 Offset(0,86)A_GiveInventory("ChargeTrainDash_P")
CHAA G 0 A_ReFire(1)
CHAA G 1 Offset(0,92)A_GiveInventory("ChargeTrainDash_P")
CHAA H 0 A_ReFire(1)
CHAA H 1 Offset(0,86)A_GiveInventory("ChargeTrainDash_P")
CHAA I 0 A_ReFire(1)
CHAA I 1 Offset(0,72)A_GiveInventory("ChargeTrainDash_P")
CHAA I 0 A_ReFire("FireH2")
Goto FireEndLeft
FireH2:
CHAA I 0 A_JumpIfNoAmmo("FireEndLeft")
CHAA I 1 Offset(0,52)A_GiveInventory("ChargeTrainDash_P")
CHAA H 0 A_ReFire(1)
CHAA H 1 Offset(0,38)A_GiveInventory("ChargeTrainDash_P")
CHAA G 0 A_ReFire(1)
CHAA G 1 Offset(0,32)A_GiveInventory("ChargeTrainDash_P")
CHAA F 0 A_ReFire(1)
CHAA F 1 Offset(0,38)A_GiveInventory("ChargeTrainDash_P")
CHAA E 0 A_ReFire(1)
CHAA E 1 Offset(0,52)A_GiveInventory("ChargeTrainDash_P")
CHAA E 0 A_ReFire("FireH1")
Goto FireEndRight

FireEndRight:
CHAA D 0 A_GiveInventory("Chargeman_FireEnd_P")
CHAA D 2 Offset(0,44)A_GiveInventory("Chargeman_ReadyNoBob_P")
CHAA C 2 Offset(0,38)A_GiveInventory("Chargeman_ReadyNoBob_P")
CHAA B 2 Offset(0,34)A_GiveInventory("Chargeman_ReadyNoBob_P")
goto ReadyWait1

FireEndLeft:
CHAA D 0 A_GiveInventory("Chargeman_FireEnd_P")
CHAA G 2 Offset(0,62)A_GiveInventory("Chargeman_ReadyNoBob_P")
CHAA E 2 Offset(0,53)A_GiveInventory("Chargeman_ReadyNoBob_P")
CHAA C 2 Offset(0,45)A_GiveInventory("Chargeman_ReadyNoBob_P")
CHAA B 2 Offset(0,38)A_GiveInventory("Chargeman_ReadyNoBob_P")
goto ReadyWait1+1

ReadyWait1:
CHAA AAAA 2 A_GiveInventory("Chargeman_Ready_P")
goto Ready1

BotFireEnd:
CHAA A 0 A_GiveInventory("BotRetreatFlag",1)
CHAA AAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAA 2 Offset(0,32)A_GiveInventory("ChargeManIsEveryWhereAmmo",2)
CHAA A 1 A_TakeInventory("BotRetreatFlag",1)
Goto Ready1



AltFire:
CHAA L 0 A_GiveInventory("Chargeman_Alt_P")
//CHAA L 0 A_GunFlash("Flash",1)
CHAA L 1 OffSet(0,36)A_TakeInventory("ChargeManIsEveryWhereAmmo",3,1)
CHAA MMM 1 OffSet(0,32)A_TakeInventory("ChargeManIsEveryWhereAmmo",3,1)
CHAA M 1 OffSet(0,49)A_TakeInventory("ChargeManIsEveryWhereAmmo",3,1)
CHAA MMM 1 OffSet(0,76)A_TakeInventory("ChargeManIsEveryWhereAmmo",3,1)
CHAA K 0 ACS_NamedExecuteWithResult("core_chargecolor",DYE_CHARGEMAN,TCLR_NONE)
CHAA K 0 ACS_NamedExecuteWithResult("core_invulnerableplayer",0,0)
CHAA K 8 OffSet(0,76)A_TakeInventory("ChargeManIsEveryWhereAmmo",1)
CHAA J 2 OffSet(0,66)
CHAA D 2 OffSet(0,17)
CHAA C 2 OffSet(0,23)
CHAA B 2 OffSet(0,28)
Goto Ready1



BotReady:
CHAA A 0 A_WeaponReady(12)
CHAA A 2 A_Refire("BotFire")
CHAA A 0 A_GiveInventory("ChargeManIsEveryWhereAmmo",2)
loop

BotFire:
CHAA A 0 A_Jump(64,"BotAlt")
CHAA A 0 ACS_NamedExecuteWithResult("cbm_NoHitStunplayer",0,true)
CHAA A 0 A_GiveInventory("VivifyCycle1",1)
CHAA B 1 Offset(0,35)A_GiveInventory("ChargeTrainDash_P")
CHAA C 0 A_ReFire(1)
CHAA C 1 Offset(0,39)A_GiveInventory("ChargeTrainDash_P")
CHAA C 0 A_ReFire(1)
CHAA C 1 Offset(0,39)A_GiveInventory("ChargeTrainDash_P")
CHAA D 0 A_ReFire(1)
CHAA D 1 Offset(0,45)A_GiveInventory("ChargeTrainDash_P")
CHAA D 0 A_ReFire(1)
CHAA D 1 Offset(0,45)A_GiveInventory("ChargeTrainDash_P")
CHAA E 0 A_ReFire(1)
Goto BotFireEnd
CHAA E 0 A_JumpIfNoAmmo("BotFireEnd")
CHAA E 1 Offset(0,52)A_GiveInventory("ChargeTrainDash_P")
CHAA E 0 A_ReFire(1)
CHAA E 1 Offset(0,52)A_GiveInventory("ChargeTrainDash_P")
CHAA F 0 A_ReFire(1)
CHAA F 1 Offset(0,56)A_GiveInventory("ChargeTrainDash_P")
CHAA F 0 A_ReFire(1)
CHAA F 1 Offset(0,56)A_GiveInventory("ChargeTrainDash_P")
CHAA F 0 A_ReFire(1)
CHAA F 1 Offset(0,56)A_GiveInventory("ChargeTrainDash_P")
CHAA F 0 A_ReFire(1)
Goto BotFireEnd
BotFireH:
CHAA F 0 A_JumpIfNoAmmo("BotFireEnd")
CHAA F 1 Offset(0,56)A_GiveInventory("ChargeTrainDash_P")
CHAA F 0 A_ReFire(1)
CHAA F 1 Offset(0,56)A_GiveInventory("ChargeTrainDash_P")
CHAA F 0 A_ReFire(1)
CHAA F 1 Offset(0,56)A_GiveInventory("ChargeTrainDash_P")
CHAA F 0 A_ReFire(1)
CHAA F 1 Offset(0,56)A_GiveInventory("ChargeTrainDash_P")
CHAA F 0 A_ReFire(1)
CHAA F 1 Offset(0,56)A_GiveInventory("ChargeTrainDash_P")
CHAA F 0 A_ReFire("BotFireH")
Goto BotFireEnd

BotFireEnd:
CHAA D 0 A_GiveInventory("Chargeman_FireEnd_P")
CHAA A 0 A_GiveInventory("BotRetreatFlag",1)
CHAA AAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAA 2 Offset(0,32)A_GiveInventory("ChargeManIsEveryWhereAmmo",2)
CHAA A 1 A_TakeInventory("BotRetreatFlag",1)
Goto BotReady

BotAlt:
CHAA L 0 A_GiveInventory("Chargeman_Alt_P")
CHAA L 1 OffSet(0,36)A_TakeInventory("ChargeManIsEveryWhereAmmo",25,1)
CHAA MMM 1 OffSet(0,32)A_RailWait
CHAA M 1 OffSet(0,49)A_RailWait
CHAA MMM 1 OffSet(0,76)A_RailWait
CHAA K 0 ACS_NamedExecuteWithResult("core_chargecolor",DYE_CHARGEMAN,TCLR_NONE)
CHAA K 8 OffSet(0,76)ACS_NamedExecuteWithResult("core_invulnerableplayer",0,0)
CHAA J 2 OffSet(0,66)
CHAA D 2 OffSet(0,17)
CHAA C 2 OffSet(0,23)
CHAA B 2 OffSet(0,28)
Goto BotReady
}
}

actor ChargeManIsEveryWhereAmmo : Ammo
{
inventory.amount 1
inventory.maxamount 75
+INVENTORY.IGNORESKILL 
}
actor ChargeM_OnceFlag : Inventory{}

actor ChargemanDashStopper : PowerSpeed
{
powerup.duration 8
speed 0.05//0
+NOTRAIL
}

actor ChargemanArmorDelay : Powerup
{
Powerup.Duration 35
}

actor ChargeManLink : Inventory 
{
inventory.amount 1
Inventory.MaxAmount 1064
}

actor ChargeManJumpBuffer : Powerup
{
powerup.duration -1
}
actor ChargeWildRideFlag : OnceC {}


actor PowerChargeManSnd5 : Powerup
{
powerup.duration 5
}
actor PowerChargeManSnd3 : Powerup
{
powerup.duration 3
}

actor Chargeman_Ready_P : CustomInventory
{
States
{
Pickup:
TNT1 A 0 A_JumpIfInventory("ChargeManIsEveryWhereAmmo",25,4)
TNT1 A 0 A_JumpIfInventory("ChargeManIsEveryWhereAmmo",3,2)
TNT1 A 0 A_WeaponReady(WRF_NOPRIMARY|WRF_NOSECONDARY)
stop
TNT1 A 0 A_WeaponReady(WRF_NOSECONDARY)
stop
TNT1 A 0 A_WeaponReady
stop
}
}
actor Chargeman_ReadyNoBob_P : CustomInventory
{
States
{
Pickup:
TNT1 A 0 A_JumpIfInventory("ChargeManIsEveryWhereAmmo",25,4)
TNT1 A 0 A_JumpIfInventory("ChargeManIsEveryWhereAmmo",3,2)
TNT1 A 0 A_WeaponReady(WRF_NOBOB|WRF_NOPRIMARY|WRF_NOSECONDARY)
stop
TNT1 A 0 A_WeaponReady(WRF_NOBOB|WRF_NOSECONDARY)
stop
TNT1 A 0 A_WeaponReady(WRF_NOBOB)
stop
}
}

actor Chargeman_Fire_P : CustomInventory
{
States
{
Pickup:
TNT1 A 0 A_GiveInventory("ChargemanDashStopper",1)
TNT1 A 0 A_JumpIfInventory("PlayerPropertyRage",1,"PickupR")
TNT1 A 0 A_GiveInventory("VivifyCycle1",1)
TNT1 A 0 A_JumpIfInventory("PowerChargeManSnd5",1,"No")
TNT1 A 0 A_GiveInventory("PowerChargeManSnd5",1)
goto Play
PickupR:
TNT1 A 0 A_GiveInventory("VivifyCycle1",2)
TNT1 A 0 A_JumpIfInventory("PowerChargeManSnd3",1,"No")
TNT1 A 0 A_GiveInventory("PowerChargeManSnd3",1)
goto Play
Play:
TNT1 A 0 A_TakeInventory("ChargeManIsEveryWhereAmmo",1)
TNT1 A 0 A_TakeInventory("ChargeManIsEveryWhereAmmo",2,1)
TNT1 A 0 A_PlaySound("weapon/train",0,0.68)
TNT1 A 0 A_SpawnItemEx("ChargeTrainClip",0,0,32,momx,momy,momz,0,8)
TNT1 A 0 A_FireCustomMissile("ChargeTrain",0,0,0,0)
stop
No:
TNT1 A 0
stop
}
}


actor Chargeman_FireEnd_P : CustomInventory
{
States
{
Pickup:
TNT1 A 0 A_TakeInventory("ChargemanDashStopper")
TNT1 A 0 ACS_NamedExecuteWithResult("cbm_NoHitStunplayer",0,false)
TNT1 A 0 A_TakeInventory("VivifyCycle1")
stop
}
}

actor ChargeTrainDash_P : CustomInventory
{
States
{
Pickup:
TNT1 A 0 A_GiveInventory("Chargeman_Fire_P")
TNT1 A 0 A_JumpIf(z-floorz==0,"Ground")
goto Air
Air:
TNT1 A 0 A_JumpIfInventory("PlayerPropertyRage",1,"Air_R")
TNT1 A 0 A_Recoil(-1.05f)//-1.75f//-4
stop
Air_R:
TNT1 A 0 A_Recoil(-1.75f)
stop
Ground:
TNT1 A 0 A_JumpIfInventory("PlayerPropertyRage",1,"Ground_R")
TNT1 A 0 A_Recoil(-2.7f)//-4.5f//-12
stop
Ground_R:
TNT1 A 0 A_Recoil(-4.5f)
stop
//Classic Train
//CHAA B 2 A_Recoil(-12)//A_Recoil(-5)
//CHAA B 2// A_Recoil(-5)
//CHAA B 1// A_Recoil(-3)
}
}

actor Chargeman_Alt_P : CustomInventory
{
States
{
Pickup:
TNT1 A 0 ACS_NamedExecuteWithResult("core_chargecolor",DYE_CHARGEMANHOT,TINT_TCLR1)
TNT1 A 0 ACS_NamedExecuteWithResult("core_invulnerableplayer",0,1)
CHAA L 0 A_PlaySound("weapon/chugga",1)
//CHAA L 0 A_SpawnItemEx("TrainSteam",0,0,120,0,0,0,0,1)
TNT1 A 0 A_SpawnItemEx("CoalSpawner",0,0,56)
TNT1 A 0 A_SpawnItemEx("ChargeAltRadius",0,0,32,momx,momy,momz,0,8)
TNT1 A 0 A_FireCustomMissile("ChargeCoalShot",0,0,0,24)
TNT1 A 0 //A_TakeInventory("ChargeManIsEveryWhereAmmo",1)
stop
}
}

actor ChargeM_CarryHelper : BasicHelper
{
+SERVERSIDEONLY
states
{
Spawn:
TNT1 A 1 A_JumpIfInTargetInventory("ChargeManLink",1,"Coop")
TNT1 A 0 A_JumpIf(!CallACS("cbm_PointerExists",AAPTR_TARGET),"Death")
loop
Coop:
TNT1 A 1 ACS_NamedExecuteWithResult("cbm_traingrab",CallACS("cbm_gettrainpassenger"))
TNT1 A 0 A_JumpIfInTargetInventory("ChargeManLink",1,"Coop")
Goto Spawn
}
}

actor TrainGrabber
{
+MISSILE
+NOBLOCKMAP
+NOGRAVITY
+DONTBLAST
+DONTREFLECT
+HITTRACER
+THRUGHOST
+FORCEALLYCOLLISION
renderstyle none
radius 34
height 32
speed 1
states
{
Spawn:
PLAY A 0
PLAY A 1//3
stop
XDeath:
PUNK H 0 A_JumpIfInTargetInventory("ChargeManJumpBuffer",1,"No")
PUNK H 0 A_JumpIfInventory("ChargeManLink",1,"No",8)
PUNK H 0 A_JumpIfInventory("ChargeWildRideFlag",1,"No",8)
PUNK H 0 A_JumpIf(CallACS("cbm_istracerally")==1,"DeathLink")
goto No
DeathLink:
BASS H 4 ACS_NamedExecuteWithResult("cbm_chargemanlink", CallACS("core_getptrtid",2), CallACS("core_getptrtid",8))
stop
No:
Death:
PUNK H 4
stop
}
}


actor ChargemanSpawnStart_P : CustomInventory
{
States
{
Pickup:
TNT1 A 0 A_JumpIfInventory("ChargeM_OnceFlag",1,"No")
TNT1 A 0 A_GiveInventory("ChargeM_OnceFlag",1)
TNT1 A 0 A_SpawnItemEx("ChargemanArmorWatcher_H")
TNT1 A 0 //A_JumpIf(CallACS("core_checkmode",1)==1 && CallACS("cbm_FetchServerCVar",66)==0,1)
stop
TNT1 A 0 A_SpawnItemEx("ChargeM_CarryHelper")
stop
No:
TNT1 A 0
stop
}
}
actor ChargemanArmorWatcher_H : BasicHelper
{
+SERVERSIDEONLY
States
{
Spawn:
TNT1 A 0
TNT1 A 5
TNT1 A 0 A_GiveToTarget("ChargeM_BasicArmorBonus_P",1)
TNT1 A 0 A_SetArg(1,CallACS("core_getarmorinfo",1,2))
TNT1 A 0 A_GiveToTarget("DynamicArmorDosage",Args[1])
TNT1 A 0 A_TakeFromTarget("BasicArmor")
TNT1 A 1
TNT1 A 0 A_SetArg(1,(Args[1]<100)+Args[1]/100)
SpawnIdle:
PLAY A 1
PLAY A 0 A_JumpIfInTargetInventory("BasicArmor",1,"Spawn_Wait")
PLAY A 0 A_JumpIf(!CallACS("cbm_PointerExists",AAPTR_TARGET),"Death")
loop
Spawn_Wait:
BASS A 1
BASS A 0 A_JumpIf(!CallACS("cbm_PointerExists",AAPTR_TARGET),"Death")
BASS A 0 A_JumpIfInTargetInventory("ChargemanArmorDelay",1,"Spawn_Wait")
goto Spawn_Take
Spawn_Take:
BASS F 1 A_TakeFromTarget("BasicArmor",Args[1])
BASS F 0 A_JumpIf(!CallACS("cbm_PointerExists",AAPTR_TARGET),"Death")
BASS F 0 A_JumpIfInTargetInventory("ChargemanArmorDelay",1,"Spawn_Wait")
BASS F 0 A_JumpIfInTargetInventory("BasicArmor",1,"Spawn_Take")
BASS H 1 A_TakeFromTarget("BasicArmor")
goto SpawnIdle+1
Death:
ROLL H 1
stop
}
}

actor ChargeTrainClip : BasicImplosion
{
damagetype "ChargeM_Ram2"
Obituary "$OB_CHARGERAM"
States
{
Spawn:
TNT1 A 0
TNT1 A 1 A_Explode(60+CallACS("core_checkrune",RUNE_SPREAD,2)*120,80,0,0,24)
stop
}
}


actor ChargeTrain : ProjSpawnFuncActor
{
PROJECTILE
damagetype "ChargeM_Ram"
Obituary "$OB_CHARGERAM"
+DONTBLAST
+DONTREFLECT
+HITTRACER
+BOUNCEONFLOORS
+BOUNCEONWALLS
+BOUNCEONCEILINGS
+CANBOUNCEWATER
+NOEXPLODEFLOOR
Bouncecount 2
BounceFactor 1.0
WallBounceFactor 1.0
damage (60)
Radius 16
Height 28
speed 60
scale 2.5
States
{
Spawn:
STEA MNO 1
stop
Crash:
XDeath:
TNT1 A 0 A_JumpIf(CallACS("cbm_istracerenemy")==1,"Death_Give")
Goto Death
Death_Give:
TNT1 A 0 A_GiveToTarget("ChargeM_BasicArmorBonus_P",1)
TNT1 A 0 A_GiveToTarget("ChargemanArmorDelay",1)
Goto Death
Death:
TNT1 A 1
stop
}
}

actor CoalSpawner : BasicHelper
{
States
{
Spawn:
TNT1 A 0
TNT1 A 0 A_SpawnItemEx("RisingCoal",0,0,0,30,0,5.5,0)
TNT1 A 0 A_SpawnItemEx("RisingCoal",0,0,0,30,0,5.5,45)
TNT1 A 0 A_SpawnItemEx("RisingCoal",0,0,0,30,0,5.5,90)
TNT1 A 0 A_SpawnItemEx("RisingCoal",0,0,0,30,0,5.5,135)
TNT1 A 0 A_SpawnItemEx("RisingCoal",0,0,0,30,0,5.5,180)
TNT1 A 0 A_SpawnItemEx("RisingCoal",0,0,0,30,0,5.5,-45)
TNT1 A 0 A_SpawnItemEx("RisingCoal",0,0,0,30,0,5.5,-90)
TNT1 A 0 A_SpawnItemEx("RisingCoal",0,0,0,30,0,5.5,-135)
TNT1 A 0 A_SpawnItemEx("RisingCoal",0,0,0,26,0,16,27.5)
TNT1 A 0 A_SpawnItemEx("RisingCoal",0,0,0,26,0,16,72.5)
TNT1 A 0 A_SpawnItemEx("RisingCoal",0,0,0,26,0,16,117.5)
TNT1 A 0 A_SpawnItemEx("RisingCoal",0,0,0,26,0,16,162.5)
TNT1 A 0 A_SpawnItemEx("RisingCoal",0,0,0,26,0,16,-27.5)
TNT1 A 0 A_SpawnItemEx("RisingCoal",0,0,0,26,0,16,-72.5)
TNT1 A 0 A_SpawnItemEx("RisingCoal",0,0,0,26,0,16,-117.5)
TNT1 A 0 A_SpawnItemEx("RisingCoal",0,0,0,26,0,16,-162.5)
TNT1 A 1
stop
}
}

actor ChargeAltRadius : BasicImplosion
{
Obituary "$OB_COALRAIN"
Damagetype "ChargeM_Coal"
States
{
Spawn:
TNT1 A 0
TNT1 A 1 A_Explode(110+CallACS("core_checkrune",RUNE_SPREAD,2)*110,96,0,0,96)
stop
}
}

actor ChargeCoalShot : ProjSpawnFuncActor
{
PROJECTILE
Obituary "$OB_COALRAIN"
Damagetype "ChargeM_Coal"
-NOGRAVITY
damage (80)
Radius 7
Height 7
speed 38
scale 3.0
States
{
Spawn:
TNT1 A 0
TNT1 A 0 A_ChangeVelocity(0,0,4)
TNT1 A 0 A_Jump(256,1,2,3,4)
COAL GHIJ 2
goto Spawn+3
Death:
//TNT1 A 0 A_SetScale(2.25)
TNT1 A 0 A_PlaySoundEx("weapon/napalm","weapon")
TNT1 A 0 //A_SpawnItemEx("CoalSpawner",0,0,56,0,0,0)
TNT1 A 0 A_Explode(80,96,0,0,48)
TNT1 A 1 A_SpawnItemEx("BasicBoom6FX_4_210",0,0,0,0,0,0,0,1)
stop
}
}

actor RisingCoal : ProjSpawnFuncActor
{
PROJECTILE
Obituary "$OB_COALRAIN"
Damagetype "ChargeM_Coal"
+DONTBLAST
//+SHOOTABLE
Radius 8
Height 10
Damage (20)
speed 30
scale 2.5
States
{
Spawn:
COAL DEF 1
goto Death
Death:
COAL D 0 A_SpawnItemEx("FallingCoal",0,0,0,0,0,0,0,1)
stop
XDeath:
TNT1 A 0
stop
}
}

actor FallingCoal : RisingCoal
{
-NOGRAVITY
Gravity 3
damage (40)//300
States
{
Spawn:
COAL ABC 1
loop
Death:
TNT1 A 0
TNT1 A 0 A_SpawnItemEx("OilPitIgnite",0,0,8)
stop
}
}

actor TrainSteam : BasicExplosion
{
scale 2.5
States
{
Spawn:
TNT1 A 0
STEA ABCDE 1
STEA FGHII 3
stop
}
}

actor Chargeman_W_NormalBar : NormalBar {Args 4,225}