#Script keeps returning nil value

1 messages · Page 1 of 1 (latest)

signal wagon
#

local function RandomColorTouched()
local ColorPart = game.Workspace:FindFirstChild("Part")
local PartIsTouched = false
ColorPart.Touched:Connect(function(otherPart)
local humanoid = otherPart.Parent:FindFirstChild("Humanoid")
if humanoid then
local Red = math.Random(0, 255)
local Green = math.Random(0, 255)
local Blue = math.Random(0, 255)

        ColorPart.Color = Color3.fromRGB(Red, Green, Blue)
    end
end)

end

RandomColorTouched()

vital pendant
#

plz

#

:3

flat sierra
patent hatch
#

ur not returning anythinc

#

also why put the :Connect() inside of a function