| |
|
|
| 22 Oct 2012 06:51 AM |
while true do
wait()
print("hello")
end |
|
|
| Report Abuse |
|
|
| |
|
|
| 22 Oct 2012 11:17 AM |
You can do this: while true do wait(2) end |
|
|
| Report Abuse |
|
|
|
| 22 Oct 2012 11:18 AM |
Fixed one: while true do wait(0) print("WASSUP NOOBS!!!") end |
|
|
| Report Abuse |
|
|
|
| 22 Oct 2012 01:03 PM |
@legal
waiting for 0 seconds is redundant.
@Everyone
while wait() do end
Less lines and more elegant. |
|
|
| Report Abuse |
|
|
|
| 22 Oct 2012 01:09 PM |
To go more in-depth, 'wait()', when a number is not specified, waits (what I think is, could be wrong) the shortest time possible, roughly 0.03 seconds. Also, be careful not to have an endless loop without any kind of wait() in it, because it may crash your game. |
|
|
| Report Abuse |
|
|
gijsbel11
|
  |
| Joined: 07 Feb 2009 |
| Total Posts: 4223 |
|
|
| 22 Oct 2012 01:14 PM |
| If roblox would enable >30 fps it would be less then 0.03 per update(client sided) |
|
|
| Report Abuse |
|
|
|
| 22 Oct 2012 02:11 PM |
"If roblox would enable >30 fps it would be less then 0.03 per update(client sided)"
Its not about the framerate, its about game ticks
|
|
|
| Report Abuse |
|
|
|
| 22 Oct 2012 03:05 PM |
@stealth
There is more than one framerate. On roblox the game's tick refresh rate is generally named the same as the rendering refresh rate. |
|
|
| Report Abuse |
|
|
|
| 22 Oct 2012 03:37 PM |
| wait(0) is the same as wait(), though it's supposed to simply wait one game tick. wait()/wait(0) in a local script can be changed by the player through their Roblox Studio settings. I'd suggest always filling in a number in your waits :) |
|
|
| Report Abuse |
|
|
|
| 22 Oct 2012 03:41 PM |
wait(0) actually does wait 0 seconds, wait() waits one game tick.
Waiting for one game tick is fine as it allows the game long enough time to process the requests without crashing. |
|
|
| Report Abuse |
|
|
|
| 22 Oct 2012 03:45 PM |
| No, Source. It's thought that wait(0) waits a single game tick, but it's the exact same as wait() if you test it. |
|
|
| Report Abuse |
|
|
|
| 22 Oct 2012 03:49 PM |
| wait() IS a game tick. wait(0) is 0. 0 is not anything. |
|
|
| Report Abuse |
|
|
|
| 22 Oct 2012 04:01 PM |
| When you call the wait function, you wait. It's pretty simple if you ask me. |
|
|
| Report Abuse |
|
|
1pie23
|
  |
| Joined: 11 Jul 2010 |
| Total Posts: 1865 |
|
|
| 22 Oct 2012 04:03 PM |
wait(0) == wait()
true
wait(0.0000000000000000000000000000000000000001) == wait()
true |
|
|
| Report Abuse |
|
|
|
| 26 Oct 2012 02:41 PM |
@Source while wait() do end Wouldn't work or at-least I don't think it would |
|
|
| Report Abuse |
|
|
|
| 26 Oct 2012 02:43 PM |
Wow. This topic went from people who don't know what they're talking about to people who do know what they're talking about, and then it ended up as people who don't know what they're talking about.
while wait() do end
Would indeed work. |
|
|
| Report Abuse |
|
|
|
| 26 Oct 2012 02:44 PM |
@Source Actually He is right wait(0) is a single game tick and it's the same thing as wait() Either way you think about it it's the same thing trust me. They both make you wait the same amount of time.
~LIKE A BLOCK~ ~Check out my youtube channel: FallenAngelGaming |
|
|
| Report Abuse |
|
|
|
| 26 Oct 2012 02:46 PM |
I didn't know that but like I said "I dont think it will work"
~LIKE A BLOCK~ ~Check out my youtube channel FallenAngelGaming |
|
|
| Report Abuse |
|
|
su8
|
  |
| Joined: 06 Mar 2009 |
| Total Posts: 6334 |
|
|
| 26 Oct 2012 03:31 PM |
wait() = wait(settings().Lua.DefaultWaitTime)
However wait(0) is always one frame |
|
|
| Report Abuse |
|
|