Skip to content

AssetsService

Inherits Instance

Service for managing/creating assets

Static Class

This object is a static class. It can be accessed like this: Assets.

Additionally, it cannot be created in the creator menu or with Instance.New().

Not newable

This object cannot be created by scripts using Instance.New().

Methods

NewAsset → BaseAsset

Parameters: assetClassName [ string ]

Create new asset with the class name

NewPTImage → PTImageAsset

Parameters: imgID [ number ]

Create new image from Polytoria with the target ID

NewPTAudio → PTAudioAsset

Parameters: audioID [ number ]

Create new audio from Polytoria with the target ID

NewPTMesh → PTMeshAsset

Parameters: assetID [ number ]

Create new mesh from Polytoria with the target ID

GetFileLinkByPath → FileLinkAsset

Parameters: path [ string ]

Retrieve FileLinkAsset with the specified path

GetFileLinkByID → FileLinkAsset

Parameters: id [ string ]

Retrieve FileLinkAsset with the specified ID