generic image
Processing...
  • Games
  • Catalog
  • Develop
  • Robux
  • Search in Players
  • Search in Games
  • Search in Catalog
  • Search in Groups
  • Search in Library
  • Log In
  • Sign Up
  • Games
  • Catalog
  • Develop
  • Robux
   
ROBLOX Forum » Game Creation and Development » Scripters
Home Search
 

Re: What is RunService mainly used for?

Previous Thread :: Next Thread 
Exanimatedn9dean is online. Exanimatedn9dean
Joined: 11 Aug 2015
Total Posts: 1469
10 Oct 2017 12:58 AM
???
Report Abuse
Hazania is not online. Hazania
Joined: 04 Jun 2010
Total Posts: 1344
10 Oct 2017 01:00 AM
Primarily, it is used to track frames so that you can have Guis or scripts that update every frame the player sees.
Report Abuse
AskavixDomini is online. AskavixDomini
Joined: 06 Aug 2016
Total Posts: 1034
10 Oct 2017 02:41 AM
One of its "properties" (i'ma get roasted for saying that) is RenderStepped. What RenderStepped is, is it fires on EVERY frame loaded.

So if a player is getting 60 FPS, then it happens 60 times a second. So say you want something updating faster than while wait() do end, this is your guy.

e.g.

game:GetService("RunService").RenderStepped:connect(function()
print("This is happening very quickly!")
end)


Report Abuse
Exanimatedn9dean is online. Exanimatedn9dean
Joined: 11 Aug 2015
Total Posts: 1469
10 Oct 2017 03:08 AM
What if you were to try and make something happen just as fast, but on the server? (Considering you cna't use it on there ## ####
Report Abuse
JarodOfOrbiter is not online. JarodOfOrbiter
Joined: 17 Feb 2011
Total Posts: 20029
10 Oct 2017 03:11 AM
You should never need to run things at 60 hertz in Roblox. It's inefficient. Make it delay more, not less. That's just for doing stuff in general.

HOWEVER
RenderStepped is useful when dealing with the camera or GUIs. For example, if you want to use WorldToViewportPoint to make your own BillboardGui hovering over someone's head, it will be kind of flickery and jumpy if you use wait. This is where you use RenderStepped.


Report Abuse
JeanBoulogne is not online. JeanBoulogne
Joined: 25 Aug 2017
Total Posts: 212
10 Oct 2017 03:13 AM
So I would use this to make for example a cinema screen?
Report Abuse
JarodOfOrbiter is not online. JarodOfOrbiter
Joined: 17 Feb 2011
Total Posts: 20029
10 Oct 2017 03:16 AM
I'll make a quick demo place so you can see what I mean.


Report Abuse
JarodOfOrbiter is not online. JarodOfOrbiter
Joined: 17 Feb 2011
Total Posts: 20029
10 Oct 2017 03:31 AM
Here you are.
https://www.roblox.com/games/1098443312/JarodOfOrbiters-Place-Number-44

Go crazy with your camera, you'll see a bit of lag on the wait version. When you're working with rendering, use RenderStpped. An even better example is when you use a custom camera. If you use 'wait', your whole screen will be flickery when the camera moves.


Report Abuse
JeanBoulogne is not online. JeanBoulogne
Joined: 25 Aug 2017
Total Posts: 212
10 Oct 2017 03:40 AM
thnx alot having those guis look at me made me think of doomguy
:D
Report Abuse
Previous Thread :: Next Thread 
Page 1 of 1
 
 
ROBLOX Forum » Game Creation and Development » Scripters
   
 
   
  • About Us
  • Jobs
  • Blog
  • Parents
  • Help
  • Terms
  • Privacy

©2017 Roblox Corporation. Roblox, the Roblox logo, Robux, Bloxy, and Powering Imagination are among our registered and unregistered trademarks in the U.S. and other countries.



Progress
Starting Roblox...
Connecting to Players...
R R

Roblox is now loading. Get ready to play!

R R

You're moments away from getting into the game!

Click here for help

Check Remember my choice and click Launch Application in the dialog box above to join games faster in the future!

Gameplay sponsored by:
Loading 0% - Starting game...
Get more with Builders Club! Join Builders Club
Choose Your Avatar
I have an account
generic image