How Would I Go about getting Orientation on Something Welded

help me

  1. What do you want to achieve? Keep it simple and clear!

  2. What is the issue? Include screenshots / videos if possible!
    image

So basically im aware of the problem, When im testing the weld in Studio with auto weld plugins There is the orientation tab which is (90, 90, 0) but when im making the weld through scripting the orientation doesnt seem to be working and i cant just say Weld.C0.Orientation = blah blah so im wondering how i would go about this and ive went on dev forum and looked at similar issues where people use Cframe.Angles but it makes it even worse.

local Assets = game:GetService("ReplicatedStorage"):WaitForChild("Assets"):WaitForChild("Sage Mode")
local Player = nil
local oldface = "rbxassetid://16044190486"
local EyeHandler = require(script.Parent.EyeHandler)

local StuffToDestroy = {}

script.Parent.Equipped:Connect(function()
	Player = game.Players:GetPlayerFromCharacter(script.Parent.Parent)
end)


script.Parent.MainRemote.OnServerEvent:Connect(function(player, Active)
	if Active == true then
		-- Activate Face
		EyeHandler:Activate(player)
		
		-- Sage Scroll
		local Scroll = Assets:WaitForChild("SageScroll"):Clone()
		Scroll.Parent = player.Character:WaitForChild("UpperTorso")
		
		local Weld = Instance.new("Weld")
		Weld.C0 = CFrame.new(-0, -0.946, 0.934)
		Weld.Part0 = player.Character:WaitForChild("UpperTorso")
		Weld.Part1 = Scroll
		Weld.Parent = player.Character:WaitForChild("UpperTorso")
		
		local Info = {
			["Scroll"] = Scroll,
			["Weld"] = Weld,
			["Player"] = player
		}
		table.insert(StuffToDestroy, Info)
		
	elseif Active == false then
		EyeHandler:Deactivate(player)
		
		for i,v in pairs(StuffToDestroy) do
			v.Scroll:Destroy()
			v.Weld:Destroy()
		end
	end
end)

Properties of Weld Made with plugin V

Properties of Weld Made with Script V

I think you might want to try this code for the weld C0

Weld.C0 = CFrame.new(Weld.C0.Position) * CFrame.Angles(math.rad(90), math.rad(90), 0)

image

thats what i was talking about i dont know why its not working

I think I rotated the Y-axis. Try to do:

CFrame.Angles(math.rad(90), 0, 0)

image

im telling you this is very interesting why its not working

I suggest you to messing around with the axis. Try to replace the 90 to 180 if it is still not working!!

Yes put it on 180 degrees to see what happens:

CFrame.Angle(math.rad(180), 0, 0)

try CFrame.Angles(math.rad(90), math.rad(90), math.rad(90))

image

Uhm, that will just make things worse because u rotating 3 axes?

1 Like

image

its getting better so your right i just need to mess around and i should get it

@clx0de Try this to see if it works or not.

I finally got it. So i will give you the solution because u made me get closers thank you.

Weld.C0 = CFrame.new(-0, -0.946, 0.934) * CFrame.Angles(math.rad(180), 0, math.rad(90))
1 Like

Also I saw that u parent it to UpperTorso. I assume it is suppose to be in LowerTorso??

This topic was automatically closed 14 days after the last reply. New replies are no longer allowed.