PcoWSkbVqDnWTu_dm2ix
We use cookies on this site to enhance your user experience
Collapse Sidebar

LoadAsset

The LoadAsset function returns a model inserted into /InsertService containing the asset.

For instance, if you want to load a Doge Model, which has the asset Id 257489726, you would use the following statement:

InsertService:LoadAsset("257489726")

This line would return an Instance of the Doge model within your game. Changing the asset Id passed as an argument changes the asset that is loaded into your game.

Interested in finding Free Models or Decals into your game? You can use the InsertService/GetFreeModels and InsertService/GetFreeDecals functions!

See another example below!

Parameters

Name Type Default Description

The asset Id of the asset being loaded.

Returns

Return Type Summary

An instance of the loaded asset.


Code Samples


InsertService:LoadAsset

local assetId = 82353
game:GetService("InsertService"):LoadAsset(assetId).Parent = game.Workspace