I have a weapon made by ROBLOX which I got in the toolbox which has several scripts that configure the gameplay of the player so far so good.
but I have a scroll script which works like this: robloxapp-20230306-2232406.wmv (1.5 MB)
when you don’t have the weapon it works fine but when you activate the weapon system it doesn’t work well. I know clearly that it is because of the scripts of the weapons, you do not have to tell me what I would like you to tell me is what would cause such a thing or what should I do to remove such an error or how would I counteract it, here I leave the script of the jumper:
local Players = game:GetService("Players")
local Player = Players.LocalPlayer
local Character = Player.Character or Player.CharacterAdded:Wait()
local Humanoid = Character:WaitForChild("Humanoid")
local Cam = workspace.CurrentCamera
local Settings = script:WaitForChild("Settings")
local RollTrack = Humanoid:LoadAnimation(Settings:WaitForChild("Roll"))
local Cooldown = Settings:WaitForChild("Cooldown")
local OnCooldown = false
local MaxForce = Vector3.new(math.huge,math.huge,math.huge)
local P = 1000
local Amount = 90
local UIS = game:GetService("UserInputService")
local RollButton = Player.PlayerGui:WaitForChild("Controls").Roll
local Vector = .1
--DashFunction
local BodyVelocity
local function Dash()
BodyVelocity = Instance.new("BodyVelocity")
if not Character.HumanoidRootPart:FindFirstChild("BodyVelocity") then
BodyVelocity.Parent = Character.HumanoidRootPart
BodyVelocity.MaxForce = MaxForce
BodyVelocity.P = P
game.Debris:AddItem(BodyVelocity, .2)
end
end
--Dash Connector--
UIS.InputBegan:Connect(function(input, Chat)
if Chat then return end
if input.KeyCode == Enum.KeyCode.E and not OnCooldown then OnCooldown = true
if (Humanoid.MoveDirection:Dot(Cam.CFrame.RightVector) > Vector) then
Dash()
RollTrack:Play()
BodyVelocity.Velocity = Character.HumanoidRootPart.CFrame.RightVector * Amount
print("Dashing Right")
elseif (Humanoid.MoveDirection:Dot(-Cam.CFrame.RightVector) > Vector) then
Dash()
RollTrack:Play()
BodyVelocity.Velocity = Character.HumanoidRootPart.CFrame.RightVector * -Amount
print("Dashing Left")
elseif (Humanoid.MoveDirection:Dot(Cam.CFrame.LookVector) > Vector) then
Dash()
RollTrack:Play()
BodyVelocity.Velocity = Character.HumanoidRootPart.CFrame.lookVector * Amount
print("Dashing Forward")
elseif (Humanoid.MoveDirection:Dot(-Cam.CFrame.LookVector) > Vector) then
Dash()
RollTrack:Play()
BodyVelocity.Velocity = Character.HumanoidRootPart.CFrame.lookVector * -Amount
print("Dashing Backward")
end
task.wait(Cooldown.Value)
wait(7)
OnCooldown = false
end
end)
--MobileConnector--
RollButton.MouseButton1Down:Connect(function()
if not OnCooldown then OnCooldown = true
if (Humanoid.MoveDirection:Dot(Cam.CFrame.RightVector) > Vector) then
Dash()
RollTrack:Play()
BodyVelocity.Velocity = Character.HumanoidRootPart.CFrame.RightVector * Amount
elseif (Humanoid.MoveDirection:Dot(-Cam.CFrame.RightVector) > Vector) then
Dash()
RollTrack:Play()
BodyVelocity.Velocity = Character.HumanoidRootPart.CFrame.RightVector * -Amount
elseif (Humanoid.MoveDirection:Dot(Cam.CFrame.LookVector) > Vector) then
Dash()
RollTrack:Play()
BodyVelocity.Velocity = Character.HumanoidRootPart.CFrame.lookVector * Amount
elseif (Humanoid.MoveDirection:Dot(-Cam.CFrame.LookVector) > Vector) then
Dash()
RollTrack:Play()
BodyVelocity.Velocity = Character.HumanoidRootPart.CFrame.lookVector * -Amount
end
task.wait(Cooldown.Value)
OnCooldown = false
end
end)
look at the video
at minute 0:08 it turns well but when the weapon appears in the inventory (I did it through a script) at minute 0:10 and after a while when I turn around it gives it in a strange way and I know it’s the weapon Because it only happens when the system is activated. I just want you to tell me what solution you have
no for now it does not give any error simply the animation is executed like this I don’t know why the truth is I think it is because the script modifies the animations. That’s why I say that someone who has manipulated these weapons or someone who knows a solution
I may not know everything about these weapons but I think if something stops working, there has to be an error in the Output window. Double-check and if it still has no errors, you can show me the script where you think the error happens.
It’s difficult to say exactly what the issue is without seeing the weapon script or knowing more about how it works. However, it seems like the problem may be related to conflicting code or a naming conflict.
One possibility is that both the weapon script and the jumper script are trying to modify the same variables or functions, causing them to interfere with each other. To fix this, you could try renaming some of the variables or functions in one of the scripts to avoid conflicts.
Another possibility is that the weapon script is modifying something that the jumper script relies on, causing it to break. You could try looking at the weapon script to see if there are any variables or functions that might be causing this, and try modifying them or commenting them out to see if it fixes the issue.
If these solutions don’t work, you may need to provide more information about the weapon script and how it interacts with the jumper script in order to diagnose the problem more accurately.
I already know what the problem is and it is IRRESOLVABLE I think so I won’t bother anymore. Because I have made a decision which consists of making my own weapons, I have been here for 5 months so I am capable, please send me documentation of what you can so that you can help me. I ask you with all my being, help me by sending me videos or anything or give me details ( I want to make weapons with ray Cast and that are fire) @AlaTomKing you too please