RFC - In-Game Map Uploads
-
For the cost of 3 months to streamline uploading, I would like the time to be spent improving the AI, if it was I would;
-
Learn how to upload my maps.
-
Upload other peoples maps for a year and try and encourage others to up load their own using the current method.
LaFayette you listed the benefits below, this is what convinced me we should keep the map uploads in Github, basically as is.
all files available at a web link.
an automatic history of changes available at web links, this is critical for an editorial review of maps to verify what has changed
automatic packaging of files
capability to do bulk updates.
capability to do bulk searches. Having all maps checked out locally, it's some easy commands to search all XMLs in existence.
capability to do bulk file adds.
. -
-
@TheDog said in RFC - In-Game Map Uploads:
... * Upload other peoples maps for a year and try and encourage others to up load their own using the current method.
...I struggled hard with git. I still do, but I did figure out how to add a map with the help of others.
sourceforge you had to have someone upload your map. You have to have someone to do the yaml PR now as well, although my guess is that is less work than the sourceforge way, and it just notifies people that the map has been updated or added. Well, I don't think it notifies one when a new map is added but ...
At any rate, once your map has been uploaded, you can update it by yourself. It just won't tell users there is an update.
Have a thread for people who can't update/need help with their maps and those that know how, if they feel like it, can help teach how or just do it.
I thought triplea was trying to "decouple" a lot of maps, so until that gets sorted ... i guess someone still needs to decide what can and can't be.
-
@LaFayette said in RFC - In-Game Map Uploads:
What is difficult about repository upload exactly?
I can share my first experience I had with GitHub a couple of years ago. I tried desperately to find a GitHub turorial, googling "GitHub tutorial for dummies", but turns out I was more of a dummy than anyone dared guess. Some questions I couldn't find an answer to were:
- What is even a "repository"?
- What is this "commit" thing? Why can't I just change the files and call it a day?
- What is "pull" and "push"? What is the difference?
- If I have already committed changes, why is there still a need to push? Or pull?
- Etc.
See, the problem was that I had a mental model about repositories and stuff, but it was the wrong model. I tried to think of a repository as something like a folder. Multiple branches - multiple folders! Add a file to a folder - why isn't that file in the "same" folder online? If I merge a branch - how does it know which folder to keep and which to discard?
-
@LaFayette said in RFC - In-Game Map Uploads:
@RogerCooper A map validator is a highly requested feature. I've also been thinking it might make sense to automatically do hue shifting from existing images to fill in missing images rather than the hue shift be controlled by configuration (just make it automatic).
Some mods such as "The Grand War" use flags rather than hue shifts anyhow.
-
@ff03k64 thanks for the feedback, responding to the questions you asked:
What all would be involved in in-game uploads?
- The map uplaod process would be brougth in game, I think the map maker would gain a new button "upload maps"
- After clicking 'upload maps', you would be prompted to log in to the lobby (this then assigns your name so the backend knows who you are)
- You would select the map folder or zip to be uploaded
- Triplea would confirm the upload details and then you click okay and it would upload it.
- New map uploads would go into a moderation queue of some sort and have to be approved to be available for general download. This moderation would only be a content check and would not be checking that the map is playable or otherwise
- The map becomes available for download, probably from a default 'Experimental' category and we later deal with category promotion in some other way.
What exactly does this file [map.yaml] do in the engine? I presume it tells the local engine which maps are available and also which maps have new versions since you downloaded them originally.
Pretty much. When you click 'download maps', the game engine downloads this file and the data from this file is used to generate the map download selection. The engine uses the data from this file to know which version you are downloading and can later detect if there are new versions available or if you have the latest version or one that is missing altogether. The preview image and the map description you see in the download maps window comes from the 'map.yaml' file.
Hence, until the 'map.yaml' file is updated (actually called 'triplea_maps.yaml', but that is a detail), until that file is updated, game engines do not see the map as yet available for download.
I think using edit mode to be able to make said XML could be very useful.
The dream I think is for the front-end to be all encompassing for map making. I would like to even bring in the map making tools to be part of starting a game, so instead of an 'edit' mode there would be a 'map making' mode.
Though, using edit mode to change a map, be able to re-export that back to disk and then upload it is certainly the idea. The latter step, to upload, is arguably the most questionable because we don't necessarily have to build it (uploading is a generic problem, there are alternatives compared to us building a custom solution).
-
@TheDog Thank you for the response. I think I would agree pretty fully now that we would be unwise to drop Github repositories as our choice for map storage. It provides quite a lot, helpful in a number of ways beyond just storing the file data.
@beelee, turns out anyone can propose a change to the map yaml file:
- Head to the file stored in the engine repository, https://github.com/triplea-game/triplea/blob/master/triplea_maps.yaml
- Click the pencil icon
- The file will change from a read-only view to a text box that you can edit
- Make your edits, add a short description of what you changed & then click 'propose changes' (if you need to create a fork and do more github guides you through that and mostly does that work for you automatically).
This ties back into using github for map storage. The same pencil icon is available to edit game XML files as well, which means anyone can propose a tweak (or a correction) to any uploaded map file.
-
First a tangent. I responded to Alkexr's post above before i realized that they were talking about when they first experienced Github. It could still be useful to have a development glossary of some sort. Do we want that, or should I just delete what I typed? If we want it where should i put it?
So, back on topic. How much bloat do we want to put into the main TripleA download? Most people won't build maps. Would we possibly want a separate version that has any features like this that gets made? The canadian units already got removed because someone thought they were unnecessary and would help download speeds. At least that is what my memory tells me.
I think if we can get better documentation, that is probably more useful than all the work that would be involved with putting all this into the engine at this point.
-
I like the idea of having a thread to get users help. I wonder if that should be a full category even rather than a single thread? A pinned & locked post to that category could have a description of what to do, how to upload and have further links and details, all that would be needed to complete the upload process.
I tried to think of a repository as something like a folder. Multiple branches - multiple folders!
There are some source control systems out that work exactly like that : )
FWIW - A commit is essentially a file diff, a set of line changes and file additions and deletes. A branch is a list of commits. By "replaying" the set of commits git can reconstruct the state of all files to any point in the commit history. Also, this is why git never deletes as well because the contents must be available if you go back in history to before a deletion (so deletes in git are handled with tombstone markers that mark content as deleted, but it's not physically removed from disk).
The "main" branch by convention is called 'master'. To keep things simple we typically use just the one branch 'master' in map repositories. I think I'm seeing good usage for a really good explanation thread to
I think this goes back to having a help thread, explaining some of this, somewhere accessible, would probably make it quite a bit easier.
-
So, back on topic. How much bloat do we want to put into the main TripleA download?
It would all be source code changes. The cost would not be observed in download speed but instead for maintenance. If you build a house, you have to keep it up, make sure the roof gets replaced, make sure if you build a house next door that you don't disturb the foundations or cut the water main to the existing house. These are the costs we would see, just more code to get right and maintain (and future maintainers, whomever they would be, it's more stuff for them to read through and understand).
Most people won't build maps. Would we possibly want a separate version that has any features like this that gets made?
Agree, though making it as easy as possible I think is largely what TripleA is all about. I would like to try and keep the tools all-in-one so it's easier to find. Really, as mentioned above, I'd like to bring it all into the 'in-game' mode and have something like 'map making' mode that adds additional options to edit and save the map.
The canadian units already got removed because someone thought they were unnecessary and would help download speeds. At least that is what my memory tells me.
We (I) did an analysis of every unit image and which maps used them. Canadian units were used by something like 8 maps, and almost half of those maps had their own duplicative copy of the canadian unit images anyways. Out of around 130 maps, having 4 unique maps use images is very few. Images that are going to be in the common game-engine have a rule-of-thumb threshold that they ought to be used in perhaps at least 20% of maps (the WWII images are used in around 70%-80% of maps).
' -
First, thank you all for the engagement on this topic!
To summarize where we are so far in this discussion:
- github repositories is a beneficial storage solution that provides a lot of features that we would be unwise to rebuild in its entirety
- automating the management of 'triplea_maps.yaml' is welcome
- documentation effort is needed to make the upload process clear. We should create at least a thread, if not a category to provide help for uploading
Follow-Up Topics to Discuss in other Threads
A number of other topics were raised that could use discussion. I'm thinking to create a thread titled something like: "How should we improve the maps ecosystem" where we could discuss the many other aspects of maps and what could use improvement.
Still under consideration: zip uploads that are automatically stored as repositories
First, if we automate the generation of 'triplea_maps.yaml' by finding data that is stored in the repositories, we'll have taken care of a portion of the download side. Specifically the idea here is that 'triplea_maps.yaml' has a section for each map, essentially we move each section of that file to the respective map repository where the backend would be configured to find it. In this way the backend could effectively generate the 'triplea_maps.yaml' file.
A really nice thing about the above is the backend wouldn't care how the map data gets into repository. After we get to that point, it could make sense to build an in-game uploader that takes a zip file and uploads it into a repository. There is enough complexity in doing that where I don't know if it would be worth it, so we'll need to play it by ear when and if we get there.
Hello! It looks like you're interested in this conversation, but you don't have an account yet.
Getting fed up of having to scroll through the same posts each visit? When you register for an account, you'll always come back to exactly where you were before, and choose to be notified of new replies (either via email, or push notification). You'll also be able to save bookmarks and upvote posts to show your appreciation to other community members.
With your input, this post could be even better 💗
Register Login