analog_electricity, fix color index loop

parent 5d65d7f4
......@@ -249,7 +249,7 @@ function disableToolDelete() {
}
function nextColorIndex() {
if(colorIndex < wireColors.length)
if(colorIndex < wireColors.length - 1)
++colorIndex;
else
colorIndex = 0;
......
Markdown is supported
0% or .
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment