|
| 06 Aug 2015 10:29 PM |
wait (5) mesh = script.Parent.Mesh canextend = true function Extend() while true do if mesh.Scale.X ~= 3.5 and canextend == false then mesh.Scale = Vector3.new(mesh.Scale.X + 0.2, mesh.Scale.Y, mesh.Scale.Z) else canextend = false end if canextend == false then mesh.Scale = Vector3.new(mesh.Scale.X - 0.1, mesh.Scale.Y, mesh.Scale.Z) if mesh.Scale.X ~= 3 then canextend = true end end wait() end end print("Script READY") wait(1) Extend()
My problem is it just keeps expanding and doesn't stop. I don't know what the problem is. |
|
|
| Report Abuse |
|
|
|
| 06 Aug 2015 10:30 PM |
Sorry! Slight script typo. wait (5) mesh = script.Parent.Mesh canextend = true function Extend() while true do if mesh.Scale.X ~= 3.5 and canextend == true then -- typo here "true" e.e mesh.Scale = Vector3.new(mesh.Scale.X + 0.2, mesh.Scale.Y, mesh.Scale.Z) else canextend = false end if canextend == false then mesh.Scale = Vector3.new(mesh.Scale.X - 0.1, mesh.Scale.Y, mesh.Scale.Z) if mesh.Scale.X ~= 3 then canextend = true end end wait() end end print("Script READY") wait(1) Extend() |
|
|
| Report Abuse |
|
|
| |
|
| |
|