badfitz60
|
  |
| Joined: 03 Sep 2010 |
| Total Posts: 1283 |
|
|
| 30 Oct 2015 11:54 AM |
how would I load chunks if a player is close to it or whatever
Never too late to change a life, sir. |
|
|
| Report Abuse |
|
|
digpoe
|
  |
| Joined: 02 Nov 2008 |
| Total Posts: 9092 |
|
| |
|
badfitz60
|
  |
| Joined: 03 Sep 2010 |
| Total Posts: 1283 |
|
|
| 30 Oct 2015 11:55 AM |
"distance"
i have my generation script as a serverscript in workspace
how would I change that to infinite terrain or would I need to do something else?
Never too late to change a life, sir. |
|
|
| Report Abuse |
|
|
Cuyler
|
  |
| Joined: 27 Feb 2006 |
| Total Posts: 3784 |
|
|
| 30 Oct 2015 11:57 AM |
Use magnitude to calculate the chunks' distance from the player, then load it either from DataStores(kind of inefficient) or ServerStorage(also inefficient...)
It's possible but it'll be kinda slow no matter how you go about doing it. Oh and I hope you mean 'Modular Models' rather than actual Terrain, because that'd be way too slow unless you're planning on only doing the surface layer.. |
|
|
| Report Abuse |
|
|
badfitz60
|
  |
| Joined: 03 Sep 2010 |
| Total Posts: 1283 |
|
|
| 30 Oct 2015 12:00 PM |
It's a heightmap generation (editted version of the one from the wiki)
Never too late to change a life, sir. |
|
|
| Report Abuse |
|
|
Cuyler
|
  |
| Joined: 27 Feb 2006 |
| Total Posts: 3784 |
|
|
| 30 Oct 2015 12:05 PM |
| Okay. Depending on the part count per chunk, it might be plausible. Pretty much just create a chunk size (16x16x16 is an example), then once that chunk has been loaded, assign it to a table or give it a name so it can be accessed later. Then once the player has moved out of your specified render distance, unload it by storing it in ServerStorage or ReplicatedStorage. Then if they come back within render distance, just simply load it back in rather than recreating it. |
|
|
| Report Abuse |
|
|
badfitz60
|
  |
| Joined: 03 Sep 2010 |
| Total Posts: 1283 |
|
|
| 30 Oct 2015 12:08 PM |
so can it stay as a single server script in workspace?
Never too late to change a life, sir. |
|
|
| Report Abuse |
|
|
|
| 30 Oct 2015 12:11 PM |
I am kind of thinking that nobody here knows what they are doing. Make procedural generated terrain using math.noise. |
|
|
| Report Abuse |
|
|
badfitz60
|
  |
| Joined: 03 Sep 2010 |
| Total Posts: 1283 |
|
|
| 30 Oct 2015 12:11 PM |
forget it
Never too late to change a life, sir. |
|
|
| Report Abuse |
|
|