function RotatedRegion3.new(o,v)local j=setmetatable({},RotatedRegion3)local S=Vertices.Block(o,v/2)j.CFrame=o j.Size=v j.Shape="\066\108\111\099\107"j.Set=S j.Support=Supports.PointCloud j.Centroid=o.p j.AlignedRegion3=Region3.new(worldBoundingBox(S))return j end RotatedRegion3.Block=RotatedRegion3.new function RotatedRegion3.Wedge(o,v)local j=setmetatable({},RotatedRegion3)local S=Vertices.Block(o,v/2)j.CFrame=o j.Size=v j.Shape="\087\101\100\103\101"j.Set=Vertices.Wedge(o,v/2)j.Support=Supports.PointCloud j.Centroid=Vertices.GetCentroid(j.Set)j.AlignedRegion3=Region3.new(worldBoundingBox(S))return j end function RotatedRegion3.CornerWedge(o,v)local j=setmetatable({},RotatedRegion3)local S=Vertices.Block(o,v/2)j.CFrame=o j.Size=v j.Shape="\067\111\114\110\101\114\087\101\100\103\101"j.Set=Vertices.CornerWedge(o,v/2)j.Support=Supports.PointCloud j.Centroid=Vertices.GetCentroid(j.Set)j.AlignedRegion3=Region3.new(worldBoundingBox(S))return j end function RotatedRegion3.Cylinder(o,v)local j=setmetatable({},RotatedRegion3)local S=Vertices.Block(o,v/2)j.CFrame=o j.Size=v j.Shape="\067\121\108\105\110\100\101\114"j.Set={o;v/2}j.Support=Supports.Cylinder j.Centroid=o.p j.AlignedRegion3=Region3.new(worldBoundingBox(S))return j end function RotatedRegion3.Ball(o,v)local j=setmetatable({},RotatedRegion3)local S=Vertices.Block(o,v/2)j.CFrame=o j.Size=v j.Shape="\066\097\108\108"j.Set={o;v/2}j.Support=Supports.Ellipsoid j.Centroid=o.p j.AlignedRegion3=Region3.new(worldBoundingBox(S))return j end function RotatedRegion3.FromPart(o)return RotatedRegion3[Vertices.Classify(o)](o.CFrame,o.Size)end
-- Public Constructors

function RotatedRegion3.new(cframe, size)
	local self = setmetatable({}, RotatedRegion3)
	local set = Vertices.Block(cframe, size / 2)

	self.CFrame = cframe
	self.Size = size
	self.Shape = "Block"

	self.Set = set
	self.Support = Supports.PointCloud
	self.Centroid = cframe.p

	self.AlignedRegion3 = Region3.new(worldBoundingBox(set))

	return self
end

RotatedRegion3.Block = RotatedRegion3.new

function RotatedRegion3.Wedge(cframe, size)
	local self = setmetatable({}, RotatedRegion3)
	local set = Vertices.Block(cframe, size / 2)

	self.CFrame = cframe
	self.Size = size
	self.Shape = "Wedge"

	self.Set = Vertices.Wedge(cframe, size / 2)
	self.Support = Supports.PointCloud
	self.Centroid = Vertices.GetCentroid(self.Set)

	self.AlignedRegion3 = Region3.new(worldBoundingBox(set))

	return self
end

function RotatedRegion3.CornerWedge(cframe, size)
	local self = setmetatable({}, RotatedRegion3)
	local set = Vertices.Block(cframe, size / 2)

	self.CFrame = cframe
	self.Size = size
	self.Shape = "CornerWedge"

	self.Set = Vertices.CornerWedge(cframe, size / 2)
	self.Support = Supports.PointCloud
	self.Centroid = Vertices.GetCentroid(self.Set)

	self.AlignedRegion3 = Region3.new(worldBoundingBox(set))

	return self
end

function RotatedRegion3.Cylinder(cframe, size)
	local self = setmetatable({}, RotatedRegion3)
	local set = Vertices.Block(cframe, size / 2)

	self.CFrame = cframe
	self.Size = size
	self.Shape = "Cylinder"

	self.Set = { cframe, size / 2 }
	self.Support = Supports.Cylinder
	self.Centroid = cframe.p

	self.AlignedRegion3 = Region3.new(worldBoundingBox(set))

	return self
end

function RotatedRegion3.Ball(cframe, size)
	local self = setmetatable({}, RotatedRegion3)
	local set = Vertices.Block(cframe, size / 2)

	self.CFrame = cframe
	self.Size = size
	self.Shape = "Ball"

	self.Set = { cframe, size / 2 }
	self.Support = Supports.Ellipsoid
	self.Centroid = cframe.p

	self.AlignedRegion3 = Region3.new(worldBoundingBox(set))

	return self
end

function RotatedRegion3.FromPart(part)
	return RotatedRegion3[Vertices.Classify(part)](part.CFrame, part.Size)
end
