Yuari
Documentation
Docs/Data types/CFrame:PointToWorldSpace

CFrame:PointToWorldSpace

Converts a point between world and object coordinate space.

Syntax

CFrame:PointToWorldSpace(v: Vector3) -> Vector3

Parameters

ParameterTypeDescription
vVector3The v value used by the call.

Returns

TypeDescription
Vector3The point converted to world space.

Description

CFrame:PointToWorldSpace is part of the Data types library. Vector and CFrame values are VM userdata with operator overloads; operations return new value objects.

The operation is performed immediately using the arguments supplied at the call site.

The aliases :PointToObjectSpace resolve to the same implementation.

Example

local cf = CFrame.new(10, 0, 0)
local world = cf:PointToWorldSpace(Vector3.new(1, 0, 0))
local object = cf:PointToObjectSpace(world)
print(world, object)

Notes

  • Aliases: :PointToObjectSpace.
  • Vector and CFrame operations return new value objects.