Skip to main content

Video

Provides functions for interfacing with VideoPlayers attached to Items

To get a VideoPlayer from an item, use the GetComponent method.

let videoComponent = item.GetComponent("Video")

You can then use the videoComponent property to access the Video class.

Methods

Method NameReturn TypeParametersDescription
IsPlayingboolnoneReturns true if the attached VideoPlayer is playing
IsMutedboolnoneReturns true if the attached VideoPlayer is muted
IsLoopingboolnoneReturns true if the attached VideoPlayer is looping
PlayvoidnonePlays the VideoPlayer
PausevoidnonePauses the VideoPlayer
StopvoidnoneStops the VideoPlayer
SetVideoClipvoidstringSets the VideoPlayer's clip from Local Script Assets (VideoClip)
SetMutevoidbool Sets the mute property of an VideoPlayer
SetLoopvoidboolSets the loop property of an VideoPlayer
GetPitchfloatnoneGets the pitch property of a VideoPlayer
SetPitchvoidfloatSets the pitch property of a VideoPlayer
GetVolumefloatnoneGets the volume property of a VideoPlayer
SetVolumevoidfloatSets the volume property of a VideoPlayer
GetPositionfloatnoneGets the position property of a VideoPlayer
SetPositionvoidfloatSets the position property of a VideoPlayer
GetLengthfloatnoneGets the length property of a VideoPlayer
LoadFromStreamvoidStreamDownloadLoads data from a StreamDownload to a VideoPlayer