#Trying to follow the Plane Tutorial

1 messages · Page 1 of 1 (latest)

slow zodiac
#
local character = script.Parent
local humanoid = character:WaitForChild("Humanoid")
local connection = nil
local seat = nil

local function Start()
    local model = seat:FindFirstAncestorOfClass("Model")
    for index, decendant in model:GetDecendants() do
        if decendant:IsA("BasePart") == true then 
            local attachment0 = Instance.new("Attachment", decendant)
            local attachment1 = Instance.new("Attachment", decendant)
            
            local beam = Instance.new("Beam")
            beam.FaceCamera = true
            beam.Segments = 1
            beam.Width0 = 0.2
            beam.Width1 = 0.2
            beam.Color = ColorSequence.new(Color3.new(1, 0, 0))
            beam.Attachment0 = attachment0
            beam.Attachment1 = attachment1
            beam.Parent = decendant
        end
    end
end

local function Stop()
end

local function Loop(deltaTime)

end

local function Seated(active, currentSeat)
    if active == false then
        if connection == nil then return end
        connection:Disconnect()
        connection = nil
        Stop()
        seat = nil
    elseif currentSeat.Name == "Plane" then 
        seat = currentSeat
        Start()
        connection = RunService.PostSimulation:Connect(Loop)
    end
end

humanoid.Seated:Connect(Seated)```
#

The code.

#

only thing that happens is this.