Unit Option Can Submerge/Hide for Land Units (Partisan/Guerrilla/Spy/Diplomat/Munition)
-
@hepps Open to discussion. I come back and think about this every so often. I'm waiting til we are working towards an incompatible release to address this as it'll probably break stuff. There are a bunch of issues with subs/destroyers and I think I'm going to break it into 3 parts:
- Allowing the existing system to work for land/air units
- Breaking isSub and isDestroyer into smaller attributes so more fine grained control can be achieved (canHide, firstStrike, canTarget, canBeTargetedBy, etc)
- 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
-
Cool. All basically what I was thinking of. Glad to see the gardener still looks in on the brabbles once in a while.
-
Let's generalize it with the concept of a "stealth" property and "anti-stealth" property. Stealth units can retreat before a combat round unless an anti-stealth unit is present. "stealth" units can't be attacked unless an anti-stealth unit is present, but they can be fired on when the "stealth" unit is an attacker.
Possibly you would need "land-stealth" and "sea-stealth" properties. Your ASW aircraft would not help against guerillas.
-
@rogercooper Yes the idea is to make a "stealth" type behavior attachable to units rather than as a all encompassing "Global Property".
The other half of the equation is also making the effects on a settable basis... ie. 1 destroyer does not affect the behavior of infinite subs.
-
@hepps Limiting the effect of anti-stealth units can create problems. What if there is more than 1 type of sub?
-
@rogercooper Well the concept I had initially proposed would allow the behavior to be settable like a support attachment. So you would have the ability to choose which units an ability can effect as well as the count.
-
@hepps How about being also able to make them re-emerge, the same way, on any following combat rounds?
-
It begins... https://github.com/triplea-game/triplea/pull/4829
I'm focusing on first allowing the existing system to work for land/air units. You can now make land and air units have
isSub
andisDestroyer
... -
@redrum UG! Now he will get his Spies …. sigh wasn't it complex enough yet?
-
@prastle Evil grin spreads over my face... all is coming into focus... dance puppets dance!
-
@redrum I'm guessing the next and soon-to-come step is atomizing the "isSub" option into its 4 components (being able to submerge, being unblockable, denying casualties fireback, being unable to hit air units)?
Also, submarine land units with blitz will be now able to conquer territories with units in them and moving past?
-
@Cernel Correct though it might be a few more than 4 components. I'm still thinking a bit about the best way to break it up. Here are the separate functions I've thought of so far and open to input around names and how to break it up:
- canHide - submerge
- surpriseStrike - roll and take casualties before regular units
- cantTarget (or canTarget) - can't target specific units like air units
- cantBeTargetedBy (or canBeTargetedBy) - can't be targeted by specific units like air units
- canMoveThroughEnemies - unblockable, Treat Hostile Territories as Friendly
- doesntBlockEnemies - enemies can move through territories if only these types of units are present (would also need blitz for enemy land territories)
The intention is for land subs to work just as sea subs work for conquering convoy zones. I haven't tested that out so far but I'm guessing there is still some work to do around land sub movement. I've mostly focused on submerging and surprise strikes so far. Fairly certain 1-4 above should work properly for land subs but 5-6 I haven't tested much yet.
-
@redrum Point 4 and 6 are not part of the basic "isSub" option. Those are additional v3 behaviours. So, if done all 6 as options, 1, 2, 3 and 5 would be effective as default (albeit 1 and 2 would be subjected to a number of different behaviours, depending on several properties (for example, with 1 you have the defensive retreat of v1.I/II, the additional defensive submerge ability of v1.III, the overriding offensive/defensive submerge after combat ability of v2, and the once again overriding offensive/defensive submerge before combat ability of v3)).
Also surpriseStrike could be split into surpriseOffence and surpriseDefence.
Also, a thing to keep in mind is that "isDestroyer" negates 1, 2, 5, as well as 4, if it applies (v3), but does not impact on 3, as well as 6, if it applies (v3).
So, I think it is really a very important thing to finally have these behaviours atomized (I recall veqryn had this plan too), also since by now, with all the various rulesets, a ridiculous number of different behaviours are all hard mashed into the "isSub" property, but the challenge would be to make it in a way to minimize confusion.
I think the atomization itself would help so much in making things way more clear, in the moment you have different options, while the "isSub" would just, then, say that it sets these 4~6 options all true.
On the namings, I really don't like "surpriseStrike", as it doesn't clearly hint about what is happening, and it seems like something that the opponent won't see it coming (that is never possible in TripleA, as nothing can be hidden). On this point, also "canHide" can be rather named "canDisengage", as that makes me think that you can hide submarines on the board, the opponent not knowing where they are (something that would be really cool).
-
@Cernel ...that you can hide submarines on the board, the opponent not knowing where they are (something that would be really cool).
That would be really cool
-
@Cernel Correct but I want to be able to represent
isSub
across all the various rule sets (v1/v2/v3, etc) so that it can really just become a shortcut option for setting other options likeisFactory
does. SoisSub
+ww2v2
would only set options 1/2/3/5 whereisSub
+ww2v3
would set all 6 options, etc. All of the existing sub properties would continue to work as is and impact land/air subs (I'd like to eventually rework these some as well but that would be later on).I've updated the first post with the overview of the proposed changes and breakdown of individual sub functions along with naming options. I'm most likely going to start on these changes soon so any suggestions or name preferences should be added to this thread.
-
@redrum But those 2 are already validated by properties, that need to be true. So, if you set those options true only in case ww2v3 or whatever is true, then you put in place a redundant double check, as I see it (you check some property for adding an option that would need to be activated by the same property).
Also, 1, 2, 3 and 5 don't need any ww2v2 or anything to be there; just 1 works different and 2 extends to defence (that is why you could split it between offensive and defensive).
-
Also, I cannot check it in the code, but I recall that ww2v2 is supposed to fully turn the game into Revised, while ww2v3 doesn't turn the game into v3, but just sets some minor things that lack their own property.
It would be really good if everything that ww2v2 and ww2v3 turn true or do would be fully documented in pos2. -
@Cernel They do but if we no longer require using
isSub
for future maps, how would you signify which units 4 & 6 apply to? You'd have to say tie 4 to units that specify 3 and 6 to units that specify 5 which is kind of messy and there could be times you only want 4/6 but not 3/5. So they need a separate unit option to specify which units would get them and then we potentially can remove the properties if they are a redundant check.Well, ideally I'd like to do the same thing we are doing here for
isSub
toww2v2
andww2v3
by ensuring they having separate properties for each feature and just act as shortcuts to set those properties. -
I'm looking to move forward with these bolded unit option names for isSub functionality:
- canEvade/canHide/canDisengage/canEscape - submerge
- isFirstStrike/surpriseStrike/preemptiveStrike - roll and take casualties before regular units
- cantTarget (or canTarget) - can't target specific units like air units
- cantBeTargetedBy (or canBeTargetedBy) - can't be targeted by specific units like air units
- canMoveThroughEnemies - unblockable, Treat Hostile Territories as Friendly
- 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-propertiescanEvade
6. Sub Retreat Before Battle
7. Submarines Defending May Submerge Or RetreatisFirstStrike
_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 AttackcantTarget
NONEcantBeTargetedBy
2. Air Attack Sub RestrictedcanMoveThroughEnemies
8. Submersible Subs
10. Subs Can End NonCombat Move With EnemiescanBeMovedThroughByEnemies
3. Submarines Prevent Unescorted Amphibious Assaults
4. Ignore Sub In Movement
9. Sub Control Sea Zone Restricted -
@redrum The only thing that I see that you are slightly undecided about is whether to go with "canTarget" or "cantTarget"...
I would think making the exceptions for what cannot be hit would be shorter than trying to setup what can be hit. Since, in all likelihood most of the time defining what a unit can't hit would be substantially shorter than what it can.