Class
PlayerViewService
NotCreatableServiceNotReplicated
Provides a way to get additional information about a player's view.
PlayerViewService provides a way to get additional information about a
player's view.
Methods 1#
| GetDeviceCameraCFrame | Returns a world space CFrame looking at the player's character. |
GetDeviceCameraCFrame(player: Player = nil): CFrame#
Returns a world space CFrame looking at the player's character,
such that setting the current camera's CFrame will view that
character from the perspective of their device.
This method leverages the device's camera and it only functions on mobile
devices. If no information is available, for example the user is not on a
mobile device or they don't have their camera turned on, this method
returns a CFrame.identity.
Returns
CFrame— The world spaceCFramelooking at the player's character, or aCFrame.identity(see description).
Inherited members#
Inherited from Instance 58
Properties (10)
Archivable, archivable, Capabilities, IsInSandbox, Name, Parent, PredictionMode, RobloxLocked, Sandboxed, UniqueId
Methods (39)
AddTag, children, ClearAllChildren, Clone, clone, Destroy, destroy, FindFirstAncestor, FindFirstAncestorOfClass, FindFirstAncestorWhichIsA, FindFirstChild, findFirstChild, FindFirstChildOfClass, FindFirstChildWhichIsA, FindFirstDescendant, GetActor, GetAttribute, GetAttributeChangedSignal, GetAttributes, GetChildren, getChildren, GetDebugId, GetDescendants, GetFullName, GetStyled, GetStyledPropertyChangedSignal, GetTags, HasTag, IsAncestorOf, IsDescendantOf, isDescendantOf, IsPropertyModified, QueryDescendants, Remove, remove, RemoveTag, ResetPropertyToDefault, SetAttribute, WaitForChild