📜  roblox studio 什么东西跟着你

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

代码示例1
local fire1 = Assets.FireStorm:Clone()
            local cfv1 = Instance.new("CFrameValue", fire1)
            local weld = Instance.new("Weld")
            weld.Part0 = fire1.PrimaryPart
            weld.Part1 = Model.HumanoidRootPart
            weld.Parent = fire1
            cfv1.Value = CFrame.new(math.random(-5,5), math.random(0,5), math.random(1, 5))
            fire1:SetPrimaryPartCFrame(Model.HumanoidRootPart.CFrame * cfv1.Value)
            fire1.Parent = demonfolder
            fire1.Name = "FireStorm1"