So I tried using InsertService:LoadAsset() to spawn pets in my game, but when I click the pet I get an error saying Unable to cast Instance to int64. It fails on this line of code:
local asset = InsertService:LoadAsset(assetId)
Any suggestions? Thanks!
What’s assetId
? The error tells you it’s supposed to be a number, but you assigned some object to it.
1 Like
The Asset ID I am using is 5496080809 and is sent over a Remote Event.
I realized the problem. I wasn’t picking up the player, so it treated assetId
as a player.
1 Like