WebOn the line after changing the brick color, type wait (3). Whatever number placed inside the () is how many seconds the script will wait. while true do loopingPart.BrickColor = BrickColor.new (0.7, 0.9, 0.9) wait (3) end Adding More Colors You have one color, now you need a second color for your code to switch back and forth between. WebJul 31, 2024 · You could do something similar to this to wait until the player's character is in the workspace after they've first joined the game: game.Players.PlayerAdded:connect (function (player) repeat wait () until game.Workspace:FindFirstChild (player.Name) local part = Workspace:WaitForChild ("Moving brick", "plane") wait (part) end)
How to run multiple threads with Lua - Roblox Studio - YouTube
Webwait number Yields the current thread until the given duration (in seconds) has elapsed, then resumes the thread on the next Heartbeat step. The actual amount of time elapsed is … WebA good devforum post about this. Basically, It's inconsistent, unreliable and mostly slower than you would want it to be. You should use task.wait () or RunService.Heartbeat:Wait () … cricket wireless downdetector
task.wait() vs wait() - Roblox Scripting Help : …
WebApr 28, 2024 · 1 One very simple method is to spawn a new thread to do the work in. print ("I should appear first") spawn (function () wait (3) print ("I should appear third") end) print ("I should appear second") Share Follow answered Apr 28, 2024 at 23:52 Kylaaa 5,944 2 18 27 Thanks I were looking for answer for so much time and that simple thing worked!! WebScheduling code is useful in many situations, such as ensuring code executes after a specific action or cycle has completed, or delaying code for a specific duration of time. … WebAug 1, 2013 · wxLua has three sleep functions: local wx = require 'wx' wx.wxSleep (12) -- sleeps for 12 seconds wx.wxMilliSleep (1200) -- sleeps for 1200 milliseconds wx.wxMicroSleep (1200) -- sleeps for 1200 microseconds (if the system supports such resolution) Share Improve this answer Follow answered Aug 19, 2013 at 2:03 Lorenzo … budget chesterfield sofa