TripleA Logo TripleA Forum
    • TripleA Website
    • Categories
    • Recent
    • Popular
    • Users
    • Groups
    • Tags
    • Register
    • Login

    XML option browser

    Scheduled Pinned Locked Moved XML Options Browser
    58 Posts 10 Posters 39.8k Views 9 Watching
    Loading More Posts
    • Oldest to Newest
    • Newest to Oldest
    • Most Votes
    Reply
    • Reply as topic
    Log in to reply
    This topic has been deleted. Only users with topic management privileges can see it.
    • General_ZodG Offline
      General_Zod Moderators @General_Zod
      last edited by General_Zod

      I think the only true advantage that the POS2 would maintain is that it showcases a lot of the code in complete context. But TASOB blows it away in every other way. If we maintain only one database, I would vote for this new one. Thus leaving POS2 with a prominent note indicating the date of last update and to refer to new database for most current information.

      1 Reply Last reply Reply Quote 0
      • C Offline
        Cernel Moderators @Mahks
        last edited by

        @mahks I disagree; being already in an xml makes POS2 much easier to be used than searching a Wiki (I never use). With the move to GitHub, POS2 can really fairly easily be updated by anyone, and the developers just need to accept the pull. While the Wiki is easier to maintain, it uses to remain unupdated for years, so letting anyone doing it is not really a reliable practice, since very few people would do it, no matter how easy to. At the end, it is needed to have 1 or at most 2 official references that are mandatory to be updated as soon as any changes are made (likely by the developers doing the changes). Another advantage of POS2 is that if you make mass changes in the repository, they will apply there too.
        I agree that having the main reference inside a game xml looks akward at first glance, but not a big deal, since it works well.

        1 Reply Last reply Reply Quote 0
        • C Offline
          Cernel Moderators @Mahks
          last edited by

          @mahks Up to the admins, but I've the feeling those would be better in mapmaking, or maybe a special subsection of mapmaking.

          1 Reply Last reply Reply Quote 0
          • General_ZodG Offline
            General_Zod Moderators @Mahks
            last edited by

            @mahks

            A find, find next or search function would be beneficial to TASOB. One that would search through not only the lists on the left and their descriptions, but also through the examples and their contexts.

            MahksM 1 Reply Last reply Reply Quote 0
            • MahksM Offline
              Mahks @General_Zod
              last edited by

              @general_zod Yes, search function ... I have been pondering that. The question is this; If it is only a left hand search then you miss many references to mid string stuff ie; a search for "sneak" would miss "Defending Subs Sneak Attack". But if you do a full string search it would be very easy to get a huge list of references. I thought I could do the latter and only return a unique link for each, not sure how helpful that would be. Still pondering...

              1 Reply Last reply Reply Quote 0
              • MahksM Offline
                Mahks @General_Zod
                last edited by

                @general_zod said :

                I see, "s" is for scenario. So it is triplea scenario option browser. Personally I would just exchange scenario for xml. TAXOB

                How about just XOB?

                General_ZodG 1 Reply Last reply Reply Quote 0
                • LaFayetteL Offline
                  LaFayette Admin
                  last edited by

                  Very nice work.

                  We could do a special commentary syntax in the source code where attachments are defined. On each build we could fire up a script that then scrapes these comments and produces a JSON that is then delivered to a 'data' section of the website and would then be available as a javascript variable. This is pretty similar to how the maps page is populated: http://triplea-game.org/maps-list/maps/

                  @Mahks if you can handle the front-end part, with jekyll, and assume you have such a JSON variable, I could do the backend scraping and deliver the JSON. https://github.com/triplea-game/triplea-game.github.io

                  Thoughts?

                  MahksM 1 Reply Last reply Reply Quote 0
                  • redrumR Offline
                    redrum Admin
                    last edited by

                    Interesting. So I think the real question here is do we have general consensus on replacing POS2 XML with this approach? As I don't think we want to try and maintain both.

                    TripleA Developer with a Passion for AI: https://forums.triplea-game.org/topic/105/ai-development-discussion-and-feedback

                    C 1 Reply Last reply Reply Quote 0
                    • General_ZodG Offline
                      General_Zod Moderators @Mahks
                      last edited by

                      @mahks

                      XOB sounds ok to me, nice and short.

                      As the search goes, it should be a search of all information in the right pane for maximum usefulness. The left pane has two sorting modes so that piece is more manageable from search standpoint. If you could replicate the common find or find next methods where it only searches up or down from current cursor location. That would be ideal because one can just bypass a lot of the stuff they know they don't want as results. In this case the cursor position being whatever is highlighted in the left pane, but I think it would need to recognize if the left pane is currently in alphabetical or hierarchal modes during the search to function well.

                      @redrum

                      I vote for XOB if it comes down to a choice of one or the other as it applies to maintenance.

                      1 Reply Last reply Reply Quote 0
                      • MahksM Offline
                        Mahks @LaFayette
                        last edited by

                        @lafayette Having the JSON based in/on the source code comments would be ideal. If the developers update those comments when changes are made.

                        It may be a lot of work to get the data into those comments in the first place though.

                        The HTML page is pretty straight forward. Could be maintained by anyone with HTML. I could do it for now.

                        But I think the most important thing is getting the data in a portable format.

                        LaFayetteL 1 Reply Last reply Reply Quote 0
                        • redrumR Offline
                          redrum Admin
                          last edited by

                          @LaFayette I don't want to put the comments in the engine source code as then no one but developers would ever maintain it. Its better in a place that map makers can also contribute to.

                          TripleA Developer with a Passion for AI: https://forums.triplea-game.org/topic/105/ai-development-discussion-and-feedback

                          MahksM 1 Reply Last reply Reply Quote 0
                          • MahksM Offline
                            Mahks @redrum
                            last edited by Mahks

                            @redrum I just realized he may have meant the POS2 file.

                            But... once the data was up to date. there should be no need to add to it unless the engine is being modified.

                            I do not know how you go about change approvals, but who ever approves the code change should update the data at the same time (document the change)

                            redrumR 1 Reply Last reply Reply Quote 0
                            • redrumR Offline
                              redrum Admin @Mahks
                              last edited by

                              @mahks Possibly but that's not how I understood his comments.

                              In theory, that's true but having the flexibility for non-developers to add more hints/info/corrections I think would always be beneficial.

                              Today, when a developer makes a code change that influences the XML then we update the POS2 XML with an example and comment. If we moved to a different way to store that info like JSON in a repo that would be fine as well and in theory work the same way. I just don't want to have multiple places to update.

                              TripleA Developer with a Passion for AI: https://forums.triplea-game.org/topic/105/ai-development-discussion-and-feedback

                              C 1 Reply Last reply Reply Quote 0
                              • C Offline
                                Cernel Moderators @redrum
                                last edited by

                                @redrum I would surely not remove the PoS2 stuff. To reduce overhead, it may be acceptable to have the practice to update primarily this thing only, as mandatory for anyone making any changes, letting PoS2 up to personal initiative to keep it updated, just like any regular maps (most likely it won't happen, or with averagely year long delays, I imagine).
                                I'm surely not a sponsor of the principle of having to update multiple things, but stuff being inside the xml itself I think it is really the easiest way to use, for fairly experienced mapmakers, that already know about everything (and just need some memory refresh and copy-paste).

                                1 Reply Last reply Reply Quote 0
                                • C Offline
                                  Cernel Moderators @redrum
                                  last edited by

                                  @redrum I agree that people that make changes should be obliged to update no more than 1 place, and possibly an easy one to manage. Reducing overhead and confusion is of paramount importance.
                                  Just I would not delete the PoS2 bible, but making a clear mention that this is not the main reference, a link to the main reference, and telling people that everyone is free to pull updates to PoS2, if they find something not in line. Likely, people reading PoS2 will read that, so you won't get too many bug reports about PoS2 being wrong, but just possibly people pulling changes to it, in case.

                                  General_ZodG 1 Reply Last reply Reply Quote 0
                                  • General_ZodG Offline
                                    General_Zod Moderators @Cernel
                                    last edited by

                                    @cernel

                                    I don't think anyone was saying delete POS2 at all. Just preference of XOB for future updates.

                                    1 Reply Last reply Reply Quote 0
                                    • redrumR Offline
                                      redrum Admin
                                      last edited by

                                      Yeah, not saying we would delete POS2 XML just essentially stop updating it.

                                      @Hepps @Frostion Any thoughts on this? Do you feel a tool like this is better for map makers than POS2 XML?

                                      TripleA Developer with a Passion for AI: https://forums.triplea-game.org/topic/105/ai-development-discussion-and-feedback

                                      C 1 Reply Last reply Reply Quote 0
                                      • C Offline
                                        Cernel Moderators @redrum
                                        last edited by

                                        @redrum I think PoS2 is better if you know about everything already, and just need copy-pasting and refreshing your memory.

                                        Just be sure to, like, clarifying in PoS2 itself that it is not necessarily updated, to avoip people assuming it is (I mean a clear notice about that at the start of the xml).

                                        1 Reply Last reply Reply Quote 0
                                        • theredbaronT Offline
                                          theredbaron
                                          last edited by

                                          I thought I should offer some encouragement here. This looks phenomenal, and is close to what I had envisioned in the past could be added to the TripleA website. I would suggest that we offload POS2 XML to this new format, while keeping a bare-bones POS2 XML file that would need very little updating.

                                          POS2 is still needed to provide an example implementation for many of these options, as well as sample code, but I think this solution will fill a different role, maybe replacing POS2's reference function. If we do it right, we might even be able to deep link to this reference from within the code comments in POS2 XML. However, as Cernel is, I'm wary of change, as I've gotten used to working with POS2 XML. So we'll have to be sure to get this right.

                                          1 Reply Last reply Reply Quote 1
                                          • LaFayetteL Offline
                                            LaFayette Admin @Mahks
                                            last edited by

                                            @redrum

                                            @LaFayette I don't want to put the comments in the engine source code as then no one but developers would ever maintain it. Its better in a place that map makers can also contribute to.

                                            I don't think that is the right concern, but I would want it to be so that developers would keep the source data up to date when adding new attachments, but open for anyone to modify and improve the documentation at the same time.

                                            We essentially have this model with triplea_maps.yml. While not perfect, it has worked out that more than just developers can update the file.

                                            I checked out the source code further, it's not in good shape to accept more information as either additional javadocs or java annotations, so keeping this info in java source files I would agree is not a good one.

                                            @mahks said in XML option browser:

                                            The HTML page is pretty straight forward. Could be maintained by anyone with HTML. I could do it for now.
                                            But I think the most important thing is getting the data in a portable format.

                                            I generally agree, but I do think there are a some additional important questions to decide/answer:

                                            • how to integrate this as an official tool so we can keep it up to date now and for the long term?
                                            • will the web server hosting technology integrate with the rest of the TripleA infrastructure, will it add another server to be managed and maintained?
                                            • will there be overhead or delays in deploying any data updates to the web server?

                                            I like the tool as presented and I think it would make sense for it to be part of the official project. I think two really good options to do that would be either:

                                            1. Similar to the maps yaml file, host a yml file that is updated when we update source, on updates the yml data would be transformed to JSON and uploaded to website (we do this about exactly for the maps.yml data today).
                                            2. Host the HTML file independently from the source code but on the github website directly. Github.io uses a jekyll, it can render HTML natively.

                                            The first option has greater one-time setup cost, but data is pure from presentation layer and can be updated at same time as source, so lowest maintenance cost over the long term compared to the second option (which is also completely viable too).

                                            Any third option (is very welcome), but would have some challenges to solve for the concern of server maintenance overhead in addition to keeping the data well maintained over time.

                                            MahksM 1 Reply Last reply Reply Quote 2

                                            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
                                            • 1
                                            • 2
                                            • 3
                                            • 2 / 3
                                            • First post
                                              Last post
                                            Copyright © 2016-2018 TripleA-Devs | Powered by NodeBB Forums