Hi, title is pretty self explanatory, I just had a question about positioning, since I’m initially positioning an object to be to the right of the character, yet its appearing in front.
Please keep in mind I have a loop running to make it orbit around the character constantly, but I initially position it to be to the right however it only positions to the front.
What I want:
Initial position:
local radius = 8
local constantHeight = 1.5
maxopBlue.CFrame = character.HumanoidRootPart.CFrame * CFrame.new(radius, constantHeight, 0)
Code in loop to orbit:
local CircleModule = {}
function CircleModule.getXY(angle, radius)
return (math.sin(angle) * radius), (math.cos(angle) * radius)
end
return CircleModule
for i = 0, 720, 6 do
local angle = math.rad(i)
local x,z = circleModule.getXY(angle, radius)
maxopBlue.CFrame = fixedPos * CFrame.new(-x, constantHeight, -z)
task.wait()
end