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

    AI Development Discussion and Feedback

    Scheduled Pinned Locked Moved AI
    316 Posts 32 Posters 431.5k Views 30 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.
    • Captain CrunchC Offline
      Captain Crunch Banned @Cernel
      last edited by

      @cernel Oh thanks for that tip about removing P.U.'s but, anyways, completely skipping Russia's 1st move was something me and my friends try occasionally for fun with the actual board game and my friends have actually beat me when I was the Axis and they were the Allies and they skipped Russia's 1st turn and let me go first with Germany and they still beat me and they loved that win!

      Against the Ai, I can't remember if I've ever beaten the Axis AI still when I forfeited my 1st turn with Russia (I would say it if I did in my posts earlier in this thread!) but it's my usual routine for testing the updated AI - the 1st game I do the Russia forfeit move, and then if I lose I don't forfeit my 1st move with Russia in the next match. Once I've beaten the Axis AI, I then do a regular match against the Allies AI which is very hard as I've said ... and getting harder!

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

        For beating the Ai, oh I wanted to mention that using Low Luck dice is a massive help and if I didn't use Low Luck dice I bet I would have played way more games trying to beat the Ai so basically Low Luck dice is a bigger help against a machine opponent than a real person I am positive eh?

        1 Reply Last reply Reply Quote 0
        • FrostionF Offline
          Frostion Admin
          last edited by Frostion

          <attachment name="triggerAttachment_Produce_submarine" attachTo="Player1 " javaClass="games.strategy.triplea.attachments.TriggerAttachment" type="player">
          <option name="conditions" value="conditionAttachment_Player1_produce_submarine"/>
          <option name="purchase" value="Submarine" count="1"/>
          </attachment>

          A human player receives the free submarine from the above trigger and can place it during the placement phase alongside other normally purchased units, but the AI is seemingly blind and does not know about, see and place the trigger given submarine?
          I actually thought that the problem of AI not placing free units was restricted to infrastructures and upgrades, I donโ€™t know it also didnโ€™t place normal units. Or is it just given isSea units that are not placed by the AI?

          BTW: I played on 1.9.0.0.10498 ๐Ÿ™‚

          Map maker of: Star Wars: Galactic War + Star Wars: Tatooine War + Caribbean Trade War + Dragon War + Age of Tribes + Star Trek: Dilithium War + Iron War + Iron War: Europe + Warcraft: War Heroes

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

            @frostion My guess is its just "isSub" units as the AI doesn't fully handle them though I'd need to take a look. If you're able to run a quick test giving them say a destroyer instead of a sub then that'll help narrow it down.

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

            1 Reply Last reply Reply Quote 0
            • FrostionF Offline
              Frostion Admin
              last edited by

              @redrum
              No, I have now tried with Battleships, Cruisers and Destroyers. The AI gets them in the bank (this can be seen in the history at the left of screen and in the history fan to the right) but the ships are never placed.

              I donโ€™t think AI can place sea units that have been given via trigger.

              I have tried the same conditions and triggers with land units, and they are placed.

              Map maker of: Star Wars: Galactic War + Star Wars: Tatooine War + Caribbean Trade War + Dragon War + Age of Tribes + Star Trek: Dilithium War + Iron War + Iron War: Europe + Warcraft: War Heroes

              redrumR 2 Replies Last reply Reply Quote 1
              • redrumR Offline
                redrum Admin @Frostion
                last edited by redrum

                @frostion Alright, thanks for the additional info. Guess placing triggered sea units must not be implemented. I'll try to take a look at it later today.

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

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

                  @frostion Do you have an example map that I can test this with so I don't have to make a bunch of fake conditions/triggers?

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

                  FrostionF 1 Reply Last reply Reply Quote 0
                  • FrostionF Offline
                    Frostion Admin @redrum
                    last edited by

                    @redrum You can test the AIโ€™s ability to place given sea units with the latest v0.2.5 release of Iron War downloadable from GitHub. Germany gets a submarine:

                        <attachment name="triggerAttachment_German_Submarine-Pens_produce_submarines" attachTo="Germany" javaClass="games.strategy.triplea.attachments.TriggerAttachment" type="player">
                            <option name="conditions" value="conditionAttachment_German_Submarine-Pens_produce_submarines"/>
                            <option name="purchase" value="Submarine" count="1"/>
                        </attachment>
                    

                    So the Submarine is by default delivered in the beginning of the purchase phase, and this can also be seen in history, but it is never placed. Not even after a few rounds.

                    I hope you are able to figure out what is wrong? ๐Ÿ˜ƒ

                    Map maker of: Star Wars: Galactic War + Star Wars: Tatooine War + Caribbean Trade War + Dragon War + Age of Tribes + Star Trek: Dilithium War + Iron War + Iron War: Europe + Warcraft: War Heroes

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

                      @frostion Oh I know what's wrong already as I looked at the code yesterday. I never implemented having the AI place triggered sea units (only land/air). I think because I couldn't find any maps that actually did that so decided not to tackle it until someone did which looks to be now ๐Ÿ™‚

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

                      1 Reply Last reply Reply Quote 3
                      • FrostionF Offline
                        Frostion Admin
                        last edited by Frostion

                        Ahhh, OK. Well, thanks for fixing the code ๐Ÿ˜ƒ๐Ÿ‘

                        Map maker of: Star Wars: Galactic War + Star Wars: Tatooine War + Caribbean Trade War + Dragon War + Age of Tribes + Star Trek: Dilithium War + Iron War + Iron War: Europe + Warcraft: War Heroes

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

                          @frostion Here is the PR: https://github.com/triplea-game/triplea/pull/3542

                          Here is a screenshot showing the Germans placing the sub:
                          0_1531434362143_d6dc56a9-e285-440a-89b9-e04103afc237-image.png

                          The one limitation is that the AI only considers the extra triggered units after its purchase. So Germany's turn 1 if it buys 10 units then it doesn't have anywhere that it can place the sub (which happens sometimes). Ideally, the AI would consider any triggered units before making its purchases but that's a more significant change and this should handle most cases.

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

                          HeppsH 1 Reply Last reply Reply Quote 0
                          • HeppsH Offline
                            Hepps Moderators @redrum
                            last edited by

                            @redrum Couldn't you hack this by designing a special unit that doesn't require a placement? (Just an idea)

                            "A joyous heart sours with the burden of expectation"
                            Hepster

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

                              @hepps Yeah that would work. There are probably other ways to do it as well like triggering extra factories, production per factory, etc before the place phase.

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

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

                                Can be tested in this pre-release: https://github.com/triplea-game/triplea/releases/tag/1.9.0.0.10558

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

                                1 Reply Last reply Reply Quote 2
                                • FrostionF Offline
                                  Frostion Admin
                                  last edited by

                                  Hurra! Nice update ๐Ÿ˜„

                                  Map maker of: Star Wars: Galactic War + Star Wars: Tatooine War + Caribbean Trade War + Dragon War + Age of Tribes + Star Trek: Dilithium War + Iron War + Iron War: Europe + Warcraft: War Heroes

                                  1 Reply Last reply Reply Quote 0
                                  • alkexrA Offline
                                    alkexr
                                    last edited by

                                    @redrum Just messing around with xml, experimenting... it seems that Hard AI doesn't recognize a production facility unless it is an infrastructure. I changed a factory to have canProduceUnits, canProduceXUnits=-1, immobile land noninfrastructure construction. Humans and Easy AI can produce units, but Hard AI only sees an empty list of territories for placement (according to the log).

                                    "For the world is changing: I feel it in the water, I feel it in the earth, and I smell it in the air."

                                    redrumR 1 Reply Last reply Reply Quote 2
                                    • redrumR Offline
                                      redrum Admin @alkexr
                                      last edited by

                                      @alkexr Hmm. I know the AI won't purchase non-infra factories but thought it could at least see them as potential placement spots. I thought I tested that on 270bc which uses legions but could be wrong. If you have an example map to test glad to take a look.

                                      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
                                      • alkexrA Offline
                                        alkexr
                                        last edited by

                                        @redrum Calling it a map would be a bit of an exaggeration... this is a copied version of a map of mine for all sorts of xml experiments. I think I restored all previous experiments before trying this. https://drive.google.com/open?id=1T8QwATSzqb1SQgaSbDeqrZWwF5n2afTQ

                                        "For the world is changing: I feel it in the water, I feel it in the earth, and I smell it in the air."

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

                                          @redrum So now the AI also places movement 0 units? Because legionaire in 270BC can place only forts.

                                          EDIT: Actually, the legio of 270BC would be a peculiar example, in that such unit should really receive no bonus (or maybe like a 0.05) to its value for being able to place units (limited to fort). It is rather the fort that should be valued a little bit more for being placeable by the legio, thus not only in cities (main example is placing some forts in Messana without a city in it). It would be really wrong if the AI would build significantly more legios due to the fact that they have some placement ability, in this case (really, it boosts the fort, not really the legio).

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

                                            @cernel Yeah, I had it mixed up. I had tested 270bc to make sure the AI didn't place legions as factories since they can only place forts. When purchasing/placing factories, the AI doesn't have a sense of 'what units a factory can build' yet since it was mostly created around A&A maps. Whether a factory is infra shouldn't really matter but that limitation was put in since a few maps have regular units that can build a very limited set of units like legions and I didn't want the AI to see them as factories.

                                            That being said, if it has non-isInfra factory units then it should consider placing units on them so I'll have to look at that.

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

                                            1 Reply Last reply Reply Quote 3

                                            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
                                            • 9
                                            • 10
                                            • 11
                                            • 12
                                            • 13
                                            • 14
                                            • 15
                                            • 16
                                            • 11 / 16
                                            • First post
                                              Last post
                                            Copyright ยฉ 2016-2018 TripleA-Devs | Powered by NodeBB Forums