Scripting HelpersARCHIVE
A little piece of Roblox history. Preserved for everyone, one question at a time.Read about the archive →
COMMUNITY QUESTION

How do I make my light part turn into neon? It wont do it!!

I am still a Rookie scripter. And I am trying to make a light script with a Part. But the material won't change to Neon... Can some of you please look at my script?

local Pointlight = Lightpart.Pointlight
local Part.Script.Parent

while true do
wait(0.1)
if game.Lighting.GetMinutesAfterMidnight () > 7 * 60 then
       Lightpart.material = Enum.Material.Plastic
        pointlight.Enabled = false
End
if game.ligthing.GetMinutesAfterMidnight () > 18 * 60 then
Lightpart.material = Enum.Material.Neon
pointlight.Enabled = true
End
End



1 answer

First, correctly label your variables.

Also, use output to see your script errors and what's wrong with it.

Also, use partnamehere.Material = "Neon" instead of Material.Neon

Lastly, make sure to capitalize and lowercase everything to the exact, for example, your "material" should be "Material" unless it's a variable.

2 comments

0

Additionally, his ends are Ends. A good amount of programming languages are case sensitive.

0

ye

This discussion is preserved as it was. New answers, comments, and votes are closed.