local v=script.Parent local N=v.Ammo local u=N.Value local j local a local l function onChanged(v)if v=="\086\097\108\117\101"or v==N.Value then if a~=nil and l~=nil then if N.Value>=1 then l.Text=""..(script.Parent.Ammo.Value..("\124"..(script.Parent.StoredAmmo.Value.."")))elseif math.floor(N.Value)==0 then l.Text=""..(script.Parent.Ammo.Value..("\124"..(script.Parent.StoredAmmo.Value.."")))elseif N.Value<0 then for v=0,1,.015 do local N=math.floor(v*u+.5)l.Text=""..(script.Parent.Ammo.Value..("\124"..(script.Parent.StoredAmmo.Value.."")))wait()end end end end end function on2Changed()if a~=nil and l~=nil then l.Text=""..(script.Parent.Ammo.Value..("\124"..(script.Parent.StoredAmmo.Value.."")))wait()end end function setUpGui()if j==nil or j:findFirstChild("\080\108\097\121\101\114\071\117\105")==nil then return end a=Instance.new("\083\099\114\101\101\110\071\117\105")l=Instance.new("\084\101\120\116\076\097\098\101\108")a.Name="\068\069\068\105\115\112\108\097\121"a.Parent=j.PlayerGui l.BackgroundColor3=(BrickColor.Black()).Color l.BackgroundTransparency=1 l.BorderColor3=(BrickColor.White()).Color l.BorderSizePixel=0 l.Name="\065\109\109\111"l.Parent=a l.Position=UDim2.new(.85,0,.825,0)l.Size=UDim2.new(0,128,0,64)l.FontSize="\083\105\122\101\049\056"l.Text=""..(script.Parent.Ammo.Value..("\124"..(script.Parent.StoredAmmo.Value.."")))l.TextColor3=(BrickColor.White()).Color end function onEquippedLocal(v)j=game.Players.LocalPlayer setUpGui()end function onUnequippedLocal(v)if a then a:remove()end a=nil l=nil j=nil end v.Equipped:connect(onEquippedLocal)v.Unequipped:connect(onUnequippedLocal)N.Changed:connect(onChanged)v.StoredAmmo.Changed:connect(on2Changed)
-- Thanks for SonicUnleashedXY & Manofthelol for this script.
-- To remove the orginial script just go into shooter & right at the bottem you will see something like this:
-- script.Parent.Tool.Name = ""..script.Parent.Ammo.Value.."|"..script.Parent.StoredAmmo.Value..""
-- Remove only that & add this to the tool.
-- Remember this was designed for Manofthelol weapons so any other weapons might not work.
-- You have no permission to repubish this in you model even if it edited.
-- If your found then you will be ban from my place.

local Tool = script.Parent
local Ammo = Tool.Ammo
local MaxAmmo = Ammo.Value

local vPlayer
local Gui
local Text

function onChanged(value)
	if value == "Value" or value == Ammo.Value then
		if Gui ~= nil and Text ~= nil then
			if Ammo.Value >= 1 then
				Text.Text = "" .. script.Parent.Ammo.Value .. "|" .. script.Parent.StoredAmmo.Value .. ""
			elseif math.floor(Ammo.Value) == 0 then
				Text.Text = "" .. script.Parent.Ammo.Value .. "|" .. script.Parent.StoredAmmo.Value .. ""
			elseif Ammo.Value < 0 then
				for i = 0, 1, 0.03 / 2 do
					local Num = math.floor(i * MaxAmmo + 0.5)

					Text.Text = "" .. script.Parent.Ammo.Value .. "|" .. script.Parent.StoredAmmo.Value .. ""
					wait()
				end
			end
		end
	end
end

function on2Changed()
	if Gui ~= nil and Text ~= nil then
		Text.Text = "" .. script.Parent.Ammo.Value .. "|" .. script.Parent.StoredAmmo.Value .. ""
		wait()
	end
end

function setUpGui()
	if vPlayer == nil or vPlayer:findFirstChild("PlayerGui") == nil then
		return
	end

	Gui = Instance.new("ScreenGui")
	Text = Instance.new("TextLabel")

	Gui.Name = "DEDisplay"
	Gui.Parent = vPlayer.PlayerGui

	Text.BackgroundColor3 = BrickColor.Black().Color
	Text.BackgroundTransparency = 1
	Text.BorderColor3 = BrickColor.White().Color
	Text.BorderSizePixel = 0
	Text.Name = "Ammo"
	Text.Parent = Gui
	Text.Position = UDim2.new(0.85, 0, 0.825, 0)
	Text.Size = UDim2.new(0, 128, 0, 64)
	Text.FontSize = "Size18"
	Text.Text = "" .. script.Parent.Ammo.Value .. "|" .. script.Parent.StoredAmmo.Value .. ""
	Text.TextColor3 = BrickColor.White().Color
end

function onEquippedLocal(mouse)
	vPlayer = game.Players.LocalPlayer

	setUpGui()
end

function onUnequippedLocal(mouse)
	if Gui then
		Gui:remove()
	end

	Gui = nil
	Text = nil
	vPlayer = nil
end

Tool.Equipped:connect(onEquippedLocal)
Tool.Unequipped:connect(onUnequippedLocal)

Ammo.Changed:connect(onChanged)
Tool.StoredAmmo.Changed:connect(on2Changed)
