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

    Unit Option Can Submerge/Hide for Land Units (Partisan/Guerrilla/Spy/Diplomat/Munition)

    Scheduled Pinned Locked Moved Feature Requests & Ideas
    69 Posts 6 Posters 36.3k Views 6 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.
    • C Offline
      Cernel Moderators @Hepps
      last edited by

      @Hepps said in Unit Option Can Submerge/Hide for Land Units (Partisan/Guerrilla/Spy/Diplomat/Munition):

      "Is Stealth" (ie. a submerge or hide ability) available for land units.


      Phases

      1. Allowing the existing system to work for land/air units
      2. Breaking isSub and isDestroyer into smaller attributes so more fine grained control can be achieved (canHide, firstStrike, canTarget, canBeTargetedBy, etc)
      3. Rework some of the global XML sub properties so that they make more sense and for some be specified at the unit level: https://forums.triplea-game.org/topic/355/sub-xml-properties

      Separate isSub Functions

      1. canEvade/canHide/canDisengage/canEscape - submerge
      2. isFirstStrike/surpriseStrike/preemptiveStrike - roll and take casualties before regular units
      3. canNotTarget (or canTarget) - can't target specific units like air units
      4. canNotBeTargetedBy (or canBeTargetedBy) - can't be targeted by specific units like air units
      5. canMoveThroughEnemies - unblockable, Treat Hostile Territories as Friendly
      6. canBeMovedThroughByEnemies/doesntBlockEnemies - enemies can move through territories if only these types of units are present (would also need blitz for enemy land territories)

      Sub Properties
      The sub properties outlined here will then be tied to the following unit attributes: https://forums.triplea-game.org/topic/355/sub-xml-properties

      canEvade
      6. Sub Retreat Before Battle
      7. Submarines Defending May Submerge Or Retreat
      8. Submersible Subs (determines if withdraws to same territory or neighboring territories)

      isFirstStrike
      _1. Super Sub Defence Bonus - If "true" adds 0-1 to the submarines defensive value if and when SuperSubs tech is activated.
      5. Defending Subs Sneak Attack

      canNotTarget
      NONE

      canNotBeTargetedBy
      2. Air Attack Sub Restricted

      canMoveThroughEnemies
      8. Submersible Subs
      10. Subs Can End NonCombat Move With Enemies

      canBeMovedThroughByEnemies
      3. Submarines Prevent Unescorted Amphibious Assaults
      4. Ignore Sub In Movement
      9. Sub Control Sea Zone Restricted

      Properties with 'isSub' that set new unit options
      2. Air Attack Sub Restricted - if unit has isSub and this is true then set canNotBeTargetedBy to all air unit types
      4. Ignore Sub In Movement - if unit has isSub and this is true then set canBeMovedThroughEnemies to true
      8. Submersible Subs - if unit has isSub and this is true then set canMoveThroughEnemies to true


      PRs

      • Land and air units can have isSub and isDestroyer: https://github.com/triplea-game/triplea/pull/4829
      • Divide isSub into attributes: https://github.com/triplea-game/triplea/pull/4831

      I think this is one of the best advancement in the program, and I cannot say how many years I wish the "isSub" option was atomized, but I cannot find this documented in pos2. I believe this should be documented, obviously, and I can do it myself, if a developer will be available for reviewing it.

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

        @Cernel Good catch. At a minimum, should probably document the new unit options. I'll try to take a look at this.

        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 1
        • C Offline
          Cernel Moderators @redrum
          last edited by

          @redrum I suggest doing it by copying the AA things, and changing a minimum.

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

            @Cernel Here is the PR: https://github.com/triplea-maps/the_pact_of_steel/pull/36

            Feel free to add feedback. I'd like to try to keep the explanations pretty concise while providing the necessary info.

            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 1
            • C Offline
              Cernel Moderators @redrum
              last edited by

              @redrum I suggest providing full info, and I'll see to review that, but, if you refer to v3 anywhere, then there is also the issue that it is not known what the general v3 property is actually doing, as I understand that is somehow marginal, differently from the v2 one, that is actually intended to fully convert the game to v2 rules, from the v1 default.

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

                I have this unit:

                                <attachment name="unitAttachment" attachTo="horsearcher" javaClass="games.strategy.triplea.attachments.UnitAttachment" type="unitType">
                                         <option name="movement" value="3"/>
                                         <option name="transportCost" value="3"/>
                                         <option name="canBlitz" value="true"/>
                                         <option name="canMoveThroughEnemies" value="true"/>
                                         <option name="attack" value="3"/>
                                         <option name="defense" value="2"/>
                                         <option name="isAAforCombatOnly" value="true"/>
                                         <option name="AttackAA" value="1"/>
                                         <option name="AttackAAmaxDieSides" value="1"/>
                                         <option name="offensiveAttackAA" value="1"/>
                                         <option name="offensiveAttackAAmaxDieSides" value="1"/>
                                         <option name="maxAAattacks" value="-1"/>
                                         <option name="maxRoundsAA" value="-1"/>
                                         <option name="damageableAA" value="false"/>
                                         <option name="typeAA" value="besiege"/>
                                         <option name="targetsAA" value="fort:wall"/>
                                         <option name="willNotFireIfPresent" value="archer:axeman:ballista:cataphract:chariot:horsearcher:horseman:legionary:levis:onager:phalangite:psilos:spearman:swordman:warelephant"/>
                                         <option name="requiresUnits" value="city"/>
                                </attachment>
                

                And these properties:

                                <property name="WW2V2" value="true" editable="false">
                                        <boolean/>
                                </property>
                                
                                <property name="Submersible Subs" value="true" editable="false">
                                        <boolean/>
                                </property>
                                
                                <property name="Defending Subs Sneak Attack" value="true" editable="false">
                                        <boolean/>
                                </property>
                

                But it is not working: the "horsarcher" units are not moving through any enemies. Am I missing something?

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

                  @Hepps said in Unit Option Can Submerge/Hide for Land Units (Partisan/Guerrilla/Spy/Diplomat/Munition):

                  canMoveThroughEnemies
                  8. Submersible Subs
                  10. Subs Can End NonCombat Move With Enemies

                  There is a problem this property. It doesn't work if the unit is a sea transport with regular cargo (apparently, if the cargo cannot end combat move with enemies, the transporting ship cannot too).

                  I'm generally testing this new feature, hoping that whatever issues I might find may be fixed.

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

                    @Cernel A similar problem also exists in case of setting "canBeMovedThroughByEnemies" true for a sea transport. If the sea transport has normal cargo loaded, other ships cannot enter its sea zone during Non Combat Movement.

                    I suggest generally to review all such matters, assuring that the presence of any cargo will just never influence of any such options. I assume such issues would be the same for land transports.

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

                      @Hepps said in Unit Option Can Submerge/Hide for Land Units (Partisan/Guerrilla/Spy/Diplomat/Munition):

                      1. canBeMovedThroughByEnemies - enemies can move through territories if only these types of units are present (would also need blitz for enemy land territories)

                      I highly suggest changing the name of this option from "canBeMovedThroughByEnemies" to something like "canBeIgnored" (which would also clearly hint a relation with "Ignore Sub In Movement"), as its function is not only to allow the opted ships to be moved through (that is, make them unable to block enemy units), but also giving the enemy the option of not creating a battle against them (something that can also be generally set, for all ships, by the property "Sea Battles May Be Ignored" (I've tested that there is no redundancy of asking it twice)) and allowing enemy ships ending non combat move with them. This is also opportune on the account that this property is not really the opposite of "canMoveThroughEnemies", since that one, instead, grants nothing about avoiding battle and doesn't allow ending non combat move with enemies as default (but as an additional ability granted by a specific property), so I think the current name (I'm suggesting changing) is going to be very confusing, as inexperienced mapmakers will likely expect something called "canBeMovedThroughByEnemies" to be just the opposite of "canMoveThroughEnemies" (for example, expecting the same results if giving one or the other option to all sea units in the game, which is not the case).

                      Also the pos2 description, namely:
                      canBeMovedThroughByEnemies values: whether enemies can move through territories if only these types of units are present (would also need blitz for enemy land territories)

                      Should be updated, as to mention the other two behaviours I detailed (I can do it, if you prefer).

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

                        @Cernel Actually, there is also a fourth behaviour set by this option, namely the fact that such sea units are unable to impede enemy ships from loading land units (this one also generally achieved by the property "Units Can Load In Hostile Sea Zone").

                        So, yeah, the option "canBeMovedThroughByEnemies" is doing 4 different things, namely:

                        • disabling the ability to block moving through;
                        • disabling the ability to impede loading;
                        • disabling the ability to impede entering during Non Combat Movement;
                        • allowing the enemy not to create a battle, and, in this case, completely ignoring the ships (also for offloading).

                        So, yeah, I strongly suggest renaming this option, if not splitting it into its 4 components.

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

                          In a game I'm playing a lot and hope to upload to the repository after the next release, I have this unit:

                                          <attachment name="unitAttachment" attachTo="catapult" javaClass="games.strategy.triplea.attachments.UnitAttachment" type="unitType">
                                                   <option name="movement" value="1"/>
                                                   <option name="transportCost" value="2"/>
                                                   <option name="attack" value="4"/>
                                                   <option name="defense" value="4"/>
                                                   <option name="attackRolls" value="0"/>
                                                   <option name="defenseRolls" value="0"/>
                                                   <option name="isAAforCombatOnly" value="true"/>
                                                   <option name="AttackAA" value="4"/>
                                                   <option name="AttackAAmaxDieSides" value="6"/>
                                                   <option name="offensiveAttackAA" value="4"/>
                                                   <option name="offensiveAttackAAmaxDieSides" value="6"/>
                                                   <option name="maxAAattacks" value="1"/>
                                                   <option name="mayOverStackAA" value="true"/>
                                                   <option name="maxRoundsAA" value="-1"/>
                                                   <option name="damageableAA" value="false"/>
                                                   <option name="typeAA" value="Artillery"/>
                                                   <option name="targetsAA" value="archer:ballista:cataphract:catapult:chariot:fort:horsearcher:horseman:irregular:legionary:phalangite:skirmisher:spearman:swordman:warelephant"/>
                                                   <option name="requiresUnits" value="metropolis"/>
                                          </attachment>
                          

                          I would rather like doing it with first strike, especially since AA attacks are not accounted by the autoselect, so that this unit is practically offered as first casualty after any offenceless, while it usually should be the very last unit in the game that you want to take out, which also hampers the usability of the battlecalculator, as you need to manually imput casualties priorities all time, that I assume most people won't even realize they can do.

                          Once the option "canNotTarget" would be fully supported, I could, then, have the same behaviour with this code:

                                          <attachment name="unitAttachment" attachTo="catapult" javaClass="games.strategy.triplea.attachments.UnitAttachment" type="unitType">
                                                   <option name="movement" value="1"/>
                                                   <option name="transportCost" value="2"/>
                                                   <option name="attack" value="4"/>
                                                   <option name="defense" value="4"/>
                                                   <option name="isFirstStrike" value="true"/>
                                                   <option name="canNotTarget" value="wall"/>
                                                   <option name="requiresUnits" value="metropolis"/>
                                          </attachment>
                          

                          However, here I'm still missing two things:

                          I would need an option to say these units insta-kills enemy units regardless of hitpoints (as done by the "damageableAA" option, though, of course, the default will have to be the opposite), as I don't want forts and warelephants to use their free hitpoint to take hits from these units.
                          I would need the bug about being able to retreat in the face of defenceless units being fixed, as with AA the program disallows me to retreat in the face of only wall units left, while it allows me to do so with first strike, because the check for autodestroying defenceless happen after AA attacks but before first srike attacks (very strange behaviour here).

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

                            @Hepps said in Unit Option Can Submerge/Hide for Land Units (Partisan/Guerrilla/Spy/Diplomat/Munition):

                            1. canMoveThroughEnemies - unblockable, Treat Hostile Territories as Friendly

                            @redrum So, as I said, this doesn't work for me, for land units. It works if the land unit is moving through a non enemy territory with enemy units in it (these units not blocking). However the unit is stopped in any case both the land territory and any units in it are enemies, while, on the other hand, the unit can still normally blitz an enemy land territory with no enemy units in it. Meaning I have these 3 cases:

                            1. The land territory is enemy and has enemy non infrastructure units in it: the unit is blocked.
                            2. The land territory is enemy but has no enemy units in it: the unit is not blocked, and captures the territory by blitzing.
                            3. The land territory is friendly but has enemy units in it: the unit is not blocked (and the territory not captured, of course).

                            So, I have two question:

                            1. Is this a still unimplemented item, or is there anything I'm missing, to make it work.
                            2. What does "Treat Hostile Territories as Friendly" exactly means? In particular, does it mean that these units cannot blitz or otherwise conquer enemy territories (I assume they still fully can, while ignoring the units inside, but want to make sure)?

                            On regard of point number 2, I've a request for a different behaviour to make, but first I need to be sure about what is the current actual or intended behaviour, or both, if they differ.

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

                              @Cernel We could eventually consider allowing some form of damageableAA for firstStrike and even standard rolls though I'm not sure how much effort that would be to add in. Though I also eventually want to enhance the battle calc to better handle AA values as well as a few other things.

                              Retreating has a lot of edge cases that aren't well supported and probably needs some updates. If there are some maps that have cases that don't seem to work well then I'll probably look to update it.

                              So generally I tested that the new properties didn't break existing functionality more than I tested whether they fully work for new cases like air/land subs though I tested some of the basic things. For canMoveThroughEnemies:

                              1. I wasn't aware of any issues but it hasn't been tested much for non-sea units.
                              2. Its meant to essentially mean that enemy units don't block movement. So if you have a land unit that has blitz and this property then it should be able to move through an enemy owned territory with enemy units. I generally want "blitz" to mean a unit can move through empty enemy territories, "canMoveThroughEnemies" to mean is can move through enemy units, and the combination of the 2 mean it can move through both enemy territories and enemy units.
                              1. The land territory is enemy and has enemy non infrastructure units in it: the unit is blocked.
                              2. The land territory is enemy but has no enemy units in it: the unit is not blocked, and captures the territory by blitzing.
                              3. The land territory is friendly but has enemy units in it: the unit is not blocked (and the territory not captured, of course).

                              2&3 are correct but 1 isn't so probably needs some fixes.

                              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
                              • C Offline
                                Cernel Moderators @Hepps
                                last edited by

                                @Hepps Is this new feature allowing for blocking movement of air units? For example, can I specify that a fighter or a bomber have to end Combat Movement when entering a territory with a fighter in it?

                                I guess not, but wondering if the matter has been refactored as to generally set whatever blocks whatever (with air units default being blocked by none). If not, I tend to think this would be the way to go.

                                Actually @redrum.

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

                                  @Cernel So the goal is that isDestroyer units should cancel out canMoveThroughEnemies for sea/land/air units. I don't think most of the movement functionality has been extended to work fully with air units yet but it could probably fairly easily be added in now.

                                  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 1
                                  • C Offline
                                    Cernel Moderators @redrum
                                    last edited by

                                    @redrum said in Unit Option Can Submerge/Hide for Land Units (Partisan/Guerrilla/Spy/Diplomat/Munition):

                                    @Cernel So the goal is that isDestroyer units should cancel out canMoveThroughEnemies for sea/land/air units.

                                    Ok, but in the moment air units can always move though, I suppose/assume that all these properties are completely pointless if assigned to air units (beside only making air units able to block non-air units).

                                    The other item I wanted to discuss also with @Hepps, as being the original proponent of the feature, is what should happen when units get ignored in movement through land or sea territories. Should the territory be conquered by the units moving through or not? My preference is that a territory with a not capturable unit on blitz should never be captured by moving past it. How I see it is that if you are ignoring units in a territory, you are hiding from them while moving, so you should not take the territory they are defending under their nose.

                                    For example, let's say that I make infantry/trenches ignorable by cavalry if alone, so that a cavalry can move through a territory with only infantry/trenches. Should the territory be conquered, while the infantry/trenches remain to the same ownership?

                                    ?

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

                                      @Cernel Land territory capture when moving through would only happen if the territory is empty and the unit has blitz. So the cavalry in your example wouldn't capture the territory but could move through the territory with infantry/trenches to attack another territory. In theory, you could use this to create more of a defense in depth system.

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

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

                                        @redrum Cool, and I agree. How about if in the territory there is an infrastructure that can be ignored in movement under a ruleset by which infrastructures block blitz. I assume, in this case, I should be able to move through the enemy infrastructure, when alone in an enemy territory, but, if doing so, the territory would not be captured (while both the infrastructure and the territory are captured if I switch to the v1 property allowing me to capture infrastructures by blitzing). Though this would also be related to the fact that, currently, if you just end combat movement into such a territory, you instantly capture it, while, by intended rules, it should be captured only during Conduct Combat (also relevant if that infrastructure is an AA gun, especially in case I'm moving one land unit into it and paratrooping the rest (which I may actually want to do in v3, since that game forbids me to paratroop during non combat movement)).

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

                                          @redrum said in Unit Option Can Submerge/Hide for Land Units (Partisan/Guerrilla/Spy/Diplomat/Munition):

                                          @Cernel Land territory capture when moving through would only happen if the territory is empty and the unit has blitz.

                                          I'm assuming here you mean by v2+ rules, as in v1 (that is the default) you also capture territories with infrastructures only, not just empty ones (just making sure).

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

                                            @Cernel Yeah, I mostly ignore the v1 rules as they are poor in general. But yes, we'd have to consider if only infrastructures. I tend to agree that I'd try to have it align to the existing rule set and how blitz works.

                                            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

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