Mini Walking Pet: Displacement and Script Issues

Hihi! ImperfectWorkclock here.

I’ve been recently working on a pet, with a friend, that follows you around. No it’s not like the Bubblegum Simulator Pets, or any knock off versions of those pets. I’ve been having issues when trying to make the pet seem more like a user rather than some gray, faceless, block character

First off, to clarify, the pet system is placed into the ServerScriptService.
image
Second off, the pet works perfectly fine when it’s unmodified.
982890a7a6dcf7fc6d53dd650184cfa7

Now, as you see it, the pet looks bland, kind of just like one of those R6 NPC Templates. Gray, blocky, and faceless.

image
The important contents within the Pet

I don’t want that. I’ve tried to make this template look more like a character. So I imported myself into the game, and tried 2 different things:

a) Transfer over all Scripts, Attachments, BodyGyros, BodyPositions, and Joints over to my imported avatar
b) Transfer all Accessories, Joints, and Decals over to the Pet Template

Both ways did not work.
Option A would not even spawn. Nothing would appear


After transferring everything over to my imported avatar
612be7ae17a01ee3f9b31514f5c3705c
Result (after putting the system back into ServerScriptService

Option B would cause the pet to look very disorientated and deformed, it’s accessories all over the place. It would also cause the pet to fall flat on it’s face and not allow it to move.


Transferred all Accessories, Decals, etc. over to the Pet
bcba759863319017dc5d6c486ad3df3e
After clicking PlayTest (and putting the pet system back into ServerScriptService)

I really don’t know where the issue is. Both have the same joints and Attachments. I don’t know why the accessories are not in the correct place, nor do I know why the Pet just lays their frozen in the ground.

I have attached the scripts in case anyone finds an issue that is causing this problem:

local char = script.Parent.Parent
local hum = char:FindFirstChild("Humanoid")
local torso = char:FindFirstChild("Torso")
local pet = script.Parent

local maxFloat = 1
local floatInc = 0.025
local sw = false
local fl = 0

while true do
    wait()
    if not sw then
        fl = fl + floatInc
        if fl >= maxFloat then
            sw = true
        end
    else
        fl = fl - floatInc
        if fl <=-maxFloat then
            sw = false
        end
    end
    if pet ~= nil and hum ~= nil and torso ~= nil then
        if hum.Health >= 0 then
            local cf = torso.CFrame * CFrame.new(3,2+fl,3)
            pet.BodyPosition.Position = Vector3.new(cf.x,cf.y,cf.z)
            pet.BodyGyro.CFrame = torso.CFrame * CFrame.new(3,0,-3)
		    pet.Humanoid:MoveTo(Vector3.new(cf.x,cf.y,cf.z))
        else
            break
        end
    end
end

The Local Script within the pet

-- services

local players = game:GetService("Players")

-- variables

local pet = script.Parent.Pet

-- functions

local function clonePetTo(player)

local model = pet:Clone()

local char = player.Character

model.HumanoidRootPart.CFrame = char.PrimaryPart.CFrame

model.Parent = char

end

-- events

players.PlayerAdded:Connect(function(plr)

plr.CharacterAdded:Connect(function(char)

clonePetTo(plr)

end)

end)

The MainScript that executes the function that clones the pet and gives it to the player.

Here is the link to the PetSystem, if you want to test it out: noobs - Roblox

Again, the issues are:
- Accessories do not fit properly on the head.
- The character does not show up at all
- The character is frozen and stuck in the ground, unable to move

Reminder: All of these issues are found when attempting to change the bland, R6 template into a normal-looking avatar

Thank you for reading through this! If you find a solution to these issues, please let me know!

2 Likes

I checked the model of the PetSystem, and one of the first things I noticed was the attachments were messed up on the template model so fixed the attachments

Then I copied my hats from my avatar, removed any values inside of them such as “AvatarPartScaleType” and “OriginalSize”, then I rescaled my hats to about the size of the template and it worked.

https://gyazo.com/bcbf2918f4a6ba4de541c6831db1b678

Here’s the template model if you need it:

8 Likes

Oh wow. Thank you so much! I didn’t even realize the Attachments were off :joy:

1 Like

wait is there a way to transfer shirts and pants onto the pet?

1 Like

Oh sorry I didn’t notice the clothes didn’t work, (probably cause my avatar doesn’t have clothes) but anyways all you have to do is delete all the BlockMeshes inside of the limbs and torso and clothes should work.

Oh ok, thanks so much! I completely forgot that the meshes deter the clothes

Hey sorry to bother you again! I seem to be having issues with the accessories
image

Anyway to fix this?
I’ve tried lowering the HatAttachments and all but it doesn’t do anything

I can’t seem to replicate what happened. I’ve tried to import the hat you’re using into the template and it worked fine.
45%20PM
Even when I got a model of a random player who has the hat you’re using, shrunk it and added the main scripts to it, it still worked.
12%20PM
I’m sorry for the late response and for not being able to help

Can you give me a step by step on how YOU put the accessories on the character and what size you resize the hats to?

Every time I shrink and put it on the character pet, it always seems to be floating a bit above the head.