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

    Random number of units placed randomly at random turns?

    Scheduled Pinned Locked Moved Maps & Mods
    38 Posts 9 Posters 14.3k 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.
    • CrazyGC Offline
      CrazyG Moderators
      last edited by

      You can do something like create a 50% chance for a unit to appear based on a condition. This could work for weather too but it takes a lot of triggers. If you had 3 possible weather effects occuring in every territory, you need 2 conditions and 3 triggers per territory.

      You can create a 50% chance for a brigand to appear in a territory. What you currently cannot do is have exactly 3 brigands total appear, and those three go to totally random territories. (at least not for a decent sized map, too many conditions to check)

      You can jerry-rig a bit of randomness with triggers, but it becomes really hard to do on a large scale due to complexity.

      @prastle said in Random number of units placed randomly at random turns?:

      Also if someone still has a copy of Global Conquest? (I think it was called.) It had random placement setup in a Risk style. @Cernel will recall and possibly still has a copy.

      This only works at the start of the game, its difficult to repeat it.

      prastleP alkexrA 2 Replies Last reply Reply Quote 0
      • prastleP Offline
        prastle Moderators Admin @CrazyG
        last edited by

        @crazyg kk was just recalling. Do you still have a copy?

        If we open a quarrel between past and present, we shall find that we have lost the future! Sir Winston Churchill

        CrazyGC 1 Reply Last reply Reply Quote 0
        • CrazyGC Offline
          CrazyG Moderators @prastle
          last edited by

          I had it at one point. Is it missing?

          prastleP 1 Reply Last reply Reply Quote 0
          • prastleP Offline
            prastle Moderators Admin @CrazyG
            last edited by

            @crazyg I don't see it in the repo anymore oh well.

            If we open a quarrel between past and present, we shall find that we have lost the future! Sir Winston Churchill

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

              @prastle said in Random number of units placed randomly at random turns?:

              @redrum gigglez Let's not bring up the past 🙂 Still causes shudders in old lobby players 😉

              @prastle I have copied this statement to 3 external hard drives... in the event I need to bring it out as proof to stop a scotch fueled rant. 😃

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

              prastleP 1 Reply Last reply Reply Quote 0
              • prastleP Offline
                prastle Moderators Admin @Hepps
                last edited by

                @hepps Ah I was reffering to the 2016 crash

                If we open a quarrel between past and present, we shall find that we have lost the future! Sir Winston Churchill

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

                  @prastle Yes I know... I am keeping this quote as proof that you once said lets not bring up the past. :face_savouring_delicious_food:

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

                  prastleP 1 Reply Last reply Reply Quote 0
                  • prastleP Offline
                    prastle Moderators Admin @Hepps
                    last edited by

                    @hepps did you copy all old maps since mine ext died?
                    🙂

                    If we open a quarrel between past and present, we shall find that we have lost the future! Sir Winston Churchill

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

                      @prastle Not sure what I have... I still have all the engine versions going back to 1.8.0.9

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

                      prastleP 1 Reply Last reply Reply Quote 0
                      • prastleP Offline
                        prastle Moderators Admin @Hepps
                        last edited by

                        @hepps engine versions don't matter its what maps did you save?
                        🙂

                        If we open a quarrel between past and present, we shall find that we have lost the future! Sir Winston Churchill

                        1 Reply Last reply Reply Quote 0
                        • B Offline
                          beelee @prastle
                          last edited by

                          @prastle said in Random number of units placed randomly at random turns?:

                          @crazyg I don't see it in the repo anymore oh well.

                          maybe Roger has it ?

                          prastleP 1 Reply Last reply Reply Quote 0
                          • prastleP Offline
                            prastle Moderators Admin @beelee
                            last edited by

                            @beelee nope just checked
                            I guess we hope @LaFayette ( who made original) or @Cernel who did some work on it has a copy

                            If we open a quarrel between past and present, we shall find that we have lost the future! Sir Winston Churchill

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

                              @crazyg said in Random number of units placed randomly at random turns?:

                              What you currently cannot do is have exactly 3 brigands total appear, and those three go to totally random territories.

                              You can. You place units with 50% chance on a fake territory, named x_1, x_2, ... etc. Interpreting this as a binary number, now you have a totally random number between 0 and 2^n - 1. Then each territory gets a number, and a condition checks if this number is equal to our random number, and if so, places a brigand. Repeat 3x. Number of triggers required is O(Territory * Number of units to spawn).

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

                              CrazyGC 1 Reply Last reply Reply Quote 4
                              • CrazyGC Offline
                                CrazyG Moderators @alkexr
                                last edited by CrazyG

                                @alkexr
                                this made me laugh it was so creative. Brilliant solution, it also points out that it would probably be very easy to just create a function that selects a random territory in the engine than an XML calls

                                alkexrA 1 Reply Last reply Reply Quote 2
                                • alkexrA Offline
                                  alkexr @CrazyG
                                  last edited by

                                  @crazyg The inspiration came from the random events system of Greyhawk Wars. Panguitch used a similar binary system.

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

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

                                    @CrazyG you can give this branch a try, YMMV: https://github.com/DanVanAtta/triplea/tree/conquest

                                    I don't see the actual map added there, just additional code to help support. IF you can get ahold the old map xml it should work with the engine run at that version.

                                    1 Reply Last reply Reply Quote 0
                                    • RogerCooperR Offline
                                      RogerCooper @redrum
                                      last edited by

                                      @redrum said in Random number of units placed randomly at random turns?:

                                      @hepps Yeah or use @RogerCooper's conversion thread. Just not sure anyone would volunteer to update them but if they would or at least consider it then it could be helpful.

                                      I converted everything I could get a hold of. If anyone has a mod not on my Scenario List send it to me and I will add it,

                                      I don't have Global Conquest and I don't remember anything like it.

                                      1 Reply Last reply Reply Quote 0
                                      • CrazyGC Offline
                                        CrazyG Moderators
                                        last edited by

                                        Random though about this. Currently you can make a trigger fire another trigger.

                                        <option name="activateTrigger" value="triggerAttachmentRussians5_FarEastReserves:1:false:false:false:false"/>
                                        

                                        (Format: "triggerName:numberOfTimes:useUses:testUses:testConditions:testChance")

                                        How doable would the following be?

                                        <option name="activateRandomTrigger" value="triggerAttachment1:triggerAttachment2:triggerAttachment3" count="2"/>
                                        

                                        The above would fire exactly 2 of those 3 triggers at random. IDK how important the additional options are for activateTrigger (I don't understand what the test things do, and if I wanted to fire the trigger more than once I would just put more lines)

                                        Also I investigated and I do not have the global conquest map on this computer. Sorry

                                        1 Reply Last reply Reply Quote 0

                                        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