BASIC TRAFFIC SIGNAL
Want to learn how to build a basic traffic light for your city game? This tutorial will help you with that.
Build a traffic light from the image above or your own design
Name and color 3 parts
Once you have created it, group all the parts.
Name the model "Traffic Light"
insert a script into it by right clicking it, and hitting "Insert Object" then click "Script"
Now, go into the script by double clicking it.
Type at the top (Or just copy below if your lazy and really don't wanna type this)
local G = script.Parent.Green local Y = script.Parent.Yellow local R = script.Parent.Red
while true do G.Material = "Neon" Y.Material = "Plastic" R.Material = "Plastic" wait(10) G.Material = "Plastic" Y.Material = "Neon" R.Material = "Plastic" wait(3) G.Material = "Plastic" Y.Material = "Plastic" R.Material = "Neon" wait(10) end
There are also other ways to make a simple traffic light, but this is the easiest because you have to type less!