Mitko0o1
|
  |
| Joined: 30 Nov 2010 |
| Total Posts: 5725 |
|
|
| 26 Jun 2015 01:13 PM |
Me an powerhotmail123 argued about which method of scripting would be more efficient.
He said that having a single, core script that loops and runs functions with coroutines or with the function Spawn(), the functions that run are going to be used instead of having many looping scripts inside different kinds of objects in workspace.
Will it be more efficient than having all the looping scripts spread out in the objects held in workspace, and by efficient I mean which one will create more lag and which one will be easier to be fixed if an error appears, or is there even a difference? |
|
|
| Report Abuse |
|
|
Zecrit
|
  |
| Joined: 24 Jan 2013 |
| Total Posts: 2618 |
|
|
| 26 Jun 2015 01:15 PM |
| More scripts = more processing for the roblox game engine to work on = more lag. |
|
|
| Report Abuse |
|
|
Mitko0o1
|
  |
| Joined: 30 Nov 2010 |
| Total Posts: 5725 |
|
|
| 26 Jun 2015 01:17 PM |
@Zec
Yeah, I though of that too, but the core script will have to run many loops in the same time, so I thought that it may not even make a difference. |
|
|
| Report Abuse |
|
|
Zecrit
|
  |
| Joined: 24 Jan 2013 |
| Total Posts: 2618 |
|
|
| 26 Jun 2015 01:17 PM |
| A script is only capable of running 1 loop at a time. |
|
|
| Report Abuse |
|
|
|
| 26 Jun 2015 01:18 PM |
Even thought it would still have quite a few loops, there would be MUCH-MORE loops with having separate scripts each holding there own loops.
Enjoying your stay at the Scripters Forum? Join this! http://www.roblox.com/My/Groups.aspx?gid=2582784 |
|
|
| Report Abuse |
|
|
|
| 26 Jun 2015 01:18 PM |
@Zecrit
Nope, use the spawn() function or Coroutines for running multiple threads at the same time.
Enjoying your stay at the Scripters Forum? Join this! http://www.roblox.com/My/Groups.aspx?gid=2582784 |
|
|
| Report Abuse |
|
|