Scripting Helpers is winding down operations and is now read-only. More info→
Ad
Log in to vote
0

How to fix angle not being changed?*SOLVED*

Asked by 4 years ago
Edited 4 years ago

The Following script is trying to move the angle of a Weld.C0 after it is placed in the body of the character:

Players = game:GetService("Players")
Players.PlayerAdded:Connect(function(Player)
 Player.CharacterAdded:Connect(function(Character)
  print("Sword Added")
  local Character = Player.Character or Player.CharacterAdded:Wait()
  local GrandSword = game:GetService("ReplicatedStorage").GrandSword:Clone()
   GrandSword.Parent = Character

  local Weld = Instance.new("Weld")
   Weld.Parent = GrandSword
   Weld.Part0 = GrandSword.Handle
   Weld.Part1 = Character.Torso
   Weld.C0 = CFrame.new(-3.7, 0, -0.6) * CFrame.Angles(0, math.rad(-44.5), 0)
 end)
end)

But the Angle isnt changed by line 13 i keeps at 0 for some reason

Btw heres the result: http://prntscr.com/qe4cjl

Any help is appreciated :D

0
Try modifying the weld.C0 firestarroblox123 440 — 4y
0
It might be the wrong CFrame firestarroblox123 440 — 4y
0
What do you mean?Isnt the script doing that already?Btw the CFrame in C0 is a varible so i can put any number in there kevinsoaresv 47 — 4y
0
Thats what I mean, try and adjust the C0 more firestarroblox123 440 — 4y

1 answer

Log in to vote
0
Answered by 4 years ago
Edited 4 years ago

Looks like the problem was in the accessory, as it was an accessory and had a handle the handle had a TouchInterest so it was being welded in the head of my char the moment it was moved to it, all i had to do was switch the accessory for a model and weld all the parts inside of the model handle together.Fixed!

Ad

Answer this question