I’m using Region3 as an anti-exploit measure to respawn noclippers and glitchers in the kitchen of a cafe. Because of the design, the kitchen is oriented on the Y axis at about 10-20 degrees or so. Can I add an orientation offset to the CFrame of the Region? From everything I’ve tried so far, it’s throwing “CFrame cannot be assigned to” errors.
local NewRegion = Region3.new(
Vector3.new(
math.min(v.Point1.Position.X, v.Point2.Position.X),
math.min(v.Point1.Position.Y, v.Point2.Position.Y),
math.min(v.Point1.Position.Z, v.Point2.Position.Z)
),
Vector3.new(
math.max(v.Point1.Position.X, v.Point2.Position.X),
math.max(v.Point1.Position.Y, v.Point2.Position.Y),
math.max(v.Point1.Position.Z, v.Point2.Position.Z)
)
)
v.Point1:Destroy()
v.Point2:Destroy()
NewRegion.CFrame = NewRegion.CFrame * CFrame.Angles(0, math.rad(20), 0) --my attempt
local NewPart = Instance.new("Part", workspace)
NewPart.Anchored = true
NewPart.CFrame = NewRegion.CFrame
NewPart.Size = NewRegion.Size
(not sure why it’s formatted so weirdly on devforum)