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

    Unit Option When Damaged Change Into Different Unit (Weakened Battleships)

    Scheduled Pinned Locked Moved Feature Requests & Ideas
    83 Posts 11 Posters 42.8k Views 10 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
      last edited by

      @redrum There is a thing may you want to look into, as it is something I've never experienced before. If I have this:

                      <attachment name="unitAttachment" attachTo="wall" javaClass="games.strategy.triplea.attachments.UnitAttachment" type="unitType">
                               <option name="movement" value="0"/>
                               <option name="canNotMoveDuringCombatMove" value="true"/>
                               <option name="attack" value="0"/>
                               <option name="defense" value="0"/>
                               <option name="hitPoints" value="1"/>
                               <option name="whenHitPointsDamagedChangesInto" value="1:true:wall_fallen"/>
                               <option name="isConstruction" value="true"/>
                               <option name="constructionType" value="fortification"/>
                               <option name="constructionsPerTerrPerTypePerTurn" value="1000"/>
                               <option name="maxConstructionsPerTypePerTerr" value="1000"/>
                               <option name="requiresUnits" value="metropolis"/>
                      </attachment>
      				
                      <attachment name="unitAttachment" attachTo="wall_fallen" javaClass="games.strategy.triplea.attachments.UnitAttachment" type="unitType">
                               <option name="movement" value="0"/>
                               <option name="canNotMoveDuringCombatMove" value="true"/>
                               <option name="attack" value="0"/>
                               <option name="defense" value="0"/>
                               <option name="isInfrastructure" value="true"/>
                               <option name="hitPoints" value="2"/>
                               <option name="whenHitPointsRepairedChangesInto" value="0:true:wall"/>
                               <option name="isConstruction" value="true"/>
                               <option name="constructionType" value="fortification"/>
                               <option name="constructionsPerTerrPerTypePerTurn" value="1000"/>
                               <option name="maxConstructionsPerTypePerTerr" value="1000"/>
                               <option name="requiresUnits" value="metropolis"/>
                      </attachment>
      

      The game starts with no problems nor errors both in 1.9.0.0.13066 and 2.0, but the "whenHitPointsDamagedChangesInto" appears not working at all.

      My guess is that this is because support for changing units when they lost all their hitpoints was added after 1.9.0.0.13066. However, I guess this is a warning to mapmakers, that if you use this option in 1.9 and the game is not giving any errors, this doesn't necessarily means that your game actually works in 1.9.

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

        @Cernel I fairly sure this is supported in 1.9.0.0.13066 as TWW uses it. At a quick glance, I think the issue probably is that it doesn't work if the unit has 0 HP remaining (unit dies instead). Can you try changing the wall to have 2 HP to see if it then transforms?

        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
        • W Offline
          waxfingers @redrum
          last edited by

          @redrum

          Hi redrum,

          Was the bombing damage feature added? Based on the thread and what I have tested for naming it was not.

          B 1 Reply Last reply Reply Quote 0
          • B Online
            beelee @waxfingers
            last edited by beelee

            Hi @waxfingers

            yea you can. Total World War uses it and I copied that for the Global 40 Expansion

            edit

            <!-- Battle Ship -->
            <attachment name="unitAttachment" attachTo="battleship" javaClass="games.strategy.triplea.attachments.UnitAttachment" type="unitType">
            <option name="movement" value="2"/>
            <option name="isSea" value="true"/>
            <option name="attack" value="4"/>
            <option name="defense" value="4"/>
            <option name="canBombard" value="true"/>
            <option name="hitPoints" value="2"/>
            <option name="blockade" value="1"/>
            <option name="canBeGivenByTerritoryTo" value="British"/>
            <option name="whenHitPointsDamagedChangesInto" value="1:true:BB_Damaged"/>
            </attachment>

            <!-- BB Damaged -->
            <attachment name="unitAttachment" attachTo="BB_Damaged" javaClass="games.strategy.triplea.attachments.UnitAttachment" type="unitType">
              <option name="movement" value="2"/>
              <option name="isSea" value="true"/>
              <option name="attack" value="0"/>
              <option name="defense" value="4"/>
              <option name="canBombard" value="false"/>
              <option name="hitPoints" value="2"/>
              <option name="blockade" value="1"/>
              <option name="canBeGivenByTerritoryTo" value="British"/>
              <option name="whenHitPointsRepairedChangesInto" value="0:true:battleship"/>
            </attachment>
            
            W 1 Reply Last reply Reply Quote 0
            • W Offline
              waxfingers @beelee
              last edited by

              @beelee

              Hi beelee,

              Yes, I noticed the "HitPoints" damage change function was added as I tested that. I meant was the SBR damage bombing function added. It was not the main thing of that article, but it was mentioned as an idea at the beginning. I am looking for such a thing now.

              My full idea is I want to have a way to make SBR damage be more permanently lasting and also have players keep fighters for defense back home to try to deter or respond to it (as Germany did).

              While the initial SBR in the war didn't really amount to much but casualties, apparently near the end when the US put money into doing it and targeted transportation and oil facilities it started to work as a strategy, especially when some material production was actually fully shutdown.

              My idea is to reduce the territory PUs to a permanent level, perhaps even 0 if not dealt with. The way I have seen to do this is to perhaps have a particular unit/facility in the territory which gets bombed. This unit/facility would then convert to another unit because of the bombed value. The condition is whatever that bombed out value unit is less the territory value (if I can grab that somehow) is the amount of PUs lost taken as a national objective/convoy type of thing (which I got to work) to a maximum of the territory value. So basically the game adds the territory PUs but then this bombing convoy takes them away again. E.g. Germany is 5 PUs, Facility bombed at 6 damage, German player forgoes repairing it at all, so at collect income he actually loses 1 PU, if he had paid 1 PU, he would then at least break even because then next round he would still need to pay this off or he keeps losing the 1 PU (it never gets generated by the territory). Thus, it is a way to actually force a response to bombing and not just leave factories burning and just use another one out of reach. The max damage of each unit/facility would be double the territory PUs in order to achieve 0 income. Eventually, if one can keep bombing like this then it would be a permanent hindrance to the economic territories that are reachable. But, with fighters defending at 2, then it also makes it so those need to stay at home and can't be heading all over the place. Apparently Germany had 70% of its Airforce parked in West G because of bombing runs, perhaps a nice thing for Russia.

              B RogerCooperR 3 Replies Last reply Reply Quote 1
              • B Online
                beelee @waxfingers
                last edited by

                @waxfingers right on I thought I may have misinterpreted your question. @redrum not around much these days. Pops in once in a while.

                @RogerCooper might know of a map that does what you want or have an idea how to do it.

                Seems as if you got the right idea and it should be possible

                1 Reply Last reply Reply Quote 0
                • B Online
                  beelee @waxfingers
                  last edited by

                  @waxfingers I like how @Black_Elk does it with his "Attack 0 Cost 5 Bombers". It's in the https://forums.triplea-game.org/topic/1140/global-40-house-rules/30

                  I can't remember but I think I use interceptors hitting at 2 and escorts at 1 due the cost difference.

                  Anyway, tested it a ton and found it to work good. Makes Germany have to keep Ftrs to defend.

                  But yea, I like your idea. I'll look at it closer when I get time. : )

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

                    @waxfingers said in Unit Option When Damaged Change Into Different Unit (Weakened Battleships):

                    My full idea is I want to have a way to make SBR damage be more permanently lasting and also have players keep fighters for defense back home to try to deter or respond to it (as Germany did).

                    While the initial SBR in the war didn't really amount to much but casualties, apparently near the end when the US put money into doing it and targeted transportation and oil facilities it started to work as a strategy, especially when some material production was actually fully shutdown.

                    My idea is to reduce the territory PUs to a permanent level, perhaps even 0 if not dealt with. The way I have seen to do this is to perhaps have a particular unit/facility in the territory which gets bombed. This unit/facility would then convert to another unit because of the bombed value. The condition is whatever that bombed out value unit is less the territory value (if I can grab that somehow) is the amount of PUs lost taken as a national objective/convoy type of thing (which I got to work) to a maximum of the territory value. So basically the game adds the territory PUs but then this bombing convoy takes them away again

                    Actually what you want is not hard to achieve. Basically, you use the old strategic bombing rules from the Classic edition which take away IPC's not production capacity.

                    Make sure that "SBR Affects Unit Production" is set to false. Set "Territory Turn Limit" to true.

                    If you want to be able to bomb territories without factories, you would need to create a new unit type with "canBeDamaged" and "isInfrastructure" set to true in the places without factories. This would make every territory bombable.

                    W 1 Reply Last reply Reply Quote 1
                    • W Offline
                      waxfingers @RogerCooper
                      last edited by

                      Hi @rogercooper

                      OK I will check that out. I am not sure if it does exactly what I am proposing though. Would removing IPCs mean a single bombing run takes away so much IPCs for that turn only? Or does the damage and consequence persist if not repaired?

                      My idea is more of a continuous drain if not dealt with and repaired. Also, I wanted the major territories to be a little bit resistant to it (would need like 3+ planes or separate bombing runs to do enough damage to have an effect). That is why the math was territory value less bombing value is the amount of IPCs lost. So if territory is 5 and bombing was only 3 then nothing happens to IPCs.

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

                        @waxfingers said in Unit Option When Damaged Change Into Different Unit (Weakened Battleships):

                        Hi @rogercooper

                        OK I will check that out. I am not sure if it does exactly what I am proposing though. Would removing IPCs mean a single bombing run takes away so much IPCs for that turn only? Or does the damage and consequence persist if not repaired?

                        My idea is more of a continuous drain if not dealt with and repaired. Also, I wanted the major territories to be a little bit resistant to it (would need like 3+ planes or separate bombing runs to do enough damage to have an effect). That is why the math was territory value less bombing value is the amount of IPCs lost. So if territory is 5 and bombing was only 3 then nothing happens to IPCs.

                        It would not be persistent. If you want persistent damage, just make damage to factory capacity unrepairable.

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