//= Guts Man
//	Jump height increased: 12 > 14
//	Ult duration reduced: 25 seconds > 16 seconds
//	Movement recoded
actor Gutsman : HighArmorClass
{
Player.ScoreIcon "GUTSMUGS"
player.startitem "IsFromMM1"
player.startitem "BaseFlagPack", 1
player.displayname "Gutsman"
player.soundclass "Gutsmanc"
player.startitem "SuperArmBoss"
player.startitem "CanThirdFire", 1
player.startitem "UltimateAttackItem3"
player.startitem "UltSoundWatcherSpawn3"
player.startitem "Base56Ammo", 56
player.startitem "HighArmor"
player.startitem "IsHeavy"
player.viewheight 51
player.forwardmove 0.7,0.7
player.sidemove 0.68,0.68
player.jumpz 14
gravity 1.2
States
{
Animation0:
Spawn:
GUTS B 0 A_JumpIfInventory("VCOnce",1,"Spawn.GutsManG")
GUTS B 1 A_JumpIf(z-floorz>0,"Jumping")
Spawn.Idle:
GUTS AAAAAAMMMMMM 1 A_JumpIf(z-floorz>0, "Jumping")
Goto Spawn.Idle
Spawn.WithRock:
GUTS B 0 A_JumpIf(momx>1||momy>1||momx<-1||momy<-1,"See.WithRock")
GUTS B 1 A_JumpIf(z-floorz>0,"Jumping")
GUTS F 0 A_JumpIf(momx>1||momy>1||momx<-1||momy<-1,"See.WithRock")
GUTS F 1 A_JumpIf(z-floorz>0,"Jumping")
Goto Spawn.WithRock+2

Animation5:
Spawn.GutsManG:
GGUS B 0 A_JumpIf(momx>1||momy>1||momx<-1||momy<-1,"See.GutsManG")
GGUS B 1
GGUS A 0 A_JumpIf(momx>1||momy>1||momx<-1||momy<-1,"See.GutsManG")
GGUS A 1
Goto Spawn.GutsManG+2

See:
GUTS B 0 A_JumpIfInventory("VCOnce",1,"See.GutsManG")
GUTS B 0 A_JumpIfInventory("CutterFlag",1,"See.WithRock")
GUTS BBBBBCCCCCDDDDDEEEEE 1 A_JumpIf(z-floorz>0,"Jumping") 
Goto Spawn+1
See.WithRock:
GUTS P 0 A_JumpIfInventory("VCOnce",1,"See.GutsManG")
GUTS PPPPPQQQQQRRRRRSSSSS 1 A_JumpIf(z-floorz>0,"Jumping.WithRock")
Goto Spawn.WithRock
See.GutsManG:
GGUS BBBBCCCCDDDDEEEE 1 
Goto Spawn.GutsManG

Animation1:
Jumping:
GUTS B 0 A_JumpIfInventory("VCOnce",1,"Spawn.GutsManG")
GUTS I 0 A_JumpIfInventory("CutterFlag",1,"Jumping.WithRock")
GUTS I 1 A_JumpIf(z-floorz<=0,"Land")
wait


Jumping.WithRock:
GUTS J 1 A_JumpIf(z-floorz<=0,"Land.WithRock")
wait

Land:
GUTS N 0 A_JumpIfInventory("CutterFlag",1,"Land.WithRock")
GUTS NNNN 1 A_JumpIf(z-floorz>0,"Jumping")
goto Spawn.Idle
Land.WithRock:
GUTS OOOO 1 A_JumpIf(z-floorz>0,"Jumping.WithRock")
goto Spawn.WithRock+2

Missile:
GUTS AA 0 A_JumpIfInventory("VCOnce",1,"PowerArmWait")
GUTS AAA 1 A_JumpIf(z-floorz>0,"JumpingMissile")
goto Spawn.Idle
JumpingMissile:
GUTS JJJ 1 A_JumpIf(z-floorz<=0,"Missile")
Goto Jumping

Animation2:
BlockSummon:
GUTS FFFFF 1 A_JumpIf(z-floorz>0,"JumpingBlockSummon")
BlockSummon2:
GUTS FFFFF 1 A_JumpIf(z-floorz>0,"JumpingBlockSummon2")
Goto Spawn.WithRock+3
JumpingBlockSummon:
GUTS JJJJJ 1 A_JumpIf(z-floorz<=0,"BlockSummon")
JumpingBlockSummon2:
GUTS JJJJJ 1 A_JumpIf(z-floorz<=0,"BlockSummon2")
Goto Jumping.WithRock

Animation3:
Missile2:
GUTS GGG 1 A_JumpIf(z-floorz>0,"JumpingMissile2")
Goto Spawn.Idle
JumpingMissile2:
GUTS KKK 1 A_JumpIf(z-floorz<=0,"Missile2")
Goto Jumping

Animation4:
GutsTackle:
GUTS LLLLL 1
Goto Spawn+2

Animation6:
PowerArmWait:
GGUS JJJ 1
Goto Spawn.GutsManG+2

Animation7:
PowerArmA:
GGUS FFF 1
Goto Spawn.GutsManG+2
Animation8:
PowerArmB:
GGUS GGG 1
Goto Spawn.GutsManG+2

Animation9:
PowerDrill:
GGU2 GGG 1
Goto Spawn.GutsManG+2

Animation10:
PowerUpperCut:
GGUS KKK 1
Goto Spawn.GutsManG+2

ClassPain:
GUTS H 0 A_JumpIfInventory("VCOnce",1,"ClassPain.GutsManG")
GUTS HHHHHHHHHH 2 A_SpawnItem("PainFX",0,3)
TNT1 A 0 A_JumpIfInventory("CutterFlag",1,1)
Goto Spawn+1
TNT1 A 0
Goto Spawn.WithRock+1
ClassPain.GutsManG:
GGUS HHHHHHHHHH 2 A_SpawnItem("PainFX",0,3)
Goto Spawn.GutsManG+1

ClassDeath:
GUTS ] 0 A_JumpIfInventory("VCOnce",1,"ClassDeath.GutsManG")
GUTS ] 8 ACS_ExecuteAlways(999,0,0)
GUTS ] 12 A_SpawnItemEx("MM1Death")
GUTS ] 0 A_PlayerScream
GUTS ] 0 A_SpawnItemEx("FakeDeathFXMM1", 0, 0, 32)
NOFX A 1 A_CheckPlayerDone
wait
ClassDeath.GutsManG:
TNT1 A 0 A_SpawnItemEx("DeadGutsManG")
TNT1 A 0 A_SpawnItemEx("DeadGutsManGArm",0,48,64,0,0,5)
TNT1 A 20 ACS_ExecuteAlways(999,0,0)
TNT1 A 0 A_PlayerScream
NOFX A 1 A_CheckPlayerDone
wait
WeaponGetM:
CUTM H 0 A_JumpIfInTargetInventory("SuperArmWepM",1,2)
CUTM H 0 A_GiveToTarget("WeaponGetter")
CUTM H 0 A_GiveToTarget("SuperArmWepM")
goto ClassDeath
}
}

Actor DeadGutsManG
{
Translation "192:192=216:216", "198:198=41:41"
+NOINTERACTION
scale 2.5
const int OFS = 64;
States
{
Spawn:
TNT1 AA 0 A_GiveInventory("ProjectileCode")
GGU2 H 35
"####" "#" 1 A_Jump(256,"Death.Timer1")
Goto Death.Timer1
Death.Timer1:
"####" "#" 0 A_Quake(2,3,0,500) "####" "#" 0 A_PlaySoundEx("weapon/mm7explode","SoundSlot5")
"####" "#" 12 A_SpawnItemEx("MM7ExplodeFX",Random(-OFS,OFS),Random(-OFS,OFS),Random(0,128))
"####" "#" 0 A_StopSoundEx("SoundSlot5")
"####" "#" 0 A_GiveInventory("CutterFlag",1)
"####" "#" 0 A_JumpIfInventory("CutterFlag",3,"Death.Timer2")
loop
Death.Timer2:
"####" "#" 0 A_Quake(2,3,0,500) "####" "#" 0 A_PlaySoundEx("weapon/mm7explode","SoundSlot5")
"####" "#" 9 A_SpawnItemEx("MM7ExplodeFX",Random(-OFS,OFS),Random(-OFS,OFS),Random(0,128))
"####" "#" 0 A_StopSoundEx("SoundSlot5")
"####" "#" 0 A_GiveInventory("CutterFlag",1)
"####" "#" 0 A_JumpIfInventory("CutterFlag",9,"Death.Timer3")
loop
Death.Timer3:
"####" "#" 0 A_Quake(2,3,0,500) "####" "#" 0 A_PlaySoundEx("weapon/mm7explode","SoundSlot5")
"####" "#" 6 A_SpawnItemEx("MM7ExplodeFX",Random(-OFS,OFS),Random(-OFS,OFS),Random(0,128))
"####" "#" 0 A_StopSoundEx("SoundSlot5")
"####" "#" 0 A_GiveInventory("CutterFlag",1)
"####" "#" 0 A_JumpIfInventory("CutterFlag",15,"Death.Timer4")
loop
Death.Timer4:
"####" "#" 0 A_Quake(2,3,0,500) "####" "#" 0 A_PlaySoundEx("weapon/mm7explode","SoundSlot5")
"####" "#" 3 A_SpawnItemEx("MM7ExplodeFX",Random(-OFS,OFS),Random(-OFS,OFS),Random(0,128))
"####" "#" 0 A_StopSoundEx("SoundSlot5")
"####" "#" 0 A_GiveInventory("CutterFlag",1)
"####" "#" 0 A_JumpIfInventory("CutterFlag",45,"Death")
loop
Death:
TNT1 A 0 A_PlaySoundEx("mm7/dead","Auto")
TNT1 A 0 A_SpawnItemEx("FakeDeathFXMM7",0,0,64)
TNT1 A 35 A_Quake(3,35,0,500)
stop
}
}

actor DeadGutsManGArm
{
Translation "192:192=216:216", "198:198=41:41"
PROJECTILE
-NOGRAVITY
+THRUACTORS
+BOUNCEONCEILINGS
Gravity 1.0
height 8
radius 8
scale 2.5
States
{
Spawn:
TNT1 AA 0 A_GiveInventory("ProjectileCode")
GGRM A 1
wait
Death:
TNT1 A 0 A_PlaySoundEx("weapon/mm7explode", "Weapon")
TNT1 AAAAAAAAAA 0 A_SpawnItemEx("MM7ExplodeFX",0,0,48,Random(5,15),0,Random(-10,10),Random(0,359))
stop
}
}

Actor SuperArmBoss : VCBaseWeapon
{
weapon.ammotype "Base56Ammo"
Obituary "$OB_GUTSMAN1"
const int HGT = 88;
CONST int OFS = 16;
const int ammoUseAlt = 28;//32;
States
{
Ready:
TNT1 A 0 A_JumpIfInventory("GutsTFCooldown",1,"Ready.NoTF")//A_JumpIfInventory("Base56Ammo",14,"Ready.CanTF")
GARM A 1 A_WeaponReady(WRF_NOSECONDARY*CallACS("VC_AmmoCheck",1,ammoUseAlt)) TNT1 A 0 A_JumpIf(ACS_NamedExecuteWithResult("VC_CheckBtn",3)==3,"User1")
TNT1 A 0 A_JumpIfInventory("UltAttackFlag",1,"UltimateAttack")
GARM A 1 A_WeaponReady(WRF_NOSECONDARY*CallACS("VC_AmmoCheck",1,ammoUseAlt)) TNT1 A 0 A_JumpIf(ACS_NamedExecuteWithResult("VC_CheckBtn",3)==3,"User1")
TNT1 A 0 A_JumpIfInventory("UltAttackFlag",1,"UltimateAttack")
TNT1 A 0 A_GiveInventory("Base56Ammo",1)
loop
Ready.NoTF:
GARM A 1 A_WeaponReady(WRF_NOSECONDARY*CallACS("VC_AmmoCheck",1,ammoUseAlt))
TNT1 A 0 A_JumpIfInventory("UltAttackFlag",1,"UltimateAttack")
GARM A 1 A_WeaponReady(WRF_NOSECONDARY*CallACS("VC_AmmoCheck",1,ammoUseAlt))
TNT1 A 0 A_JumpIfInventory("UltAttackFlag",1,"UltimateAttack")
TNT1 A 0 A_GiveInventory("Base56Ammo",1)
TNT1 A 0 A_JumpIfInventory("GutsTFCooldown",1,"Ready.NoTF")
goto Ready
//loop
Ready.Ultimate:
TNT1 A 0 A_JumpIfInventory("MediumUltimateAmmo",1,1)
Goto Ultimate.Finish
GARM J 1 A_WeaponReady(WRF_NOPRIMARY*CallACS("VC_AmmoCheck",1,7)|WRF_NOSECONDARY*CallACS("VC_AmmoCheck",1,1))
TNT1 A 0 A_JumpIf(ACS_NamedExecuteWithResult("VC_CheckBtn",3)==3,"User1.Ultimate")
GARM J 1 A_WeaponReady(WRF_NOPRIMARY*CallACS("VC_AmmoCheck",1,7)|WRF_NOSECONDARY*CallACS("VC_AmmoCheck",1,1))
TNT1 A 0 A_JumpIf(ACS_NamedExecuteWithResult("VC_CheckBtn",3)==3,"User1.Ultimate")
TNT1 A 0 A_GiveInventory("Base56Ammo",1)
loop

Deselect:
TNT1 AAAAAAAAAAAAAAAAAAAAAA 0 A_Lower
GARM A 1 A_Lower
Loop
Select:
TNT1 A 0 A_SpawnItemEx("GutsmanSkinWatcher")
TNT1 A 0 ACS_ExecuteAlways(991,0,721)
GARM A 4//trying to mitigate desync, no clue if it actually works lmfao
TNT1 AAAAAAAAAAAAAAAAAAAAAA 0 A_Raise
GARM A 1 A_Raise
Loop

Fire:
TNT1 A 0 A_JumpIfInventory("VCOnce",1,"Fire.Ultimate")
TNT1 A 0 A_JumpIfInventory("CutterFlag",8,"User1.ThrowBlock.Fire")
TNT1 A 0 A_JumpIfInventory("CutterFlag",1,"Fire.ThrowBlock")
TNT1 A 0 A_CheckFloor("Fire.SummonRock")//Anti desync rofl
TNT1 A 0 A_JumpIf(callACS("core_CheckFooting")== 1 || (abs(z-floorz) < 30 && momz <= 0),"Fire.SummonRock")//A_JumpIf(z-floorz<8,"Fire.SummonRock")//A_JumpIf(z-floorz<8,"Fire.SummonRock")
Fire.GutsLanding:
TNT1 A 0 ThrustThingZ(0,-30,0,1)
TNT1 A 0 ACS_NamedExecuteWithResult("VC_SetState",1)
GARM A 1 A_CheckFloor(1)//A_JumpIf(z-floorz<=0,1)
loop
TNT1 A 0 A_Quake(3,25,0,300)
TNT1 A 0 A_SpawnItemEx("GutsmanQuakeRadius")
TNT1 A 0 A_SpawnItemEx("ConcreteShockwaveRadius")
TNT1 A 0 A_PlaySoundEx("weapon/GutsmanQuake","SoundSlot5")
TNT1 AAAAAAAAAA 0 A_SpawnItemEx("GutsQuakeDebris",random(32,160),0,0,0,0,random(5,10),random(0,359))
Fire.SummonRock:
TNT1 A 0 A_GiveInventory("CutterFlag",Random(1,7))
TNT1 A 0 A_GiveInventory("GutsManTempRockPickUp",1)
BoulderSummon:
TNT1 A 0 A_GunFlash("Flash.SummonHold")
GARM BBBCCCDDDEEFFGGQQ 1 ACS_NamedExecuteWithResult("VC_SetState",2)
TNT1 A 0 A_GunFlash("Flash.End")
RockHold:
GARM G 0 A_ClearRefire
GARM G 1 A_WeaponReady
wait
Fire.ThrowBlock:
TNT1 A 0 A_GiveInventory("GutsManBlockPickUp",1)
ThrowBlock.Boulder:
TNT1 AA 0 A_GiveInventory("GutsManThrowBlockTrigger",1)
GARM HH 1 ACS_NamedExecuteWithResult("VC_SetState",3)
GARM B 1 Offset(0,65)ACS_NamedExecuteWithResult("VC_SetState",3)
GARM B 1 Offset(0,105)ACS_NamedExecuteWithResult("VC_SetState",3)
GARM B 1 Offset(0,145)ACS_NamedExecuteWithResult("VC_SetState",3)
GARM B 1 Offset(0,185)ACS_NamedExecuteWithResult("VC_SetState",3)
TNT1 A 15 Offset(0,70)
GARM A 1 Offset(0,65)
GARM A 1 Offset(0,60)
GARM A 1 Offset(0,55)
GARM A 1 Offset(0,50)
GARM A 1 Offset(0,45)
GARM A 1 Offset(0,40)
GARM A 1 Offset(0,35)
Goto Ready

Altfire:
TNT1 A 0 A_JumpIfInventory("VCOnce",1,"Altfire.Ultimate")
TNT1 A 0 A_JumpIfInventory("CutterFlag",8,"User1.ThrowBlock.Altfire")
TNT1 A 0 A_JumpIfInventory("CutterFlag",1,"Altfire.ThrowBlock")
TNT1 A 0 A_JumpIfInventory("NoAltfire",1,"Ready")
TNT1 A 0 A_Recoil(CallACS("VC_XYMob", -30.0))//A_Recoil(-30)
TNT1 A 0 A_TakeInventory("Base56Ammo",ammoUseAlt)
TNT1 A 0 A_PlaySoundEx("weapon/chargekick","Weapon")
//TNT1 A 0 A_JumpIf(z-floorz>8,"Altfire.Continue")
TNT1 A 0 A_SpawnItemEx("TenguDustG",-32,0,0,-8,0,0)
Altfire.Continue:
GARM I 1 Offset(-9,32) A_SpawnItemEx("GutsTackleHitBox") TNT1 A 0 ACS_NamedExecuteWithResult("VC_SetState",4)
GARM I 1 Offset(-24,32) ACS_NamedExecuteWithResult("VC_SetState",4)
GARM I 1 Offset(-35,32) ACS_NamedExecuteWithResult("VC_SetState",4)
GARM I 1 Offset(-42,32) ACS_NamedExecuteWithResult("VC_SetState",4)
Altfire.Waiting:
GARM IIIIIIIIIIII 1 Offset(-45,32) ACS_NamedExecuteWithResult("VC_SetState",4)//12
GARM I 1 Offset(-44,32) ACS_NamedExecuteWithResult("VC_SetState",4)
GARM I 1 Offset(-42,32) ACS_NamedExecuteWithResult("VC_SetState",4)
GARM I 1 Offset(-39,32) ACS_NamedExecuteWithResult("VC_SetState",4)
GARM I 1 Offset(-35,32) ACS_NamedExecuteWithResult("VC_SetState",4)
GARM I 1 Offset(-30,32) ACS_NamedExecuteWithResult("VC_SetState",4)
GARM I 1 Offset(-24,32) ACS_NamedExecuteWithResult("VC_SetState",4)
GARM I 1 Offset(-17,32) ACS_NamedExecuteWithResult("VC_SetState",4)
GARM I 1 Offset(-9,32) ACS_NamedExecuteWithResult("VC_SetState",4)
GARM I 1 Offset(-1,32) ACS_NamedExecuteWithResult("VC_SetState",4)
TNT1 A 0 ACS_NamedExecuteWithResult("VC_SetState",0)
GARM AAAAAAAAAAAA 1 A_TakeInventory("VCOnceMore",99)
Goto Ready
Altfire.ThrowBlock:
TNT1 A 0 A_GiveInventory("GutsManBlockPickUp2",1)
goto ThrowBlock.Boulder

User1:
TNT1 A 0 A_JumpIfInventory("VCOnce",1,"User1.Ultimate")
TNT1 A 0 A_JumpIf(z-floorz<8,"User1.SummonRock")
User1.GutsLanding:
TNT1 A 0 ThrustThingZ(0,-30,0,1)
TNT1 A 0 ACS_NamedExecuteWithResult("VC_SetState",1)
GARM A 1 A_JumpIf(z-floorz<=0,1)
loop
TNT1 A 0 A_Quake(3,25,0,300)
TNT1 A 0 A_SpawnItemEx("GutsmanQuakeRadius")
TNT1 A 0 A_SpawnItemEx("ConcreteShockwaveRadius")
TNT1 A 0 A_PlaySoundEx("weapon/GutsmanQuake","SoundSlot5")
TNT1 AAAAAAAAAA 0 A_SpawnItemEx("GutsQuakeDebris2",random(32,160),0,0,0,0,random(5,10),random(0,359))
User1.SummonRock:
TNT1 A 0 A_GiveInventory("CutterFlag",8)
TNT1 A 0 A_SpawnItemEx("GutsManTempRockBoulder")
Goto BoulderSummon
User1.ThrowBlock.Fire:
TNT1 A 0 A_FireCustomMissile("GutsBoulderThrowMain",0,0,0,58)
Goto User1.ThrowBlock2
User1.ThrowBlock.Altfire:
TNT1 A 0 A_FireCustomMissile("GutsBoulderThrowAlt",0,0,0,58)
Goto User1.ThrowBlock2
User1.ThrowBlock2:
TNT1 A 0 A_TakeInventory("CutterFlag",99)
TNT1 A 0 A_SpawnItemEx("GutsTFWatcher")
TNT1 A 0 ACS_NamedExecuteWithResult("VC_SetState",3)
TNT1 A 0 A_PlaySound("weapon/GutsmanToss","Weapon")
Goto ThrowBlock.Boulder

UltimateAttack:
TNT1 A 0 A_GiveInventory("NoPushFlag",1)
TNT1 A 0 A_GiveInventory("InvProtection")
TNT1 A 0 A_ChangeFlag("INVULNERABLE",True)
TNT1 A 0 A_TakeInventory("UltAttackFlag",1)
TNT1 A 0 A_GiveInventory("PowerUltBuildCooldown",1)
TNT1 A 0 ACS_NamedExecuteAlways("VC_UltimateText",0,7)
TNT1 A 0 A_PlaySoundEx("classes/ultimateactivation","Auto")
GARM A 2 ThrustThingZ(0,50,0,1)
Ultimate.Start.Landing:
TNT1 A 0 ACS_NamedExecuteWithResult("VC_SetState",1)
GARM A 1 A_JumpIf(z-floorz<=0,1)
loop
TNT1 A 0 A_PlaySoundEx("weapon/drilldigmid","Weapon",True)
TNT1 AAAAAAAAAAA 0 A_SpawnItemEx("BlockDebrisSpawner",24,0,8,random(5,15),0,random(5,15),random(0,359))
Ultimate.Start.Digging:
TNT1 A 0 A_SetTranslucent(0.0,0)
TNT1 A 1 A_Stop
TNT1 A 0 A_Quake(2,5,0,300,0)
TNT1 A 0 A_GiveInventory("VCOnceMore",1)
TNT1 A 0 A_SpawnItemEx("BlockDebrisSpawner",24,0,10,random(5,15),0,random(5,15),random(0,359))
TNT1 A 0 A_JumpIfInventory("VCOnceMore",70,1)
loop
TNT1 A 0 ThrustThingZ(0,50,0,1)
TNT1 A 0 A_SetTranslucent(1.0,0)
TNT1 A 0 A_StopSoundEx("Weapon")
TNT1 A 0 A_GiveInventory("IsHuge")
TNT1 A 0 A_GiveInventory("VCOnce",1)
TNT1 A 0 A_TakeInventory("NoPushFlag",1)
TNT1 A 0 A_PlaySoundEx("weapon/drilldigend","Weapon")
TNT1 AAAAAAAAAAA 0 A_SpawnItemEx("BlockDebrisSpawner",24,0,10,random(10,20),0,random(10,20),random(0,359))
GARM J 1 Offset(0,115)ACS_NamedExecuteWithResult("VC_SetState",5)
GARM J 1 Offset(0,95) 
GARM J 1 Offset(0,75)
GARM J 1 Offset(0,55)
GARM J 1 Offset(0,35)
TNT1 A 0 A_TakeInventory("InvProtection")
TNT1 A 0 A_TakeInventory("VCOnceMore",999)
TNT1 A 0 A_ChangeFlag("INVULNERABLE",False)
TNT1 A 0 A_SpawnItemEx("GutsManUltWatcher")
TNT1 A 0 A_GiveInventory("HalfDamageProtection")
Goto Ready.Ultimate

Fire.Ultimate:
TNT1 A 0 ACS_NamedExecuteWithResult("VC_SetState",6)
TNT1 A 0 A_JumpIf(z-floorz<8,"Fire.Ultimate.SummonRock")
Fire.Ultimate.GutsLanding:
TNT1 A 0 ThrustThingZ(0,-30,0,1)
TNT1 A 0 ACS_NamedExecuteWithResult("VC_SetState",6)
GARM J 1 A_JumpIf(z-floorz<=0,1)
loop
TNT1 A 0 A_Quake(3,25,0,300)
TNT1 A 0 A_SpawnItemEx("GutsmanQuakeRadius")
TNT1 A 0 A_SpawnItemEx("ConcreteShockwaveRadius")
TNT1 A 0 A_PlaySoundEx("weapon/GutsmanQuake","SoundSlot5")
TNT1 AAAAAAAAAA 0 A_SpawnItemEx("GutsQuakeDebris3",random(32,160),0,0,0,0,random(5,10),random(0,359))
Fire.Ultimate.SummonRock:
TNT1 A 0 A_GunFlash("Flash.SummonHold")
TNT1 A 0 A_GiveInventory("CutterFlag",9)
TNT1 A 0 A_SpawnItemEx("GutsManTempRockG")
GARM KKKLLLKKKJJJKKKLLLKKKJJJ 1 ACS_NamedExecuteWithResult("VC_SetState",6)
GARM J 1 Offset(-10,25)ACS_NamedExecuteWithResult("VC_SetState",7)
GARM J 1 Offset(-20,15)ACS_NamedExecuteWithResult("VC_SetState",7)
TNT1 A 0 A_GunFlash("Flash.End2")
TNT1 A 0 A_Recoil(-20)
TNT1 A 0 A_TakeInventory("CutterFlag",9)
TNT1 A 0 A_TakeInventory("Base56Ammo",7)
TNT1 A 0 A_PlaySoundEx("weapon/wallrush","Weapon")
TNT1 A 0 A_FireCustomMissile("GutsmanGBlock",0,0,0,0)
TNT1 AA 0 A_GiveInventory("GutsManThrowBlockTrigger",1)
GARM MM 1 Offset(-30,5)ACS_NamedExecuteWithResult("VC_SetState",8) GARM NN 1 Offset(-30,5)ACS_NamedExecuteWithResult("VC_SetState",7)
GARM MM 1 Offset(-30,5)ACS_NamedExecuteWithResult("VC_SetState",8) GARM NN 1 Offset(-30,5)ACS_NamedExecuteWithResult("VC_SetState",7)
GARM MM 1 Offset(-30,5)ACS_NamedExecuteWithResult("VC_SetState",8) GARM NN 1 Offset(-30,5)ACS_NamedExecuteWithResult("VC_SetState",7)
GARM MM 1 Offset(-30,5)ACS_NamedExecuteWithResult("VC_SetState",8) GARM NN 1 Offset(-30,5)ACS_NamedExecuteWithResult("VC_SetState",7)
GARM MM 1 Offset(-30,5)ACS_NamedExecuteWithResult("VC_SetState",8) GARM NN 1 Offset(-30,5)ACS_NamedExecuteWithResult("VC_SetState",7)
GARM MM 1 Offset(-30,5)ACS_NamedExecuteWithResult("VC_SetState",8) GARM NN 1 Offset(-30,5)ACS_NamedExecuteWithResult("VC_SetState",7)
GARM MM 1 Offset(-30,5)ACS_NamedExecuteWithResult("VC_SetState",8) GARM NN 1 Offset(-30,5)ACS_NamedExecuteWithResult("VC_SetState",7)
TNT1 A 0 ACS_NamedExecuteWithResult("VC_SetState",5)
GARM JJJJ 1 Offset(-20,15)
GARM JJJJ 1 Offset(-10,25)
Goto Ready.Ultimate

Altfire.Ultimate:
GARM J 1 Offset(-5,25)ACS_NamedExecuteWithResult("VC_SetState",7)
GARM J 1 Offset(-10,15)ACS_NamedExecuteWithResult("VC_SetState",7)
TNT1 A 0 A_GunFlash("Flash.PowerDrill")
TNT1 A 0 SetPlayerProperty(0,1,4)
Altfire.Ultimate.Drilling:
TNT1 A 0 A_PlaySoundEx("weapon/kingaxespin","Weapon")
GARM M 1 Offset(-15,15)ACS_NamedExecuteWithResult("VC_SetState",9) TNT1 A 0 A_JumpIf(ACS_NamedExecuteWithResult("VC_CheckBtn",3)==3,"User1.Ultimate")
GARM M 1 Offset(-15,15)ACS_NamedExecuteWithResult("VC_SetState",9) TNT1 A 0 A_JumpIf(ACS_NamedExecuteWithResult("VC_CheckBtn",3)==3,"User1.Ultimate")
GARM N 1 Offset(-15,15)ACS_NamedExecuteWithResult("VC_SetState",7) TNT1 A 0 A_JumpIf(ACS_NamedExecuteWithResult("VC_CheckBtn",3)==3,"User1.Ultimate")
GARM N 1 Offset(-15,15)ACS_NamedExecuteWithResult("VC_SetState",7) TNT1 A 0 A_JumpIf(ACS_NamedExecuteWithResult("VC_CheckBtn",3)==3,"User1.Ultimate")
TNT1 A 0 A_JumpIfInventory("MediumUltimateAmmo",1,1)
Goto Altfire.Ultimate.End
TNT1 A 0 A_JumpIf(ACS_NamedExecuteWithResult("VC_CheckBtn",4)==5,"Altfire.Ultimate.Drilling")//A_Refire("Altfire.Ultimate.Drilling")
Altfire.Ultimate.End:
TNT1 A 0 SetPlayerProperty(0,0,4)
TNT1 A 0 A_GunFlash("Flash.End2")
TNT1 A 0 ACS_NamedExecuteWithResult("VC_SetState",5)
GARM J 1 Offset(-10,15)
GARM J 1 Offset(-5,25)
Goto Ready.Ultimate

User1.Ultimate:
TNT1 A 0 A_GunFlash("Flash.End2")
TNT1 A 0 A_PlaySoundEx("weapon/wallrush","Weapon")
TNT1 A 0 A_PlaySoundEx("weapon/powerstone","Weapon")
GARM O 1 ACS_NamedExecuteWithResult("VC_SetState",7) TNT1 A 0 A_SpawnItemEx("GutsmanGUpperCutDamager",32,0,16)
TNT1 A 0 A_SpawnItemEx("GutsmanGUpperCutDamager",32,0,32) TNT1 A 0 A_SpawnItemEx("GutsmanGUpperCutDamager",32,0,48)
GARM O 1 ACS_NamedExecuteWithResult("VC_SetState",7) TNT1 A 0 A_SpawnItemEx("GutsmanGUpperCutDamager",32,0,64)
TNT1 A 0 A_SpawnItemEx("GutsmanGUpperCutDamager",32,0,80) TNT1 A 0 A_SpawnItemEx("GutsmanGUpperCutDamager",32,0,96)
TNT1 A 0 SetPlayerProperty(0,1,4)
GARM PPPPPPPPPPPPPPPPPPPPPPPP 1 ACS_NamedExecuteWithResult("VC_SetState",10)
TNT1 A 0 SetPlayerProperty(0,0,4)
GARM O 1 ACS_NamedExecuteWithResult("VC_SetState",7) TNT1 A 0 SetPlayerProperty(0,0,4)
GARM O 1 ACS_NamedExecuteWithResult("VC_SetState",7)
TNT1 A 0 ACS_NamedExecuteWithResult("VC_SetState",5)
Goto Ready.Ultimate

Ultimate.Finish:
TNT1 A 0 A_GiveInventory("NoPushFlag",1)
TNT1 A 0 A_GiveInventory("InvProtection")
TNT1 A 0 A_ChangeFlag("INVULNERABLE",True)
GARM J 2 ThrustThingZ(0,50,0,1)
Ultimate.Finish.Landing:
TNT1 A 0 ACS_NamedExecuteWithResult("VC_SetState",1)
GARM J 1 A_JumpIf(z-floorz<=0,1)
loop
TNT1 A 0 A_PlaySoundEx("weapon/drilldigmid","Weapon",True)
TNT1 AAAAAAAAAAA 0 A_SpawnItemEx("BlockDebrisSpawner",24,0,8,random(5,15),0,random(5,15),random(0,359))
Ultimate.Finish.Digging:
TNT1 A 0 A_SetTranslucent(0.0,0)
TNT1 A 1 A_Stop
TNT1 A 0 A_Quake(2,5,0,300,0)
TNT1 A 0 A_GiveInventory("VCOnceMore",1)
TNT1 A 0 A_SpawnItemEx("BlockDebrisSpawner",24,0,10,random(5,15),0,random(5,15),random(0,359))
TNT1 A 0 A_JumpIfInventory("VCOnceMore",70,1)
loop
TNT1 A 0 ThrustThingZ(0,50,0,1)
TNT1 A 0 A_SetTranslucent(1.0,0)
TNT1 A 0 A_StopSoundEx("Weapon")
TNT1 A 0 A_TakeInventory("IsHuge")
TNT1 A 0 A_TakeInventory("VCOnce",1)
TNT1 A 0 A_TakeInventory("NoPushFlag",1)
TNT1 A 0 ACS_NamedExecuteWithResult("VC_SetState",0)
TNT1 A 0 A_TakeInventory("PowerUltBuildCooldown",1)
TNT1 A 0 A_PlaySoundEx("weapon/drilldigend","Weapon")
TNT1 AAAAAAAAAAA 0 A_SpawnItemEx("BlockDebrisSpawner",24,0,10,random(10,20),0,random(10,20),random(0,359))
GARM A 1 Offset(0,115)A_TakeInventory("HalfDamageProtection",1)
GARM A 1 Offset(0,95)A_TakeInventory("HalfDamageProtection",1)
GARM A 1 Offset(0,75)
GARM A 1 Offset(0,55)
GARM A 1 Offset(0,35)
TNT1 A 0 A_TakeInventory("InvProtection")
TNT1 A 0 A_TakeInventory("VCOnceMore",999)
TNT1 A 0 A_ChangeFlag("INVULNERABLE",False)
Goto Ready

Flash.SummonHold:
TNT1 A 0 A_GiveInventory("NoSpeed",1)
TNT1 A 0 A_PlaySoundEx("misc/hugequake2","Body")
TNT1 A 0 A_GiveInventory("HalfDamageProtection",1)
TNT1 A 0 A_JumpIfInventory("IsDead",1,"Flash.End")
TNT1 A 1 A_Stop
wait
Flash.PowerDrill:
TNT1 A 0 A_JumpIfInventory("IsDead",1,"Flash.End")
TNT1 A 0 A_SpawnItemEx("GutsmanGDrillDamager",32)
TNT1 A 0 A_SpawnItemEx("JunkSpark1",-16,15) TNT1 A 0 A_SpawnItemEx("JunkSpark1",-16,-19)
TNT1 A 0 A_CheckFloor(2)
TNT1 A 1 A_ChangeVelocity(cos(pitch)*25,0,momz,CVF_RELATIVE|CVF_REPLACE)
Goto Flash.PowerDrillB
TNT1 A 1 A_ChangeVelocity(25,0,momz,CVF_RELATIVE|CVF_REPLACE)
Flash.PowerDrillB:
TNT1 A 0 A_JumpIfInventory("IsDead",1,"Flash.End")
TNT1 A 0 A_SpawnItemEx("GutsmanGDrillDamager",32)
TNT1 A 0 A_SpawnItemEx("JunkSpark2",-16,15) TNT1 A 0 A_SpawnItemEx("JunkSpark2",-16,-19)
TNT1 A 0 A_CheckFloor(2)
TNT1 A 1 A_ChangeVelocity(cos(pitch)*25,0,momz,CVF_RELATIVE|CVF_REPLACE)
Goto Flash.PowerDrillC
TNT1 A 1 A_ChangeVelocity(25,0,momz,CVF_RELATIVE|CVF_REPLACE)
Flash.PowerDrillC:
TNT1 A 0 A_JumpIfInventory("IsDead",1,"Flash.End")
TNT1 A 0 A_SpawnItemEx("GutsmanGDrillDamager",32)
TNT1 A 0 A_SpawnItemEx("JunkSpark3",-16,15) TNT1 A 0 A_SpawnItemEx("JunkSpark3",-16,-19)
TNT1 A 0 A_CheckFloor(2)
TNT1 A 1 A_ChangeVelocity(cos(pitch)*25,0,momz,CVF_RELATIVE|CVF_REPLACE)
Goto Flash.PowerDrillD
TNT1 A 1 A_ChangeVelocity(25,0,momz,CVF_RELATIVE|CVF_REPLACE)
Flash.PowerDrillD:
TNT1 A 0 A_JumpIfInventory("IsDead",1,"Flash.End")
TNT1 A 0 A_SpawnItemEx("GutsmanGDrillDamager",32)
TNT1 A 0 A_SpawnItemEx("JunkSpark4",-16,15) TNT1 A 0 A_SpawnItemEx("JunkSpark4",-16,-19)
TNT1 A 0 A_CheckFloor(2)
TNT1 A 1 A_ChangeVelocity(cos(pitch)*25,0,momz,CVF_RELATIVE|CVF_REPLACE)
Goto Flash.PowerDrill
TNT1 A 1 A_ChangeVelocity(25,0,momz,CVF_RELATIVE|CVF_REPLACE)
Goto Flash.PowerDrill
Flash.End:
TNT1 A 0 A_TakeInventory("HalfDamageProtection",1)
TNT1 A 0 A_TakeInventory("NoSpeed",999)
stop
Flash.End2:
TNT1 A 0 A_TakeInventory("NoSpeed",999)
stop
}
}

actor GutsManTempRockPickUp : CustomInventory
{
States
{
Pickup:
TNT1 A 0 A_JumpIfInventory("CutterFlag",7,"PickUp2G")
TNT1 A 0 A_JumpIfInventory("CutterFlag",6,"PickUp2F")
TNT1 A 0 A_JumpIfInventory("CutterFlag",5,"PickUp2E")
TNT1 A 0 A_JumpIfInventory("CutterFlag",4,"PickUp2D")
TNT1 A 0 A_JumpIfInventory("CutterFlag",3,"PickUp2C")
TNT1 A 0 A_JumpIfInventory("CutterFlag",2,"PickUp2B")
TNT1 A 0 A_JumpIfInventory("CutterFlag",1,"PickUp2A")
TNT1 A 0
stop

PickUp2A:
TNT1 A 0 A_SpawnItemEx("GutsManTempRockGuts")
stop

PickUp2B:
TNT1 A 0 A_SpawnItemEx("GutsManTempRockCut")
stop

PickUp2C:
TNT1 A 0 A_SpawnItemEx("GutsManTempRockElec")
stop

PickUp2D:
TNT1 A 0 A_SpawnItemEx("GutsManTempRockDW1")
stop

PickUp2E:
TNT1 A 0 A_SpawnItemEx("GutsManTempRockDW2")
stop

PickUp2F:
TNT1 A 0 A_SpawnItemEx("GutsManTempRockPU")
stop

PickUp2G:
TNT1 A 0 A_SpawnItemEx("GutsManTempRockPF")
stop
}
}

actor GutsManThrowBlockTrigger : Powerup
{
    powerup.duration 8
}

actor GutsManTempRockBase
{
Translation "204:204=216:216","195:195=220:220"
PROJECTILE
+NOGRAVITY
+NOINTERACTION
renderstyle "translucent"
Height 8
Radius 8
scale 2.5
var int User_Ofs;
const int SPD = 10;
States
{
Spawn:
TNT1 AA 0 A_GiveInventory("ProjectileCode",1)
TNT1 A 0 A_SetUserVar("User_Ofs",266)
TNT1 AA 1 A_Warp(AAPTR_TARGET,0,0,User_Ofs,0,WARPF_INTERPOLATE|WARPF_NOCHECKPOSITION)
TNT1 A 1 A_Warp(AAPTR_TARGET,0,0,User_Ofs,0,WARPF_INTERPOLATE|WARPF_NOCHECKPOSITION)
"####" "#" 1 A_Jump(256,"BlockSummon")
Goto BlockSummon

BlockSummon:
"####" "#" 0 A_JumpIf(User_Ofs<=84,"BlockHold")
"####" "#" 0 A_SetUserVar("User_Ofs",User_Ofs-16)
"####" "#" 1 A_Warp(AAPTR_TARGET,0,0,User_Ofs,0,WARPF_INTERPOLATE|WARPF_NOCHECKPOSITION)
loop

BlockHold:
"####" "#" 0 A_JumpIfInTargetInventory("IsTheTerminator",1,"End")
"####" "#" 0 A_JumpIf(ACS_NamedExecuteWithResult("core_targetexists",0) == 0, "Death")
"####" "#" 1 A_Warp(AAPTR_TARGET,0,0,84,0,WARPF_INTERPOLATE|WARPF_NOCHECKPOSITION)
"####" "#" 0 A_JumpIfInTargetInventory("GutsManThrowBlockTrigger",1,"End")
loop

Death:
TNT1 A 0
stop

End:
TNT1 A 0
stop
}
}

actor GutsManTempRockGuts : GutsManTempRockBase
{
States
{
Spawn:
TNT1 AA 0 A_GiveInventory("ProjectileCode",1)
TNT1 A 0 A_SetUserVar("User_Ofs",266)
TNT1 AA 1 A_Warp(AAPTR_TARGET,0,0,User_Ofs,0,WARPF_INTERPOLATE|WARPF_NOCHECKPOSITION)
SARM A 1 A_Warp(AAPTR_TARGET,0,0,User_Ofs,0,WARPF_INTERPOLATE|WARPF_NOCHECKPOSITION)
SARM A 1 A_Jump(256,"BlockSummon")
wait

Death:
TNT1 AAAA 0 A_SpawnItemEx("GutsManBlockFX",0,0,90,random(-SPD,SPD),random(-SPD,SPD),random(SPD/2,SPD),random(0,359))
TNT1 A 2 A_PlaySoundEx("weapon/superarmhit","Voice")
stop
}
}

actor GutsManTempRockCut : GutsManTempRockGuts
{
States
{
Spawn:
TNT1 AA 0 A_GiveInventory("ProjectileCode",1)
TNT1 A 0 A_SetUserVar("User_Ofs",266)
TNT1 AA 1 A_Warp(AAPTR_TARGET,0,0,User_Ofs,0,WARPF_INTERPOLATE|WARPF_NOCHECKPOSITION)
SAR2 A 1 A_Warp(AAPTR_TARGET,0,0,User_Ofs,0,WARPF_INTERPOLATE|WARPF_NOCHECKPOSITION)
SAR2 A 1 A_Jump(256,"BlockSummon")
wait

Death:
TNT1 AAAA 0 A_SpawnItemEx("CutManBlockFX",0,0,90,random(-SPD,SPD),random(-SPD,SPD),random(SPD/2,SPD),random(0,359))
TNT1 A 2 A_PlaySoundEx("weapon/superarmhit","Voice")
stop
}
}

actor GutsManTempRockElec : GutsManTempRockGuts
{
States
{
Spawn:
TNT1 AA 0 A_GiveInventory("ProjectileCode",1)
TNT1 A 0 A_SetUserVar("User_Ofs",266)
TNT1 AA 1 A_Warp(AAPTR_TARGET,0,0,User_Ofs,0,WARPF_INTERPOLATE|WARPF_NOCHECKPOSITION)
SAR3 A 1 A_Warp(AAPTR_TARGET,0,0,User_Ofs,0,WARPF_INTERPOLATE|WARPF_NOCHECKPOSITION)
SAR3 A 1 A_Jump(256,"BlockSummon")
wait

Death:
TNT1 AAAA 0 A_SpawnItemEx("ElecManBlockFX",0,0,90,random(-SPD,SPD),random(-SPD,SPD),random(SPD/2,SPD),random(0,359))
TNT1 A 2 A_PlaySoundEx("weapon/superarmhit","Voice")
stop
}
}

actor GutsManTempRockDW1 : GutsManTempRockGuts
{
States
{
Spawn:
TNT1 AA 0 A_GiveInventory("ProjectileCode",1)
TNT1 A 0 A_SetUserVar("User_Ofs",266)
TNT1 AA 1 A_Warp(AAPTR_TARGET,0,0,User_Ofs,0,WARPF_INTERPOLATE|WARPF_NOCHECKPOSITION)
SAR4 A 1 A_Warp(AAPTR_TARGET,0,0,User_Ofs,0,WARPF_INTERPOLATE|WARPF_NOCHECKPOSITION)
SAR4 A 1 A_Jump(256,"BlockSummon")
wait

Death:
TNT1 AAAA 0 A_SpawnItemEx("DW1BlockFX",0,0,90,random(-SPD,SPD),random(-SPD,SPD),random(SPD/2,SPD),random(0,359))
TNT1 A 2 A_PlaySoundEx("weapon/superarmhit","Voice")
stop
}
}

actor GutsManTempRockDW2 : GutsManTempRockGuts
{
States
{
Spawn:
TNT1 AA 0 A_GiveInventory("ProjectileCode",1)
TNT1 A 0 A_SetUserVar("User_Ofs",266)
TNT1 AA 1 A_Warp(AAPTR_TARGET,0,0,User_Ofs,0,WARPF_INTERPOLATE|WARPF_NOCHECKPOSITION)
SAR5 A 1 A_Warp(AAPTR_TARGET,0,0,User_Ofs,0,WARPF_INTERPOLATE|WARPF_NOCHECKPOSITION)
SAR5 A 1 A_Jump(256,"BlockSummon")
wait

Death:
TNT1 AAAA 0 A_SpawnItemEx("DW2BlockFX",0,0,90,random(-SPD,SPD),random(-SPD,SPD),random(SPD/2,SPD),random(0,359))
TNT1 A 2 A_PlaySoundEx("weapon/superarmhit","Voice")
stop
}
}

actor GutsManTempRockPU : GutsManTempRockGuts
{
States
{
Spawn:
TNT1 AA 0 A_GiveInventory("ProjectileCode",1)
TNT1 A 0 A_SetUserVar("User_Ofs",266)
TNT1 AA 1 A_Warp(AAPTR_TARGET,0,0,User_Ofs,0,WARPF_INTERPOLATE|WARPF_NOCHECKPOSITION)
GUTP Y 1 A_Warp(AAPTR_TARGET,0,0,User_Ofs,0,WARPF_INTERPOLATE|WARPF_NOCHECKPOSITION)
GUTP Y 1 A_Jump(256,"BlockSummon")
wait

Death:
TNT1 AAAA 0 A_SpawnItemEx("PoweredUpBlockFX",0,0,90,random(-SPD,SPD),random(-SPD,SPD),random(SPD/2,SPD),random(0,359))
TNT1 A 2 A_PlaySoundEx("weapon/superarmhit","Voice")
stop
}
}

actor GutsManTempRockPF : GutsManTempRockGuts
{
States
{
Spawn:
TNT1 AA 0 A_GiveInventory("ProjectileCode",1)
TNT1 A 0 A_SetUserVar("User_Ofs",266)
TNT1 AA 1 A_Warp(AAPTR_TARGET,0,0,User_Ofs,0,WARPF_INTERPOLATE|WARPF_NOCHECKPOSITION)
GUTP P 1 A_Warp(AAPTR_TARGET,0,0,User_Ofs,0,WARPF_INTERPOLATE|WARPF_NOCHECKPOSITION)
GUTP P 1 A_Jump(256,"BlockSummon")
wait

Death:
TNT1 AAAA 0 A_SpawnItemEx("PowerFightersBlockFX",0,0,90,random(-SPD,SPD),random(-SPD,SPD),random(SPD/2,SPD),random(0,359))
TNT1 A 2 A_PlaySoundEx("weapon/superarmhit","Voice")
stop
}
}

actor GutsManTempRockBoulder : GutsManTempRockGuts
{
States
{
Spawn:
TNT1 AA 0 A_GiveInventory("ProjectileCode",1)
TNT1 A 0 A_SetUserVar("User_Ofs",296)
TNT1 AA 1 A_Warp(AAPTR_TARGET,0,0,User_Ofs,0,WARPF_INTERPOLATE|WARPF_NOCHECKPOSITION)
GRCK A 1 A_Warp(AAPTR_TARGET,0,0,User_Ofs,0,WARPF_INTERPOLATE|WARPF_NOCHECKPOSITION)
GRCK A 1 A_Jump(256,"BlockSummon")
wait

Death:
TNT1 AAAAAAAA 0 A_SpawnItemEx("GutsBoulderFX",0,0,90,random(-SPD,SPD),random(-SPD,SPD),random(SPD/2,SPD),random(0,359))
TNT1 A 2 A_PlaySoundEx("weapon/superarmhit","Voice")
stop
}
}

actor GutsManTempRockG : GutsManTempRockBase
{
States
{
Spawn:
TNT1 AA 0 A_GiveInventory("ProjectileCode",1)
TNT1 A 0 A_SetUserVar("User_Ofs",296)
TNT1 A 0 ACS_NamedExecuteWithResult("core_alphaprojectile", CallACS("core_getptrtid", AAPTR_TARGET), APROJ_TEAM, 6553, 128)
TNT1 AA 1 A_Warp(AAPTR_TARGET,0,0,User_Ofs,0,WARPF_INTERPOLATE|WARPF_NOCHECKPOSITION)
GGRK A 1 A_Warp(AAPTR_TARGET,0,0,User_Ofs,0,WARPF_INTERPOLATE|WARPF_NOCHECKPOSITION)
GGRK A 1 A_Jump(256,"BlockSummon")
Goto BlockSummon

BlockSummon:
"####" "#" 0 A_JumpIfInTargetInventory("IsTheTerminator",1,"End")
"####" "#" 0 A_JumpIf(User_Ofs<=0,"BlockHold")
"####" "#" 0 A_SetUserVar("User_Ofs",User_Ofs-24)
"####" "#" 1 A_Warp(AAPTR_TARGET,80,0,User_Ofs,0,WARPF_INTERPOLATE|WARPF_NOCHECKPOSITION)
loop

BlockHold:
"####" "#" 0 A_JumpIf(ACS_NamedExecuteWithResult("core_targetexists",0) == 0, "Death")
"####" "#" 1 A_Warp(AAPTR_TARGET,80,0,0,0,WARPF_INTERPOLATE|WARPF_NOCHECKPOSITION)
"####" "#" 0 A_JumpIfInTargetInventory("GutsManThrowBlockTrigger",1,"End")
loop

Death:
TNT1 AAAAAAAA 0 A_SpawnItemEx("GutsManGBlockFX",0,0,90,random(-SPD,SPD),random(-SPD,SPD),random(SPD/2,SPD),random(0,359))
TNT1 A 2 A_PlaySoundEx("weapon/gutsmangbreak","Voice")
stop

End:
TNT1 A 0
stop
}
}

actor GutsQuakeDebris : BasicClientSide
{
Translation "204:204=216:216","195:195=220:220"
+MISSILE
bouncecount 2
+DOOMBOUNCE
+THRUACTORS
-NOINTERACTION
-NOGRAVITY
States
{
Spawn:
TNT1 AA 0 A_GiveInventory("ProjectileCode",1)
TNT1 A 0 A_Jump(256,"S_1","S_2","S_3","S_4","S_5","S_6","S_7")

S_1:
SAR6 A 70
stop

S_2:
SAR6 B 70
stop

S_3:
SAR6 C 70
stop

S_4:
SAR6 D 70
stop

S_5:
SAR6 E 70
stop

S_6:
SAR6 F 70
stop

S_7:
GUTP Z 70
stop
}
}

actor GutsManBlockPickUp : CustomInventory
{
States
{
Pickup:
TNT1 A 0 //A_TakeInventory("Base56Ammo",7)
TNT1 A 0 ACS_NamedExecuteWithResult("VC_SetState",3)
TNT1 A 0 A_PlaySound("weapon/GutsmanToss","Weapon")
TNT1 A 0 A_JumpIfInventory("CutterFlag",7,"PickUp2G")
TNT1 A 0 A_JumpIfInventory("CutterFlag",6,"PickUp2F")
TNT1 A 0 A_JumpIfInventory("CutterFlag",5,"PickUp2E")
TNT1 A 0 A_JumpIfInventory("CutterFlag",4,"PickUp2D")
TNT1 A 0 A_JumpIfInventory("CutterFlag",3,"PickUp2C")
TNT1 A 0 A_JumpIfInventory("CutterFlag",2,"PickUp2B")
TNT1 A 0 A_JumpIfInventory("CutterFlag",1,"PickUp2A")
Goto End
PickUp2A:
TNT1 A 0 A_FireCustomMissile("GutsManBlockThrow",0,0,0,40)
Goto End
PickUp2B:
TNT1 A 0 A_FireCustomMissile("CutManBlockThrow",0,0,0,40)
Goto End
PickUp2C:
TNT1 A 0 A_FireCustomMissile("ElecManBlockThrow",0,0,0,40)
Goto End
PickUp2D:
TNT1 A 0 A_FireCustomMissile("DW1BlockThrow",0,0,0,40)
Goto End
PickUp2E:
TNT1 A 0 A_FireCustomMissile("DW2BlockThrow",0,0,0,40)
Goto End
PickUp2F:
TNT1 A 0 A_FireCustomMissile("PoweredUpBlockThrow",0,0,0,40)
Goto End
PickUp2G:
TNT1 A 0 A_FireCustomMissile("PowerFightersBlockThrow",0,0,0,40)
Goto End
End:
TNT1 A 0 A_TakeInventory("CutterFlag",99)
stop
}
}

actor GutsManBlockPickUp2 : CustomInventory
{
States
{
Pickup:
TNT1 A 0 //A_TakeInventory("Base56Ammo",7)
TNT1 A 0 ACS_NamedExecuteWithResult("VC_SetState",3)
TNT1 A 0 A_PlaySound("weapon/GutsmanToss","Weapon")
TNT1 A 0 A_JumpIfInventory("CutterFlag",7,"PickUp2G")
TNT1 A 0 A_JumpIfInventory("CutterFlag",6,"PickUp2F")
TNT1 A 0 A_JumpIfInventory("CutterFlag",5,"PickUp2E")
TNT1 A 0 A_JumpIfInventory("CutterFlag",4,"PickUp2D")
TNT1 A 0 A_JumpIfInventory("CutterFlag",3,"PickUp2C")
TNT1 A 0 A_JumpIfInventory("CutterFlag",2,"PickUp2B")
TNT1 A 0 A_JumpIfInventory("CutterFlag",1,"PickUp2A")
Goto End
PickUp2A:
TNT1 A 0 A_FireCustomMissile("GutsManBlockThrow2",0,0,0,40)
Goto End
PickUp2B:
TNT1 A 0 A_FireCustomMissile("CutManBlockThrow2",0,0,0,40)
Goto End
PickUp2C:
TNT1 A 0 A_FireCustomMissile("ElecManBlockThrow2",0,0,0,40)
Goto End
PickUp2D:
TNT1 A 0 A_FireCustomMissile("DW1BlockThrow2",0,0,0,40)
Goto End
PickUp2E:
TNT1 A 0 A_FireCustomMissile("DW2BlockThrow2",0,0,0,40)
Goto End
PickUp2F:
TNT1 A 0 A_FireCustomMissile("PoweredUpBlockThrow2",0,0,0,40)
Goto End
PickUp2G:
TNT1 A 0 A_FireCustomMissile("PowerFightersBlockThrow2",0,0,0,40)
Goto End
End:
TNT1 A 0 A_TakeInventory("CutterFlag",99)
stop
}
}

actor BaseBlockThrow
{
PROJECTILE
damagetype "GutsMan"
Obituary "$OB_GUTSMAN1"
Damage (36)
Speed 40
Radius 16
Height 32
scale 2.5
const int OFS = 16;
const int SPD1 = 3;
const int SPD2 = 10;
States
{
Spawn:
TNT1 AA 0 A_GiveInventory("ProjectileCode",1)
TNT1 A 1
wait
Death:
TNT1 A 0 A_CheckFloor("Death.Floor")
TNT1 A 0 A_CheckCeiling("Death.Ceiling")
TNT1 A 1 A_Jump(256,"Death.Wall")
Goto Death.Wall
Death.Wall:
TNT1 A 0
stop
XDeath:
TNT1 A 0
Goto SplitSound
Death.Floor:
TNT1 A 0
Goto SplitSound
Death.Ceiling:
TNT1 A 0
Goto SplitSound
SplitSound:
TNT1 A 2 A_PlaySoundEx("weapon/superarmhit", "Voice")
stop
}
}

actor GutsManBlockThrow : BaseBlockThrow
{
States
{
Spawn:
TNT1 AA 0 A_GiveInventory("ProjectileCode",1)
SARM A 1
wait
Death.Wall:
TNT1 AAAA 0 A_SpawnItemEx("GutsManBlockFX",0,0,0,random(-SPD2,SPD2),random(-SPD2,SPD2),random(SPD2/2,SPD2),random(0,359))
stop
XDeath:
TNT1 AAAA 0 A_SpawnItemEx("GutsManBlockFX",0,0,0,random(-SPD2,SPD2),random(-SPD2,SPD2),random(SPD2/2,SPD2),random(0,359))
Goto SplitSound
Death.Floor:
TNT1 A 0 A_SpawnItemEx("GutsmanBlockDebris", -OFS, -OFS, OFS, SPD2*2, 0, 0, 0, 0)
TNT1 A 0 A_SpawnItemEx("GutsmanBlockDebris", -OFS, OFS, OFS, SPD2*3, 0, 0, 0, 0)
TNT1 A 0 A_SpawnItemEx("GutsmanBlockDebris", OFS, -OFS, OFS, SPD2*3, 0, SPD1*2, 0, 0)
TNT1 A 0 A_SpawnItemEx("GutsmanBlockDebris", OFS, OFS, OFS, SPD2*2, 0, SPD1, 0, 0)
Goto SplitSound
Death.Ceiling:
TNT1 A 0 A_SpawnItemEx("GutsmanBlockDebris", -OFS, -OFS, OFS, SPD2*2, 0, 0, 0, 0)
TNT1 A 0 A_SpawnItemEx("GutsmanBlockDebris", -OFS, OFS, OFS, SPD2*3, 0, 0, 0, 0)
TNT1 A 0 A_SpawnItemEx("GutsmanBlockDebris", OFS, -OFS, OFS, SPD2*3, 0, -SPD1*2, 0, 0)
TNT1 A 0 A_SpawnItemEx("GutsmanBlockDebris", OFS, OFS, OFS, SPD2*2, 0, -SPD1, 0, 0)
Goto SplitSound
}
}

actor CutManBlockThrow : BaseBlockThrow
{
States
{
Spawn:
TNT1 AA 0 A_GiveInventory("ProjectileCode",1)
SAR2 A 1
wait
Death.Wall:
TNT1 AAAA 0 A_SpawnItemEx("CutManBlockFX",0,0,0,random(-SPD2,SPD2),random(-SPD2,SPD2),random(SPD2/2,SPD2),random(0,359))
stop
XDeath:
TNT1 AAAA 0 A_SpawnItemEx("CutManBlockFX",0,0,0,random(-SPD2,SPD2),random(-SPD2,SPD2),random(SPD2/2,SPD2),random(0,359))
Goto SplitSound
Death.Floor:
TNT1 A 0 A_SpawnItemEx("CutManBlockDebris", -OFS, -OFS, OFS, SPD2*2, 0, 0, 0, 0)
TNT1 A 0 A_SpawnItemEx("CutManBlockDebris", -OFS, OFS, OFS, SPD2*3, 0, 0, 0, 0)
TNT1 A 0 A_SpawnItemEx("CutManBlockDebris", OFS, -OFS, OFS, SPD2*3, 0, SPD1*2, 0, 0)
TNT1 A 0 A_SpawnItemEx("CutManBlockDebris", OFS, OFS, OFS, SPD2*2, 0, SPD1, 0, 0)
Goto SplitSound
Death.Ceiling:
TNT1 A 0 A_SpawnItemEx("CutManBlockDebris", -OFS, -OFS, OFS, SPD2*2, 0, 0, 0, 0)
TNT1 A 0 A_SpawnItemEx("CutManBlockDebris", -OFS, OFS, OFS, SPD2*3, 0, 0, 0, 0)
TNT1 A 0 A_SpawnItemEx("CutManBlockDebris", OFS, -OFS, OFS, SPD2*3, 0, -SPD1*2, 0, 0)
TNT1 A 0 A_SpawnItemEx("CutManBlockDebris", OFS, OFS, OFS, SPD2*2, 0, -SPD1, 0, 0)
Goto SplitSound
}
}

actor ElecManBlockThrow : BaseBlockThrow
{
States
{
Spawn:
TNT1 AA 0 A_GiveInventory("ProjectileCode",1)
SAR3 A 1
wait
Death.Wall:
TNT1 AAAA 0 A_SpawnItemEx("ElecManBlockFX",0,0,0,random(-SPD2,SPD2),random(-SPD2,SPD2),random(SPD2/2,SPD2),random(0,359))
stop
XDeath:
TNT1 AAAA 0 A_SpawnItemEx("ElecManBlockFX",0,0,0,random(-SPD2,SPD2),random(-SPD2,SPD2),random(SPD2/2,SPD2),random(0,359))
Goto SplitSound
Death.Floor:
TNT1 A 0 A_SpawnItemEx("ElecManBlockDebris", -OFS, -OFS, OFS, SPD2*2, 0, 0, 0, 0)
TNT1 A 0 A_SpawnItemEx("ElecManBlockDebris", -OFS, OFS, OFS, SPD2*3, 0, 0, 0, 0)
TNT1 A 0 A_SpawnItemEx("ElecManBlockDebris", OFS, -OFS, OFS, SPD2*3, 0, SPD1*2, 0, 0)
TNT1 A 0 A_SpawnItemEx("ElecManBlockDebris", OFS, OFS, OFS, SPD2*2, 0, SPD1, 0, 0)
Goto SplitSound
Death.Ceiling:
TNT1 A 0 A_SpawnItemEx("ElecManBlockDebris", -OFS, -OFS, OFS, SPD2*2, 0, 0, 0, 0)
TNT1 A 0 A_SpawnItemEx("ElecManBlockDebris", -OFS, OFS, OFS, SPD2*3, 0, 0, 0, 0)
TNT1 A 0 A_SpawnItemEx("ElecManBlockDebris", OFS, -OFS, OFS, SPD2*3, 0, -SPD1*2, 0, 0)
TNT1 A 0 A_SpawnItemEx("ElecManBlockDebris", OFS, OFS, OFS, SPD2*2, 0, -SPD1, 0, 0)
Goto SplitSound
}
}

actor DW1BlockThrow : BaseBlockThrow
{
States
{
Spawn:
TNT1 AA 0 A_GiveInventory("ProjectileCode",1)
SAR4 A 1
wait
Death.Wall:
TNT1 AAAA 0 A_SpawnItemEx("DW1BlockFX",0,0,0,random(-SPD2,SPD2),random(-SPD2,SPD2),random(SPD2/2,SPD2),random(0,359))
stop
XDeath:
TNT1 AAAA 0 A_SpawnItemEx("DW1BlockFX",0,0,0,random(-SPD2,SPD2),random(-SPD2,SPD2),random(SPD2/2,SPD2),random(0,359))
Goto SplitSound
Death.Floor:
TNT1 A 0 A_SpawnItemEx("DW1BlockDebris", -OFS, -OFS, OFS, SPD2*2, 0, 0, 0, 0)
TNT1 A 0 A_SpawnItemEx("DW1BlockDebris", -OFS, OFS, OFS, SPD2*3, 0, 0, 0, 0)
TNT1 A 0 A_SpawnItemEx("DW1BlockDebris", OFS, -OFS, OFS, SPD2*3, 0, SPD1*2, 0, 0)
TNT1 A 0 A_SpawnItemEx("DW1BlockDebris", OFS, OFS, OFS, SPD2*2, 0, SPD1, 0, 0)
Goto SplitSound
Death.Ceiling:
TNT1 A 0 A_SpawnItemEx("DW1BlockDebris", -OFS, -OFS, OFS, SPD2*2, 0, 0, 0, 0)
TNT1 A 0 A_SpawnItemEx("DW1BlockDebris", -OFS, OFS, OFS, SPD2*3, 0, 0, 0, 0)
TNT1 A 0 A_SpawnItemEx("DW1BlockDebris", OFS, -OFS, OFS, SPD2*3, 0, -SPD1*2, 0, 0)
TNT1 A 0 A_SpawnItemEx("DW1BlockDebris", OFS, OFS, OFS, SPD2*2, 0, -SPD1, 0, 0)
Goto SplitSound
}
}

actor DW2BlockThrow : BaseBlockThrow
{
States
{
Spawn:
TNT1 AA 0 A_GiveInventory("ProjectileCode",1)
SAR5 A 1
wait
Death.Wall:
TNT1 AAAA 0 A_SpawnItemEx("DW2BlockFX",0,0,0,random(-SPD2,SPD2),random(-SPD2,SPD2),random(SPD2/2,SPD2),random(0,359))
stop
XDeath:
TNT1 AAAA 0 A_SpawnItemEx("DW2BlockFX",0,0,0,random(-SPD2,SPD2),random(-SPD2,SPD2),random(SPD2/2,SPD2),random(0,359))
Goto SplitSound
Death.Floor:
TNT1 A 0 A_SpawnItemEx("DW2BlockDebris", -OFS, -OFS, OFS, SPD2*2, 0, 0, 0, 0)
TNT1 A 0 A_SpawnItemEx("DW2BlockDebris", -OFS, OFS, OFS, SPD2*3, 0, 0, 0, 0)
TNT1 A 0 A_SpawnItemEx("DW2BlockDebris", OFS, -OFS, OFS, SPD2*3, 0, SPD1*2, 0, 0)
TNT1 A 0 A_SpawnItemEx("DW2BlockDebris", OFS, OFS, OFS, SPD2*2, 0, SPD1, 0, 0)
Goto SplitSound
Death.Ceiling:
TNT1 A 0 A_SpawnItemEx("DW2BlockDebris", -OFS, -OFS, OFS, SPD2*2, 0, 0, 0, 0)
TNT1 A 0 A_SpawnItemEx("DW2BlockDebris", -OFS, OFS, OFS, SPD2*3, 0, 0, 0, 0)
TNT1 A 0 A_SpawnItemEx("DW2BlockDebris", OFS, -OFS, OFS, SPD2*3, 0, -SPD1*2, 0, 0)
TNT1 A 0 A_SpawnItemEx("DW2BlockDebris", OFS, OFS, OFS, SPD2*2, 0, -SPD1, 0, 0)
Goto SplitSound
}
}

actor PoweredUpBlockThrow : BaseBlockThrow
{
Translation "204:204=216:216","195:195=220:220"
States
{
Spawn:
TNT1 AA 0 A_GiveInventory("ProjectileCode",1)
GUTP Y 1
wait
Death.Wall:
TNT1 AAAA 0 A_SpawnItemEx("PoweredUpBlockFX",0,0,0,random(-SPD2,SPD2),random(-SPD2,SPD2),random(SPD2/2,SPD2),random(0,359))
stop
XDeath:
TNT1 AAAA 0 A_SpawnItemEx("PoweredUpBlockFX",0,0,0,random(-SPD2,SPD2),random(-SPD2,SPD2),random(SPD2/2,SPD2),random(0,359))
Goto SplitSound
Death.Floor:
TNT1 A 0 A_SpawnItemEx("PoweredUpBlockDebris", -OFS, -OFS, OFS, SPD2*2, 0, 0, 0, 0)
TNT1 A 0 A_SpawnItemEx("PoweredUpBlockDebris", -OFS, OFS, OFS, SPD2*3, 0, 0, 0, 0)
TNT1 A 0 A_SpawnItemEx("PoweredUpBlockDebris", OFS, -OFS, OFS, SPD2*3, 0, SPD1*2, 0, 0)
TNT1 A 0 A_SpawnItemEx("PoweredUpBlockDebris", OFS, OFS, OFS, SPD2*2, 0, SPD1, 0, 0)
Goto SplitSound
Death.Ceiling:
TNT1 A 0 A_SpawnItemEx("PoweredUpBlockDebris", -OFS, -OFS, OFS, SPD2*2, 0, 0, 0, 0)
TNT1 A 0 A_SpawnItemEx("PoweredUpBlockDebris", -OFS, OFS, OFS, SPD2*3, 0, 0, 0, 0)
TNT1 A 0 A_SpawnItemEx("PoweredUpBlockDebris", OFS, -OFS, OFS, SPD2*3, 0, -SPD1*2, 0, 0)
TNT1 A 0 A_SpawnItemEx("PoweredUpBlockDebris", OFS, OFS, OFS, SPD2*2, 0, -SPD1, 0, 0)
Goto SplitSound
}
}

actor PowerFightersBlockThrow : BaseBlockThrow
{
States
{
Spawn:
TNT1 AA 0 A_GiveInventory("ProjectileCode",1)
GUTP P 1
wait
Death.Wall:
TNT1 AAAA 0 A_SpawnItemEx("PowerFightersBlockFX",0,0,0,random(-SPD2,SPD2),random(-SPD2,SPD2),random(SPD2/2,SPD2),random(0,359))
stop
XDeath:
TNT1 AAAA 0 A_SpawnItemEx("PowerFightersBlockFX",0,0,0,random(-SPD2,SPD2),random(-SPD2,SPD2),random(SPD2/2,SPD2),random(0,359))
Goto SplitSound
Death.Floor:
TNT1 A 0 A_SpawnItemEx("PowerFightersBlockDebris", -OFS, -OFS, OFS, SPD2*2, 0, 0, 0, 0)
TNT1 A 0 A_SpawnItemEx("PowerFightersBlockDebris", -OFS, OFS, OFS, SPD2*3, 0, 0, 0, 0)
TNT1 A 0 A_SpawnItemEx("PowerFightersBlockDebris", OFS, -OFS, OFS, SPD2*3, 0, SPD1*2, 0, 0)
TNT1 A 0 A_SpawnItemEx("PowerFightersBlockDebris", OFS, OFS, OFS, SPD2*2, 0, SPD1, 0, 0)
Goto SplitSound
Death.Ceiling:
TNT1 A 0 A_SpawnItemEx("PowerFightersBlockDebris", -OFS, -OFS, OFS, SPD2*2, 0, 0, 0, 0)
TNT1 A 0 A_SpawnItemEx("PowerFightersBlockDebris", -OFS, OFS, OFS, SPD2*3, 0, 0, 0, 0)
TNT1 A 0 A_SpawnItemEx("PowerFightersBlockDebris", OFS, -OFS, OFS, SPD2*3, 0, -SPD1*2, 0, 0)
TNT1 A 0 A_SpawnItemEx("PowerFightersBlockDebris", OFS, OFS, OFS, SPD2*2, 0, -SPD1, 0, 0)
Goto SplitSound
}
}

actor GutsManBlockThrow2 : GutsManBlockThrow
{
-NOGRAVITY
}

actor CutManBlockThrow2 : CutManBlockThrow
{
-NOGRAVITY
}

actor ElecManBlockThrow2 : ElecManBlockThrow
{
-NOGRAVITY
}

actor DW1BlockThrow2 : DW1BlockThrow
{
-NOGRAVITY
}

actor DW2BlockThrow2 : DW2BlockThrow
{
-NOGRAVITY
}

actor PoweredUpBlockThrow2 : PoweredUpBlockThrow
{
-NOGRAVITY
}

actor PowerFightersBlockThrow2 : PowerFightersBlockThrow
{
-NOGRAVITY
}

actor BaseBlockDebris
{
PROJECTILE
damagetype "GutsManBit"
Obituary "$OB_GUTSMAN1"
Damage (9)
Speed 40
Radius 8
Height 16
scale 2.5
}

actor GutsManBlockDebris : BaseBlockDebris
{
States
{
Spawn:
TNT1 AA 0 A_GiveInventory("ProjectileCode",1)
SARM B 1
wait
}
}

actor CutManBlockDebris : BaseBlockDebris
{
States
{
Spawn:
TNT1 AA 0 A_GiveInventory("ProjectileCode",1)
SAR2 B 1
wait
}
}

actor ElecManBlockDebris : BaseBlockDebris
{
States
{
Spawn:
TNT1 AA 0 A_GiveInventory("ProjectileCode",1)
SAR3 B 1
wait
}
}

actor DW1BlockDebris : BaseBlockDebris
{
States
{
Spawn:
TNT1 AA 0 A_GiveInventory("ProjectileCode",1)
SAR4 B 1
wait
}
}

actor DW2BlockDebris : BaseBlockDebris
{
States
{
Spawn:
TNT1 AA 0 A_GiveInventory("ProjectileCode",1)
SAR5 B 1
wait
}
}

actor PoweredUpBlockDebris : BaseBlockDebris
{
Translation "204:204=216:216","195:195=220:220"
States
{
Spawn:
TNT1 AA 0 A_GiveInventory("ProjectileCode",1)
GUTP Z 1
wait
}
}

actor PowerFightersBlockDebris : BaseBlockDebris
{
States
{
Spawn:
TNT1 AA 0 A_GiveInventory("ProjectileCode",1)
GUTP Q 1
wait
}
}

actor BaseBlockFX
{
+MISSILE
-SOLID
+THRUACTORS
+BOUNCEONWALLS
+CANBOUNCEWATER
+BOUNCEONCEILINGS
Radius 8
Height 16
scale 2.5
}

actor GutsManBlockFX : BaseBlockFX
{
States
{
Spawn:
TNT1 AA 0 A_GiveInventory("ProjectileCode",1)
SARM BZ 2
Goto Spawn+2
}
}

actor CutmanBlockFX : BaseBlockFX
{
States
{
Spawn:
TNT1 AA 0 A_GiveInventory("ProjectileCode",1)
SAR2 BZ 2
Goto Spawn+2
}
}

actor ElecmanBlockFX : BaseBlockFX
{
States
{
Spawn:
TNT1 AA 0 A_GiveInventory("ProjectileCode",1)
SAR3 BZ 2
Goto Spawn+2
}
}

actor DW1BlockFX : BaseBlockFX
{
States
{
Spawn:
TNT1 AA 0 A_GiveInventory("ProjectileCode",1)
SAR4 BZ 2
Goto Spawn+2
}
}

actor DW2BlockFX : BaseBlockFX
{
States
{
Spawn:
TNT1 AA 0 A_GiveInventory("ProjectileCode",1)
SAR5 BZ 2
Goto Spawn+2
}
}

actor PoweredUpBlockFX : BaseBlockFX
{
Translation "204:204=216:216","195:195=220:220"
States
{
Spawn:
TNT1 AA 0 A_GiveInventory("ProjectileCode",1)
GUTP ZX 2
Goto Spawn+2
}
}

actor PowerFightersBlockFX : BaseBlockFX
{
States
{
Spawn:
TNT1 AA 0 A_GiveInventory("ProjectileCode",1)
GUTP QX 2
Goto Spawn+2
}
}

actor GutsmanQuakeRadius
{
PROJECTILE
+FLOORHUGGER
+NOINTERACTION
+NOCLIP
Damage(0)
Height 1
Radius 1
Speed 0
States
{
Spawn:
TNT1 A 0 A_SpawnItemEx("SuperArmQuakeRadiusRange",0,0,0,0,0,0,18) TNT1 A 0 A_SpawnItemEx("SuperArmQuakeRadiusRange",0,0,0,0,0,0,36)
TNT1 A 0 A_SpawnItemEx("SuperArmQuakeRadiusRange",0,0,0,0,0,0,54) TNT1 A 0 A_SpawnItemEx("SuperArmQuakeRadiusRange",0,0,0,0,0,0,72)
TNT1 A 0 A_SpawnItemEx("SuperArmQuakeRadiusRange",0,0,0,0,0,0,90) TNT1 A 0 A_SpawnItemEx("SuperArmQuakeRadiusRange",0,0,0,0,0,0,108)
TNT1 A 0 A_SpawnItemEx("SuperArmQuakeRadiusRange",0,0,0,0,0,0,126) TNT1 A 0 A_SpawnItemEx("SuperArmQuakeRadiusRange",0,0,0,0,0,0,144)
TNT1 A 0 A_SpawnItemEx("SuperArmQuakeRadiusRange",0,0,0,0,0,0,162) TNT1 A 0 A_SpawnItemEx("SuperArmQuakeRadiusRange",0,0,0,0,0,0,180)
TNT1 A 0 A_SpawnItemEx("SuperArmQuakeRadiusRange",0,0,0,0,0,0,198) TNT1 A 0 A_SpawnItemEx("SuperArmQuakeRadiusRange",0,0,0,0,0,0,216)
TNT1 A 0 A_SpawnItemEx("SuperArmQuakeRadiusRange",0,0,0,0,0,0,234) TNT1 A 0 A_SpawnItemEx("SuperArmQuakeRadiusRange",0,0,0,0,0,0,254)
TNT1 A 0 A_SpawnItemEx("SuperArmQuakeRadiusRange",0,0,0,0,0,0,270) TNT1 A 0 A_SpawnItemEx("SuperArmQuakeRadiusRange",0,0,0,0,0,0,288)
TNT1 A 0 A_SpawnItemEx("SuperArmQuakeRadiusRange",0,0,0,0,0,0,306) TNT1 A 0 A_SpawnItemEx("SuperArmQuakeRadiusRange",0,0,0,0,0,0,324)
TNT1 A 0 A_SpawnItemEx("SuperArmQuakeRadiusRange",0,0,0,0,0,0,342) TNT1 A 0 A_SpawnItemEx("SuperArmQuakeRadiusRange",0,0,0,0,0,0,360)
stop
}
}

actor SuperArmQuakeRadiusRange
{
PROJECTILE
+FLOORHUGGER
+NOINTERACTION
+NOCLIP
Damage(0)
Height 1
Radius 1
Speed 0
States
{
Spawn:
TNT1 A 0 A_SpawnItemEx("SuperArmQuakeRadiusExplode",18) TNT1 A 0 A_SpawnItemEx("SuperArmQuakeRadiusExplode",36)
TNT1 A 0 A_SpawnItemEx("SuperArmQuakeRadiusExplode",54) TNT1 A 0 A_SpawnItemEx("SuperArmQuakeRadiusExplode",72)
TNT1 A 0 A_SpawnItemEx("SuperArmQuakeRadiusExplode",90) TNT1 A 0 A_SpawnItemEx("SuperArmQuakeRadiusExplode",108)
TNT1 A 0 A_SpawnItemEx("SuperArmQuakeRadiusExplode",126) TNT1 A 0 A_SpawnItemEx("SuperArmQuakeRadiusExplode",144)
TNT1 A 0 A_SpawnItemEx("SuperArmQuakeRadiusExplode",162) TNT1 A 0 A_SpawnItemEx("SuperArmQuakeRadiusExplode",180)
stop
}
}

actor SuperArmQuakeRadiusExplode
{
species "DustManType"
+THRUSPECIES
PROJECTILE
+DONTBLAST
+DONTREFLECT
-NOBLOCKMAP
damagetype "GutsmanQuake"
Obituary "$OB_GUTSMAN2"
damage (1)
Radius 8
Height 16
scale 2.5
States
{
Spawn:
TNT1 A 0
TNT1 A 1
stop
}
}

actor GutsmanQuakeProtect : PowerProtection
{
	Powerup.Duration -1
	DamageFactor "GutsmanQuake", 0.0
}

actor GutsTackleHitBox
{
PROJECTILE
-NOBLOCKMAP
+DONTBLAST
+DONTREFLECT
+THRUSPECIES
+THRUGHOST//Pierce shields
+HEXENBOUNCE
+RIPPER
var int user_PierceRipper;
damagetype "GutsmanTackle"
Obituary "$OB_GUTSMAN3"
species "DustManType"
damage (25)
Radius 36
Height 36
scale 2.5
reactiontime 27
States
{
Spawn:
TNT1 A 0
TNT1 A 0 A_CountDown
TNT1 A 1 A_Warp(AAPTR_TARGET,0,0,0,0,WARPF_NOCHECKPOSITION)
loop

Death:
TNT1 A 1
stop
}
}

Actor GutsmanTackleProtect : PowerProtection
{
	Powerup.Duration -1
	DamageFactor "GutsmanTackle", 0.0
}

Actor TenguDustG
{
PROJECTILE
//+FLOORHUGGER
//+SPAWNCEILING
+CLIENTSIDEONLY
scale 2.5
States
{
Spawn:
TNT1 AA 0 A_GiveInventory("ProjectileCode")
TNT1 A 1 A_JumpIf(z-floorz>8,"Spawn2")
stop

Spawn2:
TNT1 A 1 A_ChangeFlag("FLOORHUGGER",1)
TE8D AB 2
TE8D CCDD 1 A_FadeOut(0.2)
stop
}
}

actor GutsAltHandler : CustomInventory
{
States
{
Pickup:
TNT1 A 0 A_Quake(4,18,0,200,0)
TNT1 A 0 A_PlaySoundEx("weapon/gutstacklehit","Body")
stop
}
}

actor GutsQuakeDebris2 : GutsQuakeDebris
{
States
{
Spawn:
TNT1 AA 0 A_GiveInventory("ProjectileCode",1)

S_1:
GRCK F 70
stop
}
}

actor GutsBoulderThrowMain : BaseBlockThrow
{
-NOGRAVITY
Obituary "$OB_GUTSMAN4"
Damage (45)
Gravity 2.0
States
{
Spawn:
TNT1 AA 0 A_GiveInventory("ProjectileCode",1)
GRCK A 1
wait
Death:
TNT1 A 0 A_ChangeFlag("NOGRAVITY",True)
GRCK AABBCC 1 A_Stop
TNT1 A 0 A_PlaySoundEx("weapon/GutsmanRock", "Body")
TNT1 AAAAAAAAAA 0 A_SpawnItemEx("GutsBoulderDebris",0,0,32,random(5,10),0,random(4,12),random(0,359),1)
TNT1 A 15 A_Quake(3,15,0,400)
stop
XDeath:
Crash:
TNT1 A 0 A_PlaySoundEx("weapon/GutsmanRock", "Body")
TNT1 AAAAAAAAAA 0 A_SpawnItemEx("GutsBoulderDebris2",0,0,32,random(5,10),0,random(4,12),random(0,359),1)
TNT1 A 15 A_Quake(3,15,0,400)
stop
}
}

actor GutsBoulderThrowAlt : BaseBlockThrow
{
+NOINTERACTION
Obituary "$OB_GUTSMAN4"
States
{
Spawn:
TNT1 AA 0 A_GiveInventory("ProjectileCode",1)
GRCK ABC 1 A_Stop
Death:
TNT1 A 0 A_ChangeFlag("NOGRAVITY",True)
TNT1 A 0 A_PlaySoundEx("weapon/GutsmanRock", "Body")
TNT1 AAAAAAAAAA 0 A_SpawnItemEx("GutsBoulderDebris",0,0,16,Random(8,24),0,random(-1,1),random(-35,35),1)
TNT1 A 15 A_Quake(3,15,0,400)
stop
}
}

actor GutsBoulderDebris : BaseBlockDebris
{
-NOGRAVITY
+HEXENBOUNCE
+CANBOUNCEWATER
Obituary "$OB_GUTSMAN5"
BounceFactor 0.8
WallBounceFactor 1.0
var int user_dmg;
Damage(9)
Radius 10
Height 26
ReactionTime 52
States
{
Spawn:
TNT1 AA 0 A_GiveInventory("ProjectileCode")
TNT1 A 0 A_Jump(32,"Metool")
TNT1 A 1 A_Jump(256,"PieceA","PieceB","PieceC")
wait
PieceA:
GRCK DD 1 A_CountDown
GRCK D 0 A_SetUserVar("user_dmg",9)
GRCK D 1 A_CountDown
wait
PieceB:
GRCK EE 1 A_CountDown
GRCK E 0 A_SetUserVar("user_dmg",9)
GRCK E 1 A_CountDown
wait
PieceC:
GRCK FF 1 A_CountDown
GRCK F 0 A_SetUserVar("user_dmg",9)
GRCK F 1 A_CountDown
wait
Metool:
METT DD 1 A_CountDown
METT D 0 A_SetUserVar("user_dmg",9)
METT D 1 A_CountDown
wait
Death:
MMFX FGHI 2 A_Stop
stop
}
}

Actor GutsBoulderDebris2 : GutsBoulderDebris
{
damage (0 + user_dmg)
}

actor GutsBoulderFX : BaseBlockFX
{
States
{
Spawn:
TNT1 AA 0 A_GiveInventory("ProjectileCode",1)
TNT1 A 0 A_Jump(32,"Metool")
TNT1 A 1 A_Jump(256,"PieceA","PieceB","PieceC")
wait
PieceA:
GRCK D 2
TNT1 A 2
loop
PieceB:
GRCK E 2
TNT1 A 2
loop
PieceC:
GRCK F 2
TNT1 A 2
loop
Metool:
METT D 2
TNT1 A 2
loop
}
}

actor GutsManUltWatcher
{
Height 0
Radius 0
+NOINTERACTION
-SOLID
+NOGRAVITY
+MISSILE
States
{
Spawn:
TNT1 A 0
TNT1 AA 1 A_JumpIf(ACS_NamedExecuteWithResult("core_targetexists",0) == 0, "Death")
TNT1 A 0 A_TakeFromTarget("MediumUltimateAmmo",1)
TNT1 A 0 A_JumpIfInTargetInventory("MediumUltimateAmmo",1,"Spawn")
Death:
TNT1 A 0
stop
}
}

actor GutsQuakeDebris3 : GutsQuakeDebris
{
States
{
Spawn:
TNT1 AA 0 A_GiveInventory("ProjectileCode",1)
TNT1 A 0 A_Jump(256,"S_1","S_2","S_3","S_4","S_5")

S_1:
GGRK C 70
stop

S_2:
GGRK D 70
stop

S_3:
GGRK E 70
stop

S_4:
GGRK F 70
stop

S_5:
GGRK G 70
stop
}
}

actor BlockDebrisSpawner
{
Translation "204:204=216:216","195:195=220:220"
PROJECTILE
-NOGRAVITY
+BOUNCEONWALLS
Height 16
Radius 8
Scale 2.5
States
{
Spawn:
TNT1 AA 0 A_GiveInventory("ProjectileCode",1)
TNT1 A 1 A_Jump(256,"A","B","C","D","E","F","G")
wait
A:
SARM BZ 2
loop
B:
SAR2 BZ 2
loop
C:
SAR3 BZ 2
loop
D:
SAR4 BZ 2
loop
E:
SAR5 BZ 2
loop
F:
GUTP ZX 2
loop
G:
GUTP QX 2
loop
}
}

actor GutsmanGBlock
{
PROJECTILE
-NOGRAVITY
-NOBLOCKMAP
-INVULNERABLE
+SHOOTABLE
+STEPMISSILE
+NOEXPLODEFLOOR
+BOUNCEONCEILINGS
+NOTARGETSWITCH
MaxStepHeight 24
damagetype "Gutsman"
Obituary "$OB_GUTSMAN6"
renderstyle "translucent"
gravity 0.7
health 9999
Damage(70)
Speed 35
Radius 48
Height 64
Scale 2.5
states
{
Spawn:
TNT1 AA 0 A_GiveInventory("ProjectileCode",1)
TNT1 A 0 ACS_NamedExecuteWithResult("core_alphaprojectile", CallACS("core_getptrtid", AAPTR_TARGET), APROJ_TEAM, 6553, 128)
GGRK A 1 ThrustThingZ(0,0,0,1)
wait
Pain.SlashClaw:
Pain.SlashMan:
Pain.SlashMan2:
TNT1 A 0 A_ChangeFlag("INVULNERABLE",True)
TNT1 A 0 A_ScaleVelocity(-1.0)
Goto Spawn+2
Death:
TNT1 A 0 A_PlaySoundEx("weapon/gutsmangbreak","Body")
TNT1 A 0 A_PlaySoundEx("weapons/mm4/drillbombexplode","Weapon")
TNT1 AAAAAAAAAAAAAAAAAAAAAAAAA 0 A_SpawnItemEx("GutsManGBlockDebris",Random(0,48),0,Random(16,80),random(5,20),0,random(5,20),random(0,359),SXF_TRANSFERPOINTERS)
TNT1 A 25 A_Quake(3,25,0,400)
stop
}
}

actor GutsManGBlockDebris
{
PROJECTILE
-NOGRAVITY
+BOUNCEONWALLS
+CANBOUNCEWATER
+BOUNCEONCEILINGS
damagetype "Gutsmanbit"
Obituary "$OB_GUTSMAN6"
Gravity 1.0
Damage (9)
Radius 8
Height 16
scale 2.5
States
{
Spawn:
TNT1 AA 0 A_GiveInventory("ProjectileCode",1)
GGRK B 1
wait
}
}

actor GutsManGBlockFX
{
PROJECTILE
-NOGRAVITY
+THRUACTORS
+BOUNCEONWALLS
+CANBOUNCEWATER
+BOUNCEONCEILINGS
Damage (0)
Radius 8
Height 16
scale 2.5
States
{
Spawn:
TNT1 AA 0 A_GiveInventory("ProjectileCode",1)
GGRK BZ 2
loop
}
}

actor GutsmanGDrillDamager
{
species "DustManType"
+THRUSPECIES
PROJECTILE
damagetype "Gutsman"
Obituary "$OB_GUTSMAN7"
+RIPPER
+NOINTERACTION
+DONTBLAST
damage (0)
radius 1
height 1
States
{
Spawn:
TNT1 A 0
TNT1 A 1 A_Explode(6,80,0)
stop
}
}

actor GutsmanGUpperCutDamager : GutsmanGDrillDamager
{
damagetype "GutsmanGUpperCut"
Obituary "$OB_GUTSMAN8"
States
{
Spawn:
TNT1 A 0
TNT1 A 1 A_Explode(40,128,0,0,128)
stop
}
}

Actor GutsmanGFlingProtect : PowerProtection
{
	Powerup.Duration -1
	DamageFactor "GutsmanGUpperCut", 0.0
}

actor GutsmanSkinWatcher
{
Height 0
Radius 0
+NOINTERACTION
+MISSILE
states
{
Spawn:
TNT1 A 0
TNT1 AAA 1 A_GiveToTarget("GutsmanSkinCheck")
TNT1 A 0 A_JumpIf(ACS_NamedExecuteWithResult("core_targetexists",0) == 0, "Death")
loop
Death:
TNT1 A 0
stop
}
}

actor GutsmanSkinCheck : SkinChecker
{
States
{
Pickup:
TNT1 A 0 A_JumpIf(CallACS("GC_GetSkinNum")==262,"AltSkin1")
goto NormalSkin
}
}

actor GutsManGCeilingRush_CI : CustomInventory
{
states
{
Pickup:
TNT1 A 0 A_JumpIfInventory("NewWallSlam",1,"PickupNo")
TNT1 A 0 A_GiveInventory("NoNewWallSlam",1)
TNT1 A 0 A_GiveInventory("NewWallSlam",1)
TNT1 A 0 A_GiveInventory("WallSlamRealTimer",1)
TNT1 A 0 A_SpawnItemEX("GutsManGCeilingRushChecker")
stop
PickupNo:
TNT1 A 0
stop
}
}

actor GutsManGCeilingRushChecker
{
Height 0
Radius 0
Damage (0)
+NOINTERACTION
+NOCLIP
DamageType "GutsmanGCeilingRush"
Obituary "$OB_GUTSMAN9"
PROJECTILE
states
{
Spawn:
TNT1 A 0
TNT1 A 0 A_RearrangePointers(AAPTR_DEFAULT, AAPTR_DEFAULT, AAPTR_TARGET)
TNT1 A 0 A_TransferPointer(AAPTR_TARGET, AAPTR_DEFAULT, AAPTR_TARGET, AAPTR_TARGET)
SpawnStart0:
TNT1 A 0 A_GiveInventory("WallSlamTimer",1)
SpawnStart:
TNT1 A 0 A_GiveInventory("CeilingSlamTrailPickup",1,AAPTR_TRACER)
TNT1 A 1 A_GiveInventory("WallSlamTimer",1,AAPTR_TRACER)
TNT1 A 0 A_Warp(AAPTR_TRACER,0,0,CallACS("TracerHeightGet")/2,0,0)
TNT1 A 0 A_JumpIfInventory("RaThorWallRush_P",1,"DeathCheck",AAPTR_TRACER)
TNT1 A 0 A_JumpIfInventory("WallSlamRealTimer",1,"SpawnStart",AAPTR_TRACER)
goto Death
DeathCheck:
TNT1 A 0 //A_JumpIfInventory("NewWallSlam",1,"Death",AAPTR_TRACER)
TNT1 A 0 A_GiveInventory("WallSlamTimer",1)
TNT1 AAAAAAAAAAAAAAAAAAAA 0 A_SpawnItemEx("GutsManGSlamRocks",random(-8,8),random(-8,8),-8,random(-8,8),random(-8,8))
TNT1 A 0 A_Quake(3,10,0,256)
TNT1 A 0 A_PlaySoundEx("misc/quake","Body")
TNT1 A 0 A_PlaySoundEx("weapon/wallrush","Weapon")
TNT1 A 0 A_Warp(AAPTR_TRACER,0,0,CallACS("TracerHeightGet")/2,0,0)
TNT1 A 0 A_Explode(13,12,0,0,12)
TNT1 A 35
Death:
TNT1 A 2 A_GiveInventory("TempPitProtectEnd_P",1,AAPTR_TRACER)
stop
}
}

actor CeilingSlamTrailPickup : CustomInventory
{
states
{
Pickup:
TNT1 A 0 //A_JumpIf(z-floorz==0,"Pickup_NoHurtActor")
TNT1 A 0 A_JumpIfInventory("RaThorWallRush_P",1,"Nope")
TNT1 A 0 A_SpawnItemEx("GutsManGCeilingRushRealChecker",0,0,40,0,0,8,0)
TNT1 A 0 A_GiveInventory("RaThorSpeedThing",1)
stop
Pickup_NoHurtActor:
TNT1 AAAA 0 A_TakeInventory("WallSlamRealTimer",999)
TNT1 AAAA 0 A_TakeInventory("WallSlamTimer",999)
TNT1 AAAA 0 A_TakeInventory("RaThorWallRush_P",999)
stop
Nope:
TNT1 A 0
stop
}
}


Actor GutsManGCeilingRushRealChecker
{
PROJECTILE
+NOTARGETSWITCH
Scale 2.5
+DONTBLAST
+DONTREFLECT
+MTHRUSPECIES //+THRUSPECIES
//Species "Megaman"
Damage (0)
Radius 8
Height 8
Speed 20
states
{
Spawn:
TNT1 A 0
TNT1 A 1
stop
Crash:
XDeath:
TNT1 A 1 //A_GiveToTarget("RaThorDashFlagX")
stop
Death:
TNT1 A 0 A_CheckCeiling("Death2")
stop
Death2:
TNT1 A 0 A_GiveInventory("RaThorWallRush_P",1,AAPTR_TARGET)
stop
}
}

actor GutsManGSlamRocks : ThorSlamRocks
{
-SOLID
Bouncecount 1
Gravity 1.0
States
{
Spawn:
TNT1 AA 0 A_GiveInventory("ProjectileCode")
GGRK B 2
GGRK B 0 A_ChangeFlag("NOCLIP",False)
loopit:
GGRK B 2 A_JumpIf(z-floorz<=0,"Death")
loop
}
}

actor TimeThirdUlt : Powerup
{
	powerup.duration 140
}

actor RustyMovementUlt : Powerup
{
	powerup.Duration 280
}

actor GutsTFWatcher
{
+MISSILE
+NOGRAVITY
+NOINTERACTION
States
{
Spawn: 
TNT1 AA 0
TNT1 A 1 A_GiveToTarget("GutsTFCooldown",210)
Goto Drain

Drain:
TNT1 A 1 A_TakeFromTarget("GutsTFCooldown",1)
TNT1 A 0 A_JumpIfInTargetInventory("IsTheTerminator",1,"Death")
TNT1 A 0 A_JumpIf(ACS_NamedExecuteWithResult("core_targetexists",0) == 0, "Death")
TNT1 A 0 A_JumpIfInTargetInventory("GutsTFCooldown",1,"Drain")
Goto Death

Death:
TNT1 A 0
TNT1 A 1
stop
}
}

actor GutsTFCooldown : Ammo
{
inventory.amount 1
inventory.maxamount 210
+INVENTORY.IGNORESKILL
}