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


  • Donators Moderators Admin

    "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 - submerge
    2. isFirstStrike - roll and take casualties before regular units
    3. canNotTarget - can't target specific units like air units
    4. canNotBeTargetedBy - can't be targeted by specific units like air units
    5. canMoveThroughEnemies - unblockable, Treat Hostile Territories as Friendly
    6. canBeMovedThroughByEnemies - enemies can move through territories if only these types of units are present (would also need blitz for enemy land territories)

    Most functionality will now work for land/air subs but there are still some further changes need especially for canNotTarget and canNotBeTargetedBy as these are hardcoded to just check if empty or not.


    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


  • Admin

    @hepps Can you provide a little more detail around the design of the units you are thinking of using this for? Would you need isDestroyer available on land units as well to counter them?


  • Donators Moderators Admin

    @redrum Here is the conceptual idea for the Partisan

    <attachment name="unitAttachment" attachTo="exilledalliesPartisan" javaClass="games.strategy.triplea.attachments.UnitAttachment" type="unitType">
      <option name="movement" value="1"/>
      <option name="attack" value="0"/>
      <option name="defense" value="1"/>
      <option name="canHide" value="true"/>
      <option name="isAAforCombatOnly" value="true"/>
      <option name="isAAforBombingThisUnitOnly" value="false"/>
      <option name="isAAforFlyOverOnly" value="false"/>
      <option name="typeAA" value="partisansupriseattack"/>
      <option name="offensiveAttackAA" value="2"/>	  
      <option name="targetsAA" value="germanInfantry:germanCombatEngineer:germanAlpineInfantry:germanMarine"/>
      <option name="maxAAattacks" value="1"/>
      <option name="maxRoundsAA" value="-1"/>
      <option name="mayOverStackAA" value="true"/>
      <option name="isLandTransportable" value="true"/>
      <option name="transportCost" value="2"/>
      <option name="isStrategicBomber" value="true"/>
      <option name="bombingMaxDieSides" value="4"/>
      <option name="bombingBonus" value="-2"/>
      <option name="bombingTargets" value="Truck:Material:Train:Rail:Factory:Aircraftplant:Barracks:Researchcenter:Airfield"/>
      <option name="requiresUnits" value="germanOccupiedCity"/>
      <option name="requiresUnits" value="italianOccupiedCity"/>
      <option name="requiresUnits" value="japaneseOccupiedCity"/>	  
      <option name="canInvadeOnlyFrom" value="none"/>
      <option name="unitPlacementOnlyAllowedIn" value="Paris:Bordeaux:Brest:LeHavre:Lyon:Amsterdam:Brussels:Warsaw:Lwow:Wilna:Copenhagen:Oslo:Trondheim:Bergen"/>

  • Admin

    @hepps Intriguing. Both AA attack and SBR but very little attack/defense. I like the concept. Now I need the counter unit 🙂


  • Donators Moderators Admin

    @redrum uh oh Spies and Anti-Spies, Guerillas and Command units.. more Tylenol required 🙂


  • Donators Moderators Admin

    @redrum Will provide tonight. Just had to get this to you since you made me stay up half the night thinking about it. 🙂


  • Donators Moderators Admin

    @hepps Whatever do you mean I let you two brainstorm?

    Wife dragging me to bed was a good thing 🙂


  • Donators Moderators Admin

    btw I read the convo EXCELLENT THOUGHTS! about clarifications etc


  • Donators Moderators Admin

    @prastle Yes was a very productive convo.


  • Donators Moderators Admin

    @redrum Ok I couldn't wait. 🙂

    <attachment name="unitAttachment" attachTo="germanSpy" javaClass="games.strategy.triplea.attachments.UnitAttachment" type="unitType">
      <option name="movement" value="1"/>
      <option name="attack" value="0"/>
      <option name="defense" value="0"/>
      <option name="canHide" value="true"/>
      <option name="cancelsHide" value="Partisan:1:Spy:1"/>
      <option name="isAAforCombatOnly" value="true"/>
      <option name="isAAforBombingThisUnitOnly" value="false"/>
      <option name="isAAforFlyOverOnly" value="false"/>
      <option name="typeAA" value="Spyespionageattack"/>
      <option name="offensiveAttackAA" value="2"/>
      <option name="attackAA" value="3"/>  
      <option name="targetsAA" value="Diplomat:Spy:Patrisan"/>
      <option name="maxAAattacks" value="1"/>
      <option name="maxRoundsAA" value="-1"/>
      <option name="mayOverStackAA" value="true"/>  
      <option name="transportCost" value="1"/>
      <option name="isStrategicBomber" value="true"/>
      <option name="bombingMaxDieSides" value="4"/>
      <option name="bombingBonus" value="-2"/>
      <option name="bombingTargets" value="Truck:Material:Train:Rail:Factory:Aircraftplant:Barracks:Researchcenter:Airfield"/>
      <option name="isLandTransportable" value="true"/>
      <option name="isAirTransportable" value="true"/>
      <option name="requiresUnits" value="germanCity:germanBarracks"/>
      <option name="canInvadeOnlyFrom" value="none"/>
      <option name="canBeGivenByTerritoryTo" value="Germany"/>
      <option name="unitPlacementOnlyAllowedIn" value="Berlin:Hamburg:Stettin:Hannover:Bremen:Cologne:Breslau:Prague:Vienna:Munich:East Prussia"/>
    </attachment>

  • Donators Moderators Admin

    @hepps @Redrum ( psycho's 🙂 )


  • Donators Moderators Admin

    @Hepps @redrum If the spies become captured can we get tunneling options to escape the prison camp 🙂 ? Sounds great I hope you guys pull it off!


  • Donators Moderators Admin

    ... Just taking a stroll through some over grown untended gardens... 😉


  • Admin

    @hepps Guess someone should tend to the gardens...


  • Donators Moderators Admin

    @redrum Hopefully you know of a man with the shears enough to cut through the brambles.


  • Admin

    @hepps Let's say I know a guy that definitely has the gardening skills... I hear he takes bribes...


  • Donators Moderators Admin

    @redrum This sounds suspiciously like extortion. 🙂


  • Admin

    @hepps More like a capitalistic way for him to appropriately prioritize which gardens to tend...


  • Donators Moderators Admin

    @redrum Boy the gardener definitely let the vines grow thick in these gardens. The brambles have grown over everything.


  • Donators Moderators Admin

    @hepps The only reason I followed up with a post in this thread was because I was reminded of it while revamping the sub/destroyer mechanics. Made me think it might be better to approach this idea with a broader scope in mind. As far as looking all the behaviors associated with this and how they are dealt with across all units (land/sea/air).


Log in to reply