Updated specific locations to be searchable, take a look at Las Vegas as an example.

This post has been de-listed

It is no longer included in search results and normal feeds (front page, hot posts, subreddit posts, etc). It remains visible only via the author's post history.

3
How to code a save game system in a grand strategy game that you can erase borders in?
Post Body

I'd like to illustrate how I've planned to code a grand strategy map so far, and below to write about what I'm stuck on.

https://preview.redd.it/casx9qjkw8m21.png?width=239&format=png&auto=webp&s=3c6b9e87dca091e237d3dfaf148d0d92a685b564

I would start with a blank political map(I would overlay it with maps of relief, rainfall etc.)

https://preview.redd.it/gypwvqixw8m21.png?width=239&format=png&auto=webp&s=5e48cb3d993fdb3b8be8253ed80ba65f63996fc8

I would flood fill all the white areas till the borders to discern entire area of a country

https://preview.redd.it/0w0n4iuwx8m21.png?width=239&format=png&auto=webp&s=96850b14a55902dd23f8d8bf6063d6df5af50f1d

I would end up with select-able and colour-able gameobjects. Their data would be manually input in a text file.(I.E. First flood filled="Ireland", 4.784m, ...; Second flood filled="N.Ireland..." )

https://preview.redd.it/qm0tkby209m21.png?width=312&format=png&auto=webp&s=e4d1cb349eacd78f6321dfdc5d9ae29325012cbb

My game would need to feature country unification, and thus the removal of borders.

I would intersect the outermost pixels of a country with the outermost pixels of a neighboring country to determine the border(border is whatever black is found under the intersection).

https://preview.redd.it/csrbyty519m21.png?width=312&format=png&auto=webp&s=37c0257a716fe78c6505792e86bde05dc5b9ab1d

Border is removed, the area is flood filled again under a new predetermined name, and the rest of the data being a combination of the previous countries' data.

I don't know what to do when it comes to saving/loading games. So far the only thing I could think of is to create a blank political map without the new borders as a part of the save file which would be used instead of the original blank political map when the player loads the save. This kind of image saving seems to me like it would be finicky at best.

If you have any opinions or advice on how to do the saving/loading, on better ways about coding a grand strategy game, or any handy plugins, assets, libraries that concern this kind of a game, then please leave a reply. Any kind of input would be greatly appreciated.

Author
Account Strength
80%
Account Age
9 years
Verified Email
Yes
Verified Flair
No
Total Karma
188
Link Karma
167
Comment Karma
21
Profile updated: 3 days ago
Posts updated: 2 weeks ago

Subreddit

Post Details

We try to extract some basic information from the post title. This is not always successful or accurate, please use your best judgement and compare these values to the post title and body for confirmation.
Posted
5 years ago