local Player = game:GetService("Players")
local ReplicatedStorage = game:GetService("ReplicatedStorage")
local UserInputService = game:GetService("UserInputService")
local Player = [Link]
ww
local CombatClient = {}
CombatClient.__index = CombatClient
local Configs = {
ComboLengths = 4,
TimeBetweenHits = .5,
EndCooldown = 1.5,
AnimationIds = {
"",
"",
"",
"",
function CombatClient. new(playerobj: Player)
local self = setmetatable({}, CombatClient)
[Link] = playerobj
[Link] = [Link]
[Link] = [Link] or [Link]:Wait()
[Link] = true
[Link] = nil
[Link] = false
[Link] =nil
[Link]:Connect(function(char)
self:bindCharacter(char)
end)
self:bindInput
return self
end
function ComboClient:bindCharacter(character)
[Link] = character
[Link] = [Link]("Humanoid")
[Link] = [Link]:WaitForChild("Animator")
[Link] = animator
self:loadAnimations()
end
function ComboClient:loadAnimations()
[Link] = {}
for i,id in [Link] do
local anim = [Link]("Animation")
[Link] = id
[Link][i] = [Link]:LoadAnimation(anim)
end
end
function CombatClient: bindInput ()
[Link]:Connect(function(input,
gameProcessed)
if gameProcessed then return end
if [Link] == [Link].MouseButton1
then
self:StartCombo()
end
end)
end
function CombatClient:StartCombo()
if not [Link] or [Link] then return end
if not [Link] or not [Link] or [Link]
<= 0 then return end
local now = tick()
if [Link] > 0 and now - [Link] <
[Link] then return end
if [Link]
end
end
function CombatClient:PlayCombo()
for i = 1, [Link] do
local track = [Link][i]
if track then
track:Play()
end
[Link]:FireServer("Hit" .. i)
if i < [Link] then
[Link]([Link])
end
end
end
local controller = [Link](Player)