
//Change several "do something on death" actors to work with SKYEXPLODE
//Change the explosion damage to an Args[] for easier adjusting
//Additionally add SpreadRune support for actors that need it
//The SKYEXPLODE change is done so that ceiling classes can be shot on skies

actor CBM_EddieBomberBomb : EddieBomberBomb{Args 17 states{
Death:
TNT1 A 0 A_SetGravity(0.0)
TNT1 A 0 A_PlaySound("misc/mm3explosion",1)
TNT1 A 0 A_Explode(Args[0],185,0)
TNT1 A 35 A_SpawnItemEx("ExplosionEffect2",0,0,0,0,0,0,0,SXF_WEPFXCOLOR)
stop
}}


actor CBM_ArrowShot : ArrowShot{+SKYEXPLODE}


actor CBM_Gutrock : Gutrock{+SKYEXPLODE}
actor CBM_HyperBomb : HyperBomb{Args 250 states{
LightExplode:
BOMB A 0 A_PlaySound("weapons/mm1/hyperbombsmallexplode",1)
BOMB A 0 A_SetGravity(0.0)
BOMB A 0 A_Explode(Args[0]/5,180,0)
TNT1 A 35 A_SpawnItemEx("ExplosionEffect2",0,0,0,0,0,0,0,SXF_WEPFXCOLOR)
stop
MaxExplode:
BOMB A 0 A_PlaySound("weapons/mm1/hyperbombexplode",1)
BOMB A 0 A_SetGravity(0.0)
BOMB A 0 A_Explode(Args[0],180,0)
TNT1 A 35 A_SpawnItemEx("ExplosionEffect3",0,0,0,0,0,0,0,SXF_WEPFXCOLOR)
stop}}
actor CBM_FireShieldDamage : FireShieldDamage{Args 5 states{
Spawn:
TNT1 A 0
TNT1 A 0 A_Explode(Args[0]*(CallACS("core_checkrune",RUNE_SPREAD,2)*2+1),80,0,0,81)
stop}}
actor CBM_TimeSlow : TimeSlow{Args 13 states{
Spawn:
TNT1 A 0
TNT1 A 1 A_Explode(Args[0],640,0)
SLOD EFGHIJKLMNEFGHIJKLMN 1
stop}}
actor CBM_SliderDamager : SliderDamager{Args 21 states{
Spawn:
TNT1 A 0
TNT1 A 0 A_Explode(Args[0]*(CallACS("core_checkrune",RUNE_SPREAD,2)*2+1),80,0)
stop}}


actor CBM_TimeStopperRadius : TimeStopperRadius{Args 7 states{
Spawn:
TNT1 A 0
TNT1 A 0 A_Explode(Args[0]*(CallACS("core_checkrune",RUNE_SPREAD,2)*2+1),WEPC_2TS_RADIUS,0,0,WEPC_2TS_RADIUS)
stop}}
actor CBM_CrashBomb : CrashBomb{+SKYEXPLODE Args 24 states{
Death:
CRAS A 0 A_JumpIf(z-floorz<5, "Floor")
CRAS A 0 A_JumpIf(z-ceilingz==0-6, "Ceiling")
CRAS B 3 A_PlaySound("weapons/mm2/crashbombland")
CRAS C 3
CRAS DCDCDCDCDCDCDC 3
Goto XDeath
Floor:
CRAS E 3 A_PlaySound("weapons/mm2/crashbombland")
CRAS F 3
CRAS GFGFGFGFGFGFGF 3
Goto XDeath
Ceiling:
CRAS H 3 A_PlaySound("weapons/mm2/crashbombland")
CRAS I 3
CRAS JIJIJIJIJIJIJI 3
Goto XDeath
XDeath:
CRAS A 0 A_PlaySound("weapons/mm2/crasbombexplode")
CRAS A 0 A_SpawnItemEx("CrashBombExplode",0,0,0,0,0,0,0,SXF_WEPFXCOLOR)
TNT1 AAAA 9 A_Explode(Args[0],64,0)
stop
}
}


actor CBM_GeminiLaserFast : GeminiLaserFast{+SKYEXPLODE}
actor CBM_GeminiLaser : GeminiLaser{+SKYEXPLODE}
actor CBM_TopRadius : TopRadius{Args 15 states{
Spawn:
TNT1 A 0
TOPS A 2 A_Explode(Args[0]*(CallACS("core_checkrune",RUNE_SPREAD,2)*2+1),90,0)
stop}}
actor CBM_SparkShockExplode : SparkShockExplode{Args 15 states{
Spawn:
TNT1 A 0
TNT1 A 0 A_Explode(Args[0],80,0,0,80)
SPAS AHIJ 1
stop}}


actor CBM_FlashStopper : FlashStopper{Args 22 states{
Spawn:
TNT1 A 0
TNT1 A 25 A_SetArg(4,CallACS("core_checkrune",RUNE_SPREAD,2)*2+1)//Record spread at Spawn time
TNT1 A 0 A_SpawnItemEx("FlashStopperFX",0,0,64,0,0,0,0,SXF_WEPFXCOLOR)
TNT1 A 0 A_PlaySound("weapons/mm4/flashstopperexplode",1)
TNT1 A 1 A_Explode(Args[0]*Args[4],450,0)
TNT1 A 1 ACS_NamedExecuteAlways("core_flashstopperlight", 0, 450)
stop}}
actor CBM_RainFlush : RainFlush{Args 27,13 states{
Spawn:
TNT1 A 35
TNT1 A 0 A_PlaySound("weapons/mm4/rainflushexplode",2)
TNT1 A 0 A_SpawnItemEx("RainFlushSoakify")
TNT1 A 0 A_Explode(Args[0],512,0)
TNT1 AAAAAAA 1 A_SpawnItemEx("RainSprinkleSpawn",0,0,0,0,0,0,0,SXF_RAINFLUSH)
TNT1 A 0 A_SpawnItemEx("RainFlushSoakify")
TNT1 A 0 A_Explode(Args[1],512,0)
TNT1 AAAAAAA 1 A_SpawnItemEx("RainSprinkleSpawn",0,0,0,0,0,0,0,SXF_RAINFLUSH)
TNT1 A 0 A_SpawnItemEx("RainFlushSoakify")
TNT1 A 0 A_Explode(Args[1],512,0)
TNT1 AAAAAAA 1 A_SpawnItemEx("RainSprinkleSpawn",0,0,0,0,0,0,0,SXF_RAINFLUSH)
TNT1 A 0 A_SpawnItemEx("RainFlushSoakify")
TNT1 A 0 A_Explode(Args[1],512,0)
TNT1 AAAAAAA 1 A_SpawnItemEx("RainSprinkleSpawn",0,0,0,0,0,0,0,SXF_RAINFLUSH)
stop}}
actor CBM_DrillBomb : DrillBomb{+SKYEXPLODE Args 50 states{
Death:
DRIL A 0 A_PlaySound("weapons/mm4/drillbombexplode",1)
DRIL A 0 A_Explode(Args[0],96,0,0,16+7)
TNT1 A 35 A_SpawnItemEx("ExplosionEffect2",0,0,0,0,0,0,0,SXF_WEPFXCOLOR)
stop}}
actor CBM_PharaohShot3 : PharaohShot3{+SKYEXPLODE Args 75 states{
Death:
TNT1 A 0
TNT1 A 0 A_Explode(Args[0],96,0,0,16)
TNT1 A 0 A_SpawnItemEx("OilPitIgnite",0,0,8)
PHAS LMNO 2
stop}}
actor CBM_PharaohFX : PharaohFX{Args 7 states{
Spawn.jk:
PHAS J 1 A_Warp(AAPTR_TARGET,0,0,90,0,WARPF_NOCHECKPOSITION|WARPF_WARPINTERPOLATION|WARPF_COPYINTERPOLATION)
PHAS J 0 A_JumpIf(CallACS("core_pharaohshotwarper_exists")==0,"Death")
PHAS J 0 A_Warp(2,0,0,90,0,4|16|64)
PHAS J 1 A_Explode(Args[0]*(CallACS("core_checkrune",RUNE_SPREAD,2)*2+1),64,0)
PHAS J 0 A_JumpIf(CallACS("core_pharaohshotwarper_exists")==0,"Death")
PHAS J 1 A_Warp(2,0,0,90,0,4|16|64)
PHAS K 0 A_JumpIf(CallACS("core_pharaohshotwarper_exists")==0,"Death")
PHAS K 0 A_Warp(2,0,0,90,0,4|16|64)
PHAS K 1 A_Explode(Args[0]*(CallACS("core_checkrune",RUNE_SPREAD,2)*2+1),64,0)
PHAS K 0 A_JumpIf(CallACS("core_pharaohshotwarper_exists")==0,"Death")
PHAS K 1 A_Warp(2,0,0,90,0,4|16|64)
PHAS K 0 A_JumpIf(CallACS("core_pharaohshotwarper_exists")==0,"Death")
PHAS K 0 A_Warp(2,0,0,90,0,4|16|64)
PHAS K 1 A_Explode(Args[0]*(CallACS("core_checkrune",RUNE_SPREAD,2)*2+1),64,0)
PHAS J 0 A_JumpIf(CallACS("core_pharaohshotwarper_exists")==0,"Death")
loop}}
actor CBM_DustCrusher : DustCrusher{+SKYEXPLODE}
//SkullBarrier


actor CBM_GravityHold : GravityHold{Args 7 states{
Spawn:
TNT1 A 0
TNT1 A 0 A_SpawnItemEx("GravityHoldFX",0,0,0,0,0,0,0,SXF_WEPFXCOLOR)
TNT1 A 2 A_Explode(Args[0],1000,0)
TNT1 A 0 A_SpawnItemEx("GravityHoldFX",0,0,0,0,0,0,0,SXF_WEPFXCOLOR)
TNT1 A 2 A_Explode(Args[0],1000,0)
TNT1 A 0 A_SpawnItemEx("GravityHoldFX2",0,0,0,0,0,0,0,SXF_WEPFXCOLOR)
TNT1 A 2 A_Explode(Args[0],768,0)
TNT1 A 0 A_SpawnItemEx("GravityHoldFX3",0,0,0,0,0,0,0,SXF_WEPFXCOLOR)
TNT1 A 2 A_Explode(Args[0],512,0)
TNT1 A 0 A_SpawnItemEx("GravityHoldFX3",0,0,0,0,0,0,0,SXF_WEPFXCOLOR)
TNT1 A 2 A_Explode(Args[0],512,0)
stop}}
actor CBM_StarRadius : StarRadius{Args 17 states{
Spawn:
TNT1 A 0
TNT1 A 1 A_Explode(Args[0]*(CallACS("core_checkrune",RUNE_SPREAD,2)*2+1),128,0)
stop}}
actor CBM_NapalmBomb : NapalmBomb{+SKYEXPLODE Args 48 states{
Death:
NAPA A 0 A_PlaySound("weapons/mm5/napalmbombexplode",1)
NAPA A 0 A_SetGravity(0.0)
NAPA D 0 A_Explode(Args[0],96,0)
TNT1 A 35 A_SpawnItemEx("ExplosionEffect2", 0, 0, 0, 0, 0, 0, 0, SXF_WEPFXCOLOR)
stop}}
actor CBM_CrystalEye : CrystalEye{+SKYEXPLODE}
actor CBM_CrystalEyeBit : CrystalEyeBit{+SKYEXPLODE}


actor CBM_CentaurFlash : CentaurFlash{Args 20 states{
Spawn:
TNT1 A 0
TNT1 A 2 A_Explode(Args[0],256,0,0,16+48)
stop}}
actor CBM_FlameBlast : FlameBlast{+SKYEXPLODE}
actor CBM_WindStorm : WindStorm{Args 15 states{
Spawn:
WINS A 0
WINS AA 2 A_Explode(Args[0],48,0,0,48)
WINS B 0 A_CountDown
WINS BB 2 A_Explode(Args[0],48,0,0,48)
WINS C 0 A_CountDown
WINS CC 2 A_Explode(Args[0],48,0,0,48)
WINS D 0 A_CountDown
WINS DD 2 A_Explode(Args[0],48,0,0,48)
WINS A 0 A_CountDown
loop}}


actor CBM_FreezeCracker : FreezeCracker{+SKYEXPLODE}
actor CBM_WrapExplosion : WrapExplosion{Args 53 states{
Spawn:
TNT1 A 0
TNT1 A 0 A_PlaySound("weapons/mm7/dangerwrapexplode",1)
TNT1 D 0 A_Explode(Args[0],128,0)
TNT1 A 35 A_SpawnItemEx("ExplosionEffect2",0,0,0,0,0,0,0,SXF_WEPFXCOLOR)
stop}}
actor CBM_ThunderBolt : ThunderBolt{+SKYEXPLODE}
actor CBM_ThunderBoltSplit : ThunderBoltSplit{+SKYEXPLODE}
actor CBM_WildCoil : WildCoil{+SKYEXPLODE}
actor CBM_WildCoil2 : WildCoil2{+SKYEXPLODE}
actor CBM_WildCoilL : WildCoilL{+SKYEXPLODE}
actor CBM_WildCoil2L : WildCoil2L{+SKYEXPLODE}
actor CBM_SlashClaw : SlashClaw{Args 25 states{
Spawn:
SCLA H 1
SCLA IJKL 1 A_Explode(Args[0],80,0)
stop}}
actor CBM_NoiseCrush : NoiseCrush{+SKYEXPLODE}
actor CBM_ScorchWheel : ScorchWheel{Args 16 states{
Spawn:
SWHE A 0
SWHE A 0 A_SpawnItemEx("OilPitIgnite",0,0,0)
SWHE ABCDEF 2 A_Explode(Args[0],96,0)
loop}}
actor CBM_ScorchWheel2 : ScorchWheel2{Args 16 states{
Spawn:
SWHE A 0
SWHE A 0 A_SpawnItemEx("OilPitIgnite",0,0,0)
SWHE ABCDEF 2 A_Explode(Args[0],96,0)
loop}}


actor CBM_TornadoHoldPod : TornadoHoldPod{+SKYEXPLODE}
actor CBM_HoldingTornado : HoldingTornado{Args 16 states{
Spawn:
TORH F 0
TORH F 0 ACS_NamedExecuteWithResult("core_alphaprojectile",CallACS("core_getptrtid",2),APROJ_TEAM,16384,192)
TORH F 0 ThrustThingZ(0,40,0,0)
SpawnLoop:
TORH FFFGGGHHH 1 A_GiveInventory("CBM_TornadoHoldFunc",1)
goto SpawnLoop}}
actor CBM_TornadoHoldFunc : CustomInventory{States{Pickup://Can't replace a pickup easily
TNT1 A 0 A_CountDown
TNT1 A 0 A_Explode(Args[0],32,0,0,32)
TNT1 A 0 A_RadiusGive("TornadoThruster",30,RGF_PLAYERS)
stop}}
actor CBM_AstroCrush : AstroCrush{+SKYEXPLODE Args 70 states{
Death:
ASEX A 0 A_PlaySound("weapons/mm8/astrocrushexplode",1)
ASEX A 0 A_SetGravity(0.0)
ASEX A 0 A_Explode(Args[0],128,0)
ASEX ABCDEF 2
stop}}
actor CBM_FlashBomb : FlashBomb{+SKYEXPLODE}
actor CBM_FlashBombExplosion : FlashBombExplosion{+BRIGHT Args 29,20,16 states{
Spawn:
FLEX ABCD 1
FLEX E 0 A_Explode(Args[0],80,0)
FLEX EE 0 A_SpawnItemEx("FlashBombFX2",Random(-16,16),Random(-40,40),Random(-32,32),0,0,0,0,SXF_WEPFXCOLOR)
FLEX EF 1 A_SpawnItemEx("FlashBombFX1",0,0,0,random(-7,7),random(-7,7),random(-7,7),random(0,359),SXF_WEPFXCOLOR)
FLEX EE 0 A_SpawnItemEx("FlashBombFX2",Random(-16,16),Random(-40,40),Random(-32,32),0,0,0,0,SXF_WEPFXCOLOR)
FLEX GF 1 A_SpawnItemEx("FlashBombFX1",0,0,0,random(-7,7),random(-7,7),random(-7,7),random(0,359),SXF_WEPFXCOLOR)
FLEX G 0 A_Explode(Args[0],80,0)
Goto Pattern1
Pattern1:
FLEX EF 1 A_SpawnItemEx("FlashBombFX1",0,0,0,random(-7,7),random(-7,7),random(-7,7),random(0,359),SXF_WEPFXCOLOR)
FLEX E 0 A_SpawnItemEx("FlashBombFX2",Random(-16,16),Random(-16,-40),Random(-32,32),0,0,0,0,SXF_WEPFXCOLOR)
FLEX GF 1 A_SpawnItemEx("FlashBombFX2",Random(-16,16),Random(16,40),Random(-32,32),0,0,0,0,SXF_WEPFXCOLOR)
FLEX G 0 A_SpawnItemEx("FlashBombFX1",0,0,0,random(-7,7),random(-7,7),random(-7,7),random(0,359),SXF_WEPFXCOLOR)
Goto DamageNow
Pattern2:
FLEX EF 1 A_SpawnItemEx("FlashBombFX1",0,0,0,random(-7,7),random(-7,7),random(-7,7),random(0,359),SXF_WEPFXCOLOR)
FLEX E 0 A_SpawnItemEx("FlashBombFX2",Random(-16,16),Random(32,64),Random(-32,40),0,0,0,0,SXF_WEPFXCOLOR)
FLEX E 0 A_SpawnItemEx("FlashBombFX2",Random(-16,16),Random(-32,-64),Random(-32,40),0,0,0,0,SXF_WEPFXCOLOR)
FLEX EF 1 A_SpawnItemEx("FlashBombFX2",Random(-16,16),Random(-40,40),Random(-32,32),0,0,0,0,SXF_WEPFXCOLOR)
FLEX G 0 A_SpawnItemEx("FlashBombFX1",0,0,0,random(-7,7),random(-7,7),random(-7,7),random(0,359),SXF_WEPFXCOLOR)
Goto DamageNow
DamageNow:
FLEX G 0 A_JumpIfInventory("CutterFlag",12,"Damage3")
FLEX G 0 A_JumpIfInventory("CutterFlag",4,"Damage2")
FLEX G 0 A_Explode(Args[0],80,0)
Goto Continue
Damage2:
FLEX G 0 A_Explode(Args[1],80,0)
Goto Continue
Damage3:
FLEX G 0 A_Explode(Args[2],80,0)
Goto Continue
Continue:
FLEX G 0 A_CountDown
FLEX G 0 A_GiveInventory("CutterFlag",1)
FLEX G 0 A_Jump(256,"Pattern1","Pattern2")
Goto Death
Death:
FLEX A 0 A_SetGravity(0.0)
FLEX G 1
TNT1 A 1 
FLEX D 1
TNT1 A 1 
FLEX D 1
TNT1 A 1 
FLEZ C 1
stop
}}
actor CBM_WaterBalloon : WaterBalloon{Args 8 states{
Death:
WTRB K 0 A_SpawnItemEx("SoakifyEffect")
WTRB K 0 A_SetGravity(0.0)
WTRB K 0 A_Explode(Args[0],64,0)
WTRB K 0 A_JumpIf(ceilingz-z<16,"DeathUp")
WTRB KLMN 2
stop}}
actor CBM_MegaBallKicked : MegaBallKicked{+SKYEXPLODE}


actor CBM_TenguDash : TenguDash{Args 7 states{
Spawn:
TNT1 A 0
SCLA HI 1 A_Explode(Args[0]*(CallACS("core_checkrune",RUNE_SPREAD,2)*2+1),64,0)
SCLA J 0 A_Explode(Args[0]*(CallACS("core_checkrune",RUNE_SPREAD,2)*2+1),64,0)
SCLA J 1 A_ScaleVelocity(0.5)
SCLA J 1 A_FadeOut(0.5)
stop}}
actor CBM_TenguSlash1 : TenguSlash1{Args 9 states{
Spawn:
TBLA E 0
TBLA G 0 A_SpawnItemEx("PropBlowerEffect")
TBLA EF 2 A_Explode(Args[0],80,0)
stop}}
actor CBM_TenguSlash2 : TenguSlash2{Args 9 states{
Spawn:
TBLA G 0
TBLA G 0 A_SpawnItemEx("PropBlowerEffect")
TBLA GF 2 A_Explode(Args[0],80,0)
stop}}
actor CBM_TenguBlade : TenguBlade{+SKYEXPLODE}
actor CBM_LightningBolt : LightningBolt{Args 47 states{
Spawn:
LIBO G 0
LIBO G 1 A_SpawnItemEx("LightningExtend",0,0,355,0,0,0,0,SXF_WEPFXCOLOR)
LIBO G 0 A_PlaySound("weapons/mmb/lightningboltexplode",1)
LIBO G 0 A_Explode(Args[0],128,0)
LIBO H 1
goto LightningBolt::Spawn+5}}
actor CBM_IceWallSpawner : IceWallSpawner{Args 11 States{
Spawn:
TNT1 A 0
TNT1 A 1
TNT1 A 1 A_Stop
ICWL ABCDE 2
ICWL F 0 A_ChangeFlag("NOGRAVITY",0)
ICWL F 0 A_Explode(Args[0],64,0)
ICWL F 0 A_SpawnItemEx("IcePitFreeze")
ICWL F 0 A_SpawnItemEx("IceWall")
stop
}}
actor CBM_IceWall : IceWall{Stamina 1 Args 11 states{//Second arg is for health threshold for low HP sprite
Spawn:
ICWL F 0
ICWL F 1 A_TakeInventory("IceWallFlag",1,0,2)
SpawnLoop:
ICWL F 1 A_JumpIfInventory("IceWallFlag",1,"Death",2)
ICWL F 0 A_JumpIf(momx>1||momy>1||momx<-1||momy<-1,"MoveBegin")
ICWL F 0 Thing_Damage(0,Stamina)//1
ICWL F 0 A_Explode(Args[0],64,0)
ICWL F 0 A_SpawnItemEx("IcePitFreeze")
loop
MoveBegin:
ICWL F 0 ACS_NamedExecuteAlways("core_stickyLifts",0,STICKYMODE_GUTSLIFT)
ICWL F 0 A_ChangeFlag("PUSHABLE",0)
ICWL F 0 ACS_NamedExecuteAlways("core_icewallmanage", 0, 1)
ICWL F 1 A_JumpIfInventory("IceWallFlag",1,"Death",2)
Accelerate:
ICWL F 0 A_Recoil(-3)
ICWL FFFFF 1 A_JumpIfInventory("IceWallFlag",1,"Death",2)
ICWL F 0 A_Recoil(-3)
ICWL FFFFF 1 A_JumpIfInventory("IceWallFlag",1,"Death",2)
ICWL F 0 A_Recoil(-3)
ICWL FFFFF 1 A_JumpIfInventory("IceWallFlag",1,"Death",2)
ICWL F 0 A_Recoil(-2)
ICWL FFFFF 1 A_JumpIfInventory("IceWallFlag",1,"Death",2)
ICWL F 0 A_Recoil(-2)
ICWL FFFFF 1 A_JumpIfInventory("IceWallFlag",1,"Death",2)
Moving:
ICWL F 0 A_JumpIfInventory("IceWallFlag",1,"Death",2)
ICWL F 0 A_SpawnItemEx("IcePitFreeze")
ICWL F 0 Thing_Damage(0,Stamina)//1
ICWL F 1 A_JumpIfHealthLower(Args[1],"MovingLow")
loop
MovingLow:
ICWL K 0 A_JumpIfInventory("IceWallFlag",1,"Death",2)
ICWL K 0 A_SpawnItemEx("IcePitFreeze")
ICWL K 1 Thing_Damage(0,Stamina)//1
loop
}}
actor CBM_RemoteMineExplosion : RemoteMineExplosion{Args 15 states{
Spawn:
REME A 0
REME A 0 A_Explode(Args[0],100,0)
REME A 1 A_PlaySoundEx("weapons/mmb/remotemineexplode", "Weapon")
REME BAC 1
REME A 1 A_Explode(Args[0],100,0)
REME DAF 1
REME A 1 A_Explode(Args[0],100,0)
REME GAH 1
REME A 1 A_Explode(Args[0],100,0)
REME IAJ 1
REME A 1 A_Explode(Args[0],100,0)
REME KAL 1
REME A 1 A_Explode(Args[0],100,0)
REME MAB 1
REME A 1 A_Explode(Args[0],100,0)
REME CAD 1
REME A 1 A_Explode(Args[0],100,0)
REME FAG 1
REME A 1 A_Explode(Args[0],100,0)
REME HANAPOPO 1
stop}}


actor CBM_ConcreteShot : ConcreteShot{+SKYEXPLODE}
actor CBM_TornadoDamager : TornadoDamager{Args 8 states{//Spawned on weapon, can't do spread check
Spawn:
TNT1 A 0
TNT1 A 1 A_Explode(Args[0],96,0,0,96)
stop}}
actor CBM_BlackHoleBombExplosion : BlackHoleBombExplosion{Args 5 states{
Spawn:
BLKH F 0
BLKH F 0 A_GiveToTarget("BlackHoleBombCooldown",1)
BLKH F 0 A_SpawnItemEx("BlackHoleBombFXSpawner",0,0,0,0,0,0,0,1)
BLKH F 0 A_PlaySoundEx("weapons/mm9/blackholebombexplode","body",1)
BLKH F 0 ACS_NamedExecuteAlways("core_radiuspull",0,7,256)
BLKH F 0 A_Explode(Args[0],128,0)
BLKH FFGG 1
BLKH F 0 ACS_NamedExecuteAlways("core_radiuspull",0,7,256)
BLKH F 0 A_Explode(Args[0],128,0)
BLKH HHII 1
BLKH F 0 ACS_NamedExecuteAlways("core_radiuspull",0,7,256)
BLKH F 0 A_Explode(Args[0],128,0)
BLKH JJKK 1
BLKH F 0 ACS_NamedExecuteAlways("core_radiuspull",0,7,256)
BLKH F 0 A_Explode(Args[0],128,0)
BLKH LLMM 1
BLKH F 0 ACS_NamedExecuteAlways("core_radiuspull",0,7,256)
BLKH F 0 A_Explode(Args[0],128,0)
BLKH NNOO 1
BLKH F 0 ACS_NamedExecuteAlways("core_radiuspull",0,7,256)
BLKH F 0 A_Explode(Args[0],128,0)
BLKH PPQQ 1
BLKH Q 0 A_Countdown
goto Spawn+3}}


actor CBM_ChillShot : ChillShot{+SKYEXPLODE}
actor CBM_ChillSpike : ChillSpike{Args 27 States{//Such a nested explosion
Spawn:
TNT1 A 0
TNT1 A 0 A_SetAngle(random(1,360))
TNT1 A 0 A_PlaySound("weapons/mm10/chillspikeland",1)
CHIL E 0 A_SpawnItemEx("ChillSpikeFloorFX1",WEPC_10CS_SPIKERADIUS,0,0,0,0,0,0,SXF_WEPFXCOLOR)
CHIL E 0 A_SpawnItemEx("ChillSpikeFloorFX1",WEPC_10CS_SPIKERADIUS,0,0,0,0,0,120,SXF_WEPFXCOLOR)
CHIL E 0 A_SpawnItemEx("ChillSpikeFloorFX1",WEPC_10CS_SPIKERADIUS,0,0,0,0,0,240,SXF_WEPFXCOLOR)
CHIL EE 1 A_Explode(Args[0],WEPC_10CS_SPIKEEXPLODE,0,0,WEPC_10CS_SPIKEEXPLODE)
CHIL E 0 A_SetDamageType("ChillSpike")
Spawn2:
CHIL F 0 A_SpawnItemEx("ChillSpikeFloorFX2",WEPC_10CS_SPIKERADIUS,0,0,0,0,0,0,SXF_WEPFXCOLOR)
CHIL F 0 A_SpawnItemEx("ChillSpikeFloorFX2",WEPC_10CS_SPIKERADIUS,0,0,0,0,0,120,SXF_WEPFXCOLOR)
CHIL F 0 A_SpawnItemEx("ChillSpikeFloorFX2",WEPC_10CS_SPIKERADIUS,0,0,0,0,0,240,SXF_WEPFXCOLOR)
CHIL F 0 A_Explode(Args[0],WEPC_10CS_SPIKEEXPLODE,0,0,WEPC_10CS_SPIKEEXPLODE)
CHIL F 1 A_CountDownArg(0)
loop
}}
actor CBM_WallSpike : WallSpike{Args 27 States{
Spawn:
TNT1 A 0
TNT1 A 1
TNT1 A 0 A_SetUserVar(user_angle,random(1,120))
TNT1 A 0 A_PlaySound("weapons/mm10/chillspikeland",1)
CHIL G 0 A_SpawnItemEx("ChillSpikeWallFX1",3,cos(user_angle)*WEPC_10CS_SPIKERADIUS,sin(user_angle)*WEPC_10CS_SPIKERADIUS,0,0,0,0,SXF_WEPFXCOLOR)
CHIL G 0 A_SpawnItemEx("ChillSpikeWallFX1",3,cos(user_angle+120)*WEPC_10CS_SPIKERADIUS,sin(user_angle+120)*WEPC_10CS_SPIKERADIUS,0,0,0,0,SXF_WEPFXCOLOR)
CHIL G 0 A_SpawnItemEx("ChillSpikeWallFX1",3,cos(user_angle+240)*WEPC_10CS_SPIKERADIUS,sin(user_angle+240)*WEPC_10CS_SPIKERADIUS,0,0,0,0,SXF_WEPFXCOLOR)
CHIL GG 1 A_Explode(Args[0],WEPC_10CS_SPIKEEXPLODE,0,0,WEPC_10CS_SPIKEEXPLODE)
CHIL E 0 A_SetDamageType("ChillSpike")
Spawn2:
CHIL H 0 A_SpawnItemEx("ChillSpikeWallFX2",3,cos(user_angle)*WEPC_10CS_SPIKERADIUS,sin(user_angle)*WEPC_10CS_SPIKERADIUS,0,0,0,0,SXF_WEPFXCOLOR)
CHIL H 0 A_SpawnItemEx("ChillSpikeWallFX2",3,cos(user_angle+120)*WEPC_10CS_SPIKERADIUS,sin(user_angle+120)*WEPC_10CS_SPIKERADIUS,0,0,0,0,SXF_WEPFXCOLOR)
CHIL H 0 A_SpawnItemEx("ChillSpikeWallFX2",3,cos(user_angle+240)*WEPC_10CS_SPIKERADIUS,sin(user_angle+240)*WEPC_10CS_SPIKERADIUS,0,0,0,0,SXF_WEPFXCOLOR)
CHIL H 0 A_Explode(Args[0],WEPC_10CS_SPIKEEXPLODE,0,0,WEPC_10CS_SPIKEEXPLODE)
CHIL H 1 A_CountDownArg(0)
loop
}}
actor CBM_CeilingSpike : CeilingSpike{Args 27 States{
Spawn:
TNT1 A 0
TNT1 A 0 A_SetAngle(random(1,360))
TNT1 A 0 A_PlaySound("weapons/mm10/chillspikeland",1)
CHIL I 0 A_SpawnItemEx("ChillSpikeCeilingFX1",WEPC_10CS_SPIKERADIUS,0,0,0,0,0,0,SXF_WEPFXCOLOR)
CHIL I 0 A_SpawnItemEx("ChillSpikeCeilingFX1",WEPC_10CS_SPIKERADIUS,0,0,0,0,0,120,SXF_WEPFXCOLOR)
CHIL I 0 A_SpawnItemEx("ChillSpikeCeilingFX1",WEPC_10CS_SPIKERADIUS,0,0,0,0,0,240,SXF_WEPFXCOLOR)
CHIL II 1 A_Explode(Args[0],WEPC_10CS_SPIKEEXPLODE,0,0,WEPC_10CS_SPIKEEXPLODE)
CHIL E 0 A_SetDamageType("ChillSpike")
Spawn2:
CHIL J 0 A_SpawnItemEx("ChillSpikeCeilingFX2",WEPC_10CS_SPIKERADIUS,0,0,0,0,0,0,SXF_WEPFXCOLOR)
CHIL J 0 A_SpawnItemEx("ChillSpikeCeilingFX2",WEPC_10CS_SPIKERADIUS,0,0,0,0,0,120,SXF_WEPFXCOLOR)
CHIL J 0 A_SpawnItemEx("ChillSpikeCeilingFX2",WEPC_10CS_SPIKERADIUS,0,0,0,0,0,240,SXF_WEPFXCOLOR)
CHIL J 0 A_Explode(Args[0],WEPC_10CS_SPIKEEXPLODE,0,0,WEPC_10CS_SPIKEEXPLODE)
CHIL J 1 A_CountDownArg(0)
loop
}}
actor CBM_ThunderWoolRadius : ThunderWoolRadius{Args 13 states{
Spawn:
TNT1 A 0
TNT1 A 0 A_SpawnItemEx("ThunderWoolImpact",0,0,0,0,0,0,0,SXF_WEPFXCOLOR)
TNT1 A 0 A_SpawnItemEX("ElectrifyEffect")
TNT1 A 0 A_Explode(Args[0],WEPC_10TW_RADIUS,0,0,WEPC_10TW_RADIUS)
goto Super::Spawn+3}}
actor CBM_ReboundStriker : ReboundStriker{+SKYEXPLODE}
actor CBM_ReboundStrikerMax : ReboundStrikerMax{+SKYEXPLODE}
actor CBM_SolarBlaze : SolarBlaze{+SKYEXPLODE}


actor CBM_BubbleBomb : BubbleBomb{Args 42 states{
Death:
BBOM A 0
BBOM A 0 A_SpawnItemEx("SoakifyEffect")
BBOM A 0 A_PlaySound("weapons/mmv/bubblebombexplode",1)
BBOM A 0 A_Explode(Args[0],96,0,0,48)
TNT1 A 35 A_SpawnItemEx("ExplosionEffect2",0,0,0,0,0,0,0,SXF_WEPFXCOLOR)
stop}}
actor CBM_BubbleBomb2 : CBM_BubbleBomb{States{
Spawn:
TNT1 A 1
TNT1 A 0 A_SetUserVar("user_DIRECTION",-1)
TNT1 A 0 A_SetUserVar("user_SPEED", 6)
goto SpawnStart}}
actor CBM_PhotonMissile : PhotonMissile{+SKYEXPLODE}
actor CBM_PhotonMissileExplosion : PhotonMissileExplosion{Args 60 states{
Spawn:
TNT1 A 0
TNT1 A 0 A_PlaySound("weapons/mmv/photonmissileexplode",0)
TNT1 A 0 A_Explode(Args[0],128,0,0,64)
TNT1 A 35 A_SpawnItemEx("ExplosionEffect3",0,0,0,0,0,0,0,SXF_WEPFXCOLOR)
stop}}
actor CBM_BlackHoleShockWave : BlackHoleShockWave{Args 20 States{
Spawn:
BHOL Y 0
BHOL Y 0 A_Setangle(angle+args[ARGC_MAXTURN]/args[ARGC_TURNDIVISOR])
Spawn2:
BHOL YYZZ 1 A_GiveInventory("CBM_BlackholeShockWaveFunc",1)
loop}}
actor CBM_BlackholeShockWaveFunc : BlackholeShockWaveFunc{States{Pickup:
TNT1 A 0 A_CountDown
TNT1 A 0 A_Explode(Args[0],32,0,0,32)
TNT1 A 0 A_GiveInventory("RotateFunc",1)
stop}}
actor CBM_DeepDigger : DeepDigger{+SKYEXPLODE}
actor CBM_BreakDashCheck : BreakDashCheck{damage (55*(CallACS("core_checkrune",RUNE_SPREAD,2)*2+1))}
actor CBM_SaltWater : SaltWater{+SKYEXPLODE}
actor CBM_SaltWaterBit : SaltWaterBit{+SKYEXPLODE}


actor CBM_ScrewCrusher : ScrewCrusher{+SKYEXPLODE}
actor CBM_BalladeCracker : BalladeCracker{+SKYEXPLODE Args 40 states{
Death:
BALA A 0 A_PlaySound("weapons/mmk/balladecrackerexplode",1)
BALA A 0 A_Explode(Args[0],96,0)
TNT1 A 35 A_SpawnItemEx("ExplosionEffect2",0,0,0,0,0,0,0,SXF_WEPFXCOLOR)
stop}}
actor CBM_SakugarneCrush : SakugarneCrush{damage (27*(CallACS("core_checkrune",RUNE_SPREAD,2)*2+1))}
actor CBM_SakugarneDriller : SakugarneDriller{Args 80 states{
Spawn:
TNT1 A 0
TNT1 AAAAA 0 A_SpawnItemEx("SakugarneDebris",0,0,-14,random(1,5),random(-10,10),random(8,12),random(-5,5),SXF_WEPFXCOLOR)
TNT1 A 0 A_TakeFromTarget("SakugarneAmmo",2,TIF_NOTAKEINFINITE)
TNT1 A 4 A_Explode(Args[0]*(CallACS("core_checkrune",RUNE_SPREAD,2)*2+1),144,0)
stop}}

actor CBM_BlastRuneExplosion : BlastRuneExplosion{Args 25 states{
Spawn:
TNT1 A 0
TNT1 A 0 A_Explode(Args[0],64,0,0,25)
TNT1 A 0 A_PlaySound("weapons/mmk/dawnbreakerexplode",1)
DBR1 NMOPQRST 1
stop}}
actor CBM_DawnBreakerEmitter : DawnBreakerEmitter{Args 0,15 States{
Spawn:
DBR1 E 0
DBR1 E 0 A_SetPitch(30)
DBR1 E 0 A_SetArg(0,16)
Drag:
DBR1 V 0 A_SetScale(0.5,2.0)
DBR1 V 1 A_SpawnItemEx("DawnBreakerFX1",-momx,-momy,32,momx,momy,0,0,1+2+8+512)//SXF_TRANSFERTRANSLATION|SXF_ABSOLUTEMOMENTUM|SXF_ABSOLUTEPOSITION|SXF_TRANSFERPITCH
DBR1 U 0 A_SetScale(1.0,2.0)
DBR1 U 1 A_SpawnItemEx("DawnBreakerFX2",-momx,-momy,32,momx,momy,0,0,1+2+8+512)
DBR1 V 0 A_SetScale(1.5,2.0)
DBR1 V 1 A_SpawnItemEx("DawnBreakerFX3",-momx,-momy,32,momx,momy,0,0,1+2+8+512)
DBR1 U 0 A_SetScale(2.0,2.0)
DragLoop:
DBR1 U 0 A_Explode(Args[1],24,0,0,24)
DBR1 U 0 A_SetAngle(angle+12)
DBR1 U 0 A_ChangeVelocity(8,0,0,3)//CVF_RELATIVE|CVF_REPLACE
DBR1 U 0 A_SetArg(0,args[0]-1)
DBR1 U 0 A_JumpIf(args[0]<=0,"End")
DBR1 UUU 1 A_SpawnItemEx("DawnBreakerFX4",-momx,-momy,32,momx,momy,0,0,1+2+8+512)
DBR1 V 0 A_Explode(Args[1],24,0,0,24)
DBR1 V 0 A_SetAngle(angle+12)
DBR1 V 0 A_ChangeVelocity(8,0,0,3)
DBR1 V 0 A_SetArg(0,args[0]-1)
DBR1 V 0 A_JumpIf(args[0]<=0,"End")
DBR1 VVV 1 A_SpawnItemEx("DawnBreakerFX5",-momx,-momy,32,momx,momy,0,0,1+2+8+512)
loop
}
}
actor CBM_DawnBreakerDive : DawnBreakerDive{Args 12 states{
Spawn:
TNT1 A 0
TNT1 A 1 A_Explode(Args[0],64,0,0,64)
stop}}
actor CBM_DawnBreakerQuake : DawnBreakerQuake{Args 6 states{
Spawn:
TNT1 A 0
TNT1 A 0 Radius_Quake(6,7,0,3,0)
TNT1 A 0 A_PlaySound("weapons/mmk/dawnbreakerquake",1)
TNT1 AAAAAAAAAA 0 A_SpawnItemEx("DawnBreakerDebris",0,0,0,random(1,5),random(-10,10),random(8,12),random(-5,5))
TNT1 A 0 A_Explode(Args[0],96,0,0,96)
TNT1 A 35
stop}}



