Main menuGui For your char

nope wont load stilleeeeeeeeeeeeeeee

so when you’re in studio, you can see the dummy in the viewportframe. But once you play test the game, the dummy suddenly dissapears? If this is the case, make sure the “CurrentCamera” property of the ViewPortFrame is set to the Duplicated Camera that i told you to set in the ViewPortFrame earlier.

this is what it looks like with me, i put the camera inside of the ViewPortFrame and called it “VPCam”
Capture d’écran 2023-08-29 à 01.26.03

i fixed that issue the only problem i am having is YOUR avatar wont show on the dummy

Did you add a localscript inside of the viewportFrame?

CODE:

local player = game:GetService("Players").LocalPlayer
local ViewportFrame = script.Parent
local DummyReference = ViewportFrame:FindFirstChild("World"):FindFirstChild("Dummy")
local animation = DummyReference.Humanoid:LoadAnimation(script:FindFirstChild("Animation"))
animation.Looped = true

local function CreateCharacter(UserID, Dummy) -- getting the player's items
	local Appearance = game.Players:GetHumanoidDescriptionFromUserId(UserID) -- getting the appearance
	Dummy.Humanoid:ApplyDescription(Appearance) -- applying it to the dummy
end

CreateCharacter(player.UserId, DummyReference)
animation:Play()

yes i didddddddddddddddddddddddddddddd

also make sure the dummy is inside of a “WorldModel” because else it won’t animate the dummy.

already did thatttttttttttttttttttttttt

does it error in the output???

thats error it shows line 8 i think

also how do i make it only show when i am on the main menu screen
’

This is because we’re trying to do :ApplyDescription() in a localScript which can only be done in a server script. This is what i would do:

  1. Add a script (not localscript) into the ServerScriptService
  2. Put the “Dummy” model, that was previously in the viewportframe, in the ReplicatedStorage
  3. Add a RemoteEvent called “AddAppearance” and put it in the ReplicatedStorage also

Write the following code inside of the Server Script (serverScriptService):

local function CreateCharacter(UserID, Dummy) -- getting the player's items
	local Appearance = game.Players:GetHumanoidDescriptionFromUserId(UserID) -- getting the appearance
	Dummy.Humanoid:ApplyDescription(Appearance) -- applying it to the dummy
end

game.Players.PlayerAdded:Connect(function(player)
	local dummy = game:GetService("ReplicatedStorage"):WaitForChild("Dummy"):Clone()
	dummy.Name = player.Name
	CreateCharacter(player.UserId, dummy)
	game:GetService("ReplicatedStorage"):WaitForChild("AddAppearance"):FireClient(player, dummy)
end)

localScript (inside of the viewportframe):

local ViewportFrame = script.Parent

game:GetService("ReplicatedStorage"):WaitForChild("AddAppearance").OnClientEvent:Connect(function(dummy)
	dummy.Parent = viewportframe.World
	local animation = dummy.Humanoid:LoadAnimation(script:FindFirstChild("Animation"))
	animation.Looped = true
	animation:Play()
end)

could you format the script please?

what does that mean? ? ?? ? ? ? ? ?

localScript (inside of the viewportframe):

local ViewportFrame = script.Parent

game:GetService("ReplicatedStorage"):WaitForChild("AddAppearance").OnClientEvent:Connect(function(dummy)
	dummy.Parent = viewportframe.World
	local animation = dummy.Humanoid:LoadAnimation(script:FindFirstChild("Animation"))
	animation.Looped = true
	animation:Play()
end)

seperate basically because someimes they mix

ok i did all the steps but i dont even see the dummy now

does it error? show me the output

no because if tis in storage its not being used correct

my dumb**** put it in server storage…

1 Like