Me and a member of my dev team are making a spiderman web slinging system
When we make the slinging come out of the humanoidrootpart, it works just fine but when we make it come out of the hand you can see we have this issue. Video - Google Drive Video by my dev team. As you can see it does not give the results we want
We don’t understand why it works on the humanoidroot part but not the hand. Can anyone enlighten us as to why?
1 Like
If you could share a bit of the script that moves the player that’d help
1 Like
local Tween_Service = game:GetService(“TweenService”)
local player = game.Players.LocalPlayer
local humanoid = player.Character:WaitForChild(“Humanoid”)
local mouse = player:GetMouse()
local camera = workspace.CurrentCamera
local Can_Web = false
local Spider_Point = player.Character:WaitForChild(“RightArm”)
local mouseDown = false
mouse.Button1Down:connect( function()
mouseDown = true
end)
mouse.Button1Up:connect( function()
mouseDown = false
end)
while wait() do
if mouseDown then
if mouse.Target ~= nil then
if “Baseplate” == mouse.Target.Name then
Can_Web = false
else
Can_Web = true
end
end
if Can_Web and mouse.Target and SpiderRope == nil and mouse.Target:IsA("Part") and (mouse.Hit.p - Spider_Point.Position).Magnitude < maxDistance and not mouse.Target.Parent:FindFirstChild("Humanoid") and not mouse.Target:IsA("Accessory") then
SpiderRope = Instance.new("RopeConstraint", game.workspace)
SpiderRope.Visible = true
SpiderRope.Color = BrickColor.new("Institutional white")
SpiderRope.Thickness = 0.05
pointOne = Instance.new("Attachment",Spider_Point)
pointTwo = Instance.new("Attachment",mouse.Target)
pointOne.WorldPosition = Vector3.new(Spider_Point.Position.X,Spider_Point.Position.Y,Spider_Point.Position.Z)
pointTwo.WorldPosition = mouse.Hit.p
local position = pointTwo
SpiderRope.Attachment0 = pointOne
SpiderRope.Attachment1 = pointTwo
SpiderRope.Length = (pointOne.WorldPosition - pointTwo.WorldPosition).Magnitude - 1
local Tween_Info = TweenInfo.new((pointOne.WorldPosition - pointTwo.WorldPosition).Magnitude / 75);
local Tween_Goal = {
Length = 8
}
local Tween = Tween_Service:Create(SpiderRope,Tween_Info,Tween_Goal)
Tween:Play()
2 Likes