/////////////
//  GAMMA  //						The big one
/////////////

actor GammaBoss
{
scale 2.5
+FORCEYBILLBOARD
obituary "%o was stomped on by \cfGamma\c*."
radius 120
height 1000
species "Gamma"
MONSTER
-SOLID
+DROPOFF
+DONTBLAST
+LOOKALLAROUND
+SEEINVISIBLE
-SHOOTABLE
Speed 8
var int user_phase;
States
{
Spawn:
GAMA A 0 A_Jump(256, "Look")
GAMA A -1
stop
Look:
GAMA "#" 5 A_Look
loop
See:
GAMA CCCCCCCCCCCCCCCCCCCCCCCCCDDDDDDDDDDDDDDDDDDDDDDDDD 1 A_Chase
GAMA D 0 A_CustomMissile("GammaStomp2",0,0,0,0)
GAMA E 30 ACS_ExecuteAlways(17,0,0)
GAMA FFFFFFFFFFFFFFFFFFFFFFFFFGGGGGGGGGGGGGGGGGGGGGGGGG 1 A_Chase
GAMA D 0 A_CustomMissile("GammaStomp2",0,0,0,0)
GAMA B 10 ACS_ExecuteAlways(17,0,0)
Goto Attack
Attack:
GAMA D 0 A_GiveInventory("CutterFlag",1)
GAMA B 0 A_SetUserVar("user_phase", 2)
GAMA B 0 A_Jump(256, "Lightning", "Fire", "Laser")
Laser:
GAMA B 0 A_PlaySoundEx("mist/gammalaser", "Voice", 0, 1)
GAMA B 0 A_FaceTarget
GAMA BBBBBBBBBBBBBBBBBBBBBB 1 A_SpawnItemEx("GammaEyeFX",4,-26,1448)
GAMA BB 2 //A_SpawnItemEx("GammaEyeFX",25,-54,1405)
GAMA B 0 ACS_ExecuteAlways(19,0,0,user_phase)
GAMA B 0 A_StopSoundEx("Voice")
Goto Waiting
Fire:
GAMA B 0 A_PlaySoundEx("misc/gammafire", "Voice" ,0, 1)
GAMA B 0 A_FaceTarget
GAMA BBBBBBBBBBBBBBBBBBBBBBBBBBB 1 A_SpawnItemEx("GammaFireBreathFX",4,0,1390, 3, random(-20, 20), 0)
GAMA BB 2 //A_SpawnItemEx("GammaEyeFX",25,-54,1405)
GAMA B 0 A_FaceTarget
GAMA B 0 ACS_ExecuteAlways(19,0,1,user_phase)
GAMA BBBBBBBBBBBBB 1 A_SpawnItemEx("GammaFireBreathFX",4,0,1390, 3, random(-20, 20), 0)
GAMA B 0 A_StopSoundEx("Voice")
Goto Waiting
Lightning:
GAMA B 0 A_PlaySoundEx("misc/wilystart", "Voice", 1, 1)
GAMA B 0 A_FaceTarget
GAMA BBB 20 A_SpawnItemEx("GammaLitFX",25,0,1600)
GAMA B 1 A_StopSoundEx("Voice")
//GAMA B 0 A_SpawnItemEx("GammaLightningStart1", 4, 0, 1400, 0, 0, -50, 0) 
GAMA B 0 ACS_ExecuteAlways(19,0,2,user_phase)
Goto Waiting
Waiting:
GAMA B 1 A_FaceTarget
loop
SpawnEye:
GAMA B 0 A_FaceTarget
GAMA B 0 Thing_Remove(502)
GAMA B 1 A_SpawnItemEx("GammaEyeLocation",4,-26,1448)
Goto Waiting
Kneel:
GAMD A 20
GAMD B 20
GAMD C 15
GAMD D 70
WilyMad:
GAMD EEEFFF 2 A_SpawnItemEx("GammaDamagedFX", -3, random(-350, 350) , 950, 0,0,5,random(0,360))
loop
Repairing:
GAMD D 2 A_SpawnItemEx("GammaDamagedFX", -3, random(-350, 350) , 950, 0,0,5,random(0,360))
loop
RepairComplete:
GAMD D 20
GAMD DDDDDDD 0 A_SpawnItemEx("GammaJunkFX", random(-100, 100), random(-100, 100), 980, random(5, 20),0,random(0, 20), random(0,360))
GAMD D 20 A_PlaySoundEx("weapon/spreaddrillhit", "Voice", 0, 1)
GAMD DDDDDDD 0 A_SpawnItemEx("GammaJunkFX", random(-100, 100), random(-100, 100), 980, random(5, 20),0,random(0, 20), random(0,360))
GAMD D 20 A_PlaySoundEx("weapon/spreaddrillhit", "Voice", 0, 1)
GAMD DDDDDDD 0 A_SpawnItemEx("GammaJunkFX", random(-100, 100), random(-100, 100), 980, random(5, 20),0,random(0, 20), random(0,360))
GAMD D 20 A_PlaySoundEx("weapon/spreaddrillhit", "Voice", 0, 1)
GAMD D 0 A_SpawnItemEx("ETank", 0, 0, 980, 22, 0, random(0, 20), 0)
GAMD DDDDDDD 0 A_SpawnItemEx("GammaJunkFX", random(-100, 100), random(-100, 100), 980, random(5, 20),0,random(0, 20), random(0,360))
GAMD D -1 A_PlaySoundEx("weapon/spreaddrillhit", "Voice", 0, 1)
stop
Rise:
GAMD D 20
GAMD C 15
GAMD B 20
GAMD A 20
GAMA A 0 A_PlaySoundEx("zandronum/connect", "Voice", 0, 1)
GAMA A 2
GAMD A 2
GAMA A 2
GAMD A 2
GAMA A 2
GAMD A 2
GAMA A 20
Goto See
RiseFake:
GAMD D 20
GAMD C 15
GAMD B 20
GAMD A 20
GAMA A 0 A_PlaySoundEx("zandronum/connect", "Voice", 0, 1)
GAMA A 2
GAMD A 2
GAMA A 2
GAMD A 2
GAMA A 2
GAMD A 2
GAMA A -1
Goto See
Vulnerable:
GAMD D 0 A_SpawnItemEx("GammaFinalHitbox", 8, 0, 950)
GAMD D 0 A_SpawnItemEx("GammaTallPhysics", -6, 0, 0)
GAMD D 0 A_SpawnItemEx("GammaTallPhysics", -6, 64, 0, 0)
GAMD D 0 A_SpawnItemEx("GammaTallPhysics", -6, 64*2, 0, 0)
GAMD D 0 A_SpawnItemEx("GammaTallPhysics", -6, 64*3, 0, 0)
GAMD D 0 A_SpawnItemEx("GammaTallPhysics", -6, 64*4, 0, 0)
GAMD D 0 A_SpawnItemEx("GammaTallPhysics", -6, 64*5, 0, 0)
GAMD D 0 A_SpawnItemEx("GammaTallPhysics", -6, 64*6, 0, 0)
GAMD D 0 A_SpawnItemEx("GammaTallPhysics", -6, -64, 0, 0)
GAMD D 0 A_SpawnItemEx("GammaTallPhysics", -6, -64*2, 0, 0)
GAMD D 0 A_SpawnItemEx("GammaTallPhysics", -6, -64*3, 0, 0)
GAMD D 0 A_SpawnItemEx("GammaTallPhysics", -6, -64*4, 0, 0)
GAMD D 0 A_SpawnItemEx("GammaTallPhysics", -6, -64*5, 0, 0)
GAMD D 0 A_SpawnItemEx("GammaTallPhysics", -6, -64*6, 0, 0)
Goto WilyMad
}
}

actor GammaFinalHitbox
{
obituary "%o was vaporized by \cfGamma\c*."
scale 5.5
+NOGRAVITY
//MONSTER
+SHOOTABLE
-SOLID
+THRUSPECIES
+NOBLOOD
+DONTRIP
species "Gamma"
mass 9999
Health 1
height 128
radius 128
renderstyle none
painchance 256
damagefactor "normal", 0.0
damagefactor "Gamma", 0.0
damagefactor "TopSpin", 1.0
damagefactor "ChargeKick", 1.0
damagefactor "ShadowBlade", 1.0
damagefactor "PowerStone", 1.0
	states
	{
	Spawn:
	PLAY C 8 Thing_ChangeTID(0, 501)
	loop
	Death:
	PLAY H 1 ACS_Execute(25,0)
	stop
	}
}

actor GammaTallPhysics
{
scale 5.5
//+SHOOTABLE
renderstyle none
+SOLID
+INVULNERABLE
height 980
radius 64
states
{
Spawn:
PLAY A -1
stop
}
}

actor GammaJunkFX
{
scale 3.0
+MISSILE
+DOOMBOUNCE
renderstyle translucent
gravity 1.5
bouncefactor 0.1
states
{
Spawn:
TNT1 A 0
TNT1 A 1 A_Jump(256, "Junk1", "Junk2")
Junk1:
JSHI V 1 A_FadeOut(0.01)
loop
Junk2:
JSHI W 1 A_FadeOut(0.01)
loop
}
}

actor PowerMusclerBros
{
-SOLID
+NOINTERACTION
states
{
	Spawn:
	TNT1 A 0
	TNT1 A 40 A_SpawnITemEx("GammaPowerMusclerTeleport", 256*3, 256*2, 800, 0, 0, -20, 0)
	TNT1 A 40 A_SpawnITemEx("GammaPowerMusclerTeleport", 256*3, -256*2, 800, 0, 0, -20, 0)
	stop
}
}


actor GammaPowerMusclerTeleport
{
+NOGRAVITY
Scale 2.5
translation "192:192=39:39", "198:198=41:41"
States
	{
	Spawn:
	TFOG D 0 //A_ChangeVelocity(0,0,-13,CVF_RELATIVE|CVF_REPLACE)
	TFOG D 1 A_Jumpif(floorz==z, "Land")
	loop
	Land:
	TFOG D 0 A_PlaySoundEx("misc/teleportin", "Voice", 0, 1)
	TFOG E 4
	TFOG D 0 A_SpawnItemEx("GammaPowerMuscler")
	TFOG F 4
	stop
	}
}

actor GammaPowerMuscler
{
//$Category MM8BDM-Enemies
scale 2.5
Health 550
Height 160
Radius 64
painchance 256
Obituary "%o was smashed by a Power Muscler."
maxstepheight 50
+DROPOFF
mass 999999
MONSTER
+LOOKALLAROUND
+DONTBLAST
-SOLID
+NOBLOOD
-CANPASS
//bloodtype "EnemyHurtFX1"
speed 8
painsound "misc/devilpain"
painchance 256
damagefactor "Gamma", 0.0
damagefactor "TopSpin", 0.1
damagefactor "DrillBomb", 0.2
damagefactor "NapalmBomb", 0.2
damagefactor "CrashBomb", 0.2
damagefactor "HyperBomb", 0.2
damagefactor "BalladeCracker", 0.2
damagefactor "RainFlush", 0.2
damagefactor "GravityHold", 0.2
species "Gamma"
//+DONTRIP
//+NORADIUSDMG
States
{
Spawn:
TNT1 A 0
TFOG A 0 Thing_ChangeTID(0, 1208)
TNT1 A 0 ACS_ExecuteAlways(23,0)
Look:
PWRM A 6 A_LookEx(LOF_NOSOUNDCHECK,0,0,0,360,"Hello")
loop
Hello:
PWRM AAAAAA 3 A_FaceTarget
See:
PWRM EEEEEEEEEE 1 A_Wander
PWRM E 0 A_SpawnItemEx("PowerMusclerRadius")
PWRM DDDDDDDDDD 1 A_Wander
PWRM E 0 A_SpawnItemEx("PowerMusclerRadius")
PWRM A 0 A_PlaySoundEx("misc/powerland","Voice")
PWRM EEEEEEEEEE 1 A_Wander
PWRM E 0 A_SpawnItemEx("PowerMusclerRadius")
PWRM FFFFFFFFFF 1 A_Wander
PWRM E 0 A_SpawnItemEx("PowerMusclerRadius")
PWRM A 0 A_PlaySoundEx("misc/powerland","Voice")
SeeAttack:
PWRM EEEEEEEEEE 1 A_Chase
PWRM E 0 A_SpawnItemEx("PowerMusclerRadius")
PWRM DDDDDDDDDD 1 A_Chase
PWRM E 0 A_SpawnItemEx("PowerMusclerRadius")
PWRM A 0 A_PlaySoundEx("misc/powerland","Voice")
PWRM EEEEEEEEEE 1 A_Chase
PWRM E 0 A_SpawnItemEx("PowerMusclerRadius")
PWRM FFFFFFFFFF 1 A_Chase
PWRM E 0 A_SpawnItemEx("PowerMusclerRadius")
PWRM A 0 A_PlaySoundEx("misc/powerland","Voice")
Missile:
PWRM AAA 5 A_FaceTarget
PWRM A 1 A_FaceTarget
PWRM E 0 A_SpawnItemEx("PowerMusclerRadius")
PWRM B 1 A_ChangeVelocity(45.0,0.0,15.0,CVF_REPLACE|CVF_RELATIVE)
Goto Leaping
Leaping:
PWRM B 0 A_FaceTarget
PWRM B 0 A_ChangeVelocity(45.0,0,velz,CVF_REPLACE|CVF_RELATIVE)
PWRM B 0 A_JumpIfCloser(100,"ForcedLand")
PWRM B 1 A_JumpIf(Floorz-z==0,"Land")
loop
ForcedLand:
PWRM B 0 A_ChangeFlag("NOGRAVITY",1)
PWRM B 2 A_Stop
PWRM B 0 A_ChangeVelocity(0.0,0.0,-10.0,CVF_REPLACE|CVF_RELATIVE)
Leaping2:
PWRM E 0 A_SpawnItemEx("PowerMusclerFX",-26,27,115)
PWRM E 0 A_SpawnItemEx("PowerMusclerFX",-26,-27,115)
PWRM B 0 A_ChangeFlag("NOGRAVITY",0)
PWRM B 1 A_JumpIf(Floorz-z==0,"Land")
loop
Land:
PWRM B 0 A_ChangeFlag("NOGRAVITY",0)
PWRM E 0 A_SpawnItemEx("PowerMusclerShockWave")
PWRM E 0 A_SpawnItemEx("PowerMusclerRadius")
PWRM A 0 A_PlaySoundEx("misc/hugequake2","Voice")
PWRM C 3 A_Stop
PWRM A 20
Goto See
Death:
PWRM A 0 A_Stop
PWRM A 0 A_Pain
PWRM A 0 A_Fall
PWRM A 0 A_ChangeFlag("NOGRAVITY",1)
PWRM A 0 A_PlaySoundEx("weapon/drillexplode","Voice",0,1)
TNT1 A 2 A_SpawnItemEx("DrillExplode",0,0,64)
TNT1 A -1
stop
Pain.TimeStopper:
PWRM "#" 0 A_Stop
PWRM "#" 0 A_ChangeFlag("NOPAIN",1)
PWRM "#" 0 A_ChangeFlag("NOGRAVITY",1)
PWRM "########################################################################################" 2 A_SpawnItemEx("TimeStopGFX", random(8, 64), 0, random(0, 128), 0, 0, 0, random(0, 359))
PWRM "#" 0 A_ChangeFlag("NOPAIN",0)
PWRM "#" 0 A_ChangeFlag("NOGRAVITY",0)
Goto Leaping2
Pain.TimeSlow:
PWRM A 0 ACS_ExecuteAlways(24, 0)
PWRM A 0 A_GiveInventory("Slowed",1)
goto Leaping2
}
}


actor PowerMusclerShockWave
{
PROJECTILE
+THRUSPECIES
species "Gamma"
damagetype "Gamma"
States
{
Spawn:
TNT1 A 0
TNT1 A 0 A_Explode(20,64,0)
TNT1 A 0 A_SpawnItemEx("PowerMusclerShockwavePart",0,0,0,18,0,0,0)
TNT1 A 0 A_SpawnItemEx("PowerMusclerShockwavePart",0,0,0,18,0,0,15)
TNT1 A 0 A_SpawnItemEx("PowerMusclerShockwavePart",0,0,0,18,0,0,30)
TNT1 A 0 A_SpawnItemEx("PowerMusclerShockwavePart",0,0,0,18,0,0,45)
TNT1 A 0 A_SpawnItemEx("PowerMusclerShockwavePart",0,0,0,18,0,0,60)
TNT1 A 0 A_SpawnItemEx("PowerMusclerShockwavePart",0,0,0,18,0,0,75)
TNT1 A 0 A_SpawnItemEx("PowerMusclerShockwavePart",0,0,0,18,0,0,90)
TNT1 A 0 A_SpawnItemEx("PowerMusclerShockwavePart",0,0,0,18,0,0,105)
TNT1 A 0 A_SpawnItemEx("PowerMusclerShockwavePart",0,0,0,18,0,0,120)
TNT1 A 0 A_SpawnItemEx("PowerMusclerShockwavePart",0,0,0,18,0,0,135)
TNT1 A 0 A_SpawnItemEx("PowerMusclerShockwavePart",0,0,0,18,0,0,150)
TNT1 A 0 A_SpawnItemEx("PowerMusclerShockwavePart",0,0,0,18,0,0,165)
TNT1 A 0 A_SpawnItemEx("PowerMusclerShockwavePart",0,0,0,18,0,0,180)
TNT1 A 0 A_SpawnItemEx("PowerMusclerShockwavePart",0,0,0,18,0,0,195)
TNT1 A 0 A_SpawnItemEx("PowerMusclerShockwavePart",0,0,0,18,0,0,210)
TNT1 A 0 A_SpawnItemEx("PowerMusclerShockwavePart",0,0,0,18,0,0,225)
TNT1 A 0 A_SpawnItemEx("PowerMusclerShockwavePart",0,0,0,18,0,0,240)
TNT1 A 0 A_SpawnItemEx("PowerMusclerShockwavePart",0,0,0,18,0,0,255)
TNT1 A 0 A_SpawnItemEx("PowerMusclerShockwavePart",0,0,0,18,0,0,270)
TNT1 A 0 A_SpawnItemEx("PowerMusclerShockwavePart",0,0,0,18,0,0,285)
TNT1 A 0 A_SpawnItemEx("PowerMusclerShockwavePart",0,0,0,18,0,0,300)
TNT1 A 0 A_SpawnItemEx("PowerMusclerShockwavePart",0,0,0,18,0,0,315)
TNT1 A 0 A_SpawnItemEx("PowerMusclerShockwavePart",0,0,0,18,0,0,330)
TNT1 A 0 A_SpawnItemEx("PowerMusclerShockwavePart",0,0,0,18,0,0,345)
stop
}
}

actor PowerMusclerShockwavePart
{
PROJECTILE
+THRUSPECIES
species "Gamma"
Scale 2.0
damagetype "Gamma"
+NOINTERACTION
translation "192:207=80:80"
Speed 35
Damage (5)
Radius 32
Height 32
States
{
	Spawn:
	TNT1 A 0
	TNT1 A 1
	DUOR T 2
	DUOR T 5 A_ChangeFlag("NOINTERACTION",0)
	Death:
	DUOR TTTTTTTT 1 A_FadeOut(0.1)
	loop
}
}



actor PowerMusclerFX
{
+NOINTERACTION
+NOGRAVITY
-SOLID
scale 2.5
states
{
Spawn:
PWRM GHI 3
stop
}
}

actor PowerMusclerRadius
{
+MISSILE
damagetype "Gamma"
States
{
Spawn:
TNT1 A 0
TNT1 A 0 A_Explode(30,80,0)
stop
}
}


actor GammaSniperJoeShot
{
PROJECTILE
Damage (8)
damagetype "Gamma"
+FORCEXYBILLBOARD
Speed 40
scale 2.5
Height 8
Radius 8
States
{
Spawn:
BASB A 1
loop
}
}

actor GammaJoeArmy
{
-SOLID
+NOINTERACTION
states
{
	Spawn:
	TNT1 A 0
	TNT1 A 10 A_SpawnITemEx("GammaJoeTeleport", 256*5, 256*1, 600, 0, 0, -20, 0)
	TNT1 A 10 A_SpawnITemEx("GammaJoeTeleport", 256*5, -256*1, 600, 0, 0, -20, 0)
	TNT1 A 10 A_SpawnITemEx("GammaJoeTeleport", 256*4, 256*2, 600, 0, 0, -20, 0)
	TNT1 A 10 A_SpawnITemEx("GammaJoeTeleport", 256*4, -256*2, 600, 0, 0, -20, 0)
	TNT1 A 10 A_SpawnITemEx("GammaJoeTeleport", 256*3, 256*3, 600, 0, 0, -20, 0)
	TNT1 A 10 A_SpawnITemEx("GammaJoeTeleport", 256*3, -256*3, 600, 0, 0, -20, 0)
	TNT1 A 10 A_SpawnITemEx("GammaJoeTeleport", 256*2, 256*4, 600, 0, 0, -20, 0)
	TNT1 A 10 A_SpawnITemEx("GammaJoeTeleport", 256*2, -256*4, 600, 0, 0, -20, 0)
	TNT1 A 10 A_SpawnITemEx("GammaJoeTeleport", 256, 256*5, 600, 0, 0, -20, 0)
	TNT1 A 10 A_SpawnITemEx("GammaJoeTeleport", 256, -256*5, 600, 0, 0, -20, 0)
	stop
}
}

actor GammaJoeTeleport
{
+NOGRAVITY
Scale 2.5
translation "192:192=4:4", "198:198=110:110"
States
	{
	Spawn:
	TFOG A 0
	TFOG A 1 A_Jumpif(floorz==z, "Land")
	loop
	Land:
	TFOG A 0 A_PlaySoundEx("misc/teleportin", "Voice", 0, 1)
	TFOG CCAAABBB 1
	TFOG A 0 A_SpawnItemEx("GammaJoe")
	stop
	}
}

// Copied from MMSP 
actor GammaJoe
{
//$Category MM8BDM-Enemies
Height 52
Radius 32
Obituary "%o was sniped by a Sniper Joe."
Health 95
scale 2.5
translation "192:192=4:4", "198:198=110:110"
maxstepheight 50
painchance 256
MONSTER
+LOOKALLAROUND
//dropitem "BigWeaponEnergySP", 32
//dropitem "BigHealth", 32
mass 99999999
painsound "misc/devilpain"
speed 8

species "Gamma"
damagefactor "HyperBomb", 0.5
damagefactor "RainFlush", 0.1

States
{
Spawn:
TNT1 A 0
TFOG A 0 Thing_ChangeTID(0, 1208)
TNT1 A 0 ACS_ExecuteAlways(23,0)
Look:
SNIP A 5 A_LookEx(LOF_NOSOUNDCHECK,0,0,0,360,"See")
loop
See:
SNIP B 1
SNIP B 1 A_JumpIf(Args[0]==1, "See2")
SNIP B 1 //A_JumpIfTargetInLOS("ShieldUp") // THIS FUNCTION IS BUGGED ONLINE ARGH!
SNIP BBBB 1 A_Chase
SNIP A 0// A_JumpIfTargetInLOS("ShieldUp")
SNIP CCCC 1 A_Chase
SNIP A 0 //A_JumpIfTargetInLOS("ShieldUp")
SNIP DDDD 1 A_Chase
SNIP A 0 //A_JumpIfTargetInLOS("ShieldUp")
SNIP EEEE 1 A_Chase
Goto See+3
See2:
SNIP A 1 //A_JumpIfTargetInLOS("ShieldUp")
Goto Missile
//Pain:
//TNT1 A 1 A_Pain
ShieldUp:
Missile:
TNT1 A 0 A_SpawnItemEx("SniperJoeShieldX",23,-7,8,momx, momy, momz, 0, SXF_NOCHECKPOSITION|SXF_ABSOLUTEMOMENTUM, 0)
TNT1 A 0 A_SpawnItemEx("SniperJoeShieldFX",23,-17,8,momx, momy, momz, 0, SXF_NOCHECKPOSITION|SXF_ABSOLUTEMOMENTUM, 0)
SNIP A 2 A_FaceTarget
TNT1 A 0 A_GiveInventory("CutterFlag",1)
TNT1 A 0 A_JumpIfInventory("CutterFlag",20,"ReadyFire")
loop
ReadyFire:
TNT1 A 0 A_TakeInventory("CutterFlag",999)
TNT1 A 0 A_SpawnItemEx("SniperJoeShieldX",23,-7,8,momx, momy, momz, 0, SXF_NOCHECKPOSITION|SXF_ABSOLUTEMOMENTUM, 0)
TNT1 A 0 A_SpawnItemEx("SniperJoeShieldFX",23,-17,8,momx, momy, momz, 0, SXF_NOCHECKPOSITION|SXF_ABSOLUTEMOMENTUM, 0)
SNIP A 2 A_FaceTarget
SNIP A 0 A_Jump(20,"ShieldFire")
SNIP A 0 //A_JumpIfTargetInLOS("ReadyFire")
Goto ReadyFire//See
ShieldFire:
SNIP F 15 A_FaceTarget
SNIP F 0 A_FaceTarget
KYOR F 0 A_PlaySoundEx("misc/devilfire","Voice")
SNIP F 0 A_CustomMissile("GammaSniperJoeShot",12,6,0)
SNIP F 17
SNIP F 0 A_FaceTarget
KYOR F 0 A_PlaySoundEx("misc/devilfire","Voice")
SNIP F 0 A_CustomMissile("GammaSniperJoeShot",12,6,0)
SNIP F 17
SNIP F 0 A_FaceTarget
KYOR F 0 A_PlaySoundEx("misc/devilfire","Voice")
SNIP F 0 A_CustomMissile("GammaSniperJoeShot",12,6,0)
SNIP F 17
SNIP F 1 A_JumpIf(Args[0]==0, "See")
SNIP A 0 A_ClearTarget
Goto Look
Death:
TNT1 A 0 A_JumpIfInTargetInventory("SakugarneAmmo", 5, "Drop")
TNT1 A 0 A_GiveToTarget("SakugarneAmmo", 1)
DeathFX:
CRAZ A 0 A_Pain
CRAZ A 0 A_Fall
TNT1 A 5 A_SpawnItem("EnemyDeath",0,32)
TNT1 A -1
stop
Drop:
TNT1 A 0 A_TakeFromTarget("SakugarneAmmo", 99999)
TNT1 A 0 A_SpawnItemEx("BigHealth", 0, 0, 5, 10, 0, 12)
TNT1 A 0 A_SpawnItemEx("BigWeaponEnergy", 0, 0, 5, -10, 0, 12)
Goto DeathFX
Pain.TimeStopper:
SNIP "#" 0 A_ChangeFlag("NOPAIN",1)
SNIP "########################################################################################" 2 A_SpawnItemEx("TimeStopGFX", random(8, 64), 0, random(0, 64), 0, 0, 0, random(0, 359))
SNIP "#" 0 A_ChangeFlag("NOPAIN",0)
Goto See
Pain.TimeSlow:
SNIP A 0 ACS_ExecuteAlways(24, 0)
SNIP A 0 A_GiveInventory("Slowed",1)
goto See
}
}

actor EnemyDeath
{
+NOINTERACTION
+NOGRAVITY
scale 2.5
	states
	{
	Spawn:
	MMFX BCDE 4
	stop
	}
}


actor SniperJoeShieldFX
{
translation "192:192=4:4", "198:198=110:110"
-SOLID
+NOGRAVITY
+NOBLOCKMAP
+FIXMAPTHINGPOS
Height 0
Radius 0
scale 2.5
+CLIENTSIDEONLY
+NOINTERACTION
States
{
Spawn:
TNT1 A 0
SNIP I 2
stop
}
}

actor SniperJoeShieldX
{
+MISSILE
Speed 0
+DONTSPLASH
Damage 0
Height 32
Radius 32
health 9999
scale 2.5
+SHOOTABLE
+NOBLOOD
-SOLID
//+NOBLOCKMAP
painchance 256
bloodtype ""
+NOTARGETSWITCH
+DONTRIP
+GHOST
//+NOINTERACTION
+NORADIUSDMG
//+REFLECTIVE
States
{
Spawn:
TNT1 A 0
TNT1 A 2
stop
Death:
TNT1 A 0 //A_PlaySound("item/protoreflect")
TNT1 A 1
stop
Pain:
TNT1 A 0 A_SpawnItemEx("ProtoShieldDeahthFX")
TNT1 A 2 A_PlaySound("item/protoreflect")
stop
}
}

actor GammaHogale
{
Speed 4
Scale 4.5
+ACTIVATEMCROSS
+THRUACTORS
+MISSILE
+DONTREFLECT
+RIPPER
+NOGRAVITY
+DONTBLAST
+INVULNERABLE
States
{
Spawn:
HOGA A 0
HOGA A 1 ThrustThingZ(0, 200, 0, 1)
HOGA A 0 A_PlaySoundEx("misc/gutsgboost", "Voice", 0, 1)
HOGA AAAAABBBBBBCCCCCCBBBBBB 1 A_ScaleVelocity(0.8)
HOGA A 1 A_Stop
HOGA A 1 A_Recoil(-20)
Flying:
HOGA ABCBABCB 5
FlyDrop:
HOGA A 0 A_PlaySoundEx("misc/sharktorpedo", 0, 1, 1)
HOGA ABCBABCBABCBABCBABCBABCB 5 A_SpawnItemEx("GammaMet", 0, 0, -5, random(0, 12), 0, 0, random(0,360))
FlyingNormal:
HOGA ABCB 5
loop
}
}

actor GammaMet
{
//dropitem "WeaponEnergy"
-SOLID
+SHOOTABLE
+ISMONSTER
+NOBLOOD
Speed 8
Health 2
Height 32
Radius 32
species "Met"
+THRUSPECIES
obituary "%o was shot by a met."
scale 2.5
+INVULNERABLE
states
{
Spawn:
METT D 1
TFOG A 0 Thing_ChangeTID(0, 1207)
METT D 1 A_JumpIf(floorz!=z, "Spawn")
METT D 1 A_Stop
METT D 0 A_ChangeFlag("INVULNERABLE",0)
METT D 0 A_GiveInventory("GammaMetMetInvul",1)
Looking:
METT D 35
METT D 1 A_Jump(128, "Looking")
METT D 1 A_LookEx(0,0,0,0,360,"See")
loop
See:
METT D 45 A_FaceTarget
METT F 0 A_FaceTarget
METT E 5 A_TakeInventory("GammaMetMetInvul",1)
METT F 0 A_FaceTarget
METT F 0 A_JumpIfCloser(1000, "Shoot")
Goto Walk
Shoot:
METT F 0 //A_CustomMissile("GammaMetShot",0,0,25,0)
METT F 0 A_CustomMissile("GammaMetShot",0,0,0,0)
METT F 5 //A_CustomMissile("GammaMetShot",0,0,-25,0)
METT B 5
Walk:
METT AAABBBCCCBBB 1 A_Wander
METT A 0// A_Jump(80, "Close")
METT AAABBBCCCBBB 1 A_Wander
METT A 0 //A_Jump(80, "Close")
METT AAABBBCCCBBB 1 A_Wander
METT A 0 //A_Jump(80, "Close")
METT AAABBBCCCBBB 1 A_Wander
METT A 0 //A_Jump(80, "Close")
METT AAABBBCCCBBB 1 A_Wander
METT A 0 A_Jump(80, "Close")
METT AAABBBCCCBBB 1 A_Wander
METT A 0 A_Jump(80, "Close")
METT AAABBBCCCBBB 1 A_Wander
Close:
METT BE 5
METT D 5 A_GiveInventory("GammaMetMetInvul",1)
Goto Looking
Death:
TNT1 A 0 A_JumpIfInTargetInventory("SakugarneAmmo", 5, "Drop")
TNT1 A 0 A_GiveToTarget("SakugarneAmmo", 1)
DeathFX:
MMFX B 0 A_ChangeFlag("NOINTERACTION",1)
MMFX B 0 A_Fall
MMFX B 0 A_PlaySound("misc/metdie")
MMFX FGHI 3 A_Stop
stop
Death.GravityHold:
TNT1 A 0 A_JumpIfInTargetInventory("SakugarneAmmo", 5, "Drop.GravityHold")
TNT1 A 0 A_GiveToTarget("SakugarneAmmo", 1)
FlyUp:
MCAT V 1 A_ChangeFlag("NOGRAVITY",1)
MCAT V 0 A_Jump(128, "FlyUp")
MCAT VVVVVVVVVVVVVVVVVVVVVVVVVVVVVVV 1 ThrustThingZ(0, 15, 0, 1)
Goto DeathFX
Drop:
TNT1 A 0 A_TakeFromTarget("SakugarneAmmo", 99999)
TNT1 A 0 A_SpawnItemEx("SmallHealth", 0, 0, 5, 10, 0, 12)
TNT1 A 0 A_SpawnItemEx("WeaponEnergy", 0, 0, 5, -10, 0, 12)
Goto DeathFX
Drop.GravityHold:
TNT1 A 0 A_TakeFromTarget("SakugarneAmmo", 99999)
TNT1 A 0 A_SpawnItemEx("SmallHealth", 0, 0, 5, 10, 0, 12)
TNT1 A 0 A_SpawnItemEx("WeaponEnergy", 0, 0, 5, -10, 0, 12)
Goto FlyUp
}
}


actor GammaMetMetInvul : PowerProtection
{
powerup.duration -999
damagefactor "RainFlush", 1.0
damagefactor "OilSlider", 1.0
damagefactor "GravityHold", 1.0
damagefactor "StarCrash", 1.0
damagefactor "WaterWave", 1.0
damagefactor "BalladeCracker", 1.0
damagefactor "SearchSnake", 1.0
damagefactor "FireStorm", 1.0
damagefactor "TimeSlow", 1.0
damagefactor "TimeStopper", 1.0
damagefactor "CentaurFlash", 1.0
damagefactor "FlashStopper", 1.0
damagefactor "LeafShield", 1.0
damagefactor "Normal", 0.0
}


actor GammaMetShot : MetShot
{
speed 20
height 32
radius 32
species "Met"
+THRUSPECIES
damagetype "Gamma"
damage (5)
+FORCEXYBILLBOARD
}

actor GammaDamagedFXSpawner
{
-SOLID
+NOINTERACTION
renderstyle none
states
{
Spawn:
PLAY A 3 A_SpawnItemEx("GammaDamagedFX", random(0, 100), 0, 1400, 0,0,20,random(0,360))
loop
}
}

actor GammaDamagedFX
{
+NOINTERACTION
+NOGRAVITY
+CLIENTSIDEONLY
+MISSILE
scale 2.5
renderstyle translucent
alpha 0.8
States
{
	Spawn:
	POOF A 0 A_Jump(256, "Smoke1", "Smoke2")
	Smoke1:
	POOF A 1 A_FadeOut(0.05)
	POOF A 1 A_SetScale(scaleX + 0.1, scaleY + 0.1)
	loop
	Smoke2:
	POOF B 1 A_FadeOut(0.1)
	POOF B 1 A_SetScale(scaleX + 0.1, scaleY + 0.1)
	loop
}
}

actor GammaLightningStart1
{
scale 3.5
+THRUACTORS
PROJECTILE
+RIPPER
+SEEINVISIBLE
obituary "%o's circuits were fried by \cfGamma\c*."
states
{
Spawn:
GAMF I 0 A_SpawnItemEx("GammaLightningFX", 0, 0, 256, 50, 0, 0, 0)
GAMF I 0 A_SpawnItemEx("GammaLightningFX", 0, 0, 256, 50, 0, 0, 20)
GAMF I 0 A_SpawnItemEx("GammaLightningFX", 0, 0, 256, 50, 0, 0, 40)
GAMF I 0 A_SpawnItemEx("GammaLightningFX", 0, 0, 256, 50, 0, 0, 60)
GAMF I 0 A_SpawnItemEx("GammaLightningFX", 0, 0, 256, 50, 0, 0, 80)
GAMF I 0 A_SpawnItemEx("GammaLightningFX", 0, 0, 256, 50, 0, 0, 100)
GAMF I 0 A_SpawnItemEx("GammaLightningFX", 0, 0, 256, 50, 0, 0, 120)
GAMF I 0 A_SpawnItemEx("GammaLightningFX", 0, 0, 256, 50, 0, 0, 140)
GAMF I 0 A_SpawnItemEx("GammaLightningFX", 0, 0, 256, 50, 0, 0, 160)
GAMF I 0 A_SpawnItemEx("GammaLightningFX", 0, 0, 256, 50, 0, 0, 180)
GAMF I 0 A_SpawnItemEx("GammaLightningFX", 0, 0, 256, 50, 0, 0, 20)
GAMF I 0 A_SpawnItemEx("GammaLightningFX", 0, 0, 256, 50, 0, 0, 220)
GAMF I 0 A_SpawnItemEx("GammaLightningFX", 0, 0, 256, 50, 0, 0, 240)
GAMF I 0 A_SpawnItemEx("GammaLightningFX", 0, 0, 256, 50, 0, 0, 260)
GAMF I 0 A_SpawnItemEx("GammaLightningFX", 0, 0, 256, 50, 0, 0, 280)
GAMF I 0 A_SpawnItemEx("GammaLightningFX", 0, 0, 256, 50, 0, 0, 300)
GAMF I 0 A_SpawnItemEx("GammaLightningFX", 0, 0, 256, 50, 0, 0, 320)
GAMF I 0 A_SpawnItemEx("GammaLightningFX", 0, 0, 256, 50, 0, 0, 340)
GAMF I 0 A_Jump(256, "Falling")
Falling:
GAMF IJ 3
loop
Death:
GAMF I 0 A_SpawnItemEx("GammaLightningSpiral1", 0,0,0)
stop
}
}

actor GammaLightningStart2 : GammaLightningStart1
{
states
{
Falling:
GAMF IJ 3
loop
Death:
GAMF I 0 A_SpawnItemEx("GammaLightningSpiral2", 0,0,0)
stop
}
}

actor GammaLightningStart3 : GammaLightningStart1
{
states
{
Falling:
GAMF IJ 3
loop
Death:
GAMF I 0 A_SpawnItemEx("GammaLightningSpiral3", 0,0,0)
stop
}
}

actor GammaLightningFX
{
scale 1.5
+THRUACTORS
PROJECTILE
+RIPPER
renderstyle translucent
+NOINTERACTION
+FORCEYBILLBOARD
states
{
Spawn:
GAMF IIJJ 1 A_FadeOut(0.05)
loop
}
}

actor GammaLightningSpiral1
{
obituary "%o's circuits were fried by \cfGamma\c*."
scale 3.5
PROJECTILE
+RIPPER
+NOINTERACTION
+FORCEYBILLBOARD
+SEEINVISIBLE
var int user_speed; 
states
{
Spawn:
GAMF I 0
GAMF G 0 Thing_ChangeTID(0, 400)
GAMF I 0 A_RearrangePointers(0, AAPTR_TARGET)
GAMF I 0 A_ClearTarget
GAMF I 0 A_SetUserVar("user_speed", 5)
GAMF I 0 A_SpawnItemEx("GammaLightningSpiral1Part", 0, 0, 0, 20, 0, 0, 0)
GAMF I 0 A_SpawnItemEx("GammaLightningSpiral1Part", 0, 0, 0, 20, 0, 0, 90) 
GAMF I 0 A_SpawnItemEx("GammaLightningSpiral1Part", 0, 0, 0, 20, 0, 0, -90) 
GAMF I 0 A_SpawnItemEx("GammaLightningSpiral1Part", 0, 0, 0, 20, 0, 0, 180) 
GAMF IIII 1 A_LookEx(0, 0, 0, 0, 360, "See")
stop
See:
GAMF I 1 A_RearrangePointers(AAPTR_MASTER, 0, AAPTR_TARGET)
GAMF I 0 A_FaceTracer
GAMF IIJJJIIIJJJIIIJJJ 1
Moving:
GAMF I 0 A_TakeInventory("CutterFlag", 1000)
GAMF I 0 A_FaceTracer
GAMF I 0 A_ChangeVelocity(user_speed, 0, 0, CVF_RELATIVE|CVF_REPLACE)
GAMF I 0 A_JumpIfTracerCloser(256, "LoseTrack")
GAMF IIIJJJ 1 //A_SetAngle(angle+0.1)
GAMF I 0 A_SetUserVar("user_speed", user_speed + 1)
loop
LoseTrack:
GAMF I 0 A_SetUserVar("user_speed", 10)
GAMF IIIJJJIIIJJJIIIJJJIIIJJJ 1 //A_FaceTracer(5)
GAMF I 0 A_ChangeVelocity(user_speed, 0, 0, CVF_RELATIVE|CVF_REPLACE)
loop
ReTracking:
GAMF I 0 A_JumpIfInventory("CutterFlag", 15, "Moving")
GAMF IIIJJJ 1 A_FaceTracer(2)
GAMF I 0 A_ChangeVelocity(user_speed, 0, 0, CVF_RELATIVE|CVF_REPLACE)
GAMF I 0 A_GiveInventory("CutterFlag", 1)
loop
}
}

actor GammaLightningSpiral2 : GammaLightningSpiral1
{
scale 3.5
PROJECTILE
+RIPPER
+NOINTERACTION
+FORCEYBILLBOARD
states
{
Spawn:
GAMF I 0
GAMF G 0 Thing_ChangeTID(0, 400)
GAMF I 0 A_RearrangePointers(0, AAPTR_TARGET)
GAMF I 0 A_ClearTarget
GAMF I 0 A_SetUserVar("user_speed", 5)
GAMF I 0 //A_SpawnItemEx("GammaLightningSpiral1Part", 0, 0, 0, 20, 0, 0, 0)
GAMF I 0 //A_SpawnItemEx("GammaLightningSpiral1Part", 0, 0, 0, 20, 0, 0, 90) 
GAMF I 0 //A_SpawnItemEx("GammaLightningSpiral1Part", 0, 0, 0, 20, 0, 0, -90) 
GAMF I 0 //A_SpawnItemEx("GammaLightningSpiral1Part", 0, 0, 0, 20, 0, 0, 180)
GAMF I 0 A_SpawnItemEx("GammaLightningSpiral2Part", 0, 0, 0, 35, 0, 0, 0)
GAMF I 0 A_SpawnItemEx("GammaLightningSpiral2Part", 0, 0, 0, 35, 0, 0, 90) 
GAMF I 0 A_SpawnItemEx("GammaLightningSpiral2Part", 0, 0, 0, 35, 0, 0, -90) 
GAMF I 0 A_SpawnItemEx("GammaLightningSpiral2Part", 0, 0, 0, 35, 0, 0, 180)  
GAMF I 0 A_SpawnItemEx("GammaLightningSpiral2Part", 0, 0, 0, 35, 0, 0, 0 + 45)
GAMF I 0 A_SpawnItemEx("GammaLightningSpiral2Part", 0, 0, 0, 35, 0, 0, 90 + 45) 
GAMF I 0 A_SpawnItemEx("GammaLightningSpiral2Part", 0, 0, 0, 35, 0, 0, -90 + 45) 
GAMF I 0 A_SpawnItemEx("GammaLightningSpiral2Part", 0, 0, 0, 35, 0, 0, 180 + 45) 
GAMF IIII 1 A_LookEx(0, 0, 0, 0, 360, "See")
stop
}
}

actor GammaLightningSpiral3 : GammaLightningSpiral1
{
scale 3.5
PROJECTILE
+RIPPER
+NOINTERACTION
+FORCEYBILLBOARD
states
{
Spawn:
GAMF I 0
GAMF G 0 Thing_ChangeTID(0, 400)
GAMF I 0 A_RearrangePointers(0, AAPTR_TARGET)
GAMF I 0 A_ClearTarget
GAMF I 0 A_SetUserVar("user_speed", 5)
GAMF I 0 A_SpawnItemEx("GammaLightningSpiral1Part", 0, 0, 0, 20, 0, 0, 0)
GAMF I 0 A_SpawnItemEx("GammaLightningSpiral1Part", 0, 0, 0, 20, 0, 0, 90) 
GAMF I 0 A_SpawnItemEx("GammaLightningSpiral1Part", 0, 0, 0, 20, 0, 0, -90) 
GAMF I 0 A_SpawnItemEx("GammaLightningSpiral1Part", 0, 0, 0, 20, 0, 0, 180)
GAMF I 0 A_SpawnItemEx("GammaLightningSpiral2Part", 0, 0, 0, 35, 0, 0, 0)
GAMF I 0 A_SpawnItemEx("GammaLightningSpiral2Part", 0, 0, 0, 35, 0, 0, 90) 
GAMF I 0 A_SpawnItemEx("GammaLightningSpiral2Part", 0, 0, 0, 35, 0, 0, -90) 
GAMF I 0 A_SpawnItemEx("GammaLightningSpiral2Part", 0, 0, 0, 35, 0, 0, 180)  
GAMF I 0 A_SpawnItemEx("GammaLightningSpiral2Part", 0, 0, 0, 35, 0, 0, 0 + 45)
GAMF I 0 A_SpawnItemEx("GammaLightningSpiral2Part", 0, 0, 0, 35, 0, 0, 90 + 45) 
GAMF I 0 A_SpawnItemEx("GammaLightningSpiral2Part", 0, 0, 0, 35, 0, 0, -90 + 45) 
GAMF I 0 A_SpawnItemEx("GammaLightningSpiral2Part", 0, 0, 0, 35, 0, 0, 180 + 45) 
GAMF IIII 1 A_LookEx(0, 0, 0, 0, 360, "See")
stop
}
}


actor GammaLightningSpiral1Part
{
obituary "%o's circuits were fried by \cfGamma\c*."
scale 3.5
PROJECTILE
+NOINTERACTION
+FORCEYBILLBOARD
+RIPPER
states
{
Spawn:
GAMF G 0 
GAMF G 0 Thing_ChangeTID(0, 400)
GAMF GHGHGH 3
GAMF G 0 A_Stop
Moving:
GAMF G 0 A_SpawnItemEX("GammaLightningDamager", 0, 0, 0, 0, 0, 0, 0, 0)
GAMF G 0 A_SetAngle(angle+3.5)
GAMF I 0 A_SpawnItemEx("GammaSparkFX", 0, 0, 0, 15, 0, 5, random(0,360))
GAMF G 1 A_Warp(AAPTR_TARGET, 300, 0, 0, 0, WARPF_NOCHECKPOSITION|WARPF_USECALLERANGLE|WARPF_COPYINTERPOLATION)
GAMF G 0 A_SetAngle(angle+3.5)
GAMF I 0 A_SpawnItemEx("GammaSparkFX", 0, 0, 0, 15, 0, 5, random(0,360))
GAMF G 1 A_Warp(AAPTR_TARGET, 300, 0, 0, 0, WARPF_NOCHECKPOSITION|WARPF_USECALLERANGLE|WARPF_COPYINTERPOLATION)
GAMF G 0 A_SetAngle(angle+3.5)
GAMF I 0 A_SpawnItemEx("GammaSparkFX", 0, 0, 0, 15, 0, 5, random(0,360))
GAMF G 1 A_Warp(AAPTR_TARGET, 300, 0, 0, 0, WARPF_NOCHECKPOSITION|WARPF_USECALLERANGLE|WARPF_COPYINTERPOLATION)
GAMF G 0 A_SpawnItemEX("GammaLightningDamager", 0, 0, 0, 0, 0, 0, 0, 0)
GAMF G 0 A_SetAngle(angle+3.5)
GAMF I 0 A_SpawnItemEx("GammaSparkFX", 0, 0, 0, 15, 0, 5, random(0,360))
GAMF H 1 A_Warp(AAPTR_TARGET, 300, 0, 0, 0, WARPF_NOCHECKPOSITION|WARPF_USECALLERANGLE|WARPF_COPYINTERPOLATION)
GAMF G 0 A_SetAngle(angle+3.5)
GAMF I 0 A_SpawnItemEx("GammaSparkFX", 0, 0, 0, 15, 0, 5, random(0,360))
GAMF H 1 A_Warp(AAPTR_TARGET, 300, 0, 0, 0, WARPF_NOCHECKPOSITION|WARPF_USECALLERANGLE|WARPF_COPYINTERPOLATION)
GAMF G 0 A_SetAngle(angle+3.5)
GAMF I 0 A_SpawnItemEx("GammaSparkFX", 0, 0, 0, 15, 0, 5, random(0,360))
GAMF H 1 A_Warp(AAPTR_TARGET, 300, 0, 0, 0, WARPF_NOCHECKPOSITION|WARPF_USECALLERANGLE|WARPF_COPYINTERPOLATION)
loop
}
}

actor GammaLightningSpiral2Part
{
obituary "%o's circuits were fried by \cfGamma\c*."
scale 3.5
PROJECTILE
+NOINTERACTION
+RIPPER
+FORCEYBILLBOARD
states
{
Spawn:
GAMF G 0
GAMF G 0 Thing_ChangeTID(0, 400)
GAMF GHGHGH 3
GAMF G 0 A_Stop
Moving:
GAMF G 0 A_SpawnItemEX("GammaLightningDamager", 0, 0, 0, 0, 0, 0, 0, 0)
GAMF G 0 A_SetAngle(angle+1.75)
GAMF I 0 A_SpawnItemEx("GammaSparkFX", 0, 0, 0, 15, 0, 5, random(0,360))
GAMF G 1 A_Warp(AAPTR_TARGET, 650, 0, 0, 0, WARPF_NOCHECKPOSITION|WARPF_USECALLERANGLE|WARPF_COPYINTERPOLATION)
GAMF G 0 A_SetAngle(angle+1.75)
GAMF I 0 A_SpawnItemEx("GammaSparkFX", 0, 0, 0, 15, 0, 5, random(0,360))
GAMF G 1 A_Warp(AAPTR_TARGET, 650, 0, 0, 0, WARPF_NOCHECKPOSITION|WARPF_USECALLERANGLE|WARPF_COPYINTERPOLATION)
GAMF G 0 A_SetAngle(angle+1.75)
GAMF I 0 A_SpawnItemEx("GammaSparkFX", 0, 0, 0, 15, 0, 5, random(0,360))
GAMF G 1 A_Warp(AAPTR_TARGET, 650, 0, 0, 0, WARPF_NOCHECKPOSITION|WARPF_USECALLERANGLE|WARPF_COPYINTERPOLATION)
GAMF G 0 A_SpawnItemEX("GammaLightningDamager", 0, 0, 0, 0, 0, 0, 0, 0)
GAMF G 0 A_SetAngle(angle+1.75)
GAMF I 0 A_SpawnItemEx("GammaSparkFX", 0, 0, 0, 15, 0, 5, random(0,360))
GAMF H 1 A_Warp(AAPTR_TARGET, 650, 0, 0, 0, WARPF_NOCHECKPOSITION|WARPF_USECALLERANGLE|WARPF_COPYINTERPOLATION)
GAMF G 0 A_SetAngle(angle+1.75)
GAMF I 0 A_SpawnItemEx("GammaSparkFX", 0, 0, 0, 15, 0, 5, random(0,360))
GAMF H 1 A_Warp(AAPTR_TARGET, 650, 0, 0, 0, WARPF_NOCHECKPOSITION|WARPF_USECALLERANGLE|WARPF_COPYINTERPOLATION)
GAMF G 0 A_SetAngle(angle+1.75)
GAMF I 0 A_SpawnItemEx("GammaSparkFX", 0, 0, 0, 15, 0, 5, random(0,360))
GAMF H 1 A_Warp(AAPTR_TARGET, 650, 0, 0, 0, WARPF_NOCHECKPOSITION|WARPF_USECALLERANGLE|WARPF_COPYINTERPOLATION)
loop
}
}

actor GammaLightningDamager
{
DamageType "Gamma"
PROJECTILE
+NOINTERACTION
renderstyle none
obituary "%o's circuits were fried by \cfGamma\c*."
states
{
Spawn:
TNT1 A 0
TNT1 A 0 ACS_ExecuteAlways(59, 0, 500)
PLAY A 1 A_Explode(12, 64, 0, 0, 12)
stop
}
}

actor GammaSparkFX
{
renderstyle translucent
+MISSILE
height 1
radius 1
+NOGRAVITY
states
{
Spawn:
GAMA LLLMMMLLLMMMLLLMMM 1 A_SetScale(scalex - 0.05, scaley - 0.05)
stop
}
}

actor GammaFireBreathFX
{
Scale 2.5
renderstyle translucent
+NOINTERACTION
+NOGRAVITY
height 1
radius 1
-SOLID
states
{
Spawn:
FIRE D 1 A_FadeOut(0.05)
FIRE D 1 ThrustThingZ(0, 5, 0, 1)
loop
}
}

actor GammaEyeLocation
{
+NOINTERACTION
height 1
radius 1
scale 2.5
renderstyle none
states
{
Spawn:
PLAY A 0
PLAY A 0 A_SpawnItemEx("GammaEyeFX")
PLAY A 0 Thing_ChangeTID(0, 502)
PLAY A 1
loop
}
}

actor GammaEyeFX
{
scale 5.0
renderstyle translucent
translation "9:191=192:192", "192:254=192:192"
+NOINTERACTION
-SOLID
+NOGRAVITY
height 1
radius 1
states
{
Spawn:
FCRA B 1 A_SetScale(scalex + 1.0, scaley)
FCRA B 0 A_FadeOut(0.1)
loop
}
}

actor GammaFireWaver1
{
+MISSILE
+RIPPER
+NOGRAVITY
+NOBLOCKMAP
+THRUSPECIES
species "Gamma"
Radius 1
Height 64
damage (0)
scale 2.5
states
{
Spawn:
GAMA U 0 A_PlaySoundEx("weapon/atomicfire", "Voice", 0, 0)
GAMA UUUU 1 A_Weave(1, 0, 25, 0)
GAMA U 0 A_PlaySoundEx("weapon/atomicfire", "Voice", 0, 0)
GAMA U 0 A_spawnItemEx("GammaFireWallPart")
GAMA VVVV 1 A_Weave(1, 0, 25, 0)
GAMA U 0 A_PlaySoundEx("weapon/atomicfire", "Voice", 0, 0)
GAMA U 0 A_spawnItemEx("GammaFireWallPart")
GAMA WWWW 1 A_Weave(1, 0, 25, 0)
GAMA U 0 A_PlaySoundEx("weapon/atomicfire", "Voice", 0, 0)
GAMA U 0 A_spawnItemEx("GammaFireWallPart")
loop
}
}

actor GammaFireSplitter1
{
-SOLID
+MISSILE
+THRUSPECIES
species "Gamma"
scale 4.0
States
{
Spawn:
GAMA VVVVV 0 A_SpawnItemEx("GammaFireBreathFX",0,0,0,random(-20, 20), 0, random(-20, 20), random(0,360))
GAMA V 1
loop
Death:
TNT1 A 0 A_SpawnItemEx("GammaFireWallPart", 0, 0, 0, 0, 0, 0, 0)
TNT1 A 0 A_SpawnItemEx("GammaFireWallPart", 0, 64, 0, 0, 0, 0, 0)
TNT1 A 0 A_SpawnItemEx("GammaFireWallPart", 0, -64, 0, 0, 0, 0, 0)
TNT1 A 0 A_SpawnItemEx("GammaFireWallPart", 0, 128, 0, 0, 0, 0, 0)
TNT1 A 0 A_SpawnItemEx("GammaFireWallPart", 0, -128, 0, 0, 0, 0, 0)
TNT1 A 0 A_SpawnItemEx("GammaFireWallPart", 0, 128 + 64, 0, 0, 0, 0, 0)
TNT1 A 0 A_SpawnItemEx("GammaFireWallPart", 0, -128 - 64, 0, 0, 0, 0, 0)
TNT1 A 0 A_SpawnItemEx("GammaFireWall", 0, 256, 0, 50, 0, 0, 0)
TNT1 A 20 A_SpawnItemEx("GammaFireWall", 0, -256, 0, 50, 0, 0, 0)
TNT1 A 0 A_SpawnItemEx("GammaFireWaver1", 0, 0, 0, 12, 0, 0, 0)
stop
}
}


actor GammaFireWaver2
{
+MISSILE
+RIPPER
+NOGRAVITY
+NOBLOCKMAP
+THRUSPECIES
species "Gamma"
scale 2.5
Radius 1
Height 64
damage (0)
states
{
Spawn:
GAMA U 0 A_PlaySoundEx("weapon/atomicfire", "Voice", 0, 0)
GAMA UUUU 1 A_Weave(1, 0, 20, 0)
GAMA U 0 A_spawnItemEx("GammaFireWallPart")
GAMA U 0 A_PlaySoundEx("weapon/atomicfire", "Voice", 0, 0)
GAMA VVVV 1 A_Weave(1, 0, 20, 0)
GAMA U 0 A_spawnItemEx("GammaFireWallPart")
GAMA U 0 A_PlaySoundEx("weapon/atomicfire", "Voice", 0, 0)
GAMA WWWW 1 A_Weave(1, 0, 20, 0)
GAMA U 0 A_spawnItemEx("GammaFireWallPart")
loop
}
}

actor GammaFireSplitter2
{
-SOLID
+MISSILE
+THRUSPECIES
species "Gamma"
scale 4.0
States
{
Spawn:
GAMA VVVVV 0 A_SpawnItemEx("GammaFireBreathFX",0,0,0,random(-20, 20), 0, random(-20, 20), random(0,360))
GAMA V 1
loop
Death:
TNT1 A 0 A_SpawnItemEx("GammaFireWallPart", 0, 0, 0, 0, 0, 0, 0)
TNT1 A 0 A_SpawnItemEx("GammaFireWallPart", 0, 64, 0, 0, 0, 0, 0)
TNT1 A 0 A_SpawnItemEx("GammaFireWallPart", 0, -64, 0, 0, 0, 0, 0)
TNT1 A 0 A_SpawnItemEx("GammaFireWallPart", 0, 128, 0, 0, 0, 0, 0)
TNT1 A 0 A_SpawnItemEx("GammaFireWallPart", 0, -128, 0, 0, 0, 0, 0)
TNT1 A 0 A_SpawnItemEx("GammaFireWall", 0, 192, 0, 50, 0, 0, 0)
TNT1 A 20 A_SpawnItemEx("GammaFireWall", 0, -192, 0, 50, 0, 0, 0)
TNT1 A 0 A_SpawnItemEx("GammaFireWaver2", 0, 0, 0, 10, 0, 0, 0)
stop
}
}


actor GammaFireWaver3
{
+MISSILE
+RIPPER
+NOGRAVITY
+THRUSPECIES
+NOBLOCKMAP
scale 2.5
species "Gamma"
Radius 1
Height 64
damage (0)
states
{
Spawn:
GAMA U 0 A_PlaySoundEx("weapon/atomicfire", "Voice", 0, 0)
GAMA UUUU 1 A_Weave(2, 0, 12, 0)
GAMA U 0 A_spawnItemEx("GammaFireWallPart")
GAMA U 0 A_PlaySoundEx("weapon/atomicfire", "Voice", 0, 0)
GAMA VVVV 1 A_Weave(2, 0, 12, 0)
GAMA U 0 A_spawnItemEx("GammaFireWallPart")
GAMA U 0 A_PlaySoundEx("weapon/atomicfire", "Voice", 0, 0)
GAMA WWWW 1 A_Weave(2, 0, 12, 0)
GAMA U 0 A_spawnItemEx("GammaFireWallPart")
loop
}
}

actor GammaFireSplitter3
{
-SOLID
+MISSILE
+THRUSPECIES
species "Gamma"
scale 4.0
States
{
Spawn:
GAMA VVVVV 0 A_SpawnItemEx("GammaFireBreathFX",0,0,0,random(-20, 20), 0, random(-20, 20), random(0,360))
GAMA V 1
loop
Death:
TNT1 A 0 A_SpawnItemEx("GammaFireWallPart", 0, 0, 0, 0, 0, 0, 0)
TNT1 A 0 A_SpawnItemEx("GammaFireWallPart", 0, 64, 0, 0, 0, 0, 0)
TNT1 A 0 A_SpawnItemEx("GammaFireWallPart", 0, -64, 0, 0, 0, 0, 0)
TNT1 A 0 A_SpawnItemEx("GammaFireWallPart", 0, 128, 0, 0, 0, 0, 0)
TNT1 A 0 A_SpawnItemEx("GammaFireWallPart", 0, -128, 0, 0, 0, 0, 0)
TNT1 A 0 A_SpawnItemEx("GammaFireWall", 0, 128, 0, 50, 0, 0, 0)
TNT1 A 20 A_SpawnItemEx("GammaFireWall", 0, -128, 0, 50, 0, 0, 0)
TNT1 A 0 A_SpawnItemEx("GammaFireWaver3", 0, 0, 0, 12, 0, 0, 0)
stop
}
}

actor GammaFireWall 
{
+MISSILE
+THRUACTORS
+NOGRAVITY
+THRUSPECIES
obituary "%o was cremated by \cfGamma\c*."
species "Gamma"
scale 2.5
states
{
Spawn:
GAMA UUUVVVWWW 1 A_SpawnItemEx("GammaFireWallPartBlocker")
loop
Death:
GAMA U 0 SetPlayerProperty(1,0,0)
stop
}
}

actor GammaFireWallPart
{
+MISSILE
+THRUACTORS
+FLOORHUGGER
+NOGRAVITY
+THRUSPECIES
species "Gamma"
obituary "%o was cremated by \cfGamma\c*."
scale 2.5
damagetype "Gamma"
reactiontime 15
states
{
Spawn:
GAMF A 0
GAMF A 0 A_PlaySoundEx("weapon/pharaoh2", 0)
GAMF ABC 4 A_Explode(5, 38, 0, 0, 5)
Firey:
GAMF D 0 A_CountDown
GAMF DEF 4 A_Explode(5, 38, 0, 0, 5)
loop
Death:
GAMF CBA 4 A_Explode(5, 38, 0, 0, 5)
stop
}
}

actor GammaFireWallPartBlocker : GammaFireWallPart
{
+SOLID
+THRUSPECIES
species "Gamma"
-THRUACTORS
Height 128
Radius 18
}

actor GammaLaserShooter
{
obituary "%o was vaporized by \cfGamma\c*."
+NOINTERACTION
+MISSILE
+FLOORHUGGER
-SOLID
speed 20
renderstyle none
states
{
	Spawn:
	PLAY A 0
	PLAY A 0 //A_ChangeVelocity(20.0, 0.0, 0.0, CVF_RELATIVE|CVF_REPLACE)
	PLAY A 2 ACS_ExecuteAlways(18,0)
	Bzzt:
	PLAY A 0 A_PlaySoundEx("weapon/magmacharge2", "Voice", 0, 0) 
	PLAY A 0 A_SpawnItemEx("GammaLaserExplosion")
	PLAY A 0 A_SpawnItemEx("GammaLaserShooterFX", 0, 0, 0, 0, 0, 20)
	PLAY A 1 A_CustomMissile("GammaLaserFX", 0, 0, 0, 0)
	PLAY A 0 A_SpawnItemEx("GammaLaserShooterFX", 0, 0, 0, 0, 0, 20)
	PLAY A 1 A_CustomMissile("GammaLaserFX", 0, 0, 0, 0)
	PLAY A 0 A_SpawnItemEx("GammaLaserShooterFX", 0, 0, 0, 0, 0, 20)
	PLAY A 1 A_CustomMissile("GammaLaserFX", 0, 0, 0, 0)
	PLAY A 0 A_SpawnItemEx("GammaLaserShooterFX", 0, 0, 0, 0, 0, 20)
	PLAY A 1 A_CustomMissile("GammaLaserFX", 0, 0, 0, 0)
	PLAY A 0 A_GiveInventory("CutterFlag",1)
	PLAY A 0 A_JumpIfInventory("CutterFlag", 10, "End")
	loop
	End:
	PLAY A 0 A_Quake(9, 13, 0, 5000, 0)
	PLAY A 0 A_PlaySoundEx("weapon/coilexplode", "Voice", 0, 1) 
	PLAY A 5 A_GiveToTarget("AtomicFireAmmo", 1)
	PLAY A 0 A_PlaySoundEx("weapon/coilexplode", "Voice", 0, 1) 
	PLAY A 15 A_TakeFromTarget("AtomicFireAmmo", 999)
	stop
}
}

actor GammaLaserPortal
{
obituary "%o was vaporized by \cfGamma\c*."
+NOGRAVITY
+NOINTERACTION
-SOLID
scale 1.0
translation "236:239=192:195"
states
{
	Spawn:
	QBOP KLM 2 bright// A_SpawnItemEx("TimePortalFXSpawner",256,0,random(-128,128),0,0,0,random(0,360))
	loop
}
}

actor GammaLaserMarker
{
obituary "%o was vaporized by \cfGamma\c*."
-SOLID
+NOINTERACTION
states
{
	Spawn:
	TNT1 A 0
	TNT1 A 0 A_SpawnItemEx("GammaLaserShooter", -1024, 0, 0, 40, 0, 0, 0)
	stop
}
}

actor GammaLaserExplosion
{
-SOLID
+MISSILE
+NOINTERACTION
scale 2.5
obituary "%o was vaporized by \cfGamma\c*."
states
{
Spawn:
MMFX B 0
MMFX B 0 A_Jump(256, 0, 1, 2, 3)
MMFX BCDE 2 A_JumpIfInTargetInventory("AtomicFireAmmo", 1, "Death")
loop
Death:
CRAS B 0 A_SpawnItemEx("GammaLaserExplosionFX", 0, 0, 0, 0, 0, 5 + random(-1,1))
CRAS B 0 A_SpawnItemEx("GammaLaserExplosionFX", 0, 0, 0, 0, 0, 10+ random(-1,1))
CRAS B 0 A_SpawnItemEx("GammaLaserExplosionFX", 0, 0, 0, 0, 0, 15+ random(-1,1))
CRAS B 0 A_SpawnItemEx("GammaLaserExplosionFX", 0, 0, 0, 0, 0, 20+ random(-1,1))
CRAS B 0 A_SpawnItemEx("GammaLaserExplosionFX", 0, 0, 0, 0, 0, 25+ random(-1,1))
CRAS B 0 A_SpawnItemEx("GammaLaserExplosionFX", 0, 0, 0, 0, 0, 30+ random(-1,1))
CRAS B 0 A_SpawnItemEx("GammaLaserExplosionFX", 0, 0, 0, 0, 0, 35+ random(-1,1))
CRAS B 0 A_Explode(25,128,0,0,15)
stop
}
}

actor GammaLaserExplosionFX
{
+MISSILE
-SOLID
+THRUACTORS
//+NOINTERACTION
scale 2.5
states
{
Spawn:
ASEX ABCDEF 4
stop
}
}

actor GammaLaserFX
{
scale 2.5
+MISSILE
species "Gamma"
+FORCEXYBILLBOARD
+THRUSPECIES
+NOGRAVITY
+NOINTERACTION
Speed 20
States
{
Spawn:
TNT1 A 0
TNT1 A 0 A_JumpIf(z>1500, "Death")
CHBU E 1 A_SpawnItemEx("GammaLaserFX",0,0,0,momx,momy,momz,0,SXF_ABSOLUTEMOMENTUM|SXF_NOCHECKPOSITION)
stop
Death:
TNT1 A 0
stop
}
}

actor GammaLaserShooterFX
{
+MISSILE
-SOLID
+NOINTERACTION
scale 2.5
states
{
Spawn:
MMFX BCDE 2
stop
}
}

actor GammaLitFx
{
+NOINTERACTION
scale 2.5
-SOLID
+DONTBLAST
+NOGRAVITY
States
{
Spawn:
GAMA HIHIHIHIHI 2
stop
}
}

actor GammaHitbox
{
obituary "%o was vaporized by \cfGamma\c*."
scale 5.5
+INVULNERABLE
+NOGRAVITY
MONSTER
-SOLID
+THRUSPECIES
+DONTRIP
species "Gamma"
mass 9999
Health 1000
height 128
radius 128
renderstyle none
painchance 256
damagefactor "normal", 1.0
damagefactor "HardKnuckle", 1.1
damagefactor "NeedleCannon", 0.3
damagefactor "CrystalEye", 1.3
damagefactor "DrillBomb", 3.0
damagefactor "PharoahShot2", 1.5
damagefactor "PharoahShot3", 1.5
damagefactor "AtomicFire3", 3.0
damagefactor "Buster", 0.3
damagefactor "Gamma", 0.0
damagefactor "MegaBall", 500.0
	states
	{
	Spawn:
	PLAY A 1
	loop
	Start:
	PLAY F 10 A_ChangeFlag("INVULNERABLE", 0)
	Goto Spawn
	Pain:
	PLAY H 0 A_FaceTarget
	PLAY H 5 A_SpawnItemEx("PainFXBig", 50,0,10)
	Goto Spawn
	Death:
	PLAY H 1 Thing_ChangeTID(0, 501)
	loop
	}
}

actor GammaHitbox2 : GammaHitbox
{
damagefactor "normal", 0.0
damagefactor "HardKnuckle", 0.0
damagefactor "NeedleCannon", 0.0
damagefactor "CrystalEye", 0.0
damagefactor "DrillBomb", 0.0
damagefactor "PharoahShot2", 0.0
damagefactor "PharoahShot3", 0.0
damagefactor "AtomicFire3", 0.0
damagefactor "Buster", 0.0
damagefactor "Gamma", 0.0
damagefactor "MegaBall", 0
damagefactor "ProtoMan", 999.0
-INVULNERABLE
//renderstyle "Normal"
states
{
	Death:
	PLAY H 1// Thing_ChangeTID(0, 501)
	stop
}
}


actor GammaProtomanAlly
{
//$Category MM8BDM-Bosses
Height 46
Radius 16
Scale 2.5
Translation "192:192=87:87", "198:198=42:42"
+INVULNERABLE
Health 9999
mass 99999999
Speed 7
Damage 0
MONSTER
+THRUSPECIES
floatspeed 0
-COUNTKILL
-SOLID
-CANPASS
+NOBLOOD
+LOOKALLAROUND
+SLIDESONWALLS
-DROPOFF
-SHOOTABLE
states
{
	Spawn:
	TFOG A 0 A_ChangeVelocity(0,0,-13,CVF_RELATIVE|CVF_REPLACE)
	TFOG A 1 A_Jumpif(floorz==z, "Land")
	loop
	Land:
	TFOG A 0 A_PlaySoundEx("misc/teleportin", "Voice", 0, 0)
	TFOG CCAAABBB 1
	SpawnMissile:
	PROM M 1 Thing_SetTranslation(0,CLR_PROTOBUSTER)
    PROM M 1 Thing_SetTranslation(0,CLR_PROTOCHARGE1)
    PROM M 1 Thing_SetTranslation(0,CLR_PROTOBUSTER)
    PROM M 1 Thing_SetTranslation(0,CLR_PROTOCHARGE2)
	loop
	Spawn2:
	PROM AK 10
	loop
	
	Wire:
	PROM Q 10 A_SpawnItemEx("InfiniteWireAdaptor", 0, 0, 32, 16.5, 0, 3, -3.5)
	PROM L 10
	Goto Spawn2
	
	Missile:
	PROM A 0 A_FaceTarget
	PROM A 0 A_PlaySoundEx("weapon/pshot", "Voice", 0, 1)
	PROM A 0 Thing_SetTranslation(0,0)
	PROM M 16 A_CustomMissile("GammaProtoShotAlly", 32,0,0)//A_SpawnItemEx("ProtoShotAlly", 0, 0, 32, 50, 0, 0, 0)
	PROM L 12 A_ChangeFlag("NOPAIN", 0)
	Goto Spawn2
	
	Leave:
	TFOG A 0 A_Stop
	PROM N 0 A_GiveInventory("StopShield",1)
	TFOG A 0 A_PlaySoundEx("misc/teleportout", "Voice", 0, 1)
	TFOG A 0 A_ChangeFlag("NOINTERACTION", 1)
	TFOG B 0 A_ChangeFlag("NOGRAVITY",1)
	TFOG BBBAAACCC 1
	TFOG A 65 A_ChangeVelocity(0,0,13,CVF_RELATIVE|CVF_REPLACE)
	stop
	
	}
}

actor GammaProtoShotAlly : ProtoShotBoss
{
+RIPPER
damage (35)
+DONTREFLECT
+THRUGHOST
DamageType "ProtoMan"
speed 65
states
{
Death:
TNT1 A 0 A_PlaySoundEx("weapon/napalm", "Voice", 0, 1)
TNT1 AAAAAAAAAAA 1 A_SpawnItemEx("DrillExplode", random(128,-128), random(128,-128), random(128,-128))
TNT1 A 0 A_PlaySoundEx("weapon/napalm", "Voice", 0, 1)
TNT1 AAAAAAAAAAA 1 A_SpawnItemEx("DrillExplode", random(128,-128), random(128,-128), random(128,-128))
TNT1 A 0 A_PlaySoundEx("weapon/napalm", "Voice", 0, 1)
TNT1 AAAAAAAAAAA 1 A_SpawnItemEx("DrillExplode", random(128,-128), random(128,-128), random(128,-128))
TNT1 A 0 A_PlaySoundEx("weapon/napalm", "Voice", 0, 1)
TNT1 AAAAAAAAAAA 1 A_SpawnItemEx("DrillExplode", random(128,-128), random(128,-128), random(128,-128))
stop
}
}

actor PainFXBig : PainFX
{
scale 10.5
}

actor GammaRock : PunkRock2
{
translation "15:191=88:88"
scale 1.5
}

actor GammaStompFX
{
+NOINTERACTION
-SOLID
states
{
	Spawn:
	TNT1 A 0
	TNT1 AAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAA 0 A_SpawnItemEx("GammaRock", random(30,800), 0, 0, random(-3,3), random(-3,3), random(5,8), random(0,360))
	stop
}
}

actor GammaStomp
{
PROJECTILE
damagetype "Gamma"
obituary "%o was stomped on by Gamma."
+FLOORHUGGER
States
{
Spawn:
TNT1 A 1
TNT1 A 1 A_Explode(9999, 400,0)
stop
}
}

actor GammaStomp2 : GammaStomp
{
States
{
Spawn:
TNT1 A 1
TNT1 A 1 A_Explode(50, 400, 0, 0, 50)
stop
}
}

actor WilyUFO 10602
{
//$Category MM8BDM-Props
+NOGRAVITY
scale 2.5
States
{
Spawn:
WUFO AB 4
loop
Float:
WUFO AC 4
loop
Closed:
WUFO DEF 4
loop
}
}

actor WilyDamage 10603
{
//$Category MM8BDM-Bosses
//$Sprite AMMOA0
+SHOOTABLE
Health 250
States
{
Spawn:
TNT1 A 1
loop
Death:
TNT1 A 1 ACS_Execute(28,0)
stop
}
}

actor Claw
{
scale 2.5
height 16
radius 18
+SHOOTABLE
-SOLID
maxstepheight 32
+INVULNERABLE
+DROPOFF
+CANPASS
+NOBLOCKMONST
+CANTSEEK
Health 1
speed 7
states
{
Spawn:
CLAW C -1
stop
Panic:
CLAW A 0 A_ChangeFlag("INVULNERABLE", 0)
CLAW AAAABBBB 1 A_Wander
loop
Death:
TNT1 A 0 A_PlaySoundEx("misc/devilpain", "Voice")
TNT1 A 1 A_SpawnItemEx("SharkTorpedoDeath", 0, 0, 9)
stop
}
}

actor ClawFriend : Claw
{
+LOOKALLAROUND
-NOBLOCKMONST
speed 5
states
{
Spawn:
CLAW C 5 A_Look
loop
See:
CLAW AAAABBBB 1 A_Chase
loop
Melee:
CLAW A 0 A_JumpIfInventory("CutterFlag", 1, "Awe")
CLAW A 0 A_FaceTarget
CLAW A 0 A_GiveInventory("CutterFlag",1)
CLAW A 0 A_SpawnItemEx("MTank", 0, 0, 8, 8, 0, 8, 0) 
Awe:
CLAW CCCCCCC 4 A_FaceTarget(30)
CLAW C 1 A_JumpIFCloser(128, "Melee")
Goto See
}
}

actor HardDestroyableWall
{
+SHOOTABLE
Height 64
radius 8
+NODAMAGE
painchance 256
-SOLID
+NOGRAVITY
renderstyle none
states
{
Spawn:
TNT1 A -1
stop
Pain.HardKnuckle:
TNT1 A 0 A_CallSpecial(special, args[0], args[1], args[2], args[3], args[4])
TNT1 A 0 A_SpawnITemEx("DrillExplode", 0, 0, 32)
TNT1 A 0 A_PlaysoundEx("misc/mm3explosion", "Voice", 0, 0)
stop
}
}

actor DistantGammaProp
{
height 2
radius 2
states
{
Spawn:
GAMA BCD 45
GAMA E 10 ACS_Execute(56, 0)
GAMA EFG 45
GAMA B 10 ACS_Execute(56, 0)
loop
}
}

actor GammaBuildingPunch
{
height 32
radius 32
scale 2.5
+NOGRAVITY
+NOINTERACTION
states
{
Spawn:
GAMD G 0
GAMD G 10 A_Recoil(-40)
GAMD GGGGGGGGGGGGGGGGGGGGGGGGGGG 0 A_SpawnItemEx("SharkDeathFX", -48, random(-10, 450), random(-10, 100), 0, 0, 0, 0)
GAMD G 2 A_SpawnItemEx("WindowShatterFX", -48, 0, 0, 0, 0, 0, 0)
GAMD G -1 A_Stop
stop
}
}

actor GammaDeathProp
{
scale 0.5
+NOGRAVITY
translation "0:255=8:8"
states
{
Spawn:
GAMD D 1 A_SpawnItemEx("GammaDeathExplode", random(0,80), 0, random(0,200), 0,0,0,random(0,360))
loop
Death:
GAMD D 0 A_SpawnItemEx("GammaWilyDeathProp", 0, 0, 192, 2,0,2,0)
GAMD D 0 A_SpawnItemEx("GammaDeathExplosion", 0, 0, 110, 0,0,0,90)
stop
}
}

actor GammaDeathExplode : ExplosionEffect2
{
scale 0.5
translation "0:255=8:8"
}

actor GammaDeathExplosion
{
renderstyle none
scale 1.2
translation "0:255=8:8"
states
{
Spawn:
TNT1 A 1
PLY1 Z 0 A_CustomMissile("GammaDeathFX1",0,0,0,2,90)
PLY1 Z 0 A_CustomMissile("GammaDeathFX1",0,0,0,2,-90)
PLY1 Z 0 A_CustomMissile("GammaDeathFX1",0,0,90,2,45)
PLY1 Z 0 A_CustomMissile("GammaDeathFX1",0,0,-90,2,-45)
PLY1 Z 0 A_CustomMissile("GammaDeathFX1",0,0,90,2,0)
PLY1 Z 0 A_CustomMissile("GammaDeathFX1",0,0,-90,2,0)
PLY1 Z 0 A_CustomMissile("GammaDeathFX1",0,0,90,2,-45)
PLY1 Z 0 A_CustomMissile("GammaDeathFX1",0,0,-90,2,45)
PLY1 Z 0 A_CustomMissile("GammaDeathFX2",0,0,0,2,90)
PLY1 Z 0 A_CustomMissile("GammaDeathFX2",0,0,0,2,-90)
PLY1 Z 0 A_CustomMissile("GammaDeathFX2",0,0,90,2,45)
PLY1 Z 0 A_CustomMissile("GammaDeathFX2",0,0,-90,2,-45)
PLY1 Z 0 A_CustomMissile("GammaDeathFX2",0,0,90,2,0)
PLY1 Z 0 A_CustomMissile("GammaDeathFX2",0,0,-90,2,0)
PLY1 Z 0 A_CustomMissile("GammaDeathFX2",0,0,90,2,-45)
PLY1 Z 0 A_CustomMissile("GammaDeathFX2",0,0,-90,2,45)
stop
}
}

actor GammaDeathFX1
{
scale 0.5
translation "0:255=8:8"
+NOINTERACTION
+NOGRAVITY
height 1
radius 1
-SOLID
+DONTBLAST
scale 2.5
PROJECTILE
Speed 6
reactiontime 10
States
{
Spawn:
ASEX BCDE 8
ASEX A 0 A_CountDown
loop
}
}

actor GammaDeathFX2 : GammaDeathFX1
{
speed 2
}

actor GammaWilyDeathProp
{
scale 0.5
translation "0:255=8:8"
+NOGRAVITY
states
{
Spawn:
WILG A -1
stop
}
}


actor GammaTrebleProp
{
Radius 12
Height 8
scale 2.5
PROJECTILE
+DONTBLAST
ReactionTime 70
states
{
Spawn:
TRBL F 0
TRBL F 250 ThrustThingZ(0, 60, 1, 1)
Death:
TNT1 A 0 A_SpawnItemEx("GammaTreble",0,0,3,0,0,momz,0,SXF_NOCHECKPOSITION,0)
stop
}
}

actor GammaTreble
{
scale 2.5
states
{
Spawn:
TRBL F 0 A_Stop
TRBL GH 2 Thing_ChangeTID(0, 189)
TRBL E 5 A_PlaySoundEx("misc/polarroar","Voice")
Looking:
TRBL AAAAAAAA 1// A_SeekerMissile(4, 10, SMF_LOOK|SMF_PRECISE, 256, 1000)
TRBL BCBCBC 4// A_SeekerMissile(4, 10, SMF_LOOK|SMF_PRECISE, 256, 1000)
loop
Leave:
Death:
TFOG D 0 A_PlaySoundEx("misc/teleportout", "Voice", 0, 1)
TNT1 A 1 A_SpawnItemEx("TrebleDeath",0,0,0,0,0,0,0,SXF_NOCHECKPOSITION)
TNT1 A -1
stop
}
}


/*
actor Gamma
{
scale 2.5
+FORCEYBILLBOARD
obituary "%o was destroyed by Gamma."
radius 120
height 1000
MONSTER
-SOLID
+DROPOFF
+NOGRAVITY
+DONTBLAST
+LOOKALLAROUND
-SHOOTABLE
Speed 3
States
{
Spawn:
GAMA A 0
GAMA A 0 A_SpawnItemEx("GammaLook")
GAMA A 1 A_Look
Goto Spawn+2
See:
GAMA A 1 A_JumpIfInTargetInventory("StrongSpring",1,"Follow")
stop
Follow:
GAMA A 0 A_TakeInventory("CutterFlag",999)
GAMA BBBBBBBBBBBBBBBBBBBBBBBBBCCCCCCCCCCCCCCCCCCCCCCCCCDDDDDDDDDDDDDDDDDDDDDDDDD 1 A_Chase
GAMA D 0 A_CustomMissile("GammaStomp",0,0,0,0)
GAMA E 10 ACS_ExecuteAlways(5,0,12)
GAMA EEEEEEEEEEEEEEEEEEEEEEEEEFFFFFFFFFFFFFFFFFFFFFFFFFGGGGGGGGGGGGGGGGGGGGGGGGG 1 A_Chase
GAMA D 0 A_GiveInventory("Clip",1)
GAMA D 0 A_CustomMissile("GammaStomp",0,0,0,0)
GAMA B 10 ACS_ExecuteAlways(5,0,12)
GAMA B 0 A_JumpIfInventory("Clip",2,"Attack")
loop
Attack:
GAMA B 0 A_TakeInventory("Clip",99)
TNT1 A 0 ACS_ExecuteAlways(5,0,14)
GAMA B 20 A_SpawnItemEx("GammaLitFX",25,0,1600)
GAMA B 20 A_SpawnItemEx("GammaAttackSpawner",170,0,1600)
Goto Follow
Kneel:
GAMA A 0 A_GiveInventory("CutterFlag",1)
GAMA A 0 //A_ChangeFlag("SOLID",1)
GAMD A 50
GAMD B 20
GAMD C 15
GAMD D 10 ACS_Execute(5,0,19)
GAMD EFEFEFEFEFEFEFEFEFEFEFEFEFEFEFEFEFEFEFEFEFEFEFEFEFEFEFEFEFEFEFEF 5 A_SpawnItemEx("WilyHitBox",25,0,1000)
GAMD D 20
GAMA A 0 A_ChangeFlag("SOLID",0)
GAMD CBA 15
GAMD A 2
GAMA A 2
GAMD A 2
GAMA A 2
GAMD A 2
GAMA A 2 
GAMD A 2 ACS_Execute(29,0)
Goto Holdit
Holdit:
GAMA A 8
loop
Death:
GAMD E -1
stop
}
}

actor GammaAttackSpawner
{
+NOINTERACTION
-SOLID
+NOGRAVITY
obituary "%o was destroyed by Gamma."
+LOOKALLAROUND
scale 5.0
States
{
Spawn:
TNT1 AAA 1 A_Look
stop
See:
TNT1 A 0 A_Jump(256,"Attack1","Attack2","Attack3")
Goto Attack1
Attack1:
TNT1 A 0 ACS_ExecuteAlways(5,0,15)
TNT1 A 1 A_CustomMissile("GammaLightningBall",0,0,0,2,-80)
stop
Attack2:
TNT1 A 0 ACS_ExecuteAlways(5,0,15)
GAMA PQPQ 2 A_FaceTarget
TNT1 A 0 A_CustomMissile("GammaExplosive",0,0,0)
TNT1 A 0 ACS_ExecuteAlways(5,0,15)
GAMA PQPQ 2 A_FaceTarget
TNT1 A 0 A_CustomMissile("GammaExplosive",0,0,0)
TNT1 A 0 ACS_ExecuteAlways(5,0,15)
GAMA PQPQ 2 A_FaceTarget
TNT1 A 0 A_CustomMissile("GammaExplosive",0,0,0)
TNT1 A 0 ACS_ExecuteAlways(5,0,15)
GAMA PQPQ 2 A_FaceTarget
TNT1 A 0 A_CustomMissile("GammaExplosive",0,0,0)
TNT1 A 0 ACS_ExecuteAlways(5,0,15)
GAMA PQPQ 2 A_FaceTarget
TNT1 A 0 A_CustomMissile("GammaExplosive",0,0,0)
TNT1 A 0 ACS_ExecuteAlways(5,0,15)
GAMA PQPQ 2 A_FaceTarget
TNT1 A 0 A_CustomMissile("GammaExplosive",0,0,0)
TNT1 A 0 ACS_ExecuteAlways(5,0,15)
GAMA PQPQ 2 A_FaceTarget
TNT1 A 0 A_CustomMissile("GammaExplosive",0,0,0)
TNT1 A 0 ACS_ExecuteAlways(5,0,15)
GAMA PQPQ 2 A_FaceTarget
TNT1 A 0 A_CustomMissile("GammaExplosive",0,0,0)
TNT1 A 0 ACS_ExecuteAlways(5,0,15)
GAMA PQPQ 2 A_FaceTarget
TNT1 A 0 A_CustomMissile("GammaExplosive",0,0,0)
TNT1 A 0 ACS_ExecuteAlways(5,0,15)
GAMA PQPQ 2 A_FaceTarget
TNT1 A 0 A_CustomMissile("GammaExplosive",0,0,0)
TNT1 A 0 ACS_ExecuteAlways(5,0,15)
stop
Attack3:
TNT1 A 0 ACS_ExecuteAlways(5,0,15)
TNT1 A 0 A_FaceTarget
TNT1 A 1 A_CustomMissile("GammaFireBall",0,0,0,2,-60)
stop
}
}

actor GammaFireBall : FastProjectile
{
PROJECTILE
damagetype "QuickBoomerang"
damage (0)
+RIPPER
+DONTBLAST
scale 4.0
radius 8
Height 8
Speed 60
States
{
Spawn:
GAMA UVW 3
loop
Death:
TNT1 A 0 ACS_ExecuteAlways(5,0,17)
TNT1 A 0 A_GiveInventory("Clip",1)
TNT1 A 0 A_JumpIfInventory("Clip",20,"Bye")
TNT1 A 1 A_SpawnItemEx("GammaSpew",0,0,10,random(5,20),random(5,20),random(5,20),random(0,360))
loop
Bye:
TNT1 A 0
stop
}
}

actor GammaSpew// : FastProjectile
{
PROJECTILE
damagetype "QuickBoomerang"
damage (0)
+RIPPER
-NOGRAVITY
+DONTBLAST
scale 2.5
radius 16
Height 16
Speed 60
States
{
Spawn:
GAMA UVW 3
loop
Death:
GAMF A 0 A_JumpIf(z-floorz>0,"Bye")
GAMF A 0 A_PlaySoundEx("weapon/atomicfire","voice")
GAMF ABC 3
GAMF DEFDEFDEFDEFDEFDEFDEFDEFDEFDE 4 A_Explode(4, 128, 0)
GAMF CBA 3
stop
Bye:
TNT1 A 0
stop
}
}

actor GammaExplosive : FastProjectile
{
PROJECTILE
damagetype "QuickBoomerang"
damage (1)
//-NOGRAVITY
//+LOWGRAVITY
+RIPPER
scale 2.5
radius 32
Height 32
Speed 75
States
{
Spawn:
GAMA RST 3
loop
Death:
BOMB A 0 A_Explode(10, 180, 0)
BOMB BCDEFGHIJKLMNOPQR 1
stop
}
}

actor GammaLightningBall
{
PROJECTILE
+RIPPER
+DONTBLAST
damagetype "QuickBoomerang"
damage 0
scale 2.5
Speed 65
States
{
Spawn:
GAMA JKJKJKJK 2
GAMA J 0 A_Stop
//GAMA JKJKJKJKJKJK 2
GAMA K 0 A_CustomMissile("GammaLightningShooter",0,0,0,2,0)
//GAMA K 0 A_CustomMissile("GammaLightningShooter",0,0,-8,2,0)
GAMA K 0 A_CustomMissile("GammaLightningShooter",0,0,-16,2,0)
//GAMA K 0 A_CustomMissile("GammaLightningShooter",0,0,-24,2,0)
GAMA K 0 A_CustomMissile("GammaLightningShooter",0,0,-32,2,0)
//GAMA K 0 A_CustomMissile("GammaLightningShooter",0,0,-40,2,0)
GAMA K 0 A_CustomMissile("GammaLightningShooter",0,0,-48,2,0)
//GAMA K 0 A_CustomMissile("GammaLightningShooter",0,0,-56,2,0)
GAMA K 0 A_CustomMissile("GammaLightningShooter",0,0,-65,2,0)
//GAMA K 0 A_CustomMissile("GammaLightningShooter",0,0,8,2,0)
GAMA K 0 A_CustomMissile("GammaLightningShooter",0,0,16,2,0)
//GAMA K 0 A_CustomMissile("GammaLightningShooter",0,0,24,2,0)
GAMA K 0 A_CustomMissile("GammaLightningShooter",0,0,32,2,0)
//GAMA K 0 A_CustomMissile("GammaLightningShooter",0,0,40,2,0)
GAMA K 0 A_CustomMissile("GammaLightningShooter",0,0,48,2,0)
//GAMA K 0 A_CustomMissile("GammaLightningShooter",0,0,56,2,0)
GAMA K 0 A_CustomMissile("GammaLightningShooter",0,0,65,2,0)
stop
}
}

actor GammaLightningShooter
{
PROJECTILE
+RIPPER
+DONTBLAST
damage 0
scale 2.5
Speed 17
States
{
Spawn:
TNT1 A 0 ACS_Execute(5,0,16)
GAMA LM 2 A_SpawnItemEx("GammaLitFall",0,0,0,1,0,-50)
loop
}
}

actor GammaLitFall : FastProjectile
{
PROJECTILE
damage (2)
+DONTBLAST
+RIPPER
scale 2.5
radius 32
Height 32
Speed 20
States
{
Spawn:
GAMA NO 2
loop
}
}

actor GammaLitFx
{
+NOINTERACTION
scale 2.5
-SOLID
+DONTBLAST
+NOGRAVITY
States
{
Spawn:
GAMA HIHIHIHIHI 2
stop
}
}

actor GammaStomp
{
PROJECTILE
obituary "%o was stomped on by Gamma."
+FLOORHUGGER
States
{
Spawn:
TNT1 A 1
TNT1 A 1 A_Explode(9999, 400,0)
stop
}
}

actor GammaLook
{
+NOINTERACTION
+MISSILE
+NOGRAVITY
States
{
Spawn:
TNT1 A 0 A_JumpIfInTargetInventory("CutterFlag",1,"NoHitbox")
//TNT1 A 0 A_JumpIfInventory("CutterFlag",1,1)
TNT1 A 1 A_GiveToTarget("GammaForceHitbox",1)
NoHitbox:
TNT1 A 1 A_GiveToTarget("GammaForceLook",1)
Goto Spawn
}
}

actor GammaForceLook : CustomInventory
{
+INVENTORY.AUTOACTIVATE
States
{
Pickup:
TNT1 A 0 A_FaceTarget
stop
}
}

actor GammaForceHitbox : CustomInventory
{
+INVENTORY.AUTOACTIVATE
States
{
Pickup:
TNT1 A 0 A_SpawnItemEx("GammaHitBox",25,0,1500)
stop
}
}

actor GammaHitBox
{
Scale 2.5
Radius 64
Height 64
+SHOOTABLE
Health 99999
painchance 256
renderstyle none
States
{
Spawn:
PLAY A 1
PLAY A 1
stop
Pain:
PLAY A 0 A_ChangeFlag("SHOOTABLE",0)
PLAY A 0 ACS_ExecuteAlways(5,0,18)
stop
Pain.QuickBoomerang:
PLAY A 0 A_ChangeFlag("SHOOTABLE",0)
stop
Pain.AtomicFire3:
PLAY A 1 ACS_ExecuteAlways(5,0,13)
Pain.PharaohShot3:
Pain.BalladeCracker:
Pain.HardKnuckle:
PLAY A 0 A_ChangeFlag("SHOOTABLE",0)
PLAY A 0 ACS_ExecuteAlways(5,0,13)
PLAY AAAA 3 A_SpawnItem("PainFX",-13)
stop
Pain.SuperArm:
PLAY A 0 A_ChangeFlag("SHOOTABLE",0)
PLAY AAA 0 ACS_ExecuteAlways(5,0,13)
PLAY AAAA 3 A_SpawnItem("PainFX",-13)
stop
Pain.OilSlider:
Pain.MegaBall:
PLAY A 0 A_ChangeFlag("SHOOTABLE",0)
PLAY AAAAAAAAAAAAAAAAAAAAAAAAAAAAAAA 0 ACS_ExecuteAlways(5,0,13)
PLAY AAAA 3 A_SpawnItem("PainFX",-13)
stop
}
}

actor WilyHitBox : GammaHitBox
{
Health 99999
renderstyle none
States
{
Spawn:
PLAY A 5
stop
Pain.TopSpin:
Pain.MegaBall:
PLAY A 0 ACS_Execute(32,0)
stop
Pain.QuickBoomerang:
Pain.AtomicFire3:
Pain.PharaohShot3:
Pain.HardKnuckle:
Pain:
PLAY A 0 A_ChangeFlag("SHOOTABLE",0)
PLAY A 0 ACS_ExecuteAlways(5,0,18)
stop
}
}

actor ScreenFlash2 : CustomInventory
{
inventory.amount 1
inventory.maxamount 1
+INVENTORY.AUTOACTIVATE
States
{
Pickup:
TNT1 A 1 ACS_ExecuteAlways(34,0)
stop
}
}
*/