trigger question - unit with hit
-
Ok so have the DamagedBB placed when your trigger sees all the BBs sunk. Might as well make it a A0 D0 M0 since it's not going anywhere. Then your -10 PU trigger fires when he sees it's there. Then at the start of JPNs turn have a trigger remove it. That way if JPN attacks again it won't be there to soak a hit.
-
that was excatly my first programming, but this way of doing it restricts the game. I want the user to decide what he does.
If he decides to move the damaged BB to a shore next to factory it should be repaired, if the player decides to attack with it, it should be possible too.
I think the programmers should enlarge the "placement" function by the battleship_hit.
-
@numetalfan yea that'd be cool. I'd make a Feature request as WC suggested then, because edit is the only way to do it for now.
There's been a few more developers active lately. If it's easy, maybe someone will take it on sooner than later.
Might request at git also https://github.com/triplea-game/triplea/issues then add Feature Request from the Label menu. Might get more visibility that way. I'd post it here too.
-
thx
-
Trigger question.
First trigger condition....something like
name='conditionAttachmentJapaneseBattleships' attachTo='Japanese' javaClass='RulesAttachment' type='player'>
<option name='directPresenceTerritories' value='map' count='1'/>
<option name='unitPresence' value='battleship' count='1'/>Second trigger condition
name='conditionAttachmentJapaneseBattleships' attachTo='Japanese' javaClass='RulesAttachment' type='player'>
<option name='directPresenceTerritories' value='map' count='1'/>
<option name='unitPresence' value='battleship_hit' count='1'/>It does not work! There is an error
So how make a condition that checks the presence of a regular battleship but that has already got a hit in a defined territory??
-
@numetalfan do you have "when" set for your trigger ? If so , might need to play around with which phase.
It does find the BB, just not the damaged one ?
-
That was just an example. My trigger has a when...
Yeah. If there is a battleship in thst sea zone the trigger works. Is there a BB with a hit it doesn't. And ...battleship_hit.. causes an immediate error, the game will not start.
-
@numetalfan hmm...yea when the BB is hit it still calls it a BB when you hover on it so Idk ... you could try making the BB turn into a different unit when hit and then search for that.
Sort of what we were trying earlier with the "BattleshipDamaged"
-
Hi all,
I tried
<attachment name="conditionAttachmentPearlHarbour" attachTo="Americans_west" javaClass="games.strategy.triplea.attachments.RulesAttachment" type="player">
<option name="directExclusionTerritories" value="53 Sea Zone" count="1"/>
<option name="rounds" value="1"/>
</attachment>I thought this coding would check how the status of 53 sea zone is:
If Japan did not attack or the attack failed, this condition should be wrong, there would still be an unit (battleship) of the American_west thereIf the Japanese are succesful, there are no more allied ships left, so the condition would be true.
yet, it doesn't work correctly. I wonder why
-
@numetalfan I would try using "unitPresence" and"directPresenceTerritories" instead . Something like
<option name="directPresenceTerritories" value="53 Sea Zone" count="1"/>
<option name="unitPresence" value="battleship" count="1"/>
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