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

    How to improve the AI without the Devs doing too much testing?

    Scheduled Pinned Locked Moved AI
    26 Posts 7 Posters 7.3k Views 7 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.
    • F Offline
      ff03k64 @Schulz
      last edited by

      @Schulz @RogerCooper linked to a small map at one point. you could search through his posts, or maybe he will show up and can link it again, or at least say exactly what the name was.

      Normal players are permitted to make changes. All changes go through an approval process in Github. But you would want to make the changes locally anyway, to make sure they work. If you want your changes to be incorporated into the main engine, you will want to read through the documentation and directions.
      https://github.com/triplea-game/triplea/tree/master/docs/development

      RogerCooperR 1 Reply Last reply Reply Quote 0
      • T Offline
        Trevan @Schulz
        last edited by

        @Schulz said in How to improve the AI without the Devs doing too much testing?:

        Should I build a small map from the stratch or is there any good available map for this purpose? Is it wrong to test AI behaviours in normal maps even if we can guess the reasons of bad AI decisions?

        It isn't wrong to test the AI behaviors in the normal maps, but when you are trying to fix things, it is better to have a small test case where you absolutely know what should happen. In the normal maps, there's a lot of possibilities and so you might think you know the AI reasoning but you might not. An example is the canal change I made because of the Warcraft map. Looking at the AI behavior, it appeared as if the AI wasn't taking canals into account. But going through the code, it turned out it was except for in a few places. Having a map that had the canals and one that didn't allowed me to figure out exactly where the problem is.

        I would rather try to solve the issues by myself also wondering if it is appropriate to report all bad AI decisions in github separately.

        The more details that you can find about the issue, the better. Writing an issue that says "AI ignores initial subs in Dominion 1941" is ok, but I, personally, wouldn't be able to do much with that. But if there was a small map that showed the AI ignoring subs in a specific manner, then I could do something with that. The former has too many possible reasons why it is ignoring it. The later has removed a lot of the possibilities and narrows the scope of the issue.

        Later I solved this sub issue by increasing sub attack to 3. But other major issues are still present unfortunately.

        Also wondering if normal players are not permitted to change the codes could I just customize AI and keep it in my engine while leaving the current one as it is?

        Just like @ff03k64 said, anyone can submit changes through Github.

        F 1 Reply Last reply Reply Quote 1
        • F Offline
          ff03k64 @Trevan
          last edited by

          @Trevan said in How to improve the AI without the Devs doing too much testing?:

          Just like @ff03k64 said, anyone can submit changes through Github.

          They even let me submit some changes!!

          1 Reply Last reply Reply Quote 1
          • RogerCooperR Online
            RogerCooper @ff03k64
            last edited by

            @ff03k64 Mini-map is a good one for testing issues involving land combat, Capture the Flag is another good small one. Both in the experimental area of the repository.

            World War II v6 is a small version of the regular games, which could be a good place to look at naval and complicated issues. It is in the high quality area.

            1 Reply Last reply Reply Quote 0
            • SchulzS Offline
              Schulz
              last edited by

              But even if the changes makes AI better in certain maps, couldn't they also effect negatively for other maps since maps don't have their own AI? For example my map has no A&A capital rule, I mean nations do not lose their remaining incomes and production abilities if they lost their capitals and because of that I would want AI less protective of their capitals but this could make AI worse in A&A games since losing capital is huge deal in this games.

              Should I open different topics for every flawed AI behaviours if I can guess the reason or its better to collect all of them in a post in the forum?

              I would rather want all maps have their customizable AI could it be possible in the near future?

              TheDogT 1 Reply Last reply Reply Quote 0
              • TheDogT Offline
                TheDog @Schulz
                last edited by

                @Schulz
                I can tell you that the current AI is heavily weighted in defending Capitals and if there is no Capital it is still capable of defending factories, but you are correct the AI will not defend factories with same logic/determination as a Capital.

                As you probably know Trevan will be working on a variant AI over the winter break, it sounds very ambitious, so I would not post anything as individual issues yet, but do keep a log, thats what Im doing, as the Devs dont currently have the time to look at old AI issues.

                Trevan also said
                I'll see about adding a way to allow the map to set the various weights.

                So lets hope he does. :winking_face:

                When we get the new AI it will generate its own AI weakness and that's the one to concentrate on.

                https://forums.triplea-game.org/tags/thedog
                https://forums.triplea-game.org/topic/3741/curated-best-top-maps-triplea-guides

                1 Reply Last reply Reply Quote 0
                • T Offline
                  Trevan
                  last edited by

                  @LaFayette , would you prefer having custom AI weights to be written in the map xml? Or as a separate file in the game directory? The weights would control how important a capital, factory, resource, etc should be considered when building out the diffused field. There will also be a diffuse rate that can be controlled.

                  F TheDogT 2 Replies Last reply Reply Quote 0
                  • F Offline
                    ff03k64 @Trevan
                    last edited by

                    @Trevan Would either make it more compatible with current maps?

                    1 Reply Last reply Reply Quote 0
                    • T Offline
                      Trevan
                      last edited by

                      I don't think either will affect current maps. There'll be default weights that maps will automatically have. Maps will have the opportunity to override the defaults. I think putting it in the map xml might be better because then a single zip file might have multiple xmls that need different custom weights.

                      F 1 Reply Last reply Reply Quote 0
                      • F Offline
                        ff03k64 @Trevan
                        last edited by

                        @Trevan The other option would be to do it like objectives are done.

                        T 1 Reply Last reply Reply Quote 0
                        • T Offline
                          Trevan @ff03k64
                          last edited by

                          @ff03k64 Objectives aren't quite the same thing. The AI should actually utilize objectives in giving values of territories.

                          The weights are more on how should parts of the game be valued. Say the game has IPCs and Oil. All territories produce IPCs but only a few produce oil. If the AI values IPCs and Oil identically, then a territory with 3 IPCs will always be more important than a territory with 2 Oil. But, most likely, 2 Oil is better than 3 IPCs. The AI might be able to learn that but to give it a hint, the map maker could say that each Oil is worth 3x. Now, the territory with 2 Oil is actually worth 6 instead of 2 and the AI will go for that.

                          F 1 Reply Last reply Reply Quote 0
                          • Captain CrunchC Offline
                            Captain Crunch Banned
                            last edited by Captain Crunch

                            redrum has done an excellent job with the AI! It has improved at least 10 fold since I first tested it so gg

                            I will battle and test the current AI again when I'm in the mood but I will say again this game and its' engine and the Ai will always be elite and maybe the greatest RTS of all time! 🙂

                            By the way, I'm busy with physics theories and doing a math paper that is a million dollar challenge through an institute and also I'm a researcher for a famous night time radio show host and I've been followed by famous authors for my history theories and discoveries that you know nothing of yet but will tell yous eventually 😜

                            1 Reply Last reply Reply Quote 0
                            • F Offline
                              ff03k64 @Trevan
                              last edited by

                              @Trevan i just meant you could do an AI properties file like how there is an objectives property file for multiple xmls.

                              T 1 Reply Last reply Reply Quote 0
                              • T Offline
                                Trevan @ff03k64
                                last edited by

                                @ff03k64 oh, I didn't know about that. How does that file work?

                                F 1 Reply Last reply Reply Quote 0
                                • TheDogT Offline
                                  TheDog @Trevan
                                  last edited by TheDog

                                  @Trevan said in How to improve the AI without the Devs doing too much testing?:

                                  @LaFayette , would you prefer having custom AI weights to be written in the map xml? Or as a separate file in the game directory? The weights would control how important a capital, factory, resource, etc should be considered when building out the diffused field. There will also be a diffuse rate that can be controlled.

                                  @Trevan having just done a map with 5 xml variants for you, I could see map makers wanting to customise the AI per xml file, so they can customise each scenario/xml.

                                  If there was one ai.properties file it would effect all xml variants with the same parameters/logic.

                                  https://forums.triplea-game.org/tags/thedog
                                  https://forums.triplea-game.org/topic/3741/curated-best-top-maps-triplea-guides

                                  1 Reply Last reply Reply Quote 0
                                  • F Offline
                                    ff03k64 @Trevan
                                    last edited by

                                    @Trevan said in How to improve the AI without the Devs doing too much testing?:

                                    @ff03k64 oh, I didn't know about that. How does that file work?

                                    I don't know the details specifically. But it has the name of the xml, or the name of the map as part of the objective. I would guess that you could also have an AI properties file that could be called something like mapname.AIproperties as well.

                                    I believe world_war_ii_global has a single objectives file for multiple xml games.

                                    1 Reply Last reply Reply Quote 1
                                    • RogerCooperR Online
                                      RogerCooper
                                      last edited by

                                      I think it would be best to have a separate file for AI weights. It would make it easier to try different weights.

                                      1 Reply Last reply Reply Quote 0
                                      • TheDogT Offline
                                        TheDog
                                        last edited by

                                        Im now agreeing with ff03k64 and RogerCooper a separate file is best, something like xml-name.AIproperties as this covers all bases, its easier to change and its per xml file.

                                        https://forums.triplea-game.org/tags/thedog
                                        https://forums.triplea-game.org/topic/3741/curated-best-top-maps-triplea-guides

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

                                          We should be cautious about baking an engine dependency into a map. To continue supporting the map, historically any map properties we have to continue support ad-infinitium. Perhaps such a property file we could just ignore one day, but some caution should be used. I'd also wonder if the weighting values couldn't be computed by the AI, I also wonder if the formula that we are tweaking is truly the right formula and has the right considerations and coefficients to begin with.

                                          FWIW, I think experimenting with a custom compiled game with different formula weights would be a good first data point to know how much value there is in tweaking the values. Once we've gained that experience, we'll be in a better position to judge whether per-map differences are impactful.

                                          1 Reply Last reply Reply Quote 0
                                          • SchulzS Offline
                                            Schulz
                                            last edited by

                                            I would really want allowing map makers to create separate AI files for their games as well.

                                            1 Reply Last reply Reply Quote 1

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