Scripting HelpersARCHIVE
A little piece of Roblox history. Preserved for everyone, one question at a time.Read about the archive →
✓ ANSWER ACCEPTED

what is RunService? And what does RunService do?

1 answer

✓ Accepted answer

RunService has many events, so it's hard to explain all of them... The most used one in my opinion is RenderStepped (RunService.RenderStepped). This is used in localscripts and is a great way to make a forever loop. If you put a function inside of the event...

game:GetService("RunService").RenderStepped:Connect(function()
	print("Hello World")
end)

It will run every frame. If you don't know what frames are, they are like moving pictures that continuesly goes (On roblox it is max 60 frames per second, unless you use a rbx unlocker)

2 comments

0

I like NordicM's explanation. Developers use RunService to make things smoother in their game. For example, if I was trying to code being able to move furniture by moving my mouse, I would use RunService to help make the furniture move smoothly along with my mouse.

0

Thanks a lot for the help!

This discussion is preserved as it was. New answers, comments, and votes are closed.