-- Make the AnimBase
	L_15_ = Instance.new("Part", L_3_)
	L_15_.FormFactor = "Custom"
	L_15_.CanCollide = false
	L_15_.Transparency = 1
	L_15_.Anchored = false
	L_15_.Name = "AnimBase"
	
	L_16_ = Instance.new("Motor6D")
	L_16_.Part0 = L_15_
	L_16_.Part1 = L_43_
	L_16_.Parent = L_15_
	L_16_.Name = "AnimBaseW"
	--AnimBaseW.C1 = gunSettings.StartPose	
	
	L_12_ = Instance.new("Motor6D")
	L_12_.Part0 = L_3_['Right Arm']
	L_12_.Part1 = L_1_:FindFirstChild('Grip')
	L_12_.Parent = L_3_['Right Arm']
	L_12_.C1 = L_11_.GunPos
	L_12_.Name = "Grip"
	
	for L_45_forvar1, L_46_forvar2 in pairs(L_1_:GetChildren()) do
		if L_46_forvar2:IsA("Part") or L_46_forvar2:IsA("MeshPart") or L_46_forvar2:IsA("UnionOperation") then
			L_46_forvar2.Anchored = true
			
			if L_46_forvar2.Name ~= "Grip" and L_46_forvar2.Name ~= "Bolt" and L_46_forvar2.Name ~= 'Lid' then
				Weld(L_46_forvar2, L_1_:WaitForChild("Grip"))
			end
			
			if L_46_forvar2.Name == "Bolt" then
				if L_1_:FindFirstChild('BoltHinge') then
					Weld(L_46_forvar2, L_1_:WaitForChild("BoltHinge"))
				else
					Weld(L_46_forvar2, L_1_:WaitForChild("Grip"))
				end
			end;
			
			if L_46_forvar2.Name == "Lid" then
				if L_1_:FindFirstChild('LidHinge') then
					Weld(L_46_forvar2, L_1_:WaitForChild("LidHinge"))
				else
					Weld(L_46_forvar2, L_1_:WaitForChild("Grip"))
				end
			end
		end
	end
	
	for L_47_forvar1, L_48_forvar2 in pairs(L_1_:GetChildren()) do
		if L_48_forvar2:IsA("Part") or L_48_forvar2:IsA("MeshPart") or L_48_forvar2:IsA("UnionOperation") then
			L_48_forvar2.Anchored = false
		end
	end
	
	L_17_ = L_3_['Right Arm']
	L_18_ = L_3_['Left Arm']
	L_21_ = L_3_.Torso:WaitForChild("Right Shoulder")
	L_22_ = L_3_.Torso:WaitForChild("Left Shoulder")
	
	L_19_ = Instance.new("Motor6D")
	L_19_.Name = "RAW"
	L_19_.Part0 = L_15_
	L_19_.Part1 = L_17_
	L_19_.Parent = L_15_
	L_19_.C1 = L_11_.RightArmPos
	L_3_.Torso:WaitForChild("Right Shoulder").Part1 = nil
		
	L_20_ = Instance.new("Motor6D")
	L_20_.Name = "LAW"
	L_20_.Part0 = L_15_
	L_20_.Part1 = L_18_
	L_20_.Parent = L_15_
	L_20_.C1 = L_11_.LeftArmPos
	L_3_.Torso:WaitForChild("Left Shoulder").Part1 = nil
	
	if L_27_ then
		L_27_:Destroy()
	end
	
	L_28_:FireClient(L_2_, true, L_12_, L_15_, L_16_, L_19_, L_20_, L_14_)
end)

L_1_.Unequipped:connect(function()
	local L_49_ = L_3_:FindFirstChild('Torso')
	local L_50_ = L_3_:FindFirstChild('Head')
	L_27_ = Instance.new('Model', L_3_)
	L_27_.Name = "HolsterModel"
	
	for L_51_forvar1, L_52_forvar2 in pairs(L_1_:GetChildren()) do
		for L_53_forvar1, L_54_forvar2 in pairs(L_52_forvar2:GetChildren()) do
			if L_54_forvar2.ClassName == "Motor6D" then
				L_54_forvar2:Destroy()
			end
		end
	end
	
	for L_55_forvar1, L_56_forvar2 in pairs(L_1_:GetChildren()) do
		if L_56_forvar2:IsA("Part") or L_56_forvar2:IsA("MeshPart") or L_56_forvar2:IsA("UnionOperation") then
			L_56_forvar2.Anchored = true
		end
	end
	
	if L_3_.Humanoid and L_3_.Humanoid.Health > 0 then
		L_3_.HumanoidRootPart.RootJoint.C0 = CFrame.new(0, 0, 0, -1, 0, 0, 0, 0, 1, 0, 1, -0)
		L_49_['Right Hip'].C0 = CFrame.new(1, -1, 0, 0, 0, 1, 0, 1, -0, -1, 0, 0)
		L_49_['Left Hip'].C0 = CFrame.new(-1, -1, 0, 0, 0, -1, 0, 1, 0, 1, 0, 0)
		L_14_.C0 = CFrame.new(0, 1, 0, -1, 0, 0, 0, 0, 1, 0, 1, -0)
		
		L_3_.HumanoidRootPart.RootJoint.C1 = CFrame.new(0, 0, 0, -1, -0, -0, 0, 0, 1, 0, 1, 0)
		L_49_['Right Hip'].C1 = CFrame.new(0.5, 1, 0, 0, 0, 1, 0, 1, 0, -1, -0, -0)
		L_49_['Left Hip'].C1 = CFrame.new(-0.5, 1, 0, -0, -0, -1, 0, 1, 0, 1, 0, 0)
		L_14_.C1 = CFrame.new(0, -0.5, 0, -1, -0, -0, 0, 0, 1, 0, 1, 0)
	end
	
	L_49_:WaitForChild("Neck").Part1 = L_50_
	L_49_:WaitForChild("Neck").C1 = L_49_:WaitForChild("Neck").C1
	L_49_:WaitForChild("Neck").C0 = L_49_:WaitForChild("Neck").C0
	
	L_15_:Destroy()
	L_14_:Destroy()
	L_21_.Part1 = L_17_
	L_22_.Part1 = L_18_
	
	L_28_:FireClient(L_2_, false)
	
	if L_11_.HolsteringEnabled then
		for L_58_forvar1, L_59_forvar2 in pairs(L_1_:GetChildren()) do
			if L_59_forvar2:IsA("Part") or L_59_forvar2:IsA("MeshPart") or L_59_forvar2:IsA("UnionOperation") then
				L_59_forvar2.Anchored = true
				local L_60_ = L_59_forvar2:clone()
				L_60_.Parent = L_27_
			end
		end;
		
		for L_61_forvar1, L_62_forvar2 in pairs(L_27_:GetChildren()) do
			Weld(L_62_forvar2, L_27_:WaitForChild("Grip"))
		end
		
		local L_57_ = Weld(L_27_:WaitForChild("Grip"), L_3_:WaitForChild('Torso'))
		L_57_.Name = "TWeld"
		L_57_.C1 = L_11_.HolsterPos
		
		for L_63_forvar1, L_64_forvar2 in pairs(L_27_:GetChildren()) do
			L_64_forvar2.Anchored = false
		end
	end
end)

L_3_.Humanoid.Died:connect(function()	
	L_28_:FireClient(L_2_, false)
end)