So basically I am trying to fill a model with a part which I am using as a camera focus part. The issue I am facing is that some of the model's axis are being changed. For example the x would be changed to the z etc.
Here is the code so far
local weapons = script.Parent:GetChildren()
for i = 1,#weapons,1 do
if weapons[i].Name ~= script.Name then
local part = Instance.new("Part")
local o,s = weapons[i]:GetBoundingBox()
part.Size = s
part.CFrame = o
part.Parent = weapons[i]
part.Anchored = true
part.Transparency = .7
part.Name = weapons[i].Name .. "FOC"
part.BrickColor = BrickColor.new("Royal purple")
print()
end
end

3 comments
CFrame contains orientation, you can try using CFrame.Position = o.Position
Oh thank you
I just tried and i t gives me an error. The error it says is 'Position cannot be assigned to'