How to make pets

I am trying to make a feature in my game, so that when you collect something, it gives you a pet, and saves it in an inventory. How would I go about doing this? I have no idea where to start. Im just looking for a basic idea on how I could do this.


Please use the search feature to avoid duplicate questions.

These existing posts should be plenty to get you started:

There are also a few youtube tutorials. Make sure to google your questions as well before posting. Ask away if you have specific questions or need clarification on something :slight_smile:


Im not trying to make the pets follow the players, I already know how to do that. Im trying to make an inventory system that can save pets in it.

Your question is pretty broad as there are many different ways you could go about creating an inventory system. The only thing i am going to say with this is that when making any inventory system make sure you keep everything organized and make it easy for the player to use.

As far as making this it depends on how you want it, but try to make it easy for yourself code wise as a recomendation, in other terms make it easy to add pets, change pets ( inventory items)

Here are some resources:

(Ps: I know this video isn’t exactly what you need but it might help you get a better understanding)


When saving data for inventories, I would recommend saving data on a single player bases and saving Items(pets) under a table with all of it’s properties. For which “Async” you should use is up to you, but my personal recommendation is using UpdateAsync as it returns the previously saved data while allowing you to change it. In your case allowing you to add more pets to array of already saved pets

Here’s another useful resource for structuring your code and such: