Scripting Helpers is winding down operations and is now read-only. More info→
Ad
Log in to vote
0

I changed the starter character, but it's not animated?

Asked by 2 years ago

Hi, so I made a script (server script for now) to change the starter character. It works, but the character isn't animated. Can someone tell me what to do with the animation script inside my custom character, (or how to make the character animated in general) since I use a script to change the character?

This is the server script I use to change the character:

local Players = game:GetService("Players")
Players.PlayerAdded:Connect(function(Player)
    local Character = Player.Character or Player.CharacterAdded:Wait()
    local name = Character.Name
    Character:Destroy()
    local newchar = game.ServerStorage.DOGTHING:Clone()
    newchar.Parent = workspace
    newchar.Name = name
    Player.Character = newchar
    game.Players.CharacterAutoLoads = false
end)

1 answer

Log in to vote
0
Answered by
manith513 121
2 years ago

By destroying the default character, you are essentially deleting everything inside the character in workspace which includes the scripts and animations for movement and default player stuff. You will have to make your own animations or create new motor6Ds in roblox's framework that matches the same Part0's and Part1's and the same names of the limbs to use the same default animations on whatever custom character you are using (though it may be a little janky.)

0
I already rigged and animated my character. If i put it straight into StarterCharacter and put the animate script into StarterCharacterScripts, it works fine. The problem is I want multiple characters for my game. I have to use a script to change the character. For some reason, even though the character has the same animation script, it's not working. xX02Dire_Wolf20Xx 11 — 2y
Ad

Answer this question