How to make pets in roblox studio

Log in to vote

1

Answered by

Start with this! I can make a GUI button that when clicked, and you have 10 money, will give you a pet! Just follow these steps!

1

Make a RemoteEvent in ReplicatedStorage called Pets. Move the pet to ServerStorage and call it "Pet1" 2 Put this script inside the pet and disable it:

while true do wait(0.1) script.Parent.Position = script.Parent.Parent.Position - Vector3.new(3,3,0) end

2

Put this LocalScript inside a GUI button

script.Parent.MouseButton1Click:Connect(function() local Player = game.Players.LocalPlayer if Player.leaderstats:FindFirstChild("Money").Value >= 10 then game.ReplicatedStorage:FindFirstChild("Pets"):FireServer(Player.Name,"Pet1") end end)

3

Put this Script in ServerScriptService

game.ReplicatedStorage:FindFirstChild("Pets").OnServerEvent:Connect(function(player,pet) local Pets = game.ServerStorage:FindFirstChild(pet) if Pets then local Clone = Pets:Clone() Clone.Parent = game.Workspace:FindFirstChild(player):FindFirstChild("HumanoidRootPart") Clone:FindFirstChild("Script").Disabled = false end end)

Even if this does not work, it should give you some ideas! If you have any questions, comment below!

Best,

TheLastHabanero

EDIT

To save pets, you need to make a table:

local DS = game:GetService("DatastoreService") local Store = DS:GetDataStore("Pets") game.Players.PlayerAdded:Connect(function(plr) local Stats local success,fail = pcall funtion() Stats = Store:GetAsync(plr.UserId.."-Pets") end if success then for i, stat in pairs(Stats) do local Clone = game.ServerStorage:FindFirstChild(stat) if Clone then Clone:Clone().Parent = plr.Character:FindFirstChild("HumanoidRootPart") end end else end end game.Players.PlayerRemoving:Connect(function(plr) local Pets = {} local Childs = plr.Character:FindFirstChild("HumanoidRootPart"):GetChildren() if #Childs >= 1 then for i,child in pairs(Childs) do table.insert(child) end end pcall function() Store:SetAsync(plr.UserId.."-Pets",Pets) end end

Just make sure to make all the pets in Lighting and it should work! Unfortunately, unequipping and equipping will require some time to make, so you will have to wait. I'm sorry. But hey! Here's the save part! Have fun!

TheLastHabanero

How to make pets in roblox studio

How to make pets in roblox studio

How to make pets in roblox studio
report this ad

How to make pets in roblox studio

Learn how metatables and metamethods are used in Roblox Lua scripting with this scripting tutorial. List of...

How to make pets in roblox studio

Roblox Egg Hatching Series Continued The third and final episode of my Roblox egg hatching system series. You'll learn...

How to make pets in roblox studio

Learn how to trigger cutscenes to play when something happens in your game using Remote Events and Server Scripts....

Help and Feedback Scripting Support

Hello! I was wondering how I make a pet simulator x like movement where of course the pet follows you, I can easily script that, but with the back-and-forth movement smoothly. As I said above, I can make a pet that follows you, but it looks really low quality, and the pet looks like a possessed dead body. I just want to know like if I would make an infinite tween animation, but would that interfere with the body gyro or stuff like that? Or like is it something totally different. Thanks, BMWLux (:

3 Likes

How to make pets in roblox studio
BMWLux:

with the back-and-forth movement smoothly

I don’t understand, can you explain in more detail or post a video?

1 Like

Please try the Search bar up top first.
I typed in 'pet ’ and got a bunch of posts like this one:

How to make pets in roblox studio
Pet follow module [Simulator style] Community Resources

Since releasing my 100 free simulator pet models one of my most persistent requests was to make a script which makes pets follow the player, so here we are. System in action (Ignore bad gif quality) API: :AddPet(Player, PetName) Searches the pet folder for a pet by that name. :AddPet(PetName) Also works and automatically assigns the pet to the local player. :RemovePet(Player, PetName) Searches the players existing pets and removes a pet by that name. :HidePets(Player) Hides that players p…

No, im saying like in pet simulator x where they go back and forth like if you have played the game I think you would understand. Yeah no for sure I have. I can make them follow you really easily I just dont get the back and forth like when you walk and the pets come after you they have a little animation and i guess that animation is what I’m looking for (:

You mean the regular rthro animation?

dude lol, i mean the pet from pet simulator x animation XD wdym rthro? XDD

1 Like

You can get it in two ways:

RIGS Rigging is a little tricky to master, but once you get it you can bring whatever you want to life.

By rigging your pets it’s easy to animate them via any animation plugin.

Here are some useful links on this way

How to make pets in roblox studio
How to rig a custom character (2021 edition) Community Tutorials

Notes Last year, (aka like 6 months ago) I made a topic on how to create a custom character model. Since then, I have learned more about rigging so I have made an updated topic here. This should be a MUCH better tutorial as my first one was confusing and messy. I tried to make this one better. This topic is not for mesh/bone rigs. I will not be showing how to animate. I will only be showing you how to create/rig the character, and how to setup the animation plugin with your character. I…

https://developer.roblox.com/en-us/api-reference/function/Animator/LoadAnimation

CFRAMES
Another way is to change their CFrames with scripts to get the movement you want. Imo is more difficult than rigging if you are not familiar with CFrames

https://developer.roblox.com/en-us/articles/Understanding-CFrame

1 Like