actor BFG9k_gone replaces bfg9000
{
radius 8
Height 16
states
{
spawn:
    TNT1 A 0
    TNT1 A 1 Thing_Remove(0)
    STOP
}}

actor MFist : Weapon
{
  Game Doom
  Weapon.SelectionOrder 9999 //3700
  Weapon.Kickback 100
  +WEAPON.WIMPY_WEAPON
  +WEAPON.MELEEWEAPON
  +INVENTORY.UNDROPPABLE
  Weapon.PreferredSkin "FistMarine"
  Obituary "$OB_MPFIST" // "%o chewed on %k's fist."
  States
  {
  Ready:
    PUNG A 1 A_WeaponReady
    PUNG A 0 A_jumpifinventory("kicking",1,"dokick")
    loop
  Deselect:
    PUNG A 1 A_Lower
    loop
  Select:
    PUNG A 1 ACS_ExecuteAlways(480,0,13,0,0)
	PUNG A 0 A_PlayWeaponSound("m_fists_taunt")
  sel:
    PUNG A 0
    PUNG A 1 A_Raise
    loop
  Fire:
    PUNG B 4
    PUNG A 0 A_JumpIfInventory("PowerStrength",1,5)
    PUNG C 4 A_CustomPunch (3,0,0,"MFistPuff",60)
    PUNG D 5
    PUNG C 4
    PUNG B 5 A_ReFire
    goto Ready
    PUNG C 4 A_CustomPunch (25,0,0,"MFistPuff",60)
    PUNG D 5
    PUNG C 4
    PUNG B 5 A_ReFire
    goto Ready
  Spawn:
    TNT1 A 1 Thing_Remove(0)
    Stop
 DoKick:
	TNT1 A 0
        TNT1 A 0 //A_ZoomFactor(1.0)
	TNT1 A 0 A_jumpifinventory("PowerStrength",1,"BerserkerKick")
	TNT1 A 0 A_PlaySound("KICK")
	TNT1 A 0 SetPlayerProperty(0,1,0)
	KICK BCD 1
	RIFF A 0 A_FireCustomMissile("KickAttack", 0, 0, 0, -7)
	KICK H 4
	KICK A 0 A_Takeinventory("Kicking",1)
	KICK IGFEDCBA 1 
	TNT1 A 0 SetPlayerProperty(0,0,0)
	Goto Ready
    BerserkerKick:
	TNT1 A 0 A_PlaySound("KICK")
	TNT1 A 0 SetPlayerProperty(0,1,0)
	KICK ABCDEFG 1
	RIFF A 0 A_FireCustomMissile("SuperKickAttack", 0, 0, 0, -7)
	KICK H 3
	KICK A 0 A_Takeinventory("Kicking",1)
	KICK IGFEDCBA 1 
	TNT1 A 0 SetPlayerProperty(0,0,0)
	Goto Ready
  }
}

actor MFists : Fist 
{
  +WEAPON.WIMPY_WEAPON
  +WEAPON.MELEEWEAPON
  +INVENTORY.UNDROPPABLE
  Weapon.Kickback 100 //added
  Weapon.SelectionOrder 9999 //2200
  attacksound "marine/fists"
  Weapon.PreferredSkin "FistMarine"
  Obituary "$OB_MPFIST" // "%o chewed on %k's fist."
  
  States
  {
  Ready:
    MPNG A 1 A_WeaponReady
    MPNG A 0 A_jumpifinventory("kicking",1,"dokick")
    loop
  Deselect:
    MPNG A 1 A_Lower
    loop
  Select:
    MPNG A 1 ACS_ExecuteAlways(480,0,12,0,0)
	MPNG A 0 A_PlayWeaponSound("m_fists_taunt")
  Sel:
    MPNG A 0
    MPNG A 1 A_Raise

    loop
  Fire:
        MPNG A 0 A_JumpIfInventory("MLeftFist",1,"Right")
        MPNG BCD 1
	MPNG A 0 A_JumpIfInventory("PowerStrength",1,6)
	MPNG E 1 A_CustomPunch (3,0,0,"MFistPuff",60)
	MPNG FGH 2
	MPNG A 2 A_GiveInventory("MLeftFist",1)
	Goto Ready
	MPNG E 1 A_CustomPunch (23,0,0,"MFistPuff",60)
	MPNG FGH 2
	MPNG A 2 A_GiveInventory("MLeftFist",1)
	Goto Ready
  Right:	
	MPNG IJK 1
        MPNG A 0 A_JumpIfInventory("PowerStrength",1,6)
	MPNG L 1 A_CustomPunch (3,0,0,"MFistPuff",60)
	MPNG MNO 2
	MPNG A 2 A_TakeInventory("MLeftFist",1)
	Goto Ready
	MPNG L 1 A_CustomPunch (23,0,0,"MFistPuff",60)
	MPNG MNO 2
	MPNG A 2 A_TakeInventory("MLeftFist",1)
	Goto Ready
  Spawn:
    TNT1 A 1 Thing_Remove(0)
    Stop
 DoKick:
	TNT1 A 0
        TNT1 A 0 //A_ZoomFactor(1.0)
	TNT1 A 0 A_jumpifinventory("PowerStrength",1,"BerserkerKick")
	TNT1 A 0 A_PlaySound("KICK")
	TNT1 A 0 SetPlayerProperty(0,1,0)
	KICK BCD 1
	RIFF A 0 A_FireCustomMissile("KickAttack", 0, 0, 0, -7)
	KICK H 4
	KICK A 0 A_Takeinventory("Kicking",1)
	KICK IGFEDCBA 1 
	TNT1 A 0 SetPlayerProperty(0,0,0)
	Goto Ready
    BerserkerKick:
	TNT1 A 0 A_PlaySound("KICK")
	TNT1 A 0 SetPlayerProperty(0,1,0)
	KICK ABCDEFG 1
	RIFF A 0 A_FireCustomMissile("SuperKickAttack", 0, 0, 0, -7)
	KICK H 3
	KICK A 0 A_Takeinventory("Kicking",1)
	KICK IGFEDCBA 1 
	TNT1 A 0 SetPlayerProperty(0,0,0)
	Goto Ready
  }
}

Actor MFistPuff
{
+NOBLOCKMAP
+NOGRAVITY
+PUFFONACTORS
-ALLOWPARTICLES
DamageType "MarineDamage" 
attacksound "marine/fistswall"
}



ACTOR MLeftFist : Inventory
 {
  Inventory.Amount 0
  Inventory.MaxAmount 1
  States
   {
    Spawn:
    TNT1 A -1
    Loop 
   }
 }

// ChainSaw

actor MChainsaw : Chainsaw replaces Chainsaw
{
  Weapon.SelectionOrder 3700
  Weapon.PreferredSkin "ChainSawMarine"
  States
  {
	 
 Select:
	SAWG A 1 ACS_ExecuteAlways(480,0,1,0,0)
 Sel:
     SAWG A 0
	 SAWG A 1 A_Raise
     Loop

Ready:
    SAWG CD 4 A_WeaponReady
    SAWG A 0 A_jumpifinventory("kicking",1,"doKick")
    Loop

  Fire:
    SAWG AB 4 A_Saw ("weapons/sawfull","weapons/sawhit",10,"MBulletPuff") //sprite 4, damage 2
    SAWG B 0 A_ReFire
    goto Ready
  Spawn:
    CSAW A -1
    stop

 DoKick:
	TNT1 A 0
	//TNT1 A 0 A_Takeinventory("Zoomed",1) //no such inventory
        TNT1 A 0 A_ZoomFactor(1.0)
	TNT1 A 0 A_jumpifinventory("PowerStrength",1,"BerserkerKick")
	TNT1 A 0 A_PlaySound("KICK")
	TNT1 A 0 SetPlayerProperty(0,1,0)
	KICK BCD 1
	RIFF A 0 A_FireCustomMissile("KickAttack", 0, 0, 0, -7)
	KICK H 4
	KICK A 0 A_Takeinventory("Kicking",1)
	KICK IGFEDCBA 1 
	TNT1 A 0 SetPlayerProperty(0,0,0)
	Goto Ready
    BerserkerKick:
	TNT1 A 0 A_PlaySound("KICK")
	TNT1 A 0 SetPlayerProperty(0,1,0)
	KICK ABCDEFG 1
	RIFF A 0 A_FireCustomMissile("SuperKickAttack", 0, 0, 0, -7)
	KICK H 3
	KICK A 0 A_Takeinventory("Kicking",1)
	KICK IGFEDCBA 1 
	TNT1 A 0 SetPlayerProperty(0,0,0)
	Goto Ready

  }
}


// Pistol
actor MPistol : Pistol replaces Pistol
{
  Weapon.AmmoUse2 1
  Weapon.AmmoType "MClip"
  Weapon.AmmoType2 "MClip"
  Weapon.SelectionOrder 9000 //added
  Weapon.PreferredSkin "PistolMarine"
  attacksound "weapons/adpistol"
  +WEAPON.NOAUTOAIM //added
  
  States
  {
  Ready:
    PISG A 1 A_WeaponReady
    PISG A 0 A_jumpifinventory("kicking",1,"dokick")
    Loop
  Fire:
    PISG A 4
    PISG B 0 A_FireBullets (3.2, 1.2, 1, 6, "MBulletPuff")
    PISG B 5 A_GunFlash
    PISG C 4
    PISG B 5 A_ReFire
    Goto Ready
  AltFire:
    PISG A 1
    PISG A 1 A_JumpIfInventory ("RUnlock1",1,2)
    PISG A 1
    Goto Ready
    PISG A 3
    PISG B 0 A_FireBullets (5.6, 2.4, -1, 6, "MBulletPuff")
    PISG B 3 A_GunFlash
    PISG C 2
    PISG B 3 A_FireBullets (5.6, 2.4, -1, 6, "MBulletPuff")
    PISG C 2
    PISG B 5
    Goto Ready

Select:
    PISG B 1 ACS_ExecuteAlways(480,0,22,0,0)
	PISG B 0 A_PlayWeaponSound("m_shotgun_taunt")
Sel:
    PISG B 0
    PISG B 1 A_Raise
    LOOP
  Flash:
    PISF A 6 Bright A_Light1
    PISF A 0 A_Light0
    Stop
  AltFlash:
    PISF A 3 Bright A_Light1
    TNT1 A 2 A_Light0
    PISF A 4 Bright A_Light1
    TNT1 A 0 A_Light0
    Stop
 DoKick:
	TNT1 A 0
        TNT1 A 0 //A_ZoomFactor(1.0)
	TNT1 A 0 A_jumpifinventory("PowerStrength",1,"BerserkerKick")
	TNT1 A 0 A_PlaySound("KICK")
	TNT1 A 0 SetPlayerProperty(0,1,0)
	KICK BCD 1
	RIFF A 0 A_FireCustomMissile("KickAttack", 0, 0, 0, -7)
	KICK H 4
	KICK A 0 A_Takeinventory("Kicking",1)
	KICK IGFEDCBA 1 
	TNT1 A 0 SetPlayerProperty(0,0,0)
	Goto Ready
    BerserkerKick:
	TNT1 A 0 A_PlaySound("KICK")
	TNT1 A 0 SetPlayerProperty(0,1,0)
	KICK ABCDEFG 1
	RIFF A 0 A_FireCustomMissile("SuperKickAttack", 0, 0, 0, -7)
	KICK H 3
	KICK A 0 A_Takeinventory("Kicking",1)
	KICK IGFEDCBA 1 
	TNT1 A 0 SetPlayerProperty(0,0,0)
	Goto Ready
  }
}

//Pistol Sinner rank NOOB
actor MPistolForDeranked : MPistol
{
  +INVENTORY.UNDROPPABLE
  +WEAPON.CHEATNOTWEAPON
}


// Advanced Pistol

actor ADMPistol : Weapon 
{
  Weapon.Kickback 100
  Weapon.SelectionOrder 8000 //1900
  Weapon.AmmoUse 1
  Weapon.AmmoUse2 1
  Weapon.AmmoGive 8
  Weapon.AmmoType "MClip"
  Weapon.AmmoType2 "MClip"
  Obituary "$OB_MPPISTOL" // 
  attacksound "weapons/adpistol"
  Weapon.PreferredSkin "PistolMarine"
  +WEAPON.WIMPY_WEAPON
  +WEAPON.NOAUTOAIM //added
  //+INVENTORY.UNDROPPABLE
  Inventory.Pickupmessage "$PICKUP_PISTOL_DROPPED" // 
  States
  {
  Ready:
    ADPS A 1 A_WeaponReady
    ADPS A 0 A_jumpifinventory("kicking",1,"dokick")
    Loop
  Deselect:
    ADPS A 1 A_Lower
    Loop
Select:
    ADPS B 1 ACS_ExecuteAlways(480,0,2,0,0)
	ADPS B 0 A_PlayWeaponSound("m_adv_pistol_taunt")
Sel:
    ADPS B 0
    ADPS B 1 A_Raise
    LOOP
  Fire:
    ADPS B 3 A_GunFlash
    ADPF A 2 Bright A_FireBullets (0.5,0.5, 1, 12, "MBulletPuff")
	ADPS C 1 A_SetPitch(-2.0 + pitch)
    ADPS C 2
	ADPS C 1 A_SetPitch(2.0 + pitch)
    ADPS C 0 A_ReFire
    ADPS DCB 3
    Goto Ready
  AltFire:
    ADPS A 1
    ADPS A 1 A_JumpIfInventory ("RUnlock4",1,2)
    ADPS A 1
    Goto Ready
    ADPS B 3 A_GunFlash
	ADPF A 1 Bright A_FireBullets (1,1, -1, 24, "MBulletPuff")
	ADPS A 1 A_SetPitch(-1.5 + pitch)
	ADPS A 0 A_JumpIfInventory ("MClip",1,2)
	ADPS A 1 A_Jump (256, 7) //0
	ADPS B 1 A_GunFlash
	ADPF A 1 Bright A_FireBullets (1,1, -1, 24, "MBulletPuff")
	ADPS A 1 A_SetPitch(-1.5 + pitch)
	ADPS A 0 A_JumpIfInventory ("MClip",1,2)
	ADPS A 1 A_Jump (256, 3) //0
	ADPS B 1 A_GunFlash
	ADPF A 1 Bright A_FireBullets (1,1, -1, 24, "MBulletPuff")
	ADPS C 1 A_SetPitch(-1.5 + pitch)
	ADPS C 3
	ADPS C 1 A_SetPitch(4.5 + pitch)
	ADPS DCB 3 //4
	ADPS A 0 A_CheckReload
    Goto Ready
  Flash:
	TNT1 A 3 A_Light0
	TNT1 A 4 BRIGHT A_Light1
	TNT1 A 2 BRIGHT A_Light2
	TNT1 A 0 A_Light0
	Stop
  AltFlash:
	TNT1 A 3 A_Light0
	TNT1 A 2 BRIGHT A_Light1
	TNT1 A 3 BRIGHT A_Light2
	TNT1 A 0 A_Light0
	Stop
  Spawn:
    RSTP A -1 //added
    Stop //added
    //TNT1 A 1 Thing_Remove(0)
    //Stop
 DoKick:
	TNT1 A 0
        TNT1 A 0 //A_ZoomFactor(1.0)
	TNT1 A 0 A_jumpifinventory("PowerStrength",1,"BerserkerKick")
	TNT1 A 0 A_PlaySound("KICK")
	TNT1 A 0 SetPlayerProperty(0,1,0)
	KICK BCD 1
	RIFF A 0 A_FireCustomMissile("KickAttack", 0, 0, 0, -7)
	KICK H 4
	KICK A 0 A_Takeinventory("Kicking",1)
	KICK IGFEDCBA 1 
	TNT1 A 0 SetPlayerProperty(0,0,0)
	Goto Ready
    BerserkerKick:
	TNT1 A 0 A_PlaySound("KICK")
	TNT1 A 0 SetPlayerProperty(0,1,0)
	KICK ABCDEFG 1
	RIFF A 0 A_FireCustomMissile("SuperKickAttack", 0, 0, 0, -7)
	KICK H 3
	KICK A 0 A_Takeinventory("Kicking",1)
	KICK IGFEDCBA 1 
	TNT1 A 0 SetPlayerProperty(0,0,0)
	Goto Ready
  }
}

// Advanced Shotgun (Assault Shotgun)

ACTOR AssaultShotgun : Shotgun
{
	Inventory.PickupMessage "AssaultShotgun"
	Weapon.SelectionOrder 40
	Weapon.AmmoType1 "MShell"
	Weapon.AmmoType2 "MShell"
	Weapon.AmmoGive1 8
	Weapon.AmmoUse1 1
	Weapon.AmmoUse2 1
	Weapon.Kickback 200 //120
	Weapon.SelectionOrder 1000 //added
	AttackSound "weapons/Ashotgun/fire"
	Weapon.PreferredSkin "AssaultSGMarine"
	+WEAPON.NOAUTOAIM //added
	
	States
	{
	Ready:
		D3SG A 1 A_WeaponReady
		D3SG A 0 A_jumpifinventory("kicking",1,"dokick")
		loop
	Deselect:
		D3SG A 1 A_Lower
		loop
	Select:
		D3SG A 1 ACS_ExecuteAlways(480,0,33,0,0)	
		D3SG A 10 A_PlayWeaponSound("m_ass_shotgun_taunt")
    Sel:
		D3SG A 0 
		D3SG A 1 A_Raise
		Loop
	Fire:
		D3SG A 0 A_JumpIfInventory ("PM_AltFireX",1,"AltFireX")
	    D3SG A 0 A_JumpIfInventory ("PM_AltFireY",1,"AltFireY")
		D3SG A 0 A_JumpIfInventory ("PM_AltFireZ",1,"AltFireZ")	
		D3SG A 0 A_FireBullets(3, 3, 7, 6, "MBulletPuff", 1)
		D3SG A 1 A_SetPitch(-2.0 + pitch)
		D3SG A 3 A_GunFlash
		D3SG A 1 A_SetPitch(2.0 + pitch)
		D3SG B 4 A_PlaySound("weapons/Ashotgun/cock/back")
		D3SG C 3//6
		D3SG B 4 A_PlaySound("weapons/Ashotgun/cock/forward")
		D3SG A 3//6
		Goto Ready
	
	AltFireX:
		D3SG A 0 A_FireBullets(7, 7, 7, 6, "MBulletPuff", 1)
		D3SG A 1 A_SetPitch(-2.0 + pitch)
		D3SG A 4 A_GunFlash
		D3SG A 1 A_SetPitch(2.0 + pitch)
		D3SG A 0 A_CheckReload
		D3SG A 0 A_FireBullets(7, 7, 7, 6, "MBulletPuff", 1)
		D3SG A 1 A_SetPitch(-2.0 + pitch)
		D3SG A 4 A_GunFlash
		D3SG A 1 A_SetPitch(2.0 + pitch)
		D3SG A 0 A_CheckReload
			D3SG B 4 A_PlaySound("weapons/Ashotgun/cock/back")
			D3SG C 3//6
			D3SG B 4 A_PlaySound("weapons/Ashotgun/cock/forward")
			D3SG A 3//6
		Goto Ready
	AltFireY:
		D3SG A 0 A_RailAttack(random(120,150), 5, 1, "none", "black", 0, 0, "MRailPuff")
		D3SG A 1 A_SetPitch(-8.0 + pitch)
		D3SG A 3
		D3SG A 1 A_SetPitch(+8.0 + pitch)
		D3SG A 10
		D3SG B 10 A_PlaySound("weapons/Ashotgun/cock/back")
		D3SG C 6
		D3SG B 4 A_PlaySound("weapons/Ashotgun/cock/forward")
		D3SG A 20
		Goto Ready
	AltFireZ:
		D3SG A 0 A_PlaySoundEx ("weapons/mgren","weapon")
		D3SG A 0 A_FireCustomMissile ("MGrenade",5,1,0,0,0,9) //12
		D3SG A 1 A_SetPitch(-8.0 + pitch)
		D3SG A 3
		D3SG A 1 A_SetPitch(+8.0 + pitch)
		D3SG A 10
		D3SG B 10 A_PlaySound("weapons/Ashotgun/cock/back")
		D3SG C 6
		D3SG B 4 A_PlaySound("weapons/Ashotgun/cock/forward")
		D3SG A 20
		Goto Ready

	AltFire:
		D3SG A 0 A_FireBullets(7, 7, 7, 6, "MBulletPuff", 1)
		D3SG A 1 A_SetPitch(-2.0 + pitch)
		D3SG A 4 A_GunFlash
		D3SG A 1 A_SetPitch(2.0 + pitch)
		D3SG A 0 A_CheckReload
		D3SG A 0 A_FireBullets(7, 7, 7, 6, "MBulletPuff", 1)
		D3SG A 1 A_SetPitch(-2.0 + pitch)
		D3SG A 4 A_GunFlash
		D3SG A 1 A_SetPitch(2.0 + pitch)
		D3SG A 0 A_CheckReload
		
		D3SG A 0 A_FireBullets(7, 7, 7, 6, "MBulletPuff", 1)
		D3SG A 1 A_SetPitch(-2.0 + pitch)
		D3SG A 4 A_GunFlash
		D3SG A 1 A_SetPitch(2.0 + pitch)
		D3SG A 0 A_CheckReload
		D3SG A 0 A_FireBullets(7, 7, 7, 6, "MBulletPuff", 1)
		D3SG A 1 A_SetPitch(-2.0 + pitch)
		D3SG A 4 A_GunFlash
		D3SG A 1 A_SetPitch(2.0 + pitch)
		D3SG A 0 A_CheckReload
		
		D3SG A 0 A_FireBullets(7, 7, 7, 6, "MBulletPuff", 1)
		D3SG A 1 A_SetPitch(-2.0 + pitch)
		D3SG A 4 A_GunFlash
		D3SG A 1 A_SetPitch(2.0 + pitch)
		D3SG A 0 A_CheckReload
		D3SG A 0 A_FireBullets(7, 7, 7, 6, "MBulletPuff", 1)
		D3SG A 1 A_SetPitch(-2.0 + pitch)
		D3SG A 4 A_GunFlash
		D3SG A 1 A_SetPitch(2.0 + pitch)
		D3SG A 0 A_CheckReload
		
		D3SG A 0 A_JumpIfInventory ("MShell",2,2)
		D3SG A 1 A_Jump (256,5) //0
		D3SG B 4 A_PlaySound("weapons/Ashotgun/cock/back")
		D3SG C 6
		D3SG B 4 A_PlaySound("weapons/Ashotgun/cock/forward")
		D3SG A 6
		D3SG B 4 A_PlaySound("weapons/Ashotgun/cock/back")
		D3SG C 6
		D3SG B 4 A_PlaySound("weapons/Ashotgun/cock/forward")
		D3SG A 30
		Goto Ready
	Flash:
		D3SF A 3 BRIGHT A_Light1
		D3SF B 2 BRIGHT A_Light2
		D3SF B 0 A_Light0
		Stop
	AltFlash:
		D3SF A 3 BRIGHT A_Light1
		D3SF B 2 BRIGHT A_Light2
		D3SF B 0 A_Light0
		Stop
  Spawn:
    ASSG A -1 //added
	Stop //added
    //TNT1 A 1 Thing_Remove(0)
    //Stop
 DoKick:
	TNT1 A 0
        TNT1 A 0 //A_ZoomFactor(1.0)
	TNT1 A 0 A_jumpifinventory("PowerStrength",1,"BerserkerKick")
	TNT1 A 0 A_PlaySound("KICK")
	TNT1 A 0 SetPlayerProperty(0,1,0)
	KICK BCD 1
	RIFF A 0 A_FireCustomMissile("KickAttack", 0, 0, 0, -7)
	KICK H 4
	KICK A 0 A_Takeinventory("Kicking",1)
	KICK IGFEDCBA 1 
	TNT1 A 0 SetPlayerProperty(0,0,0)
	Goto Ready
    BerserkerKick:
	TNT1 A 0 A_PlaySound("KICK")
	TNT1 A 0 SetPlayerProperty(0,1,0)
	KICK ABCDEFG 1
	RIFF A 0 A_FireCustomMissile("SuperKickAttack", 0, 0, 0, -7)
	KICK H 3
	KICK A 0 A_Takeinventory("Kicking",1)
	KICK IGFEDCBA 1 
	TNT1 A 0 SetPlayerProperty(0,0,0)
	Goto Ready
	}
}


// Shotgun

actor MShotgun : Shotgun replaces Shotgun
{
  Weapon.AmmoType "MShell"
  Weapon.AmmoUse2 0
  Weapon.Kickback 100 //added
  Weapon.SelectionOrder 2000 //added
  attacksound ""
  Weapon.PreferredSkin "ShotGunMarine"
  +WEAPON.NOAUTOAIM //added
  
  States
  {
Ready:
    SHTG A 1 A_WeaponReady
    SHTG A 0 A_jumpifinventory("kicking",1,"dokick")
    Loop

  Fire:
    SHTG A 2
    SHTG A 0 A_FireBullets (5.6, 1.8, 8, 5, "MBulletPuff")
    SHTG A 0 A_GunFlash
    SHTG A 10 A_PlaySound ("weapons/shotgf", CHAN_WEAPON)
    SHTG BCDEFG 2
    SHTG H 3
    SHTG GFEDCB 2
    SHTG A 3 A_ReFire
    Goto Ready
 Select:
    SHTG A 1 ACS_ExecuteAlways(480,0,3,0,0)
	SHTG A 0 A_PlayWeaponSound("m_shotgun_taunt")
 Sel:
    SHTG A 0
    SHTG A 1 A_Raise
    Loop
  Flash:
    SHTF A 4 Bright A_Light1
    SHTF B 3 Bright A_Light2
    SHTF A 0 A_Light0
    Stop
  AltFlash:
    SHTG B 2
    SHTG C 2
    SHTG D 2
    SHTG E 10
    SHTG D 3
    SHTG C 3
    SHTG B 3
    SHTG A 3
    TNT1 A 0
    Stop
  AltFire:
    SHTG A 1
    SHTG A 1 A_JumpIfInventory ("RUnlock2",1,2)
    SHTG A 1
    Goto Ready
    TNT1 A 4 A_Gunflash
    TNT1 A 0 A_JumpIfInventory("PowerStrength",1,8)
    MPNG JK 2
    MPNG L 0 A_PlaySound ("marine/fists", CHAN_WEAPON)
    MPNG L 2 A_CustomPunch (4,0,0,"MFistPuff",60)
    MPNG MN 6
    TNT1 A 4 A_ReFire
    Goto Ready
    MPNG JK 2
    MPNG L 0 A_PlaySound ("marine/fists", CHAN_WEAPON)
    MPNG L 2 A_CustomPunch (27,0,0,"MFistPuff",60)
    MPNG MN 6
    TNT1 A 4 A_ReFire
    Goto Ready
 DoKick:
	TNT1 A 0
        TNT1 A 0 A_ZoomFactor(1.0)
	TNT1 A 0 A_jumpifinventory("PowerStrength",1,"BerserkerKick")
	TNT1 A 0 A_PlaySound("KICK")
	TNT1 A 0 SetPlayerProperty(0,1,0)
	KICK BCD 1
	RIFF A 0 A_FireCustomMissile("KickAttack", 0, 0, 0, -7)
	KICK H 4
	KICK A 0 A_Takeinventory("Kicking",1)
	KICK IGFEDCBA 1
	TNT1 A 0 SetPlayerProperty(0,0,0)
	Goto Ready
    BerserkerKick:
	TNT1 A 0 A_PlaySound("KICK")
	TNT1 A 0 SetPlayerProperty(0,1,0)
	KICK ABCDEFG 1
	RIFF A 0 A_FireCustomMissile("SuperKickAttack", 0, 0, 0, -7)
	KICK H 3
	KICK A 0 A_Takeinventory("Kicking",1)
	KICK IGFEDCBA 1 
	TNT1 A 0 SetPlayerProperty(0,0,0)
	Goto Ready
  AltHold:
    TNT1 A 4 A_Gunflash
    TNT1 A 0 A_JumpIfInventory("PowerStrength",1,8)
    MPNG JK 2
    MPNG L 0 A_PlaySound ("marine/fists", CHAN_WEAPON)
    MPNG L 2 A_CustomPunch (4,0,0,"MFistPuff",60)
    MPNG MN 6
    TNT1 A 4 A_ReFire
    Goto Ready
    MPNG JK 2
    MPNG L 0 A_PlaySound ("marine/fists", CHAN_WEAPON)
    MPNG L 2 A_CustomPunch (27,0,0,"MFistPuff",60)
    MPNG MN 6
    TNT1 A 4 A_ReFire
    Goto Ready
  }
}

// SuperShotGun

actor MSuperShotgun : SuperShotgun replaces SuperShotgun
{
  Weapon.AmmoType "MShell"
  Weapon.AmmoUse2 0
  Weapon.Kickback 700 //added 600
  Weapon.SelectionOrder 1750 //added
  attacksound ""
  Weapon.PreferredSkin "SSGMarine"
  +WEAPON.NOAUTOAIM //added
  -NOEXTREMEDEATH //added
  
  States
  {
 Select:
    SHT2 A 1 ACS_ExecuteAlways(480,0,32,0,0)
	SHT2 A 0 A_PlayWeaponSound("m_db_shotgun_taunt")
 Sel:
    SHT2 A 0
    SHT2 A 1 A_Raise
    Loop
  Ready:
    SHT2 A 1 A_WeaponReady
    SHT2 A 0 A_jumpifinventory("kicking",1,"dokick")
    Loop
  Fire:
    SHT2 A 0 A_JumpIfInventory ("PM_AltFireX",1,"AltFireX")
	SHT2 A 0 A_FireBullets (5, 5, 32, 6, "MBulletPuff")
    SHT2 A 0 A_GunFlash
    SHT2 A 7 A_PlaySound ("weapons/sshotf", CHAN_WEAPON)
	SHT2 A 1 A_SetPitch(-6.0 + pitch)
	SHT2 A 3 
	SHT2 A 1 A_SetPitch(+6.0 + pitch)
    SHT2 B 0 A_CheckReload
	SHT2 BCDEF 2
    SHT2 F 0 A_OpenShotgun2
    SHT2 HUVKL 3
    SHT2 L 0 A_LoadShotgun2
    SHT2 OPQR 2
	SHT2 R 0 A_PlaySound ("weapons/sshotc", CHAN_WEAPON)//A_CloseShotgun2 
    SHT2 RS 3
    SHT2 A 10 //15
    SHT2 A 0 A_ReFire
    Goto Ready
  AltFireX:
	SHT2 A 0 A_FireBullets (3.5, 3.5, 16, 6, "MBulletPuff")
    SHT2 A 0 A_GunFlash
    SHT2 A 7 A_PlaySound ("weapons/sshotf", CHAN_WEAPON)
	SHT2 A 1 A_SetPitch(-6.0 + pitch)
	SHT2 A 3 
	SHT2 A 1 A_SetPitch(+6.0 + pitch)
		SHT2 A 5
	SHT2 A 0 A_FireBullets (3.5, 3.5, 16, 6, "MBulletPuff")
    SHT2 A 0 A_GunFlash
    SHT2 A 7 A_PlaySound ("weapons/sshotf", CHAN_WEAPON)
	SHT2 A 1 A_SetPitch(-6.0 + pitch)
	SHT2 A 3 
	SHT2 A 1 A_SetPitch(+6.0 + pitch)	
    SHT2 B 0 A_CheckReload
	SHT2 BCDEF 2
    SHT2 F 0 A_OpenShotgun2
    SHT2 HUVKL 3
    SHT2 L 0 A_LoadShotgun2
    SHT2 OPQR 2
	SHT2 R 0 A_PlaySound ("weapons/sshotc", CHAN_WEAPON)//A_CloseShotgun2 
    SHT2 RS 3
    SHT2 A 10 //15
    Goto Ready
	
  Flash:
    SHT2 I 4 Bright A_Light1
    SHT2 J 3 Bright A_Light2
    SHT2 I 0 A_Light0
    Stop
  AltFlash:
    SHT2 B 2
    SHT2 C 2
    SHT2 D 2
    SHT2 E 10
    SHT2 D 3
    SHT2 C 3
    SHT2 B 3
    SHT2 A 3
    TNT1 A 0
    Stop
  AltFire:
    SHT2 A 1
    SHT2 A 1 A_JumpIfInventory ("RUnlock2",1,2)
    SHT2 A 1
    Goto Ready
    TNT1 A 4 A_Gunflash
    TNT1 A 0 A_JumpIfInventory("PowerStrength",1,8)
    MPNG JK 2
    MPNG L 0 A_PlaySound ("marine/fists", CHAN_WEAPON)
    MPNG L 2 A_CustomPunch (4,0,0,"MFistPuff",60)
    MPNG MN 6
    TNT1 A 4 A_ReFire
    Goto Ready
    MPNG JK 2
    MPNG L 0 A_PlaySound ("marine/fists", CHAN_WEAPON)
    MPNG L 2 A_CustomPunch (27,0,0,"MFistPuff",60)
    MPNG MN 6
    TNT1 A 4 A_ReFire
    Goto Ready
  AltHold:
    TNT1 A 4 A_Gunflash
    TNT1 A 0 A_JumpIfInventory("PowerStrength",1,8)
    MPNG JK 2
    MPNG L 0 A_PlaySound ("marine/fists", CHAN_WEAPON)
    MPNG L 2 A_CustomPunch (4,0,0,"MFistPuff",60)
    MPNG MN 6
    TNT1 A 4 A_ReFire
    Goto Ready
    MPNG JK 2
    MPNG L 0 A_PlaySound ("marine/fists", CHAN_WEAPON)
    MPNG L 2 A_CustomPunch (27,0,0,"MFistPuff",60)
    MPNG MN 6
    TNT1 A 4 A_ReFire
    Goto Ready
 DoKick:
	TNT1 A 0
        TNT1 A 0 //A_ZoomFactor(1.0)
	TNT1 A 0 A_jumpifinventory("PowerStrength",1,"BerserkerKick")
	TNT1 A 0 A_PlaySound("KICK")
	TNT1 A 0 SetPlayerProperty(0,1,0)
	KICK BCD 1
	RIFF A 0 A_FireCustomMissile("KickAttack", 0, 0, 0, -7)
	KICK H 4
	KICK A 0 A_Takeinventory("Kicking",1)
	KICK IGFEDCBA 1 
	TNT1 A 0 SetPlayerProperty(0,0,0)
	Goto Ready
    BerserkerKick:
	TNT1 A 0 A_PlaySound("KICK")
	TNT1 A 0 SetPlayerProperty(0,1,0)
	KICK ABCDEFG 1
	RIFF A 0 A_FireCustomMissile("SuperKickAttack", 0, 0, 0, -7)
	KICK H 3
	KICK A 0 A_Takeinventory("Kicking",1)
	KICK IGFEDCBA 1 
	TNT1 A 0 SetPlayerProperty(0,0,0)
	Goto Ready

  }
}

// AssaultRifle 

actor AssaultRifle : Weapon 
{
   Weapon.SelectionOrder 600
   Weapon.AmmoUse 1
   Weapon.AmmoUse2 1 
   Weapon.AmmoGive 30
   Weapon.AmmoType "MClip"
   Weapon.AmmoType2 "MClip"
   Weapon.PreferredSkin "AssaultMarine"
   attacksound "weapon/msmgfire"
   Inventory.PickupMessage "$GOTCHAINGUN" // "You got the chaingun"
   Obituary "$OB_MPCHAINGUN" // "%o was mowed down by %k's chaingun."
   //+INVENTORY.UNDROPPABLE
   +WEAPON.NOAUTOAIM //added
   
   States
   {
   Ready:
		MMCG A 0 A_JumpIfInventory ("RUnlock4",1,3)
		MMCG A 1 A_WeaponReady
		MMCG A 0 A_jumpifinventory("kicking",1,"dokick")
        Loop
  	 MMCG A 0 A_JumpIfInventory ("PM_AltFireX",1,"ReadyXZoomOn")
	 MMCG A 0 A_JumpIfInventory ("PM_AltFireY",1,"ReadyYZoomOn") 
     MMCG A 1 A_WeaponReady
     MMCG A 0 A_jumpifinventory("kicking",1,"dokick")
     Loop
	 
   ReadyXZoomOn:
	 MAGS A 1 A_ZoomFactor(1.0)
	 MAGS A 1 A_ZoomFactor(1.2)
	 MAGS A 1 A_ZoomFactor(1.4)
	 MAGS A 1 A_ZoomFactor(1.6)
	 MAGS A 1 A_ZoomFactor(1.8)
	 MAGS A 1 A_ZoomFactor(2.0)
	 MAGS A 1 A_ZoomFactor(2.5)
		MAGS A 0 A_Print("Assault scope - accuracy with 1.6 times damage increase")
     GoTo ReadyXZoomed
   ReadyXZoomed:
	 MAGS A 0 A_ZoomFactor(2.5)
 	 MAGS A 0 A_JumpIfInventory ("PM_ZoomOffX",1,"ReadyXZoomOff")
	 //MAGS A 0 A_JumpIfInventory ("PM_ZoomOffY",1,"ReadyXZoomOff")
	 MAGS A 1 A_WeaponReady
	 GoTo ReadyXZoomed
   ReadyXZoomOff:
	 MAGS A 1 A_ZoomFactor(2.5)
	 MAGS A 1 A_ZoomFactor(2.0)
	 MAGS A 1 A_ZoomFactor(1.8)
	 MAGS A 1 A_ZoomFactor(1.6)
	 MAGS A 1 A_ZoomFactor(1.4)
	 MAGS A 1 A_ZoomFactor(1.2)
	 MAGS A 1 A_ZoomFactor(1.0) 	
     GoTo Ready
 
 ReadyYZoomOn:
	 MAGR A 1 A_ZoomFactor(1.0)
	 MAGR A 1 A_ZoomFactor(1.5)
	 MAGR A 1 A_ZoomFactor(2.0)
	 MAGR A 1 A_ZoomFactor(2.5)
	 MAGR A 1 A_ZoomFactor(3.0)
	 MAGR A 1 A_ZoomFactor(3.5)
	 MAGR A 1 A_ZoomFactor(4.0)
	 MAGR A 1 A_ZoomFactor(4.5)
	 MAGR A 1 A_ZoomFactor(5.0)
		MAGR A 0 A_Print("Sniper scope - high 300-450 HP damage round")
     GoTo ReadyYZoomed
   ReadyYZoomed:
	 MAGR A 0 A_ZoomFactor(5.0)
 	 MAGR A 0 A_JumpIfInventory ("PM_ZoomOffY",1,"ReadyYZoomOff")
	 //MAGR A 0 A_JumpIfInventory ("PM_ZoomOffX",1,"ReadyYZoomOff") 
	 MAGR A 1 A_WeaponReady
	 GoTo ReadyYZoomed
   ReadyYZoomOff:
	 MAGR A 1 A_ZoomFactor(5.0)
	 MAGR A 1 A_ZoomFactor(4.5)
	 MAGR A 1 A_ZoomFactor(4.0)
	 MAGR A 1 A_ZoomFactor(3.5)
	 MAGR A 1 A_ZoomFactor(3.0)
	 MAGR A 1 A_ZoomFactor(2.5)
	 MAGR A 1 A_ZoomFactor(2.0)
	 MAGR A 1 A_ZoomFactor(1.5) 
	 MAGR A 1 A_ZoomFactor(1.0) 
     GoTo Ready
 
   Deselect:
	 MMCG A 0 A_ZoomFactor(1.0) //added
	 	MMCG A 0 A_TakeInventory ("PM_AltFireX",1)
		MMCG A 0 A_TakeInventory ("PM_AltFireY",1)
		MMCG A 0 A_TakeInventory ("PM_ZoomOffX",1)
		MMCG A 0 A_TakeInventory ("PM_ZoomOffY",1)
     MMCG A 1 A_Lower
     Loop
   Select:
     MMCG A 1 ACS_ExecuteAlways(480,0,42,0,0)
	 MMCG A 0 A_PlayWeaponSound("m_assault_msg_taunt")
   Sel:
     MMCG A 0
     MMCG A 1 A_Raise
     Loop
   Fire:
		MMCG A 0 A_JumpIfInventory ("PM_AltFireX",1,"AltFireX")
		MMCG A 0 A_JumpIfInventory ("RUnlock4",1,8)
		MMCG B 0 A_ZoomFactor(1.0)	 
		MMCG B 1 A_GunFlash
			MMCG E 0 A_FireCustomMissile("VulcanTracer", random(-2,2),0,12,-6,0,random(-1,1))
		MMCG E 2 bright A_FireBullets (4.0, 4.0, 1, 9, "MBulletPuff")
		MMCG B 0 A_ReFire
		MMCG BA 2 bright
		Goto Ready
	 MMCG B 0 A_JumpIfInventory ("PM_AltFireY",1,"AltFireY")
	 MMCG B 0 A_JumpIfInventory ("PM_AltFireZ",1,"AltFireZ") 
	 MMCG B 0 A_ZoomFactor(1.0)	 
	 MMCG B 1 A_GunFlash
		MMCG E 0 A_FireCustomMissile("VulcanTracer", random(-2,2),0,12,-6,0,random(-1,1))
	 MMCG E 2 bright A_FireBullets (4.0, 4.0, 1, 9, "MBulletPuff")
	 MMCG B 0 A_ReFire
	 MMCG BA 2 bright
	 Goto Ready
   AltFireX:
	 MAGS A 0 A_ZoomFactor(2.5)
   	 MAGS A 1 A_GunFlash
		MAGS A 0 A_FireCustomMissile("VulcanTracer", random(-2,2),0,12,-6,0,random(-1,1))
	 MAGS A 1 bright A_FireBullets (1.2, 1.2, 1, 15, "MBulletPuff") //added 3.3 12 to 15
	 MAGS A 0 A_SetPitch(-0.5 + pitch)
	 MAGS A 1
	 MAGS A 0 A_SetPitch(0.5 + pitch)
	 MAGS A 0 A_ReFire
	 MAGS AA 2 bright
	 Goto ReadyXZoomed
   AltFireY:
	 MAGR A 0 A_ZoomFactor(5.0)
   	 MAGR A 0 A_GunFlash
	 MAGR A 0 A_PlaySound ("SniperAssaultRifleShootCSAWP", CHAN_AUTO, ATTN_NORM)
		MAGR A 0 A_FireCustomMissile("AssaultRifleTracerRico", random(-2,2),0,12,-6,0,random(-1,1))
	 MAGR A 0 bright A_FireBullets (0.5, 0.5, -1, random(300,450), "MBulletPuffAssaultRifle", FBF_NORANDOM)
	 MAGR A 3 A_SetPitch(-4.0 + pitch)
	 MAGR A 1
	 MAGR A 3 A_SetPitch(4.0 + pitch)
	 MAGR A 10
	 MAGR A 15 A_PlaySound ("SniperAssaultRifleReload", CHAN_AUTO, ATTN_NORM)
	 MAGR A 20
	 MAGR A 0 A_ReFire
	 MAGR AA 2 bright
	 Goto ReadyYZoomed
   AltFireZ:
     MMCG A 0 A_ZoomFactor(1.0) 
	 MMCG A 1 A_JumpIfInventory ("RUnlock4",1,1)
	 Goto Ready
		MMCG A 0 A_TakeInventory ("PM_AltFireX",1)
		MMCG A 0 A_TakeInventory ("PM_AltFireY",1)
		MMCG A 0 A_TakeInventory ("PM_ZoomOffX",1)
		MMCG A 0 A_TakeInventory ("PM_ZoomOffY",1)
		MMCG A 0 A_PlaySoundEx ("weapons/mgren","weapon")
		MMCG A 0 A_FireCustomMissile ("MGrenade",5,1,0,0,0,9) //12
		MMCG A 1 A_SetPitch(-8.0 + pitch)
		MMCG A 3
		MMCG A 1 A_SetPitch(+8.0 + pitch)
		MMCG A 10
		MMCG A 10 A_PlaySound("weapons/Ashotgun/cock/back")
		MMCG A 6
		MMCG A 4 A_PlaySound("weapons/Ashotgun/cock/forward")
		MMCG A 20
	 Goto Ready	 

   AltFire:
     MMCG A 0 A_ZoomFactor(1.0) 
	 MMCG A 1 A_JumpIfInventory ("RUnlock4",1,1)
	 Goto Ready
		MMCG A 0 A_TakeInventory ("PM_AltFireX",1)
		MMCG A 0 A_TakeInventory ("PM_AltFireY",1)
		MMCG A 0 A_TakeInventory ("PM_ZoomOffX",1)
		MMCG A 0 A_TakeInventory ("PM_ZoomOffY",1)
	 MMCG B 1 A_GunFlash
		MMCG E 0 A_FireCustomMissile("AssaultRifleTracerRico", random(-2,2),0,12,-6,0,random(-1,1))
	 MMCG E 1 bright A_FireBullets (3.0, 3.0, -1, 27, "MBulletPuffAssaultRifle")
	 	MMCG E 1 A_SetPitch(-0.5 + pitch)
	 MMCG E 0 A_JumpIfInventory ("MClip",1,2)
	 CHGG B 1 A_Jump (256, 14) //11
	 MMCG B 1 A_GunFlash
		MMCG E 0 A_FireCustomMissile("AssaultRifleTracerRico", random(-2,2),0,12,-6,0,random(-1,1))
	 MMCG E 1 bright A_FireBullets (3.0, 3.0, -1, 27, "MBulletPuffAssaultRifle")
	 	MMCG E 1 A_SetPitch(-0.5 + pitch)
	 MMCG E 0 A_JumpIfInventory ("MClip",1,2)
	 CHGG B 1 A_Jump (256, 9) //7
	 MMCG B 1 A_GunFlash
		MMCG E 0 A_FireCustomMissile("AssaultRifleTracerRico", random(-2,2),0,12,-6,0,random(-1,1))
	 MMCG E 1 bright A_FireBullets (3.0, 3.0, -1, 27, "MBulletPuffAssaultRifle")
	 	MMCG E 1 A_SetPitch(-0.5 + pitch)
	 MMCG E 0 A_JumpIfInventory ("MClip",1,2)
	 CHGG B 1 A_Jump (256, 4) //3
	 MMCG B 1 A_GunFlash
		MMCG E 0 A_FireCustomMissile("AssaultRifleTracerRico", random(-2,2),0,12,-6,0,random(-1,1))
	 MMCG E 1 bright A_FireBullets (3.0, 3.0, -1, 27, "MBulletPuffAssaultRifle")
	 	MMCG E 1 A_SetPitch(-0.5 + pitch)
		MMCG E 1 A_SetPitch(+2.0 + pitch)
	 MMCG B 5 bright
	 MMCG B 4
	 MMCG A 8
	 MMCG A 0 A_CheckReload
	 Goto Ready	 
 DoKick:
	TNT1 A 0
        TNT1 A 0 //A_ZoomFactor(1.0)
	TNT1 A 0 A_jumpifinventory("PowerStrength",1,"BerserkerKick")
	TNT1 A 0 A_PlaySound("KICK")
	TNT1 A 0 SetPlayerProperty(0,1,0)
	KICK BCD 1
	RIFF A 0 A_FireCustomMissile("KickAttack", 0, 0, 0, -7)
	KICK H 4
	KICK A 0 A_Takeinventory("Kicking",1)
	KICK IGFEDCBA 1 
	TNT1 A 0 SetPlayerProperty(0,0,0)
	Goto Ready
    BerserkerKick:
	TNT1 A 0 A_PlaySound("KICK")
	TNT1 A 0 SetPlayerProperty(0,1,0)
	KICK ABCDEFG 1
	RIFF A 0 A_FireCustomMissile("SuperKickAttack", 0, 0, 0, -7)
	KICK H 3
	KICK A 0 A_Takeinventory("Kicking",1)
	KICK IGFEDCBA 1 
	TNT1 A 0 SetPlayerProperty(0,0,0)
	Goto Ready
  Flash:
	TNT1 A 1 BRIGHT A_Light1
	TNT1 A 2 BRIGHT A_Light2
	TNT1 A 2 BRIGHT A_Light1
	TNT1 A 0 A_Light0
	Stop
  AltFlash:
	TNT1 A 1 BRIGHT A_Light1
	TNT1 A 2 BRIGHT A_Light2
	TNT1 A 3 BRIGHT A_Light1
	TNT1 A 0 A_Light0
	Stop
  Spawn:
    MCG1 X -1
    Stop
    //TNT1 A 1 Thing_Remove(0)
    //Stop
   }
}



// ChainGun

actor MChaingun : Chaingun replaces Chaingun
{
   Weapon.AmmoType "MClip"
   Weapon.AmmoUse2 1 
   Weapon.AmmoType2 "MClip"
   Weapon.PreferredSkin "ChainGunMarine"
   Weapon.AmmoGive 40
   +WEAPON.NOAUTOAIM //added
   attacksound "weapon/VulcanFire" //added
   
   States
   {
   Ready:
     CHGG A 1 A_WeaponReady
     CHGG A 0 A_jumpifinventory("kicking",1,"dokick")
     Loop
   Select:
     CHGG A 1 ACS_ExecuteAlways(480,0,4,0,0)
	 CHGG A 0 A_PlayWeaponSound("m_vulcan_taunt")
   Sel:
     CHGG A 0 
     CHGG A 1 A_Raise
     Loop
   Deselect: 
	 CHGG A 0 A_TakeInventory("Mspinch",5)
	 CHGG A 1 A_Lower
	 Loop
   Fire:
	 CHGG A 0 A_Gunflash
	 CHGG A 2
		CHGG B 0 A_FireCustomMissile("VulcanTracer", random(-2,2),0,12,-6,0,random(-1,1))
	 CHGG B 2 A_FireBullets (3, 3, 1, 6, "MBulletPuff")
	 CHGG C 2
		CHGG D 0 A_FireCustomMissile("VulcanTracer", random(-2,2),0,12,-6,0,random(-1,1))
	 CHGG D 2 A_FireBullets (3, 3, 1, 6, "MBulletPuff")
	 CHGG A 0 A_ReFire
	 CHGG ABCD 2
	 CHGG ABCD 3 A_ReFire
	 CHGG ABCD 4 A_ReFire
         Goto Ready
   AltFire:
	 CHGG A 0 A_JumpIfInventory ("Mspinch3",0,14)
	 CHGG A 0 A_JumpIfInventory ("Mspinch3",4,8)
	 CHGG A 0 A_JumpIfInventory ("Mspinch3",3,7)
	 CHGG A 0 A_JumpIfInventory ("Mspinch3",2,4)
	 CHGG A 0 A_JumpIfInventory ("Mspinch3",1,3)
	 CHGG AB 3
	 CHGG CD 3
	 CHGG AB 2
	 CHGG CD 1
	 CHGG A 0 A_GiveInventory("Mspinch3",5)
	 CHGG A 0 A_Gunflash
	 CHGG A 1
		CHGG B 0 A_FireCustomMissile("VulcanTracer", random(-2,2),0,12,-6,0,random(-1,1))
	 CHGG B 1 A_FireBullets (6, 6, -1, 6, "MBulletPuff") //spread 8.2
	 CHGG C 1
		CHGG D 0 A_FireCustomMissile("VulcanTracer", random(-2,2),0,12,-6,0,random(-1,1))
	 CHGG D 1 A_FireBullets (6, 6, -1, 6, "MBulletPuff") //spread 8.2
	 CHGG A 0 A_ReFire
	 CHGG AB 1
	 CHGG CD 1 A_ReFire
	 CHGG AB 2 A_ReFire
	 CHGG A 0 A_TakeInventory("Mspinch3",1)
	 CHGG CD 2 A_ReFire
	 CHGG A 0 A_TakeInventory("Mspinch3",1)
	 CHGG AB 3 A_ReFire
	 CHGG A 0 A_TakeInventory("Mspinch3",1)
	 CHGG CD 3 A_ReFire
	 CHGG A 0 A_TakeInventory("Mspinch3",1)
	 CHGG AB 4 A_ReFire
	 CHGG A 0 A_TakeInventory("Mspinch3",5)
	 CHGG CD 4 A_ReFire
         Goto Ready
 DoKick:
	TNT1 A 0
        TNT1 A 0 //A_ZoomFactor(1.0)
	TNT1 A 0 A_jumpifinventory("PowerStrength",1,"BerserkerKick")
	TNT1 A 0 A_PlaySound("KICK")
	TNT1 A 0 SetPlayerProperty(0,1,0)
	KICK BCD 1
	RIFF A 0 A_FireCustomMissile("KickAttack", 0, 0, 0, -7)
	KICK H 4
	KICK A 0 A_Takeinventory("Kicking",1)
	KICK IGFEDCBA 1 
	TNT1 A 0 SetPlayerProperty(0,0,0)
	Goto Ready
    BerserkerKick:
	TNT1 A 0 A_PlaySound("KICK")
	TNT1 A 0 SetPlayerProperty(0,1,0)
	KICK ABCDEFG 1
	RIFF A 0 A_FireCustomMissile("SuperKickAttack", 0, 0, 0, -7)
	KICK H 3
	KICK A 0 A_Takeinventory("Kicking",1)
	KICK IGFEDCBA 1 
	TNT1 A 0 SetPlayerProperty(0,0,0)
	Goto Ready
   Flash: 
	 CHGF A 2 bright A_Light1
	 TNT1 A 2 A_Light2
	 CHGF B 2 bright A_Light1
	 TNT1 A 2 A_Light2
	 TNT1 A 0 A_Light0
	 Stop
   AltFlash: 
	 CHGF A 1 bright A_Light1
	 CHGF A 1 bright A_Light2
	 CHGF B 1 bright A_Light1
	 TNT1 A 1 A_Light2
	 TNT1 A 0 A_Light0
	 Stop
   }
}

// Rocket Launcher

actor MRocketLauncher : RocketLauncher replaces RocketLauncher
{
  Weapon.Selectionorder 1800 //2400
  Weapon.AmmoType "MRocketAmmo"
  Weapon.AmmoType2 "MRocketAmmo"
  Weapon.Kickback 150 //added
  Weapon.AmmoUse2 1
  Weapon.PreferredSkin "RLMarine"
  +WEAPON.NOAUTOAIM
  States
  {
  Ready:
    MISG A 1 A_WeaponReady
    MISG A 0 A_jumpifinventory("kicking",1,"dokick")
    Loop
  Fire:
		MISG A 0 A_JumpIfInventory ("Mrank6",1,3) //avoid weapon without any firing
	MISG A 0 A_JumpIfInventory ("PM_AltFireX",1,"AltFireX")	
	MISG A 0 A_JumpIfInventory ("PM_AltFireY",1,"AltFireY")
	MISG A 0 A_JumpIfInventory ("PM_AltFireZ",1,"AltFireZ")
    MISG B 8 A_GunFlash
    MISG B 2 bright A_FireCustomMissile ("MMarineRocket")
	MISG B 2 bright
	MISG B 2 bright
	MISG B 2 bright
	MISG B 2 bright
	MISG B 2 bright
    MISG B 0 A_ReFire
    Goto Ready
  AltFire:
		MISG A 0 A_JumpIfInventory ("RUnlock3",1,1)
		Goto Ready
    MISG B 8 A_GunFlash
    MISG B 0 A_PlaySoundEx ("weapons/mgren","weapon")
    MISG B 2 A_FireCustomMissile ("MGrenade",0,1,0,0,0,9) //12
	MISG B 2
	MISG B 2
	MISG B 2
	MISG B 2
    MISG B 0 A_ReFire
    Goto Ready
	
  AltFireX:
		MISG A 0 A_JumpIfInventory ("RUnlock3",1,1)
		Goto Ready
	MISG B 8 A_GunFlash
    MISG B 3 bright A_FireCustomMissile ("MMarineFastRocketX",random(-3,3),1,random(-3,3),random(-3,3),0,0)
	MISG A 2 bright
	MISG B 3 bright A_FireCustomMissile ("MMarineFastRocketX",random(-3,3),1,random(-3,3),random(-3,3),0,0)
	MISG A 2 bright
	MISG B 3 bright A_FireCustomMissile ("MMarineFastRocketX",random(-3,3),1,random(-3,3),random(-3,3),0,0)
	MISG B 2 bright
	MISG B 2 bright
	MISG B 16 bright //7
    MISG B 0 A_ReFire
    Goto Ready	
  AltFireY:
		MISG A 0 A_JumpIfInventory ("RUnlock3",1,1)
		Goto Ready
		//MISG A 0 A_JumpIfInventory("MRocketLauncherAltFireY_counter",40,"AltFireYOverheat")
	MISG B 8 A_GunFlash
    MISG B 2 bright A_FireCustomMissile ("MMarineHomingRocketY")
		//MISG B 0 A_GiveInventory("MRocketLauncherAltFireY_counter",1)
	MISG B 2 bright
	MISG B 2 bright
	MISG B 2 bright
	MISG B 2 bright
	MISG B 20 bright
    MISG B 0 A_ReFire
    Goto Ready
  AltFireZ:
		MISG A 0 A_JumpIfInventory ("RUnlock3",1,1)
		Goto Ready
	MISG B 8 A_GunFlash
    MISG B 2 bright A_FireCustomMissile ("MMarineBlastRocketZ")
	MISG B 2 bright
	MISG B 2 bright
	MISG B 2 bright
	MISG B 2 bright
	MISG B 65 bright
    MISG B 0 A_ReFire
    Goto Ready
	
 Select:
    MISG A 1 ACS_ExecuteAlways(480,0,5,0,0)
	MISG A 0 A_PlayWeaponSound("m_rocket_taunt")
 Sel:
    MISG A 0 
    MISG A 1 A_Raise
    LOOP
 DoKick:
	TNT1 A 0
        TNT1 A 0 //A_ZoomFactor(1.0)
	TNT1 A 0 A_jumpifinventory("PowerStrength",1,"BerserkerKick")
	TNT1 A 0 A_PlaySound("KICK")
	TNT1 A 0 SetPlayerProperty(0,1,0)
	KICK BCD 1
	RIFF A 0 A_FireCustomMissile("KickAttack", 0, 0, 0, -7)
	KICK H 4
	KICK A 0 A_Takeinventory("Kicking",1)
	KICK IGFEDCBA 1 
	TNT1 A 0 SetPlayerProperty(0,0,0)
	Goto Ready
    BerserkerKick:
	TNT1 A 0 A_PlaySound("KICK")
	TNT1 A 0 SetPlayerProperty(0,1,0)
	KICK ABCDEFG 1
	RIFF A 0 A_FireCustomMissile("SuperKickAttack", 0, 0, 0, -7)
	KICK H 3
	KICK A 0 A_Takeinventory("Kicking",1)
	KICK IGFEDCBA 1 
	TNT1 A 0 SetPlayerProperty(0,0,0)
	Goto Ready
  Flash:
    MISF A 3 Bright A_Light1
    MISF B 4 Bright
    MISF CD 4 Bright A_Light2
    MISF A 0 A_Light0
    Stop
  AltFlash:
    MISF A 3 Bright A_Light1
    MISF B 4 Bright
    MISF CD 4 Bright A_Light2
    MISF A 0 A_Light0
    Stop
  //AltFireYOverheat:
	//MISG A 1 A_Print("RocketLauncher AltFireY overheat (40 rockets), cooldown")
	//MISG A 0 A_TakeInventory("PM_AltFireX",1)
	//MISG A 0 A_TakeInventory("PM_AltFireY",1)
	//MISG A 0 A_TakeInventory("PM_AltFireZ",1)
	//goto Ready
  }
}






ACTOR MMarineFastRocketX
{
   Radius 8
   Height 11
   Speed 85 //18
   Damage 15
   PROJECTILE
   DeathSound "weapons/hrlexp"
   ExplosionDamage 64 //96 //56
   ExplosionRadius 192
   +Rockettrail
   +RANDOMIZE
   +DEHEXPLOSION
   Damagetype "MarineRLDamage"
   -NOTELEPORT //added
   +TELESTOMP //added
   SeeSound "weapons/hrlfir"
   Decal Scorch
   States
   {
   Spawn:
      HMIS A 4 Bright A_SeekerMissile(0,0,0,0)
      HMIS A 4 Bright
      goto Spawn
   Death:
      MISL B 8 bright A_Explode(64,192)
      MISL C 6 bright
      MISL D 4 bright
      stop
   }
}



ACTOR MMarineHomingRocketY
{
   Radius 8
   Height 11
   Speed 12 //18
   Damage 15
   PROJECTILE
   DeathSound "weapons/hrlexp"
   ExplosionDamage 160
   ExplosionRadius 160
   +SeekerMissile
   +SCREENSEEKER
   +Rockettrail
   +RANDOMIZE
   +DEHEXPLOSION
   Damagetype "MarineRLDamage"
   -NOTELEPORT //added
   +TELESTOMP //added
   SeeSound "weapons/hrlfir"
   Decal Scorch
   
   BounceCount 3 //added 3.0.1
   +CANBOUNCEWATER //added 3.0.1
   +DOOMBOUNCE //added 3.0.1
   +NOBOUNCESOUND //added 3.0.1
   +NOWALLBOUNCESND //added 3.0.1
   
   States
   {
   Spawn:
      HMIS A 4 Bright A_SeekerMissile(30,60,SMF_PRECISE||SMF_LOOK,256,10) //45,90 //SMF_LOOK removed // range 10-20 3.0.1
      HMIS A 4 Bright
      goto Spawn
   Death:
      MISL B 8 bright A_Explode(160,160)
      MISL C 6 bright
      MISL D 4 bright
      stop
   }
}


ACTOR MMarineBlastRocketZ
{
   Radius 8
   Height 11
   Speed 15 //18
   Damage 15
   PROJECTILE
   DeathSound "weapons/hrlexp"
   ExplosionDamage 50
   ExplosionRadius 50
   //+SeekerMissile
   //+SCREENSEEKER
   +Rockettrail
   +RANDOMIZE
   +DEHEXPLOSION
   Damagetype "MarineRLDamage"
   -NOTELEPORT //added
   +TELESTOMP //added
   
   SeeSound "weapons/hrlfir"
   Decal Scorch
   
   //BounceCount 3 //added 3.0.1
   //+CANBOUNCEWATER //added 3.0.1
   //+DOOMBOUNCE //added 3.0.1
   //+NOBOUNCESOUND //added 3.0.1
   //+NOWALLBOUNCESND //added 3.0.1
   
   States
   {
   Spawn:
      HMIS A 4 Bright A_SeekerMissile(30,60) //45,90 //SMF_LOOK removed // range 10-20 3.0.1
      HMIS A 4 Bright
      goto Spawn
   Death:
      TNT1 A 1 A_SpawnItemEx("BFGGravityWaveShieldIluminate",0,0,0,0,0,0,0,SXF_TRANSFERPOINTERS,0)
	  TNT1 A 1 bright A_Explode(50,50)
	 TNT1 A 1 A_SpawnItemEx ("MMarineBlastRocketZCracker",0,0,0,0,0,0,0,SXF_TRANSFERPOINTERS,0)
	  TNT1 A 1 A_SpawnItemEx ("MMarineBlastRocketZCracker",24,0,0,0,0,0,0,SXF_TRANSFERPOINTERS,0)
	  TNT1 A 1 A_SpawnItemEx ("MMarineBlastRocketZCracker",-24,0,0,0,0,0,0,SXF_TRANSFERPOINTERS,0)
	  TNT1 A 1 A_SpawnItemEx ("MMarineBlastRocketZCracker",0,24,0,0,0,0,0,SXF_TRANSFERPOINTERS,0)
	  TNT1 A 1 A_SpawnItemEx ("MMarineBlastRocketZCracker",0,-24,0,0,0,0,0,SXF_TRANSFERPOINTERS,0)
		TNT1 A 1 A_SpawnItemEx ("MMarineBlastRocketZCracker",24,12,0,0,0,0,0,SXF_TRANSFERPOINTERS,0)
		TNT1 A 1 A_SpawnItemEx ("MMarineBlastRocketZCracker",-24,-12,0,0,0,0,0,SXF_TRANSFERPOINTERS,0)
		TNT1 A 1 A_SpawnItemEx ("MMarineBlastRocketZCracker",12,24,0,0,0,0,0,SXF_TRANSFERPOINTERS,0)
		TNT1 A 1 A_SpawnItemEx ("MMarineBlastRocketZCracker",-12,-24,0,0,0,0,0,SXF_TRANSFERPOINTERS,0)
			TNT1 A 1 A_SpawnItemEx ("MMarineBlastRocketZCracker",0,48,0,0,0,0,0,SXF_TRANSFERPOINTERS,0)
			TNT1 A 1 A_SpawnItemEx ("MMarineBlastRocketZCracker",48,0,0,0,0,0,0,SXF_TRANSFERPOINTERS,0)
			TNT1 A 1 A_SpawnItemEx ("MMarineBlastRocketZCracker",-48,0,0,0,0,0,0,SXF_TRANSFERPOINTERS,0)
			TNT1 A 1 A_SpawnItemEx ("MMarineBlastRocketZCracker",0,-48,0,0,0,0,0,SXF_TRANSFERPOINTERS,0)
				TNT1 A 1 A_SpawnItemEx ("MMarineBlastRocketZCracker",0,96,0,0,0,0,0,SXF_TRANSFERPOINTERS,0)
				TNT1 A 1 A_SpawnItemEx ("MMarineBlastRocketZCracker",96,0,0,0,0,0,0,SXF_TRANSFERPOINTERS,0)
				TNT1 A 1 A_SpawnItemEx ("MMarineBlastRocketZCracker",-96,0,0,0,0,0,0,SXF_TRANSFERPOINTERS,0)
				TNT1 A 1 A_SpawnItemEx ("MMarineBlastRocketZCracker",0,-96,0,0,0,0,0,SXF_TRANSFERPOINTERS,0)
				TNT1 A 1 A_SpawnItemEx ("MMarineBlastRocketZCracker",96,96,0,0,0,0,0,SXF_TRANSFERPOINTERS,0)
				TNT1 A 1 A_SpawnItemEx ("MMarineBlastRocketZCracker",-96,-96,0,0,0,0,0,SXF_TRANSFERPOINTERS,0)
					TNT1 A 1 A_SpawnItemEx ("MMarineBlastRocketZCracker",96,56,0,0,0,0,0,SXF_TRANSFERPOINTERS,0)
					TNT1 A 1 A_SpawnItemEx ("MMarineBlastRocketZCracker",56,96,0,0,0,0,0,SXF_TRANSFERPOINTERS,0)
					TNT1 A 1 A_SpawnItemEx ("MMarineBlastRocketZCracker",-96,-56,0,0,0,0,0,SXF_TRANSFERPOINTERS,0)
					TNT1 A 1 A_SpawnItemEx ("MMarineBlastRocketZCracker",-56,-96,0,0,0,0,0,SXF_TRANSFERPOINTERS,0)
      stop
   }
}


actor MMarineBlastRocketZCracker
{
  radius 4
  height 1
  speed 0
  damage 1
  alpha 1
  DamageType "MarineRLDamage"
  renderstyle add
  PROJECTILE
  +NOBLOCKMAP
  +NOGRAVITY
  +FLOORCLIP //added 4.3
  -BLOODLESSIMPACT
  +RIPPER
  states
  {
  Spawn:
    TNT1 A 1 A_Fire 
	GoTo Death
  Death:
    FIRE A 1 bright A_StartFire
    FIRE BAB 1 bright A_Fire
    FIRE C 1 bright A_FireCrackle
    FIRE BCBCDCDCDEDED 1 bright A_Fire
  
	FIRE A 1 bright A_StartFire
    FIRE BAB 1 bright A_Fire
    FIRE C 1 bright A_FireCrackle
    FIRE BCBCDCDCDEDED 1 bright A_Fire

	FIRE A 1 bright A_StartFire
    FIRE BAB 1 bright A_Fire
    FIRE C 1 bright A_FireCrackle
    FIRE BCBCDCDCDEDED 1 bright A_Fire
   
	FIRE A 1 bright A_StartFire
    FIRE BAB 1 bright A_Fire
    FIRE C 1 bright A_FireCrackle
    FIRE BCBCDCDCDEDED 1 bright A_Fire
    FIRE E 1 bright A_FireCrackle
    FIRE FEFEFGHGHGH 1 bright A_Fire
    stop
  }
}







actor MMarineRocket : Rocket
{
 DamageType "MarineRLDamage"
 -NOTELEPORT //added
 +TELESTOMP //added
}

ACTOR MGrenade : Grenade
{
	Radius 8
	Height 8
	Speed 25
	Damage 20
	Projectile
	BounceCount 9
	Scale 1.5
	-NOGRAVITY
	-NOTELEPORT
	+TELESTOMP //added
	+CANBOUNCEWATER //added
	+DOOMBOUNCE
	+DEHEXPLOSION
	+ROCKETTRAIL
	//+GRENADETRAIL
	+EXPLODEONDEATH
	+USESTBOUNCESOUND
	SeeSound "weapons/mgrenbounce"
	DeathSound "weapon/grenadeexplode" //weapons/rocklx
	Obituary "$OB_GRENADE"
	DamageType "MarineRLDamage"
	States
	{
	Spawn:
		GRN2 ABCDEFGHIJK 3  
		loop
	Death:
		MISL B 8 bright A_Explode
		MISL C 6 bright
		MISL D 4 bright
		stop
	}

}


actor remover : rocket
{
states
{
death:
    MISL B 8 A_takefromtarget("ArachnotronClass",1)
    MISL B 8 A_takefromtarget("ArachGunnerClass",1)
    MISL B 8 A_takefromtarget("ArchvileClass",1)
    MISL B 8 A_takefromtarget("BaronOfHellClass",1)
    MISL B 8 A_takefromtarget("BelphegorClass",1)
    MISL B 8 A_takefromtarget("CacodemonClass",1)
    MISL B 8 A_takefromtarget("CacoLanternClass",1)
    MISL B 8 A_takefromtarget("AbaddonClass",1)
    MISL B 8 A_takefromtarget("ChainGunGuyClass",1)
    MISL B 8 A_takefromtarget("ChainGunGuy2Class",1)
    MISL B 8 A_takefromtarget("CyberdemonClass",1)
    MISL B 8 A_takefromtarget("CyberAnniClass",1)
    MISL B 8 A_takefromtarget("DemonClass",1)
    MISL B 8 A_takefromtarget("BloodDemonClass",1)
    MISL B 8 A_takefromtarget("DooMImpClass",1)
    MISL B 8 A_takefromtarget("DarkImpClass",1)
    MISL B 8 A_takefromtarget("ShadowClass",1)
    MISL B 8 A_takefromtarget("SoulHarvesterclass",1)
    MISL B 8 A_takefromtarget("FatsoClass",1)
    MISL B 8 A_takefromtarget("HectebusClass",1)
    MISL B 8 A_takefromtarget("FMarineFistClass",1)
    MISL B 8 A_takefromtarget("HellKnightClass",1)
    MISL B 8 A_takefromtarget("LostSoulClass",1)
    MISL B 8 A_takefromtarget("MasterMindClass",1)
    MISL B 8 A_takefromtarget("PainElementalClass",1)
    MISL B 8 A_takefromtarget("RevenantClass",1)
    MISL B 8 A_takefromtarget("ShotgunGuyClass",1)
    MISL B 8 A_takefromtarget("SSgZombieClass",1)
    MISL B 8 A_takefromtarget("AShotgunGuyClass",1)
    MISL B 8 A_takefromtarget("SpectreClass",1)
    MISL B 8 A_takefromtarget("WolfensteinSSClass",1)
    MISL B 8 A_takefromtarget("ZombieManClass",1)
    MISL B 8 A_takefromtarget("ChainsawZombieClass",1)
    MISL B 8 A_takefromtarget("PlasmaZombieClass",1)

}}






// PlasmaRifle

actor MPlasmaRifle : PlasmaRifle replaces PlasmaRifle
{
  Weapon.PreferredSkin "PlsmMarine"
  Weapon.AmmoType "MCell"
  Weapon.AmmoType2 "MCell"
  Weapon.AmmoUse2 1
  Weapon.SelectionOrder 1700 //added
  +WEAPON.NOAUTOAIM //added
  
  States
  {
  Ready:
    PLSG A 1 A_WeaponReady
    PLSG A 0  A_jumpifinventory("kicking",1,"dokick")
    Loop
 Select:
	PLSG A 1 ACS_ExecuteAlways(480,0,6,0,0) 
	PLSG A 0 A_PlayWeaponSound("m_tesla_taunt")
 Sel:
    PLSG A 0 
    PLSG A 1 A_Raise
    LOOP
  Fire:	
		PLSG A 0 A_JumpIfInventory ("PM_AltFireX",1,"AltFireX")	
		PLSG A 0 A_JumpIfInventory ("PM_AltFireY",1,"AltFireY")
		PLSG A 0 A_JumpIfInventory ("PM_AltFireZ",1,"AltFireZ")
		PLSG A 0 A_JumpIfInventory ("RUnlock5",1,"FirePowered") //speedy primary fire
    PLSG A 1 A_GunFlash
    PLSG A 2 A_FireCustomMissile ("MPlasmaBall",random(-1,1),1,0,0,0) //2
    PLSG B 0 A_ReFire
    PLSG BCDE 4
    PLSG F 8
    PLSG EDCB 2
    Goto Ready
  FirePowered:
  	PLSG A 1 A_GunFlash
	PLSG A 1 A_FireCustomMissile ("MPlasmaBall",random(-1,1),1,0,0,0) //2
	PLSG B 0 A_ReFire
	PLSG BCDE 4
	PLSG F 8
	PLSG EDCB 2
	Goto Ready
  AltFire:
		PLSG A 0 A_JumpIfInventory ("RUnlock5",1,1)
		Goto Ready
		PLSG A 0 A_JumpIfInventory ("MCell",10,1)
		Goto Ready
    PLSG A 6
    PLSG A 1 A_GunFlash
	   PLSG A 1 A_FireCustomMissile ("MPlasmaBall",0,1,0,0,0)
	   PLSG A 0 A_FireCustomMissile ("MPlasmaBall",-2,1,0,0,0)
	   PLSG A 0 A_FireCustomMissile ("MPlasmaBall",2,1,0,0,0)
	   PLSG A 1	   
	   PLSG A 0 A_FireCustomMissile ("MPlasmaBall",-4,1,0,0,0)
	   PLSG A 0 A_FireCustomMissile ("MPlasmaBall",4,1,0,0,0)
	   PLSG A 1  
	   PLSG A 0 A_FireCustomMissile ("MPlasmaBall",-5,1,0,0,0)
	   PLSG A 0 A_FireCustomMissile ("MPlasmaBall",5,1,0,0,0)
	   PLSG A 1
	   PLSG A 0 A_FireCustomMissile ("MPlasmaBall",-8,1,0,0,0)
	   PLSG A 0 A_FireCustomMissile ("MPlasmaBall",8,1,0,0,0)  
	   PLSG A 1
	   PLSG A 0 A_FireCustomMissile ("MPlasmaBall",-10,1,0,0,0)
	   PLSG A 0 A_FireCustomMissile ("MPlasmaBall",10,1,0,0,0) 
    PLSG B 0 A_ReFire
    PLSG BCDE 4
    PLSG F 8
    PLSG EDCB 2
    Goto Ready
	
 AltFireX:
		PLSG A 0 A_JumpIfInventory ("RUnlock5",1,13)
		    PLSG A 1 A_GunFlash
			PLSG A 2 A_FireCustomMissile ("MPlasmaBall",random(-1,1),1,0,0,0) //2
			PLSG B 0 A_ReFire
			PLSG BCDE 4
			PLSG F 8
			PLSG EDCB 2
			Goto Ready
   	PLSG A 1 A_GunFlash
	PLSG A 2 A_FireCustomMissile ("MPlasmaBallFast",random(-1,1),1,0,0,0) //2
	PLSG B 0 A_ReFire
	PLSG BCDE 4
	PLSG F 8
	PLSG EDCB 2
	Goto Ready
 AltFireY:
	//PLSG A 0 A_JumpIfInventory ("MPlasmaRifleAltFireY_counter",350,"AltFireYOverheat")
		PLSG A 0 A_JumpIfInventory ("RUnlock5",1,13)
		    PLSG A 1 A_GunFlash
			PLSG A 2 A_FireCustomMissile ("MPlasmaBall",random(-1,1),1,0,0,0) //2
			PLSG B 0 A_ReFire
			PLSG BCDE 4
			PLSG F 8
			PLSG EDCB 2
			Goto Ready
	PLSG A 1 A_GunFlash
	PLSG A 3 A_FireCustomMissile ("MPlasmaBallHoming",random(-1,1),1,0,0,0) //2
	//PLSG A 0 A_GiveInventory("MPlasmaRifleAltFireY_counter",1)
	PLSG B 0 A_ReFire
	PLSG BCDE 4
	PLSG F 8
	PLSG EDCB 2
	Goto Ready
 AltFireZ:
 		PLSG A 0 A_JumpIfInventory ("RUnlock5",1,13)
		    PLSG A 1 A_GunFlash
			PLSG A 2 A_FireCustomMissile ("MPlasmaBall",random(-1,1),1,0,0,0) //2
			PLSG B 0 A_ReFire
			PLSG BCDE 4
			PLSG F 8
			PLSG EDCB 2
			Goto Ready
	PLSG A 1 A_GunFlash
	PLSG A 35 A_PlaySound("weapons/PlasmaAltZFire", CHAN_WEAPON, 1, 0, ATTN_NORM)
	PLSG A 1 A_GunFlash
		PLSG A 1 A_FireCustomMissile ("MPlasmaBallRipper",0,1,0,0,0) //2
		PLSG A 1 A_FireCustomMissile ("MPlasmaBallRipper",0,1,0,0,0) //2
		PLSG A 1 A_FireCustomMissile ("MPlasmaBallRipper",0,1,0,0,0) //2
		PLSG A 1 A_FireCustomMissile ("MPlasmaBallRipper",0,1,0,0,0) //2
		PLSG A 1 A_FireCustomMissile ("MPlasmaBallRipper",0,1,0,0,0) //2
		PLSG A 1 A_FireCustomMissile ("MPlasmaBallRipper",0,1,0,0,0) //2
		PLSG A 1 A_FireCustomMissile ("MPlasmaBallRipper",0,1,0,0,0) //2
		PLSG A 1 A_FireCustomMissile ("MPlasmaBallRipper",0,1,0,0,0) //2
		PLSG A 1 A_FireCustomMissile ("MPlasmaBallRipper",0,1,0,0,0) //2
		PLSG A 1 A_FireCustomMissile ("MPlasmaBallRipper",0,1,0,0,0) //2
		//PLSG A 1 A_FireCustomMissile ("MPlasmaBallRipper",0,1,0,0,0) //2
		//PLSG A 1 A_FireCustomMissile ("MPlasmaBallRipper",0,1,0,0,0) //2
	PLSG A 1 A_GunFlash
	PLSG B 40
	PLSG B 1 A_ReFire
	PLSG BCDE 4
	PLSG F 8
	PLSG EDCB 2
	Goto Ready

 DoKick:
	TNT1 A 0
        TNT1 A 0 //A_ZoomFactor(1.0)
	TNT1 A 0 A_jumpifinventory("PowerStrength",1,"BerserkerKick")
	TNT1 A 0 A_PlaySound("KICK")
	TNT1 A 0 SetPlayerProperty(0,1,0)
	KICK BCD 1
	RIFF A 0 A_FireCustomMissile("KickAttack", 0, 0, 0, -7)
	KICK H 4
	KICK A 0 A_Takeinventory("Kicking",1)
	KICK IGFEDCBA 1 
	TNT1 A 0 SetPlayerProperty(0,0,0)
	Goto Ready
    BerserkerKick:
	TNT1 A 0 A_PlaySound("KICK")
	TNT1 A 0 SetPlayerProperty(0,1,0)
	KICK ABCDEFG 1
	RIFF A 0 A_FireCustomMissile("SuperKickAttack", 0, 0, 0, -7)
	KICK H 3
	KICK A 0 A_Takeinventory("Kicking",1)
	KICK IGFEDCBA 1 
	TNT1 A 0 SetPlayerProperty(0,0,0)
	Goto Ready
   Flash:
    PLSF A 2 Bright A_Light1
    PLSF B 2 Bright A_Light0
    PLSF A 0 A_Light0
    Stop
   AltFlash:
    PLSF A 2 Bright A_Light1
    PLSF B 2 Bright A_Light2
    PLSF A 2 Bright A_Light1
    PLSF A 0 A_Light0
    Stop
  //AltFireYOverheat:
	//PLSG A 1 A_Print("PlasmaRifle AltFireY overheat (350 rounds), cooldown")
	//PLSG A 0 A_TakeInventory("PM_AltFireX",1)
	//PLSG A 0 A_TakeInventory("PM_AltFireY",1)
	//PLSG A 0 A_TakeInventory("PM_AltFireZ",1)
	//goto Ready
  }
}




actor MRailgun : Weapon replaces Railgun
{
   Weapon.Kickback 400 //300
   Weapon.SelectionOrder 450
   Inventory.PickupSound "misc/w_pkup"
   Inventory.PickupMessage "$GOTCHAINGUN" // "You got the chaingun"
   Obituary "$OB_MPCHAINGUN" // "%o was mowed down by %k's chaingun."
   Weapon.AmmoUse 25
   Weapon.Ammotype1 "MCell"
   Weapon.Ammogive 50
   AttackSound "weapons/RailAttack"
   Weapon.PreferredSkin "SonicRailGunMarine"
   Damagetype "MarineRail"
   //+INVENTORY.UNDROPPABLE
   -NOEXTREMEDEATH
   +WEAPON.NOAUTOAIM //added
   
   States
   {

   Select:
	SRCG B 1 ACS_ExecuteAlways(480,0,62,0,0)	
	SRCG B 0 A_PlayWeaponSound("m_desolator_taunt")
   Sel:
	SRCG B 0
	SRCG B 1 A_Raise
	LOOP
	
   Ready: //Ready for any fire
	SRCG E 0 A_JumpIfInventory ("PM_AltFireX",1,"ReadyXZoomOn")
    SRCG E 0 A_JumpIfInventory ("PM_AltFireY",1,"ReadyYZoomOn")
	SRCG E 0 A_jumpifinventory("kicking",1,"dokick")
    SRCG E 1 A_WeaponReady
	LOOP
	
   ReadyCharging:
	SRCG C 8 A_PlaySoundEx ("weapons/RailCharge","weapon")
	SRCG CDE 8
	SRCG E 0 A_jumpifinventory("kicking",1,"dokick")
	SRCG E 1
	Goto ReadyCharged

   ReadyCharged:
	 SRCG B 0 A_JumpIfInventory ("PM_AltFireX",1,"ReadyXZoomOn")
     SRCG B 0 A_JumpIfInventory ("PM_AltFireY",1,"ReadyYZoomOn")
	 SRCG E 0 A_jumpifinventory("kicking",1,"dokick")
	 SRCG E 1 A_WeaponReady
	Goto ReadyCharged

   Deselect:
    SRCG B 0 A_ZoomFactor(1.0)
		SRCG B 0 A_TakeInventory ("PM_AltFireX",1)
		SRCG B 0 A_TakeInventory ("PM_AltFireY",1)
		SRCG B 0 A_TakeInventory ("PM_ZoomOffX",1)
		SRCG B 0 A_TakeInventory ("PM_ZoomOffY",1)
	SRCG B 1 A_Lower
	LOOP

	
   ReadyXZoomOn:
	 MAGS A 1 A_ZoomFactor(1.0)
	 MAGS A 1 A_ZoomFactor(1.2)
	 MAGS A 1 A_ZoomFactor(1.4)
	 MAGS A 1 A_ZoomFactor(1.6)
	 MAGS A 1 A_ZoomFactor(1.8)
	 MAGS A 1 A_ZoomFactor(2.0)
	 MAGS A 1 A_ZoomFactor(2.5)
	 MAGS A 10
     GoTo ReadyXZoomed
   ReadyXZoomed:
	 MAGS A 0 A_ZoomFactor(2.5)
 	 MAGS A 0 A_JumpIfInventory ("PM_ZoomOffX",1,"ReadyXZoomOff")
	 //MAGS A 0 A_JumpIfInventory ("PM_ZoomOffY",1,"ReadyXZoomOff")
	 MAGS A 1 A_WeaponReady
	 GoTo ReadyXZoomed
   ReadyXZoomOff:
	 MAGS A 1 A_ZoomFactor(2.5)
	 MAGS A 1 A_ZoomFactor(2.0)
	 MAGS A 1 A_ZoomFactor(1.8)
	 MAGS A 1 A_ZoomFactor(1.6)
	 MAGS A 1 A_ZoomFactor(1.4)
	 MAGS A 1 A_ZoomFactor(1.2)
	 MAGS A 1 A_ZoomFactor(1.0) 	
     GoTo ReadyCharged
 
 ReadyYZoomOn:
	 MAGR A 1 A_ZoomFactor(1.0)
	 MAGR A 1 A_ZoomFactor(1.5)
	 MAGR A 1 A_ZoomFactor(2.0)
	 MAGR A 1 A_ZoomFactor(2.5)
	 MAGR A 1 A_ZoomFactor(3.0)
	 MAGR A 1 A_ZoomFactor(3.5)
	 MAGR A 1 A_ZoomFactor(4.0)
	 MAGR A 1 A_ZoomFactor(4.5)
	 MAGR A 1 A_ZoomFactor(5.0)
	 MAGS A 10
     GoTo ReadyYZoomed
   ReadyYZoomed:
	 MAGR A 0 A_ZoomFactor(5.0)
 	 MAGR A 0 A_JumpIfInventory ("PM_ZoomOffY",1,"ReadyYZoomOff")
	 //MAGR A 0 A_JumpIfInventory ("PM_ZoomOffX",1,"ReadyYZoomOff") 
	 MAGR A 1 A_WeaponReady
	 GoTo ReadyYZoomed
   ReadyYZoomOff:
	 MAGR A 1 A_ZoomFactor(5.0)
	 MAGR A 1 A_ZoomFactor(4.5)
	 MAGR A 1 A_ZoomFactor(4.0)
	 MAGR A 1 A_ZoomFactor(3.5)
	 MAGR A 1 A_ZoomFactor(3.0)
	 MAGR A 1 A_ZoomFactor(2.5)
	 MAGR A 1 A_ZoomFactor(2.0)
	 MAGR A 1 A_ZoomFactor(1.5) 
	 MAGR A 1 A_ZoomFactor(1.0) 
     GoTo ReadyCharged
	
 Fire:
	SRCG B 0 A_JumpIfInventory ("PM_AltFireX",1,"FireX")
	SRCG B 0 A_JumpIfInventory ("PM_AltFireY",1,"FireY")
	SRCG G 0 A_CheckReload
	SRCG G 0 bright A_RailAttack(random(120,180)*5, 0, 1, "red", "white", 0, 0, "MRailPuff")
	SRCG G 2 A_GunFlash
	SRCG G 1 bright
	SRCG G 1 bright
	SRCG G 1 bright
	SRCG G 1 bright
	SRCG G 1 bright
	SRCG G 1 bright
	SRCG G 1 bright
	SRCG F 6 bright
	SRCG B 10
	SRCG H 5
	SRCG H 5
	SRCG H 5
	SRCG H 5
	SRCG H 5
	SRCG H 0 A_JUMP(70,2)
	SRCG HHH 0
	GOTO ReadyCharging

   FireX:
	 MAGS A 0 A_ZoomFactor(2.5)
	 MAGS A 0 bright A_RailAttack(random(120,180)*5, 0, 1, "red", "white", 0, 0, "MRailPuff")
	 MAGS A 2 A_GunFlash
	 MAGS A 3 A_SetPitch(-4.0 + pitch)
	 MAGS A 1
	 MAGS A 3 A_SetPitch(4.0 + pitch)
	 MAGS A 72
	 Goto ReadyXZoomed
   FireY:
	 MAGR A 0 A_ZoomFactor(5.0)
	 MAGR A 0 bright A_RailAttack(random(120,180)*5, 0, 1, "red", "white", 0, 0, "MRailPuff")
	 MAGR A 3 A_GunFlash
	 MAGR A 3 A_SetPitch(-4.0 + pitch)
	 MAGR A 1
	 MAGR A 3 A_SetPitch(4.0 + pitch)
	 MAGR A 72
	 Goto ReadyYZoomed

  AltFire:
	SRCG B 0 A_ZoomFactor(1.0)
		SRCG B 0 A_TakeInventory ("PM_AltFireX",1)
		SRCG B 0 A_TakeInventory ("PM_AltFireY",1)
		SRCG B 0 A_TakeInventory ("PM_ZoomOffX",1)
		SRCG B 0 A_TakeInventory ("PM_ZoomOffY",1)
			SRCG B 0 A_JumpIfInventory ("runlock7",1,1)
			goto Ready
		SRCG G 0 bright A_RailAttack(random(16,20)*5, 0, 1, "none", "red", 0, 0, "MRailPuff")
		SRCG G 2 A_GunFlash
		SRCG G 4 bright
		SRCG G 1 bright
		SRCG G 1 bright
	SRCG F 1 bright
	SRCG B 1
	SRCG B 1 A_Refire
	goto ReadyCharged //no charging
	//GOTO Ready+7

DoKick:
	TNT1 A 0
        TNT1 A 0 //A_ZoomFactor(1.0)
	TNT1 A 0 A_jumpifinventory("PowerStrength",1,"BerserkerKick")
	TNT1 A 0 A_PlaySound("KICK")
	TNT1 A 0 SetPlayerProperty(0,1,0)
	KICK BCD 1
	RIFF A 0 A_FireCustomMissile("KickAttack", 0, 0, 0, -7)
	KICK H 4
	KICK A 0 A_Takeinventory("Kicking",1)
	KICK IGFEDCBA 1 
	TNT1 A 0 SetPlayerProperty(0,0,0)
	Goto ReadyCharged
    BerserkerKick:
	TNT1 A 0 A_PlaySound("KICK")
	TNT1 A 0 SetPlayerProperty(0,1,0)
	KICK ABCDEFG 1
	RIFF A 0 A_FireCustomMissile("SuperKickAttack", 0, 0, 0, -7)
	KICK H 3
	KICK A 0 A_Takeinventory("Kicking",1)
	KICK IGFEDCBA 1 
	TNT1 A 0 SetPlayerProperty(0,0,0)
	Goto ReadyCharged
   Flash:
	TNT1 A 2 A_Light0
	TNT1 A 4 A_Light2
	TNT1 A 4 A_Light1
	TNT1 A 0 A_Light0
	Stop
  Spawn:
	CRIL A -1
	Stop
    //RAIL A -1
    //Stop
   }
}





actor MBulletPuff : BulletPuff
{
 DamageType "MarineDamage"
 +NOEXTREMEDEATH
}

actor MRailPuff : MBulletPuff
{
 DamageType "MarineRail"
 -NOEXTREMEDEATH
}

actor MPlasmaBall : PlasmaBall //PlasmaBall replaces PlasmaBall 
{
 DamageType "MarineDamage"
 -NOTELEPORT
 +TELESTOMP //added
}

actor MPlasmaBallFast : PlasmaBall //PlasmaBall replaces PlasmaBall 
{
 DamageType "MarineDamage"
 -NOTELEPORT
 +TELESTOMP //added
 Speed 150 //25 //125
 SeeSound "weapons/PlasmaQ3"
}

actor MPlasmaBallHoming
{
  Radius 13
  Height 8
  Speed 10 //25
  Damage 8 //5
  Projectile
  SeeSound "weapons/plasmaf"
  DeathSound "weapons/plasmax"
  ExplosionDamage 6
  ExplosionRadius 24 
  +SeekerMissile //added
  +SCREENSEEKER //added
  //+Rockettrail
  DamageType "MarineDamage" //added
  -NOTELEPORT //added
  +TELESTOMP //added
  +RANDOMIZE
  +DEHEXPLOSION
  Obituary "$OB_MPPLASMARIFLE" // "%o was melted by %k's plasma gun."
  RenderStyle Add
  Alpha 0.75
  
  BounceCount 3 //added 3.0.1
  +CANBOUNCEWATER //added 3.0.1
  +DOOMBOUNCE //added 3.0.1
  +NOBOUNCESOUND //added 3.0.1
  +NOWALLBOUNCESND //added 3.0.1
  
  States
  {
  Spawn:
    PLSS AB 6 Bright A_SeekerMissile(30,60,SMF_PRECISE||SMF_LOOK,256,10) //45,90 //SMF_LOOK removed added 3.0.1
    goto Spawn
  Death:
    PLSE ABCDE 4 Bright A_Explode(6,24)
    Stop
  }
}

actor MPlasmaBallRipper : PlasmaBall //PlasmaBall replaces PlasmaBall 
{
 DamageType "MarineDamage"
 -NOTELEPORT
 +TELESTOMP //added
 +RIPPER
 +EXTREMEDEATH
 Speed 15
 Damage 4
 SeeSound "weapons/PlasmaQ3"
 
 BounceCount 2
 +CANBOUNCEWATER
 +DOOMBOUNCE
 +NOBOUNCESOUND
 +NOWALLBOUNCESND
}










actor MBFGBall : BFGBall
{
  DamageType "BFGSplash"
  States
  {
  Death:
    BFE1 AB 8 bright
    BFE1 C 8 bright A_BFGSpray("MBFGExtra")
    BFE1 DEF 8 bright
    stop
  }
}


actor MBFGExtra : BFGExtra 
{
DamageType "BFGSplash"
}

actor MBFG10kShot : BFG10kShot replaces BFG10kShot
{
  Damage 150
  DamageType "BFGSplash"
//  Damage 150
//  DamageType "KPLASMA"
}






actor MBFG10K : BFG10K replaces BFG10K
{
  Weapon.AmmoUse 10
  Weapon.AmmoGive 50
  Weapon.Kickback 100 //50
  DamageType  "BFGSplash"
  Weapon.PreferredSkin "BFG10kMarine"
  Weapon.AmmoType "MCell"
  +WEAPON.NOAUTOAIM //added
  
States
{

  Select:
	BG2G A 1 ACS_ExecuteAlways(480,0,7,0,0)
	BG2G A 0 A_PlayWeaponSound("m_bfg_taunt")
  Sel:
	BG2G A 0
    BG2G A 1 A_Raise
    LOOP
  Ready:
    //BG2G A 0 A_PlaySound ("weapons/bfg10kidle")
    BG2G A 1 A_WeaponReady
    BG2G A 1 A_WeaponReady
    BG2G A 1 A_WeaponReady
    BG2G A 0 A_jumpifinventory("kicking",1,"dokick")
    BG2G B 1 A_WeaponReady
    BG2G B 1 A_WeaponReady
    BG2G B 1 A_WeaponReady
    BG2G A 0 A_jumpifinventory("kicking",1,"dokick")
    BG2G C 1 A_WeaponReady
    BG2G C 1 A_WeaponReady
    BG2G C 1 A_WeaponReady
    BG2G A 0 A_jumpifinventory("kicking",1,"dokick")
    BG2G D 1 A_WeaponReady
    BG2G D 1 A_WeaponReady
    BG2G D 1 A_WeaponReady
    BG2G A 0 A_jumpifinventory("kicking",1,"dokick")
    Loop
	
  Fire:
		BG2G A 0 A_JumpIfInventory ("PM_AltFireX",1,"AltFireX")	
		BG2G A 0 A_JumpIfInventory ("PM_AltFireY",1,"AltFireY")
		BG2G A 0 A_JumpIfInventory ("PM_AltFireZ",1,"AltFireZ")	
	BG2G E 20 A_PlaySound ("weapons/bfg10kf")
	BG2G F 4
	BG2G G 1
	BG2G H 1
	BG2G I 1
	BG2G J 1
	Goto Hold
  Hold:
		BG2G A 0 A_JumpIfInventory("MBFG10K_Splash_Used",300,"BFGSplashOveruse")
    BG2G K 2 Bright A_GunFlash
    BG2G L 2 Bright A_FireBullets(0,0,1,0,"MBFG10kShot")
		BG2G L 0 A_GiveInventory("MBFG10K_Splash_Used", 1)
    BG2G M 2 Bright 
    BG2G O 2
    BG2G N 0 A_ReFire
    BG2G O 35 A_PlaySound ("weapons/bfg10kcool")
    Goto Ready
	
  BFGSplashOveruse:
	  BG2G A 0 A_Print("300 BFG Splash shots overuse, cooling down")
	  Goto Ready	
  BFGOveruse:
	  BG2G A 0 A_Print("36 BFG shots already used in this level")
	  Goto Ready
  BFGGravityWaveBlastOveruse:
	  BG2G A 0 A_Print("12 BFG Gravity Wave Blast shots already used in this level")
	  Goto Ready
  BFGBlackHoleOveruse:
	  BG2G A 0 A_Print("6 BFG Black Hole collapse stars already used in this level")
	  Goto Ready	  
  BFGGravityWaveShieldOveruse:
	  BG2G A 0 A_Print("3 BFG Gravity Wave Shields already used in this level")
	  Goto Ready

  AltFire: //added
		BG2G A 0 A_JumpIfInventory("MBFG10K_BFG_Used",36,"BFGOveruse")
    BG2G A 20 A_BFGSound
    BG2G K 10 A_GunFlash
    BG2G A 30 A_FireCustomMissile ("MarineBFGBall",0,1,5,10)//A_FireBFG
		BG2G A 0 A_GiveInventory("MBFG10K_BFG_Used", 1)
    BG2G A 20 A_ReFire
    Goto Ready
	
 AltFireX:
		BG2G A 0 A_JumpIfInventory("MBFG10K_GravityWaveBlast_Used",12,"BFGGravityWaveBlastOveruse")
    BG2G A 20 A_BFGSound
    BG2G K 10 A_GunFlash 
    BG2G A 30 A_FireCustomMissile ("BFGGravityWaveBlast",0,1,5,10)
		BG2G A 0 A_GiveInventory("MBFG10K_GravityWaveBlast_Used", 1)
    BG2G A 20 //A_ReFire 
    Goto Ready

 AltFireY:
		BG2G A 0 A_JumpIfInventory("MBFG10K_BlackHole_Used",6,"BFGBlackHoleOveruse")
    BG2G A 0 A_Print("BFG Black Hole implosion ball charging ...")
	BG2G J 0 A_PlaySound ("MBFGSHLD")
	BG2G J 70 //140
	BG2G AJAJAJAJAJAJAJAJAJAJ 1
	BG2G AJAJAJAJAJAJAJAJAJAJ 1
	BG2G AJAJAJAJAJAJAJAJAJAJ 1
	BG2G AJAJAJAJAJAJAJAJAJAJ 1
	BG2G AJAJAJAJAJAJAJAJAJAJ 1
    BG2G K 1 A_GunFlash 
	BG2G A 0 A_PlaySound ("weapons/bfg10kf")
		BG2G A 30 A_FireCustomMissile ("BFGBlackHoleBlast",0,1,5,10)
		BG2G A 0 A_GiveInventory("MBFG10K_BlackHole_Used", 1)
    BG2G A 20 //A_ReFire 
    Goto Ready

 AltFireZ:
		BG2G A 0 A_JumpIfInventory("MBFG10K_GravityWaveShield_Used",3,"BFGGravityWaveShieldOveruse")
    BG2G A 0 A_Print("BFG Gravity Wave Shield charging ...")
	BG2G J 0 A_PlaySound ("MBFGSHLD")
	BG2G J 70 //140
	BG2G AJAJAJAJAJAJAJAJAJAJ 1
	BG2G AJAJAJAJAJAJAJAJAJAJ 1
	BG2G AJAJAJAJAJAJAJAJAJAJ 1
	BG2G AJAJAJAJAJAJAJAJAJAJ 1
	BG2G AJAJAJAJAJAJAJAJAJAJ 1
	BG2G K 0 A_Print("BFG Gravity Wave Shield activated")
    BG2G K 1 A_GunFlash
	BG2G K 0 A_GiveInventory("MShieldProt", 1) //Temporary invulnerability
	BG2G A 0 A_PlaySound ("weapons/bfg10kf")
		BG2G A 0 A_SpawnItemEx("BFGGravityWaveShieldIluminate",0,0,0,0,0,0,0,SXF_TRANSFERPOINTERS,0)
    BG2G AKLMON 1 A_Blast (BF_DONTWARN, 10000, 100, 20)
	BG2G A 0 A_PlaySound ("weapons/bfg10kf")
		BG2G A 0 A_SpawnItemEx("BFGGravityWaveShieldIluminate",0,0,0,0,0,0,0,SXF_TRANSFERPOINTERS,0)
	BG2G AKLMON 1 A_Blast (BF_DONTWARN, 10000, 100, 20)
	BG2G A 0 A_PlaySound ("weapons/bfg10kf")
		BG2G A 0 A_SpawnItemEx("BFGGravityWaveShieldIluminate",0,0,0,0,0,0,0,SXF_TRANSFERPOINTERS,0)
	BG2G AKLMON 1 A_Blast (BF_DONTWARN, 10000, 100, 20)
	BG2G A 0 A_PlaySound ("weapons/bfg10kf")
		BG2G A 0 A_SpawnItemEx("BFGGravityWaveShieldIluminate",0,0,0,0,0,0,0,SXF_TRANSFERPOINTERS,0)
	BG2G AKLMON 1 A_Blast (BF_DONTWARN, 10000, 100, 20)
	BG2G A 0 A_PlaySound ("weapons/bfg10kf")
		BG2G A 0 A_SpawnItemEx("BFGGravityWaveShieldIluminate",0,0,0,0,0,0,0,SXF_TRANSFERPOINTERS,0)
	BG2G AKLMON 1 A_Blast (BF_DONTWARN, 10000, 100, 20)
	BG2G A 0 A_PlaySound ("weapons/bfg10kf")
		BG2G A 0 A_SpawnItemEx("BFGGravityWaveShieldIluminate",0,0,0,0,0,0,0,SXF_TRANSFERPOINTERS,0)
	BG2G AKLMON 1 A_Blast (BF_DONTWARN, 10000, 100, 20)
	BG2G A 0 A_PlaySound ("weapons/bfg10kf")
		BG2G A 0 A_SpawnItemEx("BFGGravityWaveShieldIluminate",0,0,0,0,0,0,0,SXF_TRANSFERPOINTERS,0)
	BG2G AKLMON 1 A_Blast (BF_DONTWARN, 10000, 100, 20)
	
	BG2G A 0 A_PlaySound ("weapons/bfg10kf")
		BG2G A 0 A_SpawnItemEx("BFGGravityWaveShieldIluminate",0,0,0,0,0,0,0,SXF_TRANSFERPOINTERS,0)
    BG2G AKLMON 1 A_Blast (BF_DONTWARN, 10000, 100, 20)
	BG2G A 0 A_PlaySound ("weapons/bfg10kf")
		BG2G A 0 A_SpawnItemEx("BFGGravityWaveShieldIluminate",0,0,0,0,0,0,0,SXF_TRANSFERPOINTERS,0)
	BG2G AKLMON 1 A_Blast (BF_DONTWARN, 10000, 100, 20)
	BG2G A 0 A_PlaySound ("weapons/bfg10kf")
		BG2G A 0 A_SpawnItemEx("BFGGravityWaveShieldIluminate",0,0,0,0,0,0,0,SXF_TRANSFERPOINTERS,0)
	BG2G AKLMON 1 A_Blast (BF_DONTWARN, 10000, 100, 20)
	BG2G A 0 A_PlaySound ("weapons/bfg10kf")
		BG2G A 0 A_SpawnItemEx("BFGGravityWaveShieldIluminate",0,0,0,0,0,0,0,SXF_TRANSFERPOINTERS,0)
	BG2G AKLMON 1 A_Blast (BF_DONTWARN, 10000, 100, 20)
	BG2G A 0 A_PlaySound ("weapons/bfg10kf")
		BG2G A 0 A_SpawnItemEx("BFGGravityWaveShieldIluminate",0,0,0,0,0,0,0,SXF_TRANSFERPOINTERS,0)
	BG2G AKLMON 1 A_Blast (BF_DONTWARN, 10000, 100, 20)
	BG2G A 0 A_PlaySound ("weapons/bfg10kf")
		BG2G A 0 A_SpawnItemEx("BFGGravityWaveShieldIluminate",0,0,0,0,0,0,0,SXF_TRANSFERPOINTERS,0)
	BG2G AKLMON 1 A_Blast (BF_DONTWARN, 10000, 100, 20)
	BG2G A 0 A_PlaySound ("weapons/bfg10kf")
		BG2G A 0 A_SpawnItemEx("BFGGravityWaveShieldIluminate",0,0,0,0,0,0,0,SXF_TRANSFERPOINTERS,0)
	BG2G AKLMON 1 A_Blast (BF_DONTWARN, 10000, 100, 20)

	BG2G A 0 A_PlaySound ("weapons/bfg10kf")
		BG2G A 0 A_SpawnItemEx("BFGGravityWaveShieldIluminate",0,0,0,0,0,0,0,SXF_TRANSFERPOINTERS,0)
    BG2G AKLMON 1 A_Blast (BF_DONTWARN, 10000, 100, 20)
	BG2G A 0 A_PlaySound ("weapons/bfg10kf")
		BG2G A 0 A_SpawnItemEx("BFGGravityWaveShieldIluminate",0,0,0,0,0,0,0,SXF_TRANSFERPOINTERS,0)
	BG2G AKLMON 1 A_Blast (BF_DONTWARN, 10000, 100, 20)
	BG2G A 0 A_PlaySound ("weapons/bfg10kf")
		BG2G A 0 A_SpawnItemEx("BFGGravityWaveShieldIluminate",0,0,0,0,0,0,0,SXF_TRANSFERPOINTERS,0)
	BG2G AKLMON 1 A_Blast (BF_DONTWARN, 10000, 100, 20)
	BG2G A 0 A_PlaySound ("weapons/bfg10kf")
		BG2G A 0 A_SpawnItemEx("BFGGravityWaveShieldIluminate",0,0,0,0,0,0,0,SXF_TRANSFERPOINTERS,0)
	BG2G AKLMON 1 A_Blast (BF_DONTWARN, 10000, 100, 20)
	BG2G A 0 A_PlaySound ("weapons/bfg10kf")
		BG2G A 0 A_SpawnItemEx("BFGGravityWaveShieldIluminate",0,0,0,0,0,0,0,SXF_TRANSFERPOINTERS,0)
	BG2G AKLMON 1 A_Blast (BF_DONTWARN, 10000, 100, 20)
	BG2G A 0 A_PlaySound ("weapons/bfg10kf")
		BG2G A 0 A_SpawnItemEx("BFGGravityWaveShieldIluminate",0,0,0,0,0,0,0,SXF_TRANSFERPOINTERS,0)
	BG2G AKLMON 1 A_Blast (BF_DONTWARN, 10000, 100, 20)
	BG2G A 0 A_PlaySound ("weapons/bfg10kf")
		BG2G A 0 A_SpawnItemEx("BFGGravityWaveShieldIluminate",0,0,0,0,0,0,0,SXF_TRANSFERPOINTERS,0)
	BG2G AKLMON 1 A_Blast (BF_DONTWARN, 10000, 100, 20)

	BG2G A 0 A_PlaySound ("weapons/bfg10kf")
		BG2G A 0 A_SpawnItemEx("BFGGravityWaveShieldIluminate",0,0,0,0,0,0,0,SXF_TRANSFERPOINTERS,0)
    BG2G AKLMON 1 A_Blast (BF_DONTWARN, 10000, 100, 20)
	BG2G A 0 A_PlaySound ("weapons/bfg10kf")
		BG2G A 0 A_SpawnItemEx("BFGGravityWaveShieldIluminate",0,0,0,0,0,0,0,SXF_TRANSFERPOINTERS,0)
	BG2G AKLMON 1 A_Blast (BF_DONTWARN, 10000, 100, 20)
	BG2G A 0 A_PlaySound ("weapons/bfg10kf")
		BG2G A 0 A_SpawnItemEx("BFGGravityWaveShieldIluminate",0,0,0,0,0,0,0,SXF_TRANSFERPOINTERS,0)
	BG2G AKLMON 1 A_Blast (BF_DONTWARN, 10000, 100, 20)
	BG2G A 0 A_PlaySound ("weapons/bfg10kf")
		BG2G A 0 A_SpawnItemEx("BFGGravityWaveShieldIluminate",0,0,0,0,0,0,0,SXF_TRANSFERPOINTERS,0)
	BG2G AKLMON 1 A_Blast (BF_DONTWARN, 10000, 100, 20)
	BG2G A 0 A_PlaySound ("weapons/bfg10kf")
		BG2G A 0 A_SpawnItemEx("BFGGravityWaveShieldIluminate",0,0,0,0,0,0,0,SXF_TRANSFERPOINTERS,0)
	BG2G AKLMON 1 A_Blast (BF_DONTWARN, 10000, 100, 20)
	BG2G A 0 A_PlaySound ("weapons/bfg10kf")
		BG2G A 0 A_SpawnItemEx("BFGGravityWaveShieldIluminate",0,0,0,0,0,0,0,SXF_TRANSFERPOINTERS,0)
	BG2G AKLMON 1 A_Blast (BF_DONTWARN, 10000, 100, 20)
	BG2G A 0 A_PlaySound ("weapons/bfg10kf")
		BG2G A 0 A_SpawnItemEx("BFGGravityWaveShieldIluminate",0,0,0,0,0,0,0,SXF_TRANSFERPOINTERS,0)
	BG2G AKLMON 1 A_Blast (BF_DONTWARN, 10000, 100, 20)
	
		BG2G A 0 A_GiveInventory("MBFG10K_GravityWaveShield_Used", 1)
    BG2G A 20 A_Print("BFG Gravity Wave Shield de-activated")
    Goto Ready


	
 DoKick:
	TNT1 A 0
        TNT1 A 0 //A_ZoomFactor(1.0)
	TNT1 A 0 A_jumpifinventory("PowerStrength",1,"BerserkerKick")
	TNT1 A 0 A_PlaySound("KICK")
	TNT1 A 0 SetPlayerProperty(0,1,0)
	KICK BCD 1
	RIFF A 0 A_FireCustomMissile("KickAttack", 0, 0, 0, -7)
	KICK H 4
	KICK A 0 A_Takeinventory("Kicking",1)
	KICK IGFEDCBA 1 
	TNT1 A 0 SetPlayerProperty(0,0,0)
	Goto Ready
    BerserkerKick:
	TNT1 A 0 A_PlaySound("KICK")
	TNT1 A 0 SetPlayerProperty(0,1,0)
	KICK ABCDEFG 1
	RIFF A 0 A_FireCustomMissile("SuperKickAttack", 0, 0, 0, -7)
	KICK H 3
	KICK A 0 A_Takeinventory("Kicking",1)
	KICK IGFEDCBA 1 
	TNT1 A 0 SetPlayerProperty(0,0,0)
	Goto Ready
  Flash:
    TNT1 A 2 Bright A_Light1
    TNT1 A 3 Bright
    TNT1 A 0 A_Light0
    Stop
}
}



ACTOR MarineBFGBall
{
  Radius 13
  Height 8
  Speed 25
  Damage 100
  Projectile
  +RANDOMIZE
  RenderStyle Add
  Alpha 0.75
  DeathSound "weapons/bfgx"
  Obituary "$OB_MPBFG_BOOM"
  DamageType "BFGSplash"
  -NOTELEPORT
  +TELESTOMP
  States
  {
  Spawn:
    BFS1 AB 4 Bright
    Loop
  Death:
    BFE1 AB 8 Bright
    BFE1 C 8 Bright A_BFGSpray
		//BFE1 C 0 A_Explode(250,16)
		BFE1 C 0 A_Explode(150,32)	
		BFE1 C 0 A_Explode(100,48)
		BFE1 C 0 A_Explode(75,64)
		BFE1 C 0 A_Explode(50,96)
		BFE1 C 0 A_Explode(25,128)
		//BFE1 C 0 A_Explode(20,256)
		//BFE1 C 0 A_Explode(15,512)
		//BFE1 C 0 A_Explode(10,1024)
		BFE1 DEF 8 Bright
    Stop
  }
}



//AltFire X
actor BFGGravityWaveBlast
{
  radius 4
  height 1
  speed 24 //12
  alpha 1
  damage 20
  DamageType "BFGSplash"
  renderstyle add
  PROJECTILE
  +NOBLOCKMAP
  +NOGRAVITY
  PROJECTILE
  -BLOODLESSIMPACT
  -NOTELEPORT
  +TELESTOMP
  +EXTREMEDEATH
    
  states
  {
  Spawn:
    PAR3 ABCD 2
	loop
  Death:
    PAR3 ABCD 2
	PAR3 A 0 A_SpawnItemEx("BFGGravityWaveBlastIluminate",0,0,0,0,0,0,0,SXF_TRANSFERPOINTERS,0)
	PAR3 A 0 A_PlaySound("weapon/grenadeexplode", CHAN_WEAPON, 1, 0, ATTN_NONE)
	PAR3 A 0 A_Blast (BF_DONTWARN, 10000, 150, 20)
	PAR3 A 0 A_Explode(250,16)
	PAR3 A 0 A_Explode(150,32)	
	PAR3 A 0 A_Explode(100,48)
	PAR3 A 0 A_Explode(75,64)
	PAR3 A 0 A_Explode(50,96)
    PAR3 A 0 A_Explode(25,128)
    PAR3 A 0 A_Explode(20,256)
	PAR3 A 0 A_Explode(15,512)
	PAR3 A 0 A_Explode(10,1024)

    TNT1 A 8
	TNT1 A 0 A_SpawnItemEx("BFGGravityWaveBlastIluminate",0,0,0,0,0,0,0,SXF_TRANSFERPOINTERS,0)
	TNT1 A 0 A_PlaySound("weapon/grenadeexplode", CHAN_WEAPON, 1, 0, ATTN_NONE)
	TNT1 A 0 A_Blast (BF_DONTWARN, 10000, 150, 20)
	PAR3 A 0 A_Explode(250,16)
	PAR3 A 0 A_Explode(150,32)	
	PAR3 A 0 A_Explode(100,48)
	PAR3 A 0 A_Explode(75,64)
	PAR3 A 0 A_Explode(50,96)
    PAR3 A 0 A_Explode(25,128)
    PAR3 A 0 A_Explode(20,256)
	PAR3 A 0 A_Explode(15,512)
	PAR3 A 0 A_Explode(10,1024)

    TNT1 A 8
	TNT1 A 0 A_SpawnItemEx("BFGGravityWaveBlastIluminate",0,0,0,0,0,0,0,SXF_TRANSFERPOINTERS,0)
	TNT1 A 0 A_PlaySound("weapon/grenadeexplode", CHAN_WEAPON, 1, 0, ATTN_NONE)
	TNT1 A 0 A_Blast (BF_DONTWARN, 10000, 150, 20)
	PAR3 A 0 A_Explode(250,16)
	PAR3 A 0 A_Explode(150,32)	
	PAR3 A 0 A_Explode(100,48)
	PAR3 A 0 A_Explode(75,64)
	PAR3 A 0 A_Explode(50,96)
    PAR3 A 0 A_Explode(25,128)
    PAR3 A 0 A_Explode(20,256)
	PAR3 A 0 A_Explode(15,512)
	PAR3 A 0 A_Explode(10,1024)
    stop
  }
}


//AltFire Z
actor BFGBlackHoleBlast
{
  radius 4
  height 1
  speed 24 //12
  alpha 1
  damage 20
  DamageType "BFGSplash"
  renderstyle add
  PROJECTILE
  +NOBLOCKMAP
  +NOGRAVITY
  PROJECTILE
  -BLOODLESSIMPACT
  -NOTELEPORT
  +TELESTOMP
  +EXTREMEDEATH
  
  -NOCLIP
  
  states
  {
  Spawn:
	PAB3 A 1
	PAW3 A 1
	PAB3 B 1
	PAW3 B 1
	PAB3 C 1
	PAW3 C 1
	PAB3 D 1
	PAW3 D 1
    //PAB3 ABCD 2
	loop
  Death:
    PAB3 ABCD 2
	PAB3 A 0 A_SpawnItemEx("BFGGravityWaveBlastIluminate",0,0,0,0,0,0,0,SXF_TRANSFERPOINTERS,0)
	PAB3 A 0 Radius_Quake(99999,100,0,100,0)
    PAB3 A 0 A_PlaySound("Weapons/YamatoBlast",CHAN_WEAPON, 1, 0, ATTN_NONE)
	PAB3 A 0 A_Blast (BF_DONTWARN, 10000, 150, 20)
	PAB3 A 0 A_Explode(2000,16)
	PAB3 A 0 A_Explode(1500,32)
	PAB3 A 0 A_Explode(1200,64)	
	PAB3 A 0 A_Explode(800,96)
	PAB3 A 0 A_Explode(600,128)
    PAB3 A 0 A_Explode(400,256)
    PAB3 A 0 A_Explode(300,512)
	PAB3 A 0 A_Explode(250,768)
	PAB3 A 0 A_Explode(200,1024)
	
    stop
  }
}

ACTOR BFGGravityWaveBlastIluminate
{
	+NOGRAVITY
	+NOINTERACTION
	//+CLIENTSIDEONLY
	Renderstyle Add
	Alpha 1
	Scale 5.5
	States
	{
	Spawn:
        YAE3 ABCBA 1 Bright A_FadeOut(0.2) //0.0075
		Wait
	}
}

ACTOR BFGGravityWaveShieldIluminate
{
	+NOGRAVITY
	+NOINTERACTION
	//+CLIENTSIDEONLY
	Renderstyle Add
	Alpha 1
	Scale 5.5
	States
	{
	Spawn:
        YAE3 SRQPONOPQRS 1 Bright A_FadeOut(0.2) //0.0075
		Wait
	}
}






// Vulcan Minigun

ACTOR Vulcan : Minigun replaces Minigun
{
    Weapon.AmmoType "MClip"
    Weapon.PreferredSkin "MinigunMarine" 
	+WEAPON.DONTBOB
	+WEAPON.NOAUTOAIM //added
	attacksound "weapon/VulcanFire" //added 50% loudness
	
	States
	{
	Ready:
		MNGG A 1 A_WeaponReady
		MNGG A 0 A_jumpifinventory("kicking",1,"dokick")
		MNGG A 0 A_JumpIfInventory ("Mspinch",0,1)
		Loop
        	MNGG A 0 A_PlaySoundEx ("weapon/VulcanCannonLoop","weapon",0)
		MNGG BA 2
		goto ready
	Select:
		MNGG A 1 ACS_ExecuteAlways(480,0,43,0,0) 
		MNGG A 1 A_TakeInventory ("Mspinch",1)
		MNGG A 0 A_PlayWeaponSound("m_vulcan_taunt")
    Sel:
		MNGG A 0
		MNGG A 1 A_Raise
		Loop
		//MNGG A 0 A_PlaySoundEx ("weapon/VulcanCannonLoop","weapon",0)
		//goto Ready
		Loop
	Deselect: 
		MNGG A 0 A_TakeInventory("Mspinch",1)
		MNGG A 0 A_TakeInventory("Mspinch2",1)
		MNGG A 0 ACS_ExecuteAlways(426,0,10)
		MNGG A 0 A_StopSoundEx ("Weapon")
		MNGG A 1 A_Lower
		Loop
	Fire:
		MNGG A 1
	    MNGG A 0 A_JumpIfInventory ("Mspinch",0,"Fire2")
		MNGG A 0 A_JumpIfInventory ("Mspinch2",0,17)
			//MNGG A 0 A_JumpIfInventory("MVulcanPrimary_counter",1750,"PrimaryOverheat")
		MNGG A 0 A_PlaySoundEx ("weapon/VulcanCannonUp","weapon",0)
	        MNGG A 0 A_JumpIfInventory ("runlock6",1,8)
		MNGG A 0 ACS_ExecuteAlways(426,0,7)
		MNGG ABABA 4
		MNGG BABAB 3
		MNGG ABA 2
		MNGG A 0 A_GiveInventory("Mspinch2",1)
			MNGG A 0 A_GunFlash
			MNGG A 0 A_FireCustomMissile("VulcanTracer", random(-2,2),0,12,-6,0,random(-1,1))
		MNGG A 1 bright A_FireBullets(5.6, 2.5, -1, 12, "MBulletPuff")
			MNGG B 0 A_FireCustomMissile("VulcanTracer", random(-2,2),0,12,-6,0,random(-1,1))
		MNGG B 1 bright A_FireBullets(5.6, 2.5, -1, 12, "MBulletPuff")
			MNGG A 0 A_FireCustomMissile("VulcanTracer", random(-2,2),0,12,-6,0,random(-1,1))
		MNGG A 1 bright A_FireBullets(5.6, 2.5, -1, 12, "MBulletPuff")
			MNGG B 0 A_FireCustomMissile("VulcanTracer", random(-2,2),0,12,-6,0,random(-1,1))
		MNGG B 1 bright A_FireBullets(5.6, 2.5, -1, 12, "MBulletPuff")
			//MNGG B 0 A_GiveInventory("MVulcanPrimary_counter",4)
			//MNGG B 0 A_JumpIfInventory("MVulcanPrimary_counter",1750,"PrimaryOverheat")
		MNGG A 1 A_ReFire
		MNGG A 0 A_JumpIfInventory ("Mspinch",0,"Ready")
		MNGG A 0 A_PlaySoundEx ("weapon/VulcanCannonDown","weapon",0)
		MNGG ABA 2 
		MNGG BABAB 3
	        MNGG A 0 A_JumpIfInventory ("runlock6",1,2)
			MNGG A 0 ACS_ExecuteAlways(426,0,10)
		MNGG AA 0
		MNGG ABABA 4
		MNGG A 0 A_TakeInventory("Mspinch2",1)
		goto Ready
	Fire2:
		MNGG A 0 A_JumpIfInventory ("PM_AltFireX",1,"AltFireX")
		MNGG A 0 A_JumpIfInventory ("PM_AltFireY",1,"AltFireY")
		MNGG A 0 A_JumpIfInventory ("PM_AltFireZ",1,"AltFireZ")
		//MNGG A 0 A_JumpIfInventory("MVulcanPrimary_counter",1750,"PrimaryOverheat")
	    MNGG A 0 A_GunFlash
			MNGG A 0 A_FireCustomMissile("VulcanTracer", random(-2,2),0,12,-6,0,random(-1,1))
		MNGG A 1 bright A_FireBullets(5.6, 2.5, -1, 12, "MBulletPuff")
			MNGG B 0 A_FireCustomMissile("VulcanTracer", random(-2,2),0,12,-6,0,random(-1,1))
		MNGG B 1 bright A_FireBullets(5.6, 2.5, -1, 12, "MBulletPuff")
			MNGG A 0 A_FireCustomMissile("VulcanTracer", random(-2,2),0,12,-6,0,random(-1,1))
		MNGG A 1 bright A_FireBullets(5.6, 2.5, -1, 12, "MBulletPuff")
			MNGG B 0 A_FireCustomMissile("VulcanTracer", random(-2,2),0,12,-6,0,random(-1,1))
		MNGG B 1 bright A_FireBullets(5.6, 2.5, -1, 12, "MBulletPuff")
			//MNGG B 0 A_GiveInventory("MVulcanPrimary_counter",4)
			//MNGG B 0 A_JumpIfInventory("MVulcanPrimary_counter",1750,"PrimaryOverheat")
		MNGG A 0 A_ReFire
	    MNGG A 0 A_JumpIfInventory ("runlock6",1,2)
		MNGG A 0 ACS_ExecuteAlways(426,0,7)
	    MNGG AA 0
		goto Ready

	AltFireX:
		MNGG A 0 A_JumpIfInventory("MVulcanAltFireXYZ_counter",750,"AltFireXYZOverheat")
	    MNGG A 0 A_GunFlash
		MNGG A 0 A_FireCustomMissile("VulcanTracerRico", random(-2,2),0,12,-6,0,random(-1,1))
		MNGG A 0 A_FireCustomMissile("VulcanTracerRico", random(-2,2),0,12,-6,0,random(-1,1))
		MNGG A 1 bright A_FireBullets(10, 5, -1, 16, "MBulletPuffVulcanXYZ")
		MNGG A 0 A_GiveInventory("MVulcanAltFireXYZ_counter",1)
			MNGG B 0 A_FireCustomMissile("VulcanTracerRico", random(-2,2),0,12,-6,0,random(-1,1))
			MNGG A 0 A_FireCustomMissile("VulcanTracerRico", random(-2,2),0,12,-6,0,random(-1,1))
			MNGG B 1 bright A_FireBullets(10, 5, -1, 16, "MBulletPuffVulcanXYZ")
			MNGG B 0 A_GiveInventory("MVulcanAltFireXYZ_counter",1)
		MNGG A 0 A_FireCustomMissile("VulcanTracerRico", random(-2,2),0,12,-6,0,random(-1,1))
		MNGG A 0 A_FireCustomMissile("VulcanTracerRico", random(-2,2),0,12,-6,0,random(-1,1))
		MNGG A 1 bright A_FireBullets(10, 5, -1, 16, "MBulletPuffVulcanXYZ")
		MNGG A 0 A_GiveInventory("MVulcanAltFireXYZ_counter",1)
			MNGG B 0 A_FireCustomMissile("VulcanTracerRico", random(-2,2),0,12,-6,0,random(-1,1))
			MNGG A 0 A_FireCustomMissile("VulcanTracerRico", random(-2,2),0,12,-6,0,random(-1,1))
			MNGG B 1 bright A_FireBullets(10, 5, -1, 16, "MBulletPuffVulcanXYZ")
			MNGG B 0 A_GiveInventory("MVulcanAltFireXYZ_counter",1)
		MNGG A 0 A_ReFire
	    MNGG A 0 A_JumpIfInventory ("runlock6",1,2)
		MNGG A 0 ACS_ExecuteAlways(426,0,7)
	    MNGG AA 0
		goto Ready
		
	AltFireY:
		MNGG A 0 A_JumpIfInventory("MVulcanAltFireXYZ_counter",750,"AltFireXYZOverheat")
	    MNGG A 0 A_GunFlash
		MNGG A 0 A_FireCustomMissile("VulcanTracerRico", random(-2,2),0,12,-6,0,random(-1,1))
		MNGG A 0 A_FireCustomMissile("VulcanTracerRico", random(-2,2),0,12,-6,0,random(-1,1))
		MNGG A 1 bright A_FireBullets(12, 12, -1, 12, "MBulletPuffVulcanXYZ")
		MNGG A 0 A_GiveInventory("MVulcanAltFireXYZ_counter",1)
			MNGG A 0 A_FireCustomMissile("VulcanTracerRico", random(-2,2),0,12,-6,0,random(-1,1))
			MNGG A 0 A_FireCustomMissile("VulcanTracerRico", random(-2,2),0,12,-6,0,random(-1,1))
			MNGG A 0 A_FireBullets(12, 12, -1, 12, "MBulletPuffVulcanXYZ")
			MNGG A 0 A_GiveInventory("MVulcanAltFireXYZ_counter",1)
		MNGG B 0 A_FireCustomMissile("VulcanTracerRico", random(-2,2),0,12,-6,0,random(-1,1))
		MNGG A 0 A_FireCustomMissile("VulcanTracerRico", random(-2,2),0,12,-6,0,random(-1,1))
		MNGG B 1 bright A_FireBullets(12, 12, -1, 12, "MBulletPuffVulcanXYZ")
		MNGG B 0 A_GiveInventory("MVulcanAltFireXYZ_counter",1)
			MNGG B 0 A_FireCustomMissile("VulcanTracerRico", random(-2,2),0,12,-6,0,random(-1,1))
			MNGG A 0 A_FireCustomMissile("VulcanTracerRico", random(-2,2),0,12,-6,0,random(-1,1))
			MNGG B 0 A_FireBullets(12, 12, -1, 12, "MBulletPuffVulcanXYZ")
			MNGG B 0 A_GiveInventory("MVulcanAltFireXYZ_counter",1)
		MNGG A 0 A_FireCustomMissile("VulcanTracerRico", random(-2,2),0,12,-6,0,random(-1,1))
		MNGG A 0 A_FireCustomMissile("VulcanTracerRico", random(-2,2),0,12,-6,0,random(-1,1))
		MNGG A 1 bright A_FireBullets(12, 12, -1, 12, "MBulletPuffVulcanXYZ")
		MNGG A 0 A_GiveInventory("MVulcanAltFireXYZ_counter",1)
			MNGG A 0 A_FireCustomMissile("VulcanTracerRico", random(-2,2),0,12,-6,0,random(-1,1))
			MNGG A 0 A_FireCustomMissile("VulcanTracerRico", random(-2,2),0,12,-6,0,random(-1,1))
			MNGG A 0 A_FireBullets(12, 12, -1, 12, "MBulletPuffVulcanXYZ")
			MNGG A 0 A_GiveInventory("MVulcanAltFireXYZ_counter",1)
		MNGG B 0 A_FireCustomMissile("VulcanTracerRico", random(-2,2),0,12,-6,0,random(-1,1))
		MNGG A 0 A_FireCustomMissile("VulcanTracerRico", random(-2,2),0,12,-6,0,random(-1,1))
		MNGG B 1 bright A_FireBullets(12, 12, -1, 12, "MBulletPuffVulcanXYZ")
		MNGG B 0 A_GiveInventory("MVulcanAltFireXYZ_counter",1)
			MNGG B 0 A_FireCustomMissile("VulcanTracerRico", random(-2,2),0,12,-6,0,random(-1,1))
			MNGG A 0 A_FireCustomMissile("VulcanTracerRico", random(-2,2),0,12,-6,0,random(-1,1))
			MNGG B 0 A_FireBullets(12, 12, -1, 12, "MBulletPuffVulcanXYZ")
			MNGG B 0 A_GiveInventory("MVulcanAltFireXYZ_counter",1)
		MNGG A 0 A_ReFire
	    MNGG A 0 A_JumpIfInventory ("runlock6",1,2)
		MNGG A 0 ACS_ExecuteAlways(426,0,7)
	    MNGG AA 0
		goto Ready

	AltFireZ:
		MNGG A 0 A_JumpIfInventory("MVulcanAltFireXYZ_counter",750,"AltFireXYZOverheat")
	    MNGG A 0 A_GunFlash
		MNGG A 0 A_FireCustomMissile("VulcanTracerRico", random(-2,2),0,12,-6,0,random(-1,1))
		MNGG A 0 A_FireCustomMissile("VulcanTracerRico", random(-2,2),0,12,-6,0,random(-1,1))
		MNGG A 1 bright A_FireBullets(30, 2.5, -1, 12, "MBulletPuffVulcanXYZ")
		MNGG A 0 A_GiveInventory("MVulcanAltFireXYZ_counter",1)
			MNGG A 0 A_FireCustomMissile("VulcanTracerRico", random(-2,2),0,12,-6,0,random(-1,1))
			MNGG A 0 A_FireCustomMissile("VulcanTracerRico", random(-2,2),0,12,-6,0,random(-1,1))
			MNGG A 0 A_FireBullets(30, 2.5, -1, 12, "MBulletPuffVulcanXYZ")
			MNGG A 0 A_GiveInventory("MVulcanAltFireXYZ_counter",1)
		MNGG B 0 A_FireCustomMissile("VulcanTracerRico", random(-2,2),0,12,-6,0,random(-1,1))
		MNGG A 0 A_FireCustomMissile("VulcanTracerRico", random(-2,2),0,12,-6,0,random(-1,1))
		MNGG B 1 bright A_FireBullets(30, 2.5, -1, 12, "MBulletPuffVulcanXYZ")
		MNGG B 0 A_GiveInventory("MVulcanAltFireXYZ_counter",1)
			MNGG B 0 A_FireCustomMissile("VulcanTracerRico", random(-2,2),0,12,-6,0,random(-1,1))
			MNGG A 0 A_FireCustomMissile("VulcanTracerRico", random(-2,2),0,12,-6,0,random(-1,1))
			MNGG B 0 A_FireBullets(30, 2.5, -1, 12, "MBulletPuffVulcanXYZ")
			MNGG B 0 A_GiveInventory("MVulcanAltFireXYZ_counter",1)
		MNGG A 0 A_FireCustomMissile("VulcanTracerRico", random(-2,2),0,12,-6,0,random(-1,1))
		MNGG A 0 A_FireCustomMissile("VulcanTracerRico", random(-2,2),0,12,-6,0,random(-1,1))
		MNGG A 1 bright A_FireBullets(30, 2.5, -1, 12, "MBulletPuffVulcanXYZ")
		MNGG A 0 A_GiveInventory("MVulcanAltFireXYZ_counter",1)
			MNGG A 0 A_FireCustomMissile("VulcanTracerRico", random(-2,2),0,12,-6,0,random(-1,1))
			MNGG A 0 A_FireCustomMissile("VulcanTracerRico", random(-2,2),0,12,-6,0,random(-1,1))
			MNGG A 0 A_FireBullets(30, 2.5, -1, 12, "MBulletPuffVulcanXYZ")
			MNGG A 0 A_GiveInventory("MVulcanAltFireXYZ_counter",1)
		MNGG B 0 A_FireCustomMissile("VulcanTracerRico", random(-2,2),0,12,-6,0,random(-1,1))
		MNGG A 0 A_FireCustomMissile("VulcanTracerRico", random(-2,2),0,12,-6,0,random(-1,1))
		MNGG B 1 bright A_FireBullets(30, 2.5, -1, 12, "MBulletPuffVulcanXYZ")
		MNGG B 0 A_GiveInventory("MVulcanAltFireXYZ_counter",1)
			MNGG B 0 A_FireCustomMissile("VulcanTracerRico", random(-2,2),0,12,-6,0,random(-1,1))
			MNGG A 0 A_FireCustomMissile("VulcanTracerRico", random(-2,2),0,12,-6,0,random(-1,1))
			MNGG B 0 A_FireBullets(30, 2.5, -1, 12, "MBulletPuffVulcanXYZ")
			MNGG B 0 A_GiveInventory("MVulcanAltFireXYZ_counter",1)
		MNGG A 0 A_ReFire
	    MNGG A 0 A_JumpIfInventory ("runlock6",1,2)
		MNGG A 0 ACS_ExecuteAlways(426,0,7)
	    MNGG AA 0
		goto Ready
	//PrimaryOverheat:
		//MNGG A 1 A_Print("Vulcan Primary barrel overheat (1750 rounds), cooldown")
		//MNGG A 0 A_TakeInventory("PM_AltFireX",1)
		//MNGG A 0 A_TakeInventory("PM_AltFireY",1)
		//MNGG A 0 A_TakeInventory("PM_AltFireZ",1)
		//MNGG A 0 A_JumpIfInventory ("runlock6",1,2)
			//MNGG A 0 A_GunFlash
			//MNGG A 0 A_FireCustomMissile("VulcanTracer", random(-2,2),0,12,-6,0,random(-1,1))
			//MNGG A 3 bright A_FireBullets(5.6, 2.5, -1, 12, "MBulletPuff")
			//MNGG B 0 A_FireCustomMissile("VulcanTracer", random(-2,2),0,12,-6,0,random(-1,1))
			//MNGG B 3 bright A_FireBullets(5.6, 2.5, -1, 12, "MBulletPuff")
			//MNGG A 0 A_FireCustomMissile("VulcanTracer", random(-2,2),0,12,-6,0,random(-1,1))
			//MNGG A 3 bright A_FireBullets(5.6, 2.5, -1, 12, "MBulletPuff")
			//MNGG B 0 A_FireCustomMissile("VulcanTracer", random(-2,2),0,12,-6,0,random(-1,1))
			//MNGG B 3 bright A_FireBullets(5.6, 2.5, -1, 12, "MBulletPuff")
			//MNGG B 0 A_GiveInventory("MVulcanPrimary_counter",4)
		//MNGG A 0 ACS_ExecuteAlways(426,0,7)
	    //MNGG AA 0
		//goto Ready
	AltFireXYZOverheat:
		MNGG A 1 A_Print("Vulcan AltFireXYZ barrel overheat (750 rounds), cooldown")
		MNGG A 0 A_TakeInventory("PM_AltFireX",1)
		MNGG A 0 A_TakeInventory("PM_AltFireY",1)
		MNGG A 0 A_TakeInventory("PM_AltFireZ",1)
		MNGG A 0 A_JumpIfInventory ("runlock6",1,2)
		MNGG A 0 ACS_ExecuteAlways(426,0,7)
	    MNGG AA 0
		goto Ready

 DoKick:
	TNT1 A 0
        TNT1 A 0 //A_ZoomFactor(1.0)
	TNT1 A 0 A_jumpifinventory("PowerStrength",1,"BerserkerKick")
	TNT1 A 0 A_PlaySound("KICK")
	TNT1 A 0 SetPlayerProperty(0,1,0)
	KICK BCD 1
	RIFF A 0 A_FireCustomMissile("KickAttack", 0, 0, 0, -7)
	KICK H 4
	KICK A 0 A_Takeinventory("Kicking",1)
	KICK IGFEDCBA 1 
	TNT1 A 0 SetPlayerProperty(0,0,0)
	Goto Ready
    BerserkerKick:
	TNT1 A 0 A_PlaySound("KICK")
	TNT1 A 0 SetPlayerProperty(0,1,0)
	KICK ABCDEFG 1
	RIFF A 0 A_FireCustomMissile("SuperKickAttack", 0, 0, 0, -7)
	KICK H 3
	KICK A 0 A_Takeinventory("Kicking",1)
	KICK IGFEDCBA 1 
	TNT1 A 0 SetPlayerProperty(0,0,0)
	Goto Ready
	spawn:
		VLCN A -1
		Stop
	    //TNT1 A 0 Thing_remove(0)
		//stop
	AltFire:
	    MNGG A 0 A_JumpIfInventory ("Mspinch",0,"stopspin")
		MNGG A 0 A_PlaySoundEx ("weapon/VulcanCannonUp","weapon",0)
	        MNGG A 0 A_JumpIfInventory ("runlock6",1,7)
		MNGG A 0 ACS_ExecuteAlways(426,0,7)
		MNGG ABABA 4
		MNGG BABAB 3
		MNGG ABA 2
		MNGG A 0 A_GiveInventory("Mspinch",1)
		goto ready
	StopSpin:
	    MNGG A 0 A_TakeInventory("Mspinch",1)
		MNGG A 0 A_PlaySoundEx ("weapon/VulcanCannonDown","weapon",0)
		MNGG ABA 2 
		MNGG BABAB 3
		MNGG A 0 ACS_ExecuteAlways(426,0,10)
		MNGG ABABA 4
		goto ready
	Flash: 
		TNT1 A 2 BRIGHT A_Light1 
		TNT1 B 2 BRIGHT A_Light2 
		TNT1 A 0 BRIGHT A_Light0
		Stop
	}
}





ACTOR Mspinch : Inventory
 {
  Inventory.Amount 0
  Inventory.MaxAmount 1
  States
   {
    Spawn:
    TNT1 A -1
    Loop 
   }
 }
ACTOR Mspinch2 : Inventory
 {
  Inventory.Amount 0
  Inventory.MaxAmount 1
  States
   {
    Spawn:
    TNT1 A -1
    Loop 
   }
 }
ACTOR Mspinch3 : Inventory
 {
  Inventory.Amount 0
  Inventory.MaxAmount 5
  States
   {
    Spawn:
    TNT1 A -1
    Loop 
   }
 }

// Items 

// Plasm Cells

ACTOR MCell : Ammo replaces Cell
{
  Inventory.PickupMessage "$GOTCELL" // "Picked up an energy cell."
  Inventory.Amount 20
  Inventory.MaxAmount 250
  Ammo.BackpackAmount 20
  Ammo.BackpackMaxAmount 500
  Inventory.Icon "ICONC"
  States
  {
  Spawn:
    CELL A -1
    Stop
  }
}

ACTOR MCellPack : MCell replaces CellPack
{
  Inventory.PickupMessage "$GOTCELLBOX" // "Picked up an energy cell pack."
  Inventory.Amount 60
  States
  {
  Spawn:
    CELP A -1
    Stop
  }
}

// Rockets

ACTOR MRocketAmmo : Ammo replaces RocketAmmo
{
  Inventory.PickupMessage "$GOTROCKET" // "Picked up a rocket."
  Inventory.Amount 1
  Inventory.MaxAmount 30
  Ammo.BackpackAmount 1
  Ammo.BackpackMaxAmount 50
  Inventory.Icon "ICONR"
  States
  {
  Spawn:
    ROCK A -1
    stop  }
}

ACTOR MRocketBox : MRocketAmmo replaces RocketBox
{
  Inventory.PickupMessage "$GOTROCKBOX" // "Picked up a box of rockets."
  Inventory.Amount 5
  States
  {
  Spawn:
    BROK A -1
    Stop
  }
}

// Shells

ACTOR MShell : Ammo replaces Shell
{
  Inventory.PickupMessage "$GOTSHELLS" // "Picked up 4 shotgun shells."
  Inventory.Amount 4
  Inventory.MaxAmount 50
  Ammo.BackpackAmount 4
  Ammo.BackpackMaxAmount 80
  Inventory.Icon "ICONS"
  States
  {
  Spawn:
    SHEL A -1
    Stop
  }
}

ACTOR MShellBox : MShell replaces ShellBox
{
  Inventory.PickupMessage "$GOTSHELLBOX" // "Picked up a box of shotgun shells."
  Inventory.Amount 16
  States
  {
  Spawn:
    SBOX A -1
    Stop
  }
}

// CLip 

ACTOR MClip : Ammo replaces Clip
{
  Inventory.PickupMessage "$GOTCLIP" // "Picked up a clip."
  Inventory.Amount 10
  Inventory.MaxAmount 400
  Ammo.BackpackAmount 20
  Ammo.BackpackMaxAmount 600
  Inventory.Icon "ICONB"
  States
  {
  Spawn:
    CLIP A -1
    Stop
  }
}

actor MClipBox : MClip replaces ClipBox
{
  Inventory.PickupMessage "$GOTCLIPBOX" // "Picked up a box of bullets."
  Inventory.Amount 50
  States
  {
  Spawn:
    AMMO A -1
    Stop
  }
}


Actor Berserker : Inventory
{
inventory.maxamount 1
}

Actor Kicking : Inventory
{
inventory.maxamount 1
}



ACTOR KickAttack: FastProjectile
{
	Radius 6
	Height 6
	//DamageType Kick
	Projectile 
	//+FORCEXYBILLBOARD
	+NOEXTREMEDEATH
	+BLOODSPLATTER
	RenderStyle Add
	Alpha 0.6
        Damage 10 //8
	Speed 30
	//HitObituary "$OB_IMPHIT"
	SeeSound "none"
	DeathSound "none"
	Decal "BulletChip"
	DamageType "MarineKickBasic"
	
	ProjectileKickBack 200
	
	States
	{
	Spawn:
	TNT1 A 1 BRIGHT
        TNT1 A 3 //A_PlaySound("weapons/gswing")
	Stop
	Death:
	TNT1 A 3 A_PlaySound("player/cyborg/fist")
	TNT1 A 9
	Stop
	}
}


ACTOR SuperKickAttack: KickAttack
{
	Damage 40
	//-NOEXTREMEDEATH
	DamageType "MarineKickPowered" //DamageType Extremepunches
}




//Vulcan bullet tracer
Actor VulcanTracer: FastProjectile
{
	-DONTSPLASH
	//seesound "weapon/VulcanFire"
	damagetype Cutless
	Projectile
	+RANDOMIZE
	+FORCEXYBILLBOARD
	+DONTSPLASH 
    +NOEXTREMEDEATH
	+CLIENTSIDEONLY //no network traffic spam
	damage 0
	radius 2
	height 2
	speed 140
	renderstyle ADD
	alpha 0.9
	scale .15
states
{
Spawn:
	TRAC A 1 BRIGHT
	Loop
Death:
	TNT1 A 0
    Stop
XDeath:
	TNT1 A 0
	Stop
} }

//Vulcan bullet tracer with ricochet sound and visuals
Actor VulcanTracerRico: FastProjectile
{
	-DONTSPLASH
	//seesound "weapon/VulcanFire"
	damagetype Cutless
	Projectile
	+RANDOMIZE
	+FORCEXYBILLBOARD
	+DONTSPLASH 
    +NOEXTREMEDEATH
	+CLIENTSIDEONLY //no network traffic spam
	damage 0
	radius 2
	height 2
	speed 140
	renderstyle ADD
	alpha 0.9
	scale .15
states
{
Spawn:
	TRAC A 1 BRIGHT
	Loop
Death:
	TNT1 A 0 A_PlaySound("ricochet/hit")
    Stop
XDeath:
	TNT1 A 0 A_PlaySound("ricochet/hit")
	Stop
} }

//Ricochet round splash on wall
ACTOR MBulletPuffVulcanXYZ
{
  DamageType "MarineDamage"
  +NOEXTREMEDEATH
  +NOBLOCKMAP
  +NOGRAVITY
  +ALLOWPARTICLES
  +RANDOMIZE
  RenderStyle ADD //Translucent
  Alpha 1.5
  VSpeed 1
  Mass 5
  States
  {
  Spawn:
    FX58 ABCDEFGHJ 1
    Stop
  }
}



Actor AssaultRifleTracerRico: FastProjectile
{
	-DONTSPLASH
	//seesound "weapon/VulcanFire"
	damagetype Cutless
	Projectile
	+RANDOMIZE
	+FORCEXYBILLBOARD
	+DONTSPLASH 
    +NOEXTREMEDEATH
	+CLIENTSIDEONLY //no network traffic spam
	damage 0
	radius 2
	height 2
	speed 140
	renderstyle ADD
	alpha 0.9
	scale .15
states
{
Spawn:
	TRAC A 1 BRIGHT
	Loop
Death:
	TNT1 A 0 A_PlaySound("ricochet/hit")
    Stop
XDeath:
	TNT1 A 0 A_PlaySound("ricochet/hit")
	Stop
} }

//Ricochet round splash on wall
ACTOR MBulletPuffAssaultRifle
{
  DamageType "MarineDamage"
  +NOEXTREMEDEATH
  +NOBLOCKMAP
  +NOGRAVITY
  +ALLOWPARTICLES
  +RANDOMIZE
  RenderStyle ADD //Translucent
  Alpha 1.5
  VSpeed 1
  Mass 5
  States
  {
  Spawn:
    FX58 ABCDEFGHJ 1
    Stop
  }
}




//From RO_pb_2.2zan_01.pk3
ACTOR MQuadShotgun : Weapon
{
	Inventory.PickupMessage "You've got the Quad Shotgun!"
	Obituary "%o was blown away and smeared on wall by %k's Quad shotgun."
	//Weapon.UpSound "Quadshot/Up"
	Weapon.SelectionOrder 1745
	Weapon.AmmoType "MShell"
	Weapon.AmmoUse 4
	Weapon.AmmoGive 16
	Weapon.SlotNumber 3
	Weapon.Kickback 900
	Weapon.PreferredSkin "SSGMarine"
	attacksound ""
	
	+WEAPON.NOAUTOAIM
	
	States {
		Spawn: 
			SSHG X -1
			Stop
		Ready:
			SSHG A 1 A_WeaponReady
			SSHG A 0 A_jumpifinventory("kicking",1,"dokick")
			Loop
		Select:
			SHTG A 1 ACS_ExecuteAlways(480,0,34,0,0)
			SHTG A 1 A_PlayWeaponSound("Quadshot/Close")
		 Sel:
			SSHG A 0
			SSHG A 1 A_Raise
			Loop
		Deselect:
			SSHG A 0 A_ZoomFactor(1)
			SSHG A 0 A_TakeInventory("QuadSingleShotUsed",4)
			SSHG A 1 A_Lower
			Loop
		Fire:
			SSHG F 0 A_JumpIfInventory ("PM_AltFireX",1,"AltFireX")
			SSHG F 0 A_JumpIfInventory ("PM_AltFireY",1,"AltFireY")
				SSHG F 0 A_jumpifinventory("QuadSingleShotUsed",1,"AltFireYReload")
				SSHG F 0 A_jumpifinventory("QuadSingleShotUsed",2,"AltFireYReload")
				SSHG F 0 A_jumpifinventory("QuadSingleShotUsed",3,"AltFireYReload")
				SSHG F 0 A_jumpifinventory("QuadSingleShotUsed",4,"AltFireYReload")
			SSHG F 0 Bright A_GunFlash
			SSHG F 0 Bright A_AlertMonsters
			SSHG F 0 Bright A_PlaySound("Quadshot/Fire",1,0.6)
			SSHG F 0 Bright A_FireBullets(15, 7, random(55,65), 5, "MQSSG_Puff")
				SSHG F 0 A_FireCustomMissile("MQSSG_Ricochet", random(-2,2),0,12,-6,0,random(-1,1))
				SSHG F 0 A_FireCustomMissile("MQSSG_Ricochet", random(-2,2),0,12,-6,0,random(-1,1))
				SSHG F 0 A_FireCustomMissile("MQSSG_Ricochet", random(-2,2),0,12,-6,0,random(-1,1))
				SSHG F 0 A_FireCustomMissile("MQSSG_Ricochet", random(-2,2),0,12,-6,0,random(-1,1))
				SSHG F 0 A_FireCustomMissile("MQSSG_Ricochet", random(-2,2),0,12,-6,0,random(-1,1))	
					SSHG F 0 Bright A_Recoil (5) //A_ChangeVelocity (Cos(Pitch) * -29, 0, Sin(Pitch) * 29,CVF_RELATIVE)
					SSHG F 0 Bright A_Quake(6,12,0,32,none)
			SSHG F 0 Bright A_SetAngle(Angle-6)
			SSHG F 0 Bright A_SetPitch(Pitch-4)
			SSHG F 1 Bright A_ZoomFactor(0.95)
			SSHG F 0 Bright A_SetAngle(Angle-3)
			SSHG F 0 Bright A_SetPitch(Pitch-2)
			SSHF B 1 A_ZoomFactor(0.91)
			SSHG F 0 Bright A_SetAngle(Angle-3)
			SSHG F 0 Bright A_SetPitch(Pitch-2)
			SSHF C 1 A_ZoomFactor(0.85)
			SSHG F 0 Bright A_SetAngle(Angle-3)
			SSHG F 0 Bright A_SetPitch(Pitch-2)
			SSHF D 1 A_ZoomFactor(0.82)
			SSHG F 0 Bright A_SetAngle(Angle-1.5)
			SSHG F 0 Bright A_SetPitch(Pitch-1)
			SSHF E 1 A_ZoomFactor(0.8)
			SSHG F 0 Bright A_SetAngle(Angle-1.5)
			SSHG F 0 Bright A_SetPitch(Pitch-1)
			SSHF F 1 A_ZoomFactor(0.82)
			SSHG F 0 Bright A_SetAngle(Angle-1.5)
			SSHG F 0 Bright A_SetPitch(Pitch-1)
			SSHF G 1 A_ZoomFactor(0.84)
			SSHG F 0 Bright A_SetAngle(Angle-1.5)
			SSHG F 0 Bright A_SetPitch(Pitch-1)
			SSHF H 1 A_ZoomFactor(0.87)
			SSHG F 0 Bright A_SetAngle(Angle-0.75)
			SSHG F 0 Bright A_SetPitch(Pitch-0.5)
			SSHF I 1 A_ZoomFactor(0.9)
			SSHG F 0 Bright A_SetAngle(Angle-0.75)
			SSHG F 0 Bright A_SetPitch(Pitch-0.5)
			SSHF J 1 A_ZoomFactor(0.92)
			SSHG F 0 Bright A_SetAngle(Angle-0.375)
			SSHG F 0 Bright A_SetPitch(Pitch-0.25)
			SSHF K 1 A_ZoomFactor(0.94)
			SSHF L 1 A_ZoomFactor(0.96)
			SSHF M 1 A_ZoomFactor(0.97)
			SSHF N 1 A_ZoomFactor(0.98)
			SSHG A 1 A_ZoomFactor(0.99)
			SSHG A 1 A_ZoomFactor(1)
				SSHG A 1 A_SetAngle(Angle+17.7)
				SSHG A 1 A_SetPitch(Pitch+15.8)
			SSHG A 1 A_CheckReload 
			SSHN ABDEG 2 //1
			SSHO ABDEIK 1
			SSHO M 1 A_PlaySound("Quadshot/Open",5,0.7)
			SSHO NOQRTUWX 1
			SSHL A 3
			SSHL BCDE 2 //1
			SSHL F 1 A_PlaySound("Quadshot/Load",6,0.6)
			SSHL GHIJ 1
			SSHL K 2
			SSHL LMNO 2 //1
			SSHL P 1 A_PlaySound("Quadshot/Load",5,0.6)
			SSHL QRSTU 1
			SSHL V 2
			SSHC ABDE 2 //1
			SSHO R 0 A_PlaySound("Quadshot/Close",6,0.7)
			SSHO RQONKI 1
			SSHN GFDCB 1
			SSHG A 12
			SSHG A 3 A_ReFire
			Goto Ready
			
		AltFireX:
			SSHG F 0 A_jumpifinventory("QuadSingleShotUsed",1,"AltFireYReload")
			SSHG F 0 A_jumpifinventory("QuadSingleShotUsed",2,"AltFireYReload")
			SSHG F 0 A_jumpifinventory("QuadSingleShotUsed",3,"AltFireYReload")
			SSHG F 0 A_jumpifinventory("QuadSingleShotUsed",4,"AltFireYReload")
			SSHG A 0 Bright A_AlertMonsters
			SSHG A 0 Bright A_PlaySound("Quadshot/Fire",1,0.6)
			SSHG A 0 Bright A_FireBullets(3.5, 3.5, random(14,16), 5, "MQSSG_Puff")
			SSHG A 0 A_Recoil (1)
				SSHG A 0 A_FireCustomMissile("MQSSG_Ricochet", random(-2,2),0,12,-6,0,random(-1,1))
				SSHG A 0 A_FireCustomMissile("MQSSG_Ricochet", random(-2,2),0,12,-6,0,random(-1,1))
				SSHG A 0 A_FireCustomMissile("MQSSG_Ricochet", random(-2,2),0,12,-6,0,random(-1,1))
			SSHF B 1 A_SetPitch(-6.0 + pitch)
			SSHF C 3 
			SSHF B 1 A_SetPitch(+6.0 + pitch)
			SSHG A 3
			SSHG A 0 Bright A_AlertMonsters
			SSHG A 0 Bright A_PlaySound("Quadshot/Fire",1,0.6)
			SSHG A 0 Bright A_FireBullets(3.5, 3.5, random(14,16), 5, "MQSSG_Puff")
			SSHG A 0 A_Recoil (1)
				SSHG A 0 A_FireCustomMissile("MQSSG_Ricochet", random(-2,2),0,12,-6,0,random(-1,1))
				SSHG A 0 A_FireCustomMissile("MQSSG_Ricochet", random(-2,2),0,12,-6,0,random(-1,1))
				SSHG A 0 A_FireCustomMissile("MQSSG_Ricochet", random(-2,2),0,12,-6,0,random(-1,1))
			SSHF B 1 A_SetPitch(-6.0 + pitch)
			SSHF C 3
			SSHF B 1 A_SetPitch(+6.0 + pitch)
			SSHG A 3
			SSHG A 0 Bright A_AlertMonsters
			SSHG A 0 Bright A_PlaySound("Quadshot/Fire",1,0.6)
			SSHG A 0 Bright A_FireBullets(3.5, 3.5, random(14,16), 5, "MQSSG_Puff")
			SSHG A 0 A_Recoil (1)
				SSHG A 0 A_FireCustomMissile("MQSSG_Ricochet", random(-2,2),0,12,-6,0,random(-1,1))
				SSHG A 0 A_FireCustomMissile("MQSSG_Ricochet", random(-2,2),0,12,-6,0,random(-1,1))
				SSHG A 0 A_FireCustomMissile("MQSSG_Ricochet", random(-2,2),0,12,-6,0,random(-1,1))
			SSHF B 1 A_SetPitch(-6.0 + pitch)
			SSHF C 3 
			SSHF B 1 A_SetPitch(+6.0 + pitch)
			SSHG A 3
			SSHG A 0 Bright A_AlertMonsters
			SSHG A 0 Bright A_PlaySound("Quadshot/Fire",1,0.6)
			SSHG A 0 Bright A_FireBullets(3.5, 3.5, random(14,16), 5, "MQSSG_Puff")
			SSHG A 0 A_Recoil (1)
				SSHG A 0 A_FireCustomMissile("MQSSG_Ricochet", random(-2,2),0,12,-6,0,random(-1,1))
				SSHG A 0 A_FireCustomMissile("MQSSG_Ricochet", random(-2,2),0,12,-6,0,random(-1,1))
				SSHG A 0 A_FireCustomMissile("MQSSG_Ricochet", random(-2,2),0,12,-6,0,random(-1,1))
			SSHF B 1 A_SetPitch(-6.0 + pitch)
			SSHF C 3 
			SSHF B 1 A_SetPitch(+6.0 + pitch)
			SSHG A 1 A_CheckReload 
			SSHN ABDEG 2 //1
			SSHO ABDEIK 1
			SSHO M 1 A_PlaySound("Quadshot/Open",5,0.7)
			SSHO NOQRTUWX 1
			SSHL A 3
			SSHL BCDE 2 //1
			SSHL F 1 A_PlaySound("Quadshot/Load",6,0.6)
			SSHL GHIJ 1
			SSHL K 2
			SSHL LMNO 2 //1
			SSHL P 1 A_PlaySound("Quadshot/Load",5,0.6)
			SSHL QRSTU 1
			SSHL V 2
			SSHC ABDE 2 //1
			SSHO R 0 A_PlaySound("Quadshot/Close",6,0.7)
			SSHO RQONKI 1
			SSHN GFDCB 1
			SSHG A 12
			SSHG A 3
			Goto Ready
		AltFireY:
			SSHG A 0 A_jumpifinventory("QuadSingleShotUsed",4,"AltFireYReload")
			SSHG A 0 Bright A_AlertMonsters
			SSHG A 0 Bright A_PlaySound("Quadshot/Fire",1,0.6)
			SSHG A 0 Bright A_FireBullets(2, 2, random(14,16), 5, "MQSSG_Puff")
				SSHG A 0 A_GiveInventory("QuadSingleShotUsed",1)
			SSHG A 0 A_Recoil (1)
				SSHG A 0 A_FireCustomMissile("MQSSG_Ricochet", random(-2,2),0,12,-6,0,random(-1,1))
				SSHG A 0 A_FireCustomMissile("MQSSG_Ricochet", random(-2,2),0,12,-6,0,random(-1,1))
				SSHG A 0 A_FireCustomMissile("MQSSG_Ricochet", random(-2,2),0,12,-6,0,random(-1,1))
			SSHF B 1 A_SetPitch(-6.0 + pitch)
			SSHF C 3 
			SSHF B 1 A_SetPitch(+6.0 + pitch)
			SSHG A 8 //3
			SSHG A 0 A_jumpifinventory("QuadSingleShotUsed",4,"AltFireYReload")
			Goto Ready
		AltFireYReload:	
			SSHG A 1 A_CheckReload 
			SSHN ABDEG 2 //1
			SSHO ABDEIK 1
			SSHO M 1 A_PlaySound("Quadshot/Open",5,0.7)
			SSHO NOQRTUWX 1
			SSHL A 3
			SSHL BCDE 2 //1
			SSHL F 1 A_PlaySound("Quadshot/Load",6,0.6)
			SSHL GHIJ 1
			SSHL K 2
			SSHL LMNO 2 //1
			SSHL P 1 A_PlaySound("Quadshot/Load",5,0.6)
			SSHL QRSTU 1
			SSHL V 2
			SSHC ABDE 2 //1
			SSHO R 0 A_PlaySound("Quadshot/Close",6,0.7)
			SSHO RQONKI 1
			SSHN GFDCB 1
			SSHG A 12
			SSHG A 3
			SSHG A 0 A_TakeInventory("QuadSingleShotUsed",4)
			Goto Ready
		Flash:
			TNT1 A 3 Bright
			TNT1 A 2 Bright
			Goto LightDone
		DoKick:
			TNT1 A 0
			TNT1 A 0 //A_ZoomFactor(1.0)
			TNT1 A 0 A_jumpifinventory("PowerStrength",1,"BerserkerKick")
			TNT1 A 0 A_PlaySound("KICK")
			TNT1 A 0 SetPlayerProperty(0,1,0)
			KICK BCD 1
			RIFF A 0 A_FireCustomMissile("KickAttack", 0, 0, 0, -7)
			KICK H 4
			KICK A 0 A_Takeinventory("Kicking",1)
			KICK IGFEDCBA 1 
			TNT1 A 0 SetPlayerProperty(0,0,0)
			Goto Ready
			BerserkerKick:
			TNT1 A 0 A_PlaySound("KICK")
			TNT1 A 0 SetPlayerProperty(0,1,0)
			KICK ABCDEFG 1
			RIFF A 0 A_FireCustomMissile("SuperKickAttack", 0, 0, 0, -7)
			KICK H 3
			KICK A 0 A_Takeinventory("Kicking",1)
			KICK IGFEDCBA 1 
			TNT1 A 0 SetPlayerProperty(0,0,0)
			Goto Ready
		}
}


//QSSG sound on walls
Actor MQSSG_Ricochet: FastProjectile
{
	-DONTSPLASH
	damagetype Cutless
	Projectile
	+RANDOMIZE
	+FORCEXYBILLBOARD
	+DONTSPLASH 
    +NOEXTREMEDEATH
	+CLIENTSIDEONLY
	damage 0
	radius 2
	height 2
	speed 140
	renderstyle ADD
	alpha 0.9
	scale .15
states
{
Spawn:
	TNT1 A 1 BRIGHT
	Loop
Death:
	TNT1 A 0 A_PlaySound("ricochet/hit")
    Stop
XDeath:
	TNT1 A 0 A_PlaySound("ricochet/hit")
	Stop
} }

//QSSG visual ricochet on walls
ACTOR MQSSG_Puff
{
  DamageType "MarineDamage"
  +NOBLOCKMAP
  +NOGRAVITY
  +ALLOWPARTICLES
  +RANDOMIZE
  RenderStyle ADD //Translucent
  Alpha 1.5
  VSpeed 1
  Mass 7 //5
  States
  {
  Spawn:
    SX58 ABCDEFGHJ 1
    Stop
  }
}



