Bay 12 Games Forum

Please login or register.

Login with username, password and session length
Advanced search  

Author Topic: Continued Worldgen  (Read 806 times)

Madventurer

  • Bay Watcher
    • View Profile
Continued Worldgen
« on: May 26, 2012, 11:32:04 am »

Searching didn't find find any similar topics, and I don't remember seeing it earlier.

Continued worldgen that can be accessed from legends mode. From what I've heard, worldgen doesn't happen during fortress or adventurer (?). So, pass a little time and new historical figures appear! Currently the only way to pass time is making a fortress: You really can't do that with adventuring. Maybe a button for "Generate one year" or "Generate X years" would change that. Goblins kill your fortress, you pass 50 years, elves have taken it.
Or just for when you want to make an ancient home that gets overrun and then reclaim it hundreds of years later (Moria!).

Comments and improvements are welcome.

And tell me if this is here already...
Logged
Then he made grudge wit about 20 other dwarfs (still don't know why - perhaps they were stealing his chair).

Itsdavyjones

  • Bay Watcher
    • View Profile
Re: Continued Worldgen
« Reply #1 on: May 26, 2012, 11:35:24 am »

Intresting idea I have to say.
Logged

NW_Kohaku

  • Bay Watcher
  • [ETHIC:SCIENCE_FOR_FUN: REQUIRED]
    • View Profile
Re: Continued Worldgen
« Reply #2 on: May 26, 2012, 11:57:34 am »

This has been suggested before plenty of times.  Are you aware that our search bar is not like google search, and operates on Boolean AND?  If you put in more than one word, every word has to be in a single post to return a hit.  So putting in as few words as possible (preferably just one) will return the best results.

Most importantly, however, it's already planned to be put in the game. 

The thing is, Toady wants worldgen to continue into play, but this means turning abstracted systems into ones that continue in a concrete way, even when you walk up and watch them happening in person.  Hence, it needs to be capable of happening on multiple scales of abstraction, and it needs to be capable of taking the ways that the player has changed the world into account.

It will happen eventually, and be put into the game gradually, as the simulation becomes more advanced.
Logged
Personally, I like [DF] because after climbing the damned learning cliff, I'm too elitist to consider not liking it.
"And no Frankenstein-esque body part stitching?"
"Not yet"

Improved Farming
Class Warfare

Madventurer

  • Bay Watcher
    • View Profile
Re: Continued Worldgen
« Reply #3 on: May 26, 2012, 11:59:38 am »

This has been suggested before plenty of times.  Are you aware that our search bar is not like google search, and operates on Boolean AND?  If you put in more than one word, every word has to be in a single post to return a hit.  So putting in as few words as possible (preferably just one) will return the best results.

I did exactly like that.

And for the rest, I meant that passing time between forts, not during them.
Thats pretty different.
Logged
Then he made grudge wit about 20 other dwarfs (still don't know why - perhaps they were stealing his chair).

GreatWyrmGold

  • Bay Watcher
  • Sane, by the local standards.
    • View Profile
Re: Continued Worldgen
« Reply #4 on: May 26, 2012, 12:38:24 pm »

There's a couple problems.

1. While the world is being generated, it's in a sort of fluid, abstract form. Once it's generated, it is more...crystalized, definite, malleable. Turning whatever form you leave the world in back to the abstract kind that worldgen needs would be harder than redesigning worldgen to use the malleable crystal of the generated world, which seems pretty hard even without accounting for changes the player makes in the world.
Logged
Sig
Are you a GM with players who haven't posted? TheDelinquent Players Help will have Bay12 give you an action!
[GreatWyrmGold] gets a little crown. May it forever be his mark of Cain; let no one argue pointless subjects with him lest they receive the same.

NW_Kohaku

  • Bay Watcher
  • [ETHIC:SCIENCE_FOR_FUN: REQUIRED]
    • View Profile
Re: Continued Worldgen
« Reply #5 on: May 26, 2012, 02:18:29 pm »

I did exactly like that.

And for the rest, I meant that passing time between forts, not during them.
Thats pretty different.

Well, trust me, there are plenty of suggestions exactly like this.

And it doesn't matter whether it's during or after forts, the thing is that the way that data is handled in worldgen is different from the way that data is stored.  Worldgens take up as much as 2 gigs of RAM, and then get compressed down into a save containing less than 100 megs of data.

The pigeonhole principle alone should tell you that you're losing a ton of granularity in the data because of that. 

"Continuing Worldgen" means reconstructing that abstracted and complex worldgen principle while in-play. 

I'm not saying that it would be impossible to make a "continue worldgen" option without having a "make worldgen continue while in play", but the thing is, you're just flat out going to see both come at the same time, because building the structure to do one means building the structure to do the other.
Logged
Personally, I like [DF] because after climbing the damned learning cliff, I'm too elitist to consider not liking it.
"And no Frankenstein-esque body part stitching?"
"Not yet"

Improved Farming
Class Warfare

Bohandas

  • Bay Watcher
  • Discordia Vobis Com Et Cum Spiritum
    • View Profile
Re: Continued Worldgen
« Reply #6 on: May 26, 2012, 02:35:51 pm »

I did exactly like that.

And for the rest, I meant that passing time between forts, not during them.
Thats pretty different.

Well, trust me, there are plenty of suggestions exactly like this.

And it doesn't matter whether it's during or after forts, the thing is that the way that data is handled in worldgen is different from the way that data is stored.  Worldgens take up as much as 2 gigs of RAM, and then get compressed down into a save containing less than 100 megs of data.

The pigeonhole principle alone should tell you that you're losing a ton of granularity in the data because of that. 

"Continuing Worldgen" means reconstructing that abstracted and complex worldgen principle while in-play. 

I'm not saying that it would be impossible to make a "continue worldgen" option without having a "make worldgen continue while in play", but the thing is, you're just flat out going to see both come at the same time, because building the structure to do one means building the structure to do the other.
Actually, the simplest way to continue worldgen would be incompatible with making worldgen continue during play. What you would need to do is to regenerate the world up to the same point where it stopped initially using the same seed number, check for differences in the regenerated world and the saved world, modify the world in memory to rectify it with the world as saved, and then continue the generator.

This method has several glaring problems, including the fact that it doesn't account for WHEN things occurred during play - Essentially your fortresses would be the only things that will have changed in any way between the time of the initial generator ending and the generator resuming - Also it would likely take even MORE ram than the initial world generation due to having to check for differences. It would, however, probably be the simplest way to do it.
Logged
NEW Petition to stop the anti-consumer, anti-worker, Trans-Pacific Partnership agreement
What is TPP
----------------------
Remember, no one can tell you who you are except an emotionally unattached outside observer making quantifiable measurements.
----------------------
Έπαινος Ερις

NW_Kohaku

  • Bay Watcher
  • [ETHIC:SCIENCE_FOR_FUN: REQUIRED]
    • View Profile
Re: Continued Worldgen
« Reply #7 on: May 26, 2012, 02:43:32 pm »

I'm assuming, however, the goal is not to create that sort of simplest solution, and to create a real solution, because there's a reason Toady hasn't done that yet.  (And it's certainly not because there isn't someone in FotF coming in asking every two weeks...)

Toady wants to make the full can-run-while-you-are-playing-the-game version of worldgen, which presumably means that it will involve Adventure Mode having characters that decide to actually do things, rather than sit in place and wait for adventurers to come either talk to them or kill them. 

That's all a part of the current arc of Adventure Mode updates that was supposed to have the Personality Rewrites take place (which would give the mechanics for the AI to have "goals" and "desires" that would theoretically be what leads them to decide what to actually be doing in gameplay), at which point we'd get the villagers milling around doing things with some reasonable AI, at which point, that AI could be abstracted when not looked at directly to be the "continuing worldgen in play" that could simply be accelerated to have the Continued Worldgen option people have been continuously asking for.
Logged
Personally, I like [DF] because after climbing the damned learning cliff, I'm too elitist to consider not liking it.
"And no Frankenstein-esque body part stitching?"
"Not yet"

Improved Farming
Class Warfare

Mrhappyface

  • Bay Watcher
    • View Profile
Re: Continued Worldgen
« Reply #8 on: May 27, 2012, 10:17:47 am »

Think of a kiln baking clay. Turning it back into soft clay while still retaining its shape is pretty hard.
Logged
This is Dwarf Fortress. Where torture, enslavement, and murder are not only tolerable hobbies, but considered dwarfdatory.

GreatWyrmGold

  • Bay Watcher
  • Sane, by the local standards.
    • View Profile
Re: Continued Worldgen
« Reply #9 on: May 27, 2012, 01:40:34 pm »

I wonder if, as a temporary solution, the world could be left in its...clayey form until you started a fortress or adventurer? Meh, probably not worth it.
Logged
Sig
Are you a GM with players who haven't posted? TheDelinquent Players Help will have Bay12 give you an action!
[GreatWyrmGold] gets a little crown. May it forever be his mark of Cain; let no one argue pointless subjects with him lest they receive the same.

Bytyan

  • Bay Watcher
    • View Profile
Re: Continued Worldgen
« Reply #10 on: May 27, 2012, 02:30:57 pm »

I wonder if, as a temporary solution, the world could be left in its...clayey form until you started a fortress or adventurer? Meh, probably not worth it.
I think this metaphor has passed it's peak.
In any event, with the relevant arch coming relatively soon, it's unlikely we will get a temporary fix, and it is not likely to be fixed properly for months or years.
It could be that it gets bumped up with the personality rewrite, but I wouldn't hold my breath.
Logged

NW_Kohaku

  • Bay Watcher
  • [ETHIC:SCIENCE_FOR_FUN: REQUIRED]
    • View Profile
Re: Continued Worldgen
« Reply #11 on: May 27, 2012, 06:49:09 pm »

I wonder if, as a temporary solution, the world could be left in its...clayey form until you started a fortress or adventurer? Meh, probably not worth it.

Unfortunately, no. 

This takes place when you are given the option to accept a newly genned world, and make it into a save for the first time because the transformation from .5 - 2 gigs of memory into 5-100 megs of hard disk save file takes place at that time when it says "offloading world:  X/Y" 

When you have a world to actually start, it's coming off the hard drive, which is the only way it can actually run.  After all, the actual embark tiles or area around an adventurer that is loaded into memory takes up a biggish chunk of memory, itself - you'd be guaranteed slamming past the 32bit library's 2 gig memory limit on any medium world with a reasonable size history and an average embark, since even a starting fortress on a 4x4 embark takes up half a gig.  That means you have to put world data onto the hard drive in a compressed format. 

The only thing that could be really possible is a "continue worldgenning even further than this" before you accept a world (like if you run it for 500 years, and figure another 100 would do it good).  Once you accept the world, though, it has to go onto the hard disk in the compressed format. 
Logged
Personally, I like [DF] because after climbing the damned learning cliff, I'm too elitist to consider not liking it.
"And no Frankenstein-esque body part stitching?"
"Not yet"

Improved Farming
Class Warfare

King Mir

  • Bay Watcher
    • View Profile
Re: Continued Worldgen
« Reply #12 on: May 28, 2012, 01:41:12 am »

And it doesn't matter whether it's during or after forts, the thing is that the way that data is handled in worldgen is different from the way that data is stored.  Worldgens take up as much as 2 gigs of RAM, and then get compressed down into a save containing less than 100 megs of data.

The pigeonhole principle alone should tell you that you're losing a ton of granularity in the data because of that. 
The pigeonhole principle does not apply here. The common application of the pigeonhole principle in computing is in pointing out the non-universality of compression algorithms. But you don't need a universal compression algorithm here. It may be that insufficient data is saved to continue world gen, and given that 2GB is much larger than 100 MB, it may even be likely, but it is not necessarily so. If the pigeon-hole principle did apply, it would necessarily be the case. World gen may represent data with lots of redundancies and that patterned, repetative data can be compressed to a smaller memory footprint losslessly.

I apologize for being anal about this, but this statement was bugging me.