The International Simutrans Forum

Development => Extension Requests => Topic started by: Leartin on February 21, 2019, 12:28:06 PM

Title: Expansion of custom maps
Post by: Leartin on February 21, 2019, 12:28:06 PM
https://forum.simutrans.com/index.php/topic,18783 (https://forum.simutrans.com/index.php/topic,18783) <-- For reference

Title: Re: Expansion of custom maps
Post by: DrSuperGood on February 21, 2019, 02:09:40 PM
Quote
DrSuperGood added the ability to see the map seed when expanding the map, but not (yet) to edit it - which is good for normal maps (especially since you could never retrieve it after you lost it), but it seems a missed opportunity to allow custom maps to be expanded by entering your own seed, as those maps wouldn't have one.
It also opens up the opportunity for people to lose their map seed number forever by accidently modifying it, unaware that they might need it again in the future to expand their map seamlessly. To prevent this kind of problem one would need to have the field as read-only unless explicit confirmation is given to modify it (eg an unlock toggle).

This would be a non trivial UI modification. So instead I did the quickest possible solution to display map seed number to meet the requirements for now.
Title: Re: Expansion of custom maps
Post by: Leartin on February 21, 2019, 02:59:42 PM
As I said, if you lose your original map seed, you wouldn't be able to retrieve it. I agree that just allowing to edit it would be a bad move.
However, somehow the game knows that it's a custom map, since it does not expand those. Custom maps would not have this problem in the first place, since their seed is somewhere between non-existent and useless. Hence if the field is read only in case it's a generated map, but editable if it's not, you wouldn't need explicit confirmation. (No idea if that is any more trivial though)
Title: Re: Expansion of custom maps
Post by: Ters on February 21, 2019, 05:57:30 PM
I thought the reason why the seed is in the map in the first place, is because the map can not be reliably expanded using any other number. That only the original seed will generate new terrain that matches the edges of the old.
Title: Re: Expansion of custom maps
Post by: Leartin on February 22, 2019, 06:22:19 AM
I thought the reason why the seed is in the map in the first place, is because the map can not be reliably expanded using any other number. That only the original seed will generate new terrain that matches the edges of the old.
Exactly. Which is why it's hard to believe there would be any reason to change the map seed of a generated map. But for a map made via heightmap, the option to expand without a matching border would still be better than no option to expand at all. Choosing the seed, one can hope there is one that almost matches, making the seam less appearent, and landscaping tools can help smoothen it further. Not ideal, but it's something.
Title: Re: Expansion of custom maps
Post by: prissi on February 24, 2019, 12:52:17 PM
The enlarged map would have no valleys, but deep slopes, because the smoothening algorithm will run over it after generation or the raw values. Other than that it will be continuos, and some may even like the challenge of such features.