script:
local rp = game:GetService("ReplicatedStorage") local Barrage = rp:WaitForChild("Stand1Remotes"):WaitForChild("Barrage")
local TweenService = game:GetService("TweenService")
local Animations = script:WaitForChild("Animations")
local SSS = game:GetService("ServerScriptService") local Library = SSS:WaitForChild("Library") local DictionaryHandler = require(Library:WaitForChild("DictionaryHandler"))
local Barrage_Hander = require(script.Barrage_Handler)
Barrage.OnServerEvent:Connect(function(Player,isActive) local Character = Player.Character local Humanoid = Character.Humanoid local HumanoidRP = Character.HumanoidRootPart
if not DictionaryHandler.findPlayer(Humanoid,"Stunned") and not DictionaryHandler.findPlayer(Humanoid,"Blocking") then
if isActive then
local Stand = Character.FindFirstChild("Stand")
if Stand then
local AnimControl = Stand:FindFirstChild("AnimControl")
if AnimControl then
local Controller = Stand.PrimaryPart:FindFirstChild("Controller")
if Controller then
local Folder = Instance.new("Folder",Character)
Folder.Name = "Effects"
Humanoid.Walkspeed = 4
Humanoid.JumpPower = 0
local goal = {}
goal.C0 = Controller.Part0.CFrame:ToObjectSpace(Controller.Part1.CFrame)
goal.C1 = Controller.Part0.CFrame:ToObjectSpace(Controller.Part1.CFrame * CFrame.new(0,.25,-2))
local info = TweenInfo.new(.1)
local Tween = TweenService:Create(Controller, info, goal)
Tween:Play()
Tween.Completed:Connect(function()
Tween:Destroy()
local punching = AnimControl:LoadAnimation(Animations.Barrage)
punching:Play()
end)
end
end
else
Barrage:FireClient(Player)
end
else
end
else
Barrage:FireClient(Player)
end
end)
Local script:
local player = game:GetService("Players").LocalPlayer
local rp = game:GetService("ReplicatedStorage") local Barrage = rp:WaitForChild("Stand1Remotes"):WaitForChild("Barrage")
local UIS = game:GetService("UserInputService") local runservice = game:GetService("RunService")
local debounce = false local IsActive = false local cd = 1
UIS.InputBegan:Connect(function(input,isTyping) if isTyping then return elseif input.KeyCode == Enum.KeyCode.E then if debounce == false and IsActive == false then debounce = true IsActive = true
Barrage:FireServer(IsActive)
wait(.1)
debounce = false
end
end
end)
Barrage.OnClientEvent:Connect(function() wait(cd) debounce = false IsActive = false end)
runservice.Heartbeat:Connect(function() UIS.InputEnded:Connect(function(input) if input.KeyCode == Enum.KeyCode.E then if debounce == false and IsActive == true then debounce = true IsActive = false
Barrage:FireServer(IsActive)
end
end
end)
end)
