my code
local reload_sound = script.Parent.Reload
local tool = script.Parent
local handle = tool.Handle
local userInputService = game:GetService("UserInputService")
local debounce = false
local player = game:GetService("Players").LocalPlayer
userInputService.InputBegan:Connect(function(input, gameProcessedEvent)
if input.KeyCode == Enum.KeyCode.R then
if tool.Parent == player.Character and script.Parent.AmmoValue.Value < 30 then
reload_sound:Play()
script.Parent.AmmoValue.Value = 30 -- what i want to change
else
end
end
end)
