ACTOR MKRifle : Weapon Replaces Pistol
{
	Weapon.AmmoUse1 0
	Weapon.AmmoGive1 15
	Weapon.AmmoUse2 0
	Weapon.AmmoGive2 0
	Weapon.AmmoType1 "Clip2"
	Weapon.AmmoType2 "MKAmmo"
	Weapon.BobRangeX 0.3
	Weapon.BobRangeY 1.0
	Weapon.BobStyle Alpha
	Weapon.BobSpeed 2.0
	Obituary "%k [MK61] %0"
    AttackSound "None"
    Inventory.PickupSound "MKGET"
	Inventory.Pickupmessage "MK61"
	Tag "MK61"
	+WEAPON.WIMPY_WEAPON
    +WEAPON.NOAUTOAIM
    +WEAPON.NOALERT
    +WEAPON.NOAUTOFIRE
    Scale 0.9
	States
	{
	PickUp:
	TNT1 A 0 A_Playsound("PICKUPONELINER")
	TNT1 A 0
	Stop
	
	Steady:
	TNT1 A 1
	Goto Ready
	
	Ready:
        TNT1 A 1 A_JumpIfInventory("GoFatality", 1, "Steady")
        TNT1 A 0 A_PlaySound("MKGET")
        MKFS ABC 1
        TNT1 AAAAAAAA 0
        TNT1 A 0 //A_JumpIfInventory("SigAmmo",1,2)
        //Goto Reload
        TNT1 AAAA 0

        TNT1 A 0 A_JumpIfInventory("Kicking",1,"DoKick")
        TNT1 A 0 A_JumpIfInventory("Taunting",1,"Taunt")
		TNT1 A 0 A_JumpIfInventory("Salute1", 1, "Salute")
		TNT1 A 0 A_JumpIfInventory("Salute2", 1, "Salute")
        TNT1 A 0 A_JumpIfInventory("Reloading",1,"Reload")
		MKFG A 4 A_WeaponReady
		
	    TNT1 A 0 A_JumpIfInventory("Kicking",1,"DoKick")
        TNT1 A 0 A_JumpIfInventory("Taunting",1,"Taunt")
		TNT1 A 0 A_JumpIfInventory("Salute1", 1, "Salute")
		TNT1 A 0 A_JumpIfInventory("Salute2", 1, "Salute")
        TNT1 A 0 A_JumpIfInventory("Reloading",1,"Reload")
		MKFG A 4 A_WeaponReady
		
		TNT1 A 0 A_JumpIfInventory("Kicking",1,"DoKick")
        TNT1 A 0 A_JumpIfInventory("Taunting",1,"Taunt")
		TNT1 A 0 A_JumpIfInventory("Salute1", 1, "Salute")
		TNT1 A 0 A_JumpIfInventory("Salute2", 1, "Salute")
        TNT1 A 0 A_JumpIfInventory("Reloading",1,"Reload")
		MKFG A 4 A_WeaponReady
		
		TNT1 A 0 A_JumpIfInventory("Kicking",1,"DoKick")
        TNT1 A 0 A_JumpIfInventory("Taunting",1,"Taunt")
		TNT1 A 0 A_JumpIfInventory("Salute1", 1, "Salute")
		TNT1 A 0 A_JumpIfInventory("Salute2", 1, "Salute")
        TNT1 A 0 A_JumpIfInventory("Reloading",1,"Reload")
		MKFG A 4 A_WeaponReady
		
		TNT1 A 0 A_JumpIfInventory("Kicking",1,"DoKick")
        TNT1 A 0 A_JumpIfInventory("Taunting",1,"Taunt")
		TNT1 A 0 A_JumpIfInventory("Salute1", 1, "Salute")
		TNT1 A 0 A_JumpIfInventory("Salute2", 1, "Salute")
        TNT1 A 0 A_JumpIfInventory("Reloading",1,"Reload")
		MKFG A 4 A_WeaponReady
        //TNT1 A 0 BRIGHT A_FireCustomMissile("Alerter", random(-2,2), 0, -1, 0)
		Goto Ready+9
    Ready2:
        TNT1 A 0 A_JumpIfInventory("Kicking",1,"DoKick")
        TNT1 A 0 A_JumpIfInventory("Taunting",1,"Taunt")
        TNT1 A 0 A_JumpIfInventory("Reloading",1,"Reload")
		TNT1 A 0 A_JumpIfInventory("Salute1", 1, "Salute")
		TNT1 A 0 A_JumpIfInventory("Salute2", 1, "Salute")
		MK2G A 2 A_WeaponReady
		Loop
	Deselect:
		TNT1 A 0 A_Takeinventory("Zoomed",1)
        TNT1 A 0 A_ZoomFactor(1.0)
        MKFS CBA 1
		TNT1 A 0 A_Takeinventory("ADSmode",1)
		TNT1 A 1 A_Lower
		Wait
	Select:
	
	TNT1 A 0 A_Takeinventory("FistsSelected",1)
	TNT1 A 0 A_Takeinventory("SawSelected",1)
	TNT1 A 0 A_Takeinventory("ShotgunSelected",1)
	TNT1 A 0 A_Takeinventory("SSGSelected",1)
	TNT1 A 0 A_Takeinventory("MinigunSelected",1)
	TNT1 A 0 A_Takeinventory("PlasmaGunSelected",1)
	TNT1 A 0 A_Takeinventory("RocketLauncherSelected",1)
    TNT1 A 0 A_Takeinventory("GrenadeLauncherSelected",1)
	TNT1 A 0 A_Takeinventory("BFGSelected",1)
	TNT1 A 0 A_Takeinventory("BFG10kSelected",1)
	TNT1 A 0 A_Takeinventory("RailGunSelected",1)
	TNT1 A 0 A_Takeinventory("SubMachineGunSelected",1)
	TNT1 A 0 A_Takeinventory("RevenantLauncherSelected",1)
	TNT1 A 0 A_Takeinventory("LostSoulSelected",1)
	TNT1 A 0 A_Takeinventory("FlameCannonSelected",1)
	TNT1 A 0 A_Takeinventory("HasBarrel",1)
	
		TNT1 A 0 A_Raise
		Wait
    Fire:
        TNT1 A 0 A_JumpIfInventory("MKAmmo",1,2)
        Goto Reload
        TNT1 AAAA 0
		
		
		
		
		TNT1 A 0 A_JumpIfInventory("Zoomed",1,"Fire2")
		TNT1 A 0 A_PlaySound("MKFIRE2",1)
        TNT1 A 0 A_PlaySound("MKFIRE", 3)
        //TNT1 A 0 A_FireCustomMissile("SmokeSpawner",0,0,0,5)
		MKFF A 1 BRIGHT A_AlertMonsters
		TNT1 A 0 A_FireCustomMissile("YellowFlareSpawn",0,0,0,0)
		MKFF B 1 BRIGHT A_FireBullets (4, 4, -1, 35, "HitPuff")
        MKFF A 0 A_FireCustomMissile("MinigunTracer2", random(-2,2), 0, -1, 0)
		MKFF D 0 A_FireCustomMissile("MinigunTracer2", random(-2,2), 0, -1, 0)
		MKFF A 0 A_FireCustomMissile("MinigunTracer2", random(-2,2), 0, -1, 0)
		MKFF D 0 A_FireCustomMissile("MinigunTracer2", random(-2,2), 0, -1, 0)
		MKFF A 0 A_FireCustomMissile("MinigunTracer2", random(-2,2), 0, -1, 0)
		MKFF D 0 A_FireCustomMissile("MinigunTracer2", random(-2,2), 0, -1, 0)
        //TNT1 A 0 ACS_Execute(373, 0, 0, 0, 0)
		TNT1 A 0 A_FireCustomMissile("ShakeYourAssMinor", 0, 0, 0, 0)
		TNT1 A 0 A_FireCustomMissile("YellowFlareSpawn",0,0,0,0)
		TNT1 A 0 A_Takeinventory("MKAmmo",1)
		TNT1 A 0 A_setpitch(Pitch-0.55)
		MKFF C 1 A_FireCustomMissile("RifleCaseSpawn",5,0,8,-9)
        //SIFG A 2
		MKFG A 1 A_Refire
		//SIFG A 7 A_WeaponReady(1)
		Goto Ready+6

      Fire2:
        TNT1 A 0 A_PlaySound("MKFIRE2",1)
        TNT1 A 0 A_PlaySound("MKFIRE", 3)
        //TNT1 A 0 A_FireCustomMissile("SmokeSpawner",0,0,0,5)
		MK2G A 0 A_AlertMonsters
		TNT1 A 0 A_FireCustomMissile("YellowFlareSpawn",0,0,0,5)
		MK2F A 1 BRIGHT A_FireBullets (2, 2, -1, 35, "HitPuff")
        MK2F A 0 BRIGHT A_FireCustomMissile("MinigunTracer2", 0, 0, -1, 0)
		MK2F A 0 BRIGHT A_FireCustomMissile("MinigunTracer2", 0, 0, -1, 0)
		MK2F A 0 BRIGHT A_FireCustomMissile("MinigunTracer2", 0, 0, -1, 0)
		MK2F A 0 BRIGHT A_FireCustomMissile("MinigunTracer2", 0, 0, -1, 0)
		MK2F A 0 BRIGHT A_FireCustomMissile("MinigunTracer2", 0, 0, -1, 0)
		MK2F A 0 BRIGHT A_FireCustomMissile("MinigunTracer2", 0, 0, -1, 0)
		MK2F A 0 BRIGHT A_FireCustomMissile("MinigunTracer2", 0, 0, -1, 0)
		MK2F A 0 BRIGHT A_FireCustomMissile("MinigunTracer2", 0, 0, -1, 0)
        //TNT1 A 0 ACS_Execute(373, 0, 0, 0, 0)
		TNT1 A 0 A_FireCustomMissile("ShakeYourAssMinor", 0, 0, 0, 0)
		TNT1 A 0 A_Takeinventory("MKAmmo",1)
		TNT1 A 0 A_setpitch(Pitch-0.55)
		MK2F B 1 A_WeaponReady(1)
		TNT1 A 0 A_FireCustomMissile("RifleCaseSpawn",-2,0,8,0)
        MK2F C 1 A_WeaponReady(1)
        //SI2F B 0
		//SI2G A 2 A_WeaponReady(1)
		TNT1 A 0 A_Refire
		MK2G A 10 A_WeaponReady(1)
        //SI2G A 0
		Goto Ready2

    AltFire:
        TNT1 A 0
		TNT1 A 0 A_JumpIfInventory("Zoomed",1,8)
		TNT1 A 0 A_Giveinventory("Zoomed",1)
		TNT1 A 0 A_Giveinventory("GoSpecial",1)
        TNT1 A 0 A_ZoomFactor(2.3)
		TNT1 A 0 A_Giveinventory("ADSmode",1)
        MKFZ AB 1
        Goto Ready2
        TNT1 AAAAAA 0
        MKFZ BA 1
		TNT1 A 0 A_Takeinventory("Zoomed",1)
        TNT1 A 0 A_ZoomFactor(1.0)
		TNT1 A 0 A_Takeinventory("ADSmode",1)
        Goto Ready+6
		
	NoAmmo:
	MKFG A 1 A_PlaySound("weapons/empty")
	TNT1 A 0 A_Takeinventory("Zoomed",1)
    TNT1 A 0 A_ZoomFactor(1.0)
	TNT1 A 0 A_Takeinventory("ADSmode",1)
	Goto Ready+12
	
    Reload:
		MKFG A 1 A_WeaponReady
		TNT1 A 0 A_ZoomFactor(1.0)
		TNT1 A 0 A_Takeinventory("Reloading",1)
		TNT1 A 0 A_Takeinventory("ADSmode",1)
		TNT1 A 0 A_Takeinventory("Zoomed",1)
		TNT1 A 0 A_JumpIfInventory("MKAmmo",100,64)

        TNT1 A 0 A_JumpIfInventory("Clip2",1,3)
        Goto NoAmmo
        TNT1 AAA 0
		TNT1 A 0 A_Takeinventory("Zoomed",1)
		TNT1 A 0 A_GiveInventory ("Pumping", 1)
		TNT1 A 0 A_Takeinventory("Reloading",1)
        MKFR ABC 1 A_JumpIfInventory("Kicking",1,"DoKick") 
		MKFR DE 1 A_PlaySound("MAGOUT", 1)
        MKFR F 1 A_FireCustomMissile("EmptyDrumSpawn",-5,0,8,-4)
		//Offset(-12,12) Original for Frame G
		MKFR G 30 A_JumpIfInventory("Kicking",1,"DoKick")
		MKFR HIJ 1 A_JumpIfInventory("Kicking",1,"DoKick") 
		MKFR J 1 A_PlaySound("MAGIN")
		MKFR KLMMMMMNOPQRST 1 A_JumpIfInventory("Kicking",1,"DoKick") 
		//Offset(-16,0) For the new snapping animations for the Reload
		MKFR T 5 A_JumpIfInventory("Kicking",1,"DoKick")
		MKFR U 1 A_JumpIfInventory("Kicking",1,"DoKick")
		MKFR V 1 A_JumpIfInventory("Kicking",1,"DoKick")
		MKFR W 1 A_JumpIfInventory("Kicking",1,"DoKick")
		MKFR X 1 A_JumpIfInventory("Kicking",1,"DoKick")
		MKFR Y 3 A_JumpIfInventory("Kicking",1,"DoKick")
		MKFR Z 1 A_JumpIfInventory("Kicking",1,"DoKick")
		TNT1 A 0 A_PlaySound("weapons/sgmvpump", 5)
		MKR2 A 1 A_JumpIfInventory("Kicking",1,"DoKick")
		MKR2 B 10 A_JumpIfInventory("Kicking",1,"DoKick")
		
		InsertBullets:
		TNT1 AAAA 0
		TNT1 A 0 A_JumpIfInventory("MKAmmo",100,15)
		TNT1 A 0 A_JumpIfInventory("Clip2",1,3)
		Goto Ready+6
        TNT1 AAAAAA 0
		TNT1 A 0 A_Giveinventory("MKAmmo",1)
		TNT1 A 0 A_Takeinventory("Clip2",1)
		Goto InsertBullets
		
		TNT1 AAAAAAAAAA 0
		TNT1 A 0 A_Takeinventory("Reloading",1)
        Goto Ready+6
		TNT1 AAAA 0
				TNT1 A 0 A_Takeinventory("Reloading",1)
        Goto Ready+6
 	Spawn:
		RIFL E -1
		Stop
		
		
    DoKick:
	    TNT1 A 0
		TNT1 A 0 A_Takeinventory("Zoomed",1)
        TNT1 A 0 A_ZoomFactor(1.0)
		TNT1 A 0 A_Takeinventory("ADSmode",1)
		NULL A 0 A_JumpIf (momZ > 0, "AirKick")
		NULL A 0 A_JumpIf (momZ < 0, "AirKick")
		
        TNT1 A 0 A_jumpifinventory("PowerStrength",1,"BerserkerKick")
		TNT1 A 0 A_PlaySound("KICK")
		TNT1 A 0 SetPlayerProperty(0,1,0)
		KICK BCD 1
		//TNT1 A 0 A_Custompunch(4,0,1,"KickPuff")
		MKFF 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 A_JumpIfInventory("GoFatality", 1, "Steady")
		TNT1 A 0 SetPlayerProperty(0,0,0)
		Goto Ready+6
    BerserkerKick:
		TNT1 A 0 A_PlaySound("KICK")
		TNT1 A 0 SetPlayerProperty(0,1,0)
		KICK ABCDEFG 1
        MKFF 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 A_JumpIfInventory("GoFatality", 1, "Steady")
		TNT1 A 0 SetPlayerProperty(0,0,0)
		Goto Ready+6
	
	AirKick:
	    TNT1 A 0 A_jumpifinventory("PowerStrength",1,"SuperAirKick")
		TNT1 A 0 A_PlaySound("KICK")
		TNT1 A 0 A_Recoil (-6)
		KICK JKLMN 1
        MKFF A 0 A_FireCustomMissile("AirKickAttack", 0, 0, 0, -31)
        KICK O 3
		KICK A 0 A_Takeinventory("Kicking",1)
		KICK PQRST 2
		TNT1 A 0 A_JumpIfInventory("GoFatality", 1, "Steady")
		Goto Ready+6
		
	SuperAirKick:
		TNT1 A 0 A_PlaySound("KICK")
		TNT1 A 0 A_Recoil (-6)
		KICK JKLMN 1
        MKFF A 0 A_FireCustomMissile("SuperAirKickAttack", 0, 0, 0, -31)
        KICK O 3
		KICK A 0 A_Takeinventory("Kicking",1)
		KICK PQRST 2
		TNT1 A 0 A_JumpIfInventory("GoFatality", 1, "Steady")
		Goto Ready+6
    /*Taunt:
		TNT1 A 0 A_JumpIfInventory("IsPostal",1,"FlipOff1")
		TNT1 A 0 A_JumpIfInventory("IsQuaker540",1,"FlipOff2")
		TNT1 A 0 A_JumpIfInventory("IsNikolai",1,"FlipOff3")
		TNT1 A 0 A_JumpIfInventory("IsSgtDoomguy5th",1,"FlipOff4")
		TNT1 A 0 A_JumpIfInventory("IsCommander",1,"FlipOff5")
		TNT1 A 0 A_JumpIfInventory("IsDukeNukem",1,"FlipOff6")
		TNT1 A 0 A_Takeinventory("Zoomed",1)
		Goto Ready+14
	FlipOff1:
		TNT1 A 0 A_ZoomFactor(1.0)
        TNT1 A 5
		FUCK A 2
		TNT1 A 0 BRIGHT A_FireCustomMissile("Taunter", 0, 0, -1, 0)
		TNT1 A 0 BRIGHT A_FireCustomMissile("Taunter", -9, 0, -1, 0)
		TNT1 A 0 BRIGHT A_FireCustomMissile("Taunter", 9, 0, -1, 0)
        FUCK B 2 A_PlaySound("PFUCK", 1)
        FUCK C 2 A_AlertMonsters
		FUCK D 15 A_Takeinventory("Taunting",1)
        FUCK CBA 5
        TNT1 A 5
		Goto Ready+14
	FlipOff2:
		TNT1 A 0 A_ZoomFactor(1.0)
        TNT1 A 5
		FUCK A 2
		TNT1 A 0 BRIGHT A_FireCustomMissile("Taunter", 0, 0, -1, 0)
		TNT1 A 0 BRIGHT A_FireCustomMissile("Taunter", -9, 0, -1, 0)
		TNT1 A 0 BRIGHT A_FireCustomMissile("Taunter", 9, 0, -1, 0)
        FUCK B 2 A_PlaySound("DFUCK", 1)
        FUCK C 2 A_AlertMonsters
		FUCK D 15 A_Takeinventory("Taunting",1)
        FUCK CBA 5
        TNT1 A 5
		Goto Ready+14
	FlipOff3:
		TNT1 A 0 A_ZoomFactor(1.0)
        TNT1 A 5
		FUCK A 2
		TNT1 A 0 BRIGHT A_FireCustomMissile("Taunter", 0, 0, -1, 0)
		TNT1 A 0 BRIGHT A_FireCustomMissile("Taunter", -9, 0, -1, 0)
		TNT1 A 0 BRIGHT A_FireCustomMissile("Taunter", 9, 0, -1, 0)
        FUCK B 2 A_PlaySound("NFUCK", 1)
        FUCK C 2 A_AlertMonsters
		FUCK D 15 A_Takeinventory("Taunting",1)
        FUCK CBA 5
        TNT1 A 5
		Goto Ready+14
	FlipOff4:
		TNT1 A 0 A_ZoomFactor(1.0)
        TNT1 A 5
		FUCK A 2
		TNT1 A 0 BRIGHT A_FireCustomMissile("Taunter", 0, 0, -1, 0)
		TNT1 A 0 BRIGHT A_FireCustomMissile("Taunter", -9, 0, -1, 0)
		TNT1 A 0 BRIGHT A_FireCustomMissile("Taunter", 9, 0, -1, 0)
        FUCK B 2 A_PlaySound("5FUCK", 1)
        FUCK C 2 A_AlertMonsters
		FUCK D 15 A_Takeinventory("Taunting",1)
        FUCK CBA 5
        TNT1 A 5
		Goto Ready+14
	FlipOff5:
		TNT1 A 0 A_ZoomFactor(1.0)
        TNT1 A 5
		FUCK A 2
		TNT1 A 0 BRIGHT A_FireCustomMissile("Taunter", 0, 0, -1, 0)
		TNT1 A 0 BRIGHT A_FireCustomMissile("Taunter", -9, 0, -1, 0)
		TNT1 A 0 BRIGHT A_FireCustomMissile("Taunter", 9, 0, -1, 0)
        FUCK B 2 A_PlaySound("TFUCK", 1)
        FUCK C 2 A_AlertMonsters
		FUCK D 15 A_Takeinventory("Taunting",1)
        FUCK CBA 5
        TNT1 A 5
		Goto Ready+14
	FlipOff6:
		TNT1 A 0 A_ZoomFactor(1.0)
        TNT1 A 5
		FUCK A 2
		TNT1 A 0 BRIGHT A_FireCustomMissile("Taunter", 0, 0, -1, 0)
		TNT1 A 0 BRIGHT A_FireCustomMissile("Taunter", -9, 0, -1, 0)
		TNT1 A 0 BRIGHT A_FireCustomMissile("Taunter", 9, 0, -1, 0)
        FUCK B 2 A_PlaySound("NUCK", 1)
        FUCK C 2 A_AlertMonsters
		FUCK D 15 A_Takeinventory("Taunting",1)
        FUCK CBA 5
        TNT1 A 5
		Goto Ready+14
	Salute:
	    TNT1 A 0 SetPlayerProperty(0,1,0)
		TNT1 A 0 A_ALertMonsters
		SALU ABCDEDCDEDCDEDCBA 4
		TNT1 A 0 A_TakeInventory("Salute1",1)
		TNT1 A 0 A_TakeInventory("Salute2",1)
		TNT1 A 0 SetPlayerProperty(0,0,0)
		Goto Ready*/
	}
}

//Actor Zoomed : Inventory
//{
//inventory.maxamount 1
//}

//-------------------------------------------

//Actor SigAmmo : Inventory
//{
//inventory.maxamount 40
//}
ACTOR MKAmmo : Ammo
{
   Inventory.Amount 0
   Inventory.MaxAmount 100
   Ammo.BackpackAmount 0
   Ammo.BackpackMaxAmount 100
   Inventory.Icon "RIFLA0"
}
