I’m currently creating a tool that, when equipped, makes a part appear, and said part is named “aura” and is welded to the player’s HumanoidRootPart. I’m trying to make it so the aura is at the HumanoidRootPart’s position.
The problem is, the aura part isn’t at the HumanoidRootPart’s position when it’s welded, it’s always behind it, or above it. The position it’s welded in seems to be random.
Here is the code that creates the aura part and the weld for it.
--Make aura
local aura = Instance.new("Part")
aura.Name = "Aura"
aura.Shape = Enum.PartType.Ball
aura.CanCollide = false
aura.Material = Enum.Material.ForceField
aura.Color = Color3.fromRGB(255, 213, 0)
aura.Massless = true
aura.Size = Vector3.new(shieldTime, shieldTime, shieldTime)
aura.Parent = tool
local auraWeld = Instance.new("WeldConstraint")
auraWeld.Part1 = aura
auraWeld.Enabled = false
--Welding the aura
aura.Position = rootPart.Position
auraWeld.Part0 = rootPart
auraWeld.Enabled = true
auraWeld.Parent = aura
-
What do you want to achieve? I want to make a tool that welds a part to the player’s HumanoidRootPart
-
What is the issue? The part is not at the HumanoidRootPart’s position when welded.
-
What solutions have you tried so far? I searched for similar posts but found no solution.
Both the aura part and the weld is created locally, and the HumanoidRootPart’s position is always at the center of the player’s character.