local rs = game:GetService("ReplicatedStorage")
local strikeRe = rs:WaitForChild("StrikeRe")
local uis = game:GetService("UserInputService")
local canStrike = true
local hookCoolDown = .3
local hookKey = Enum.UserInputType.MouseButton1
local player = game:GetService("Players").LocalPlayer
local char = player.Character or player.CharacterAdded:Wait()
local hum = char:WaitForChild("Humanoid")
local hookAnim = script:WaitForChild("HookAnim")
local hookAnimTrak = hum.Animator:LoadAnimation(hookAnim)
local snd = script:WaitForChild("Sound")
local function hookPunch()
if canStrike and hum.Health > 0 then
canStrike = false
print("We are doing a hook punch")
hookAnimTrak:Play()
snd:Play()
strikeRe:FireServer("Hook")
wait(hookCoolDown)
canStrike = true
end
end
uis.InputBegan:Connect(function(input, gameProcess)
if input.UserInputType == hookKey then
hookPunch()
end
end)
** You are now Level 1! **