📜  如何在 roblox 中找到人形机器人 - Lua 代码示例

📅  最后修改于: 2022-03-11 14:54:55.807000             🧑  作者: Mango

代码示例1
-- Player = Stores stuff like you UserId. Its you!- Developers have access to like purchases and so
-- Character = How you look like - The Model in your Workspace
-- Humanoid = A little Robot inside the Character that Holds Values like your Health or WalkSpeed

game.Players.PlayerAdded:Connect(function(plr)
    plr.CharacterAdded:Connect(function(Character)
        local Humanoid = Character:FindFirstChild("Humanoid")
        print(Character.Name)
        print(Humanoid.Health)
    end)
end)