Navigation

    TripleA Logo

    TripleA Forum

    • Register
    • Login
    • Search
    • TripleA Website
    • Categories
    • Recent
    • Popular
    • Users
    • Groups
    • Tags

    Buying Tech as Units

    Map Making
    3
    3
    44
    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.
    • G
      GREGOREK last edited by

      I'm cleaning up and advancing Jurassic. Evolution seems more appropriate for dinosaurs than Technology Development. It controls the order of advancement. I'm very close to making it happen through productionFrontiers but have a couple glitches that need your guidance. The evolution will show up as a Unit for purchase but it cannot be placed and must disappear.

      One productionFrontier for all is preferred, but can make one for each player if necessary.

          <productionFrontier name="production">
      	<frontierRules name="buyPterodactylus"/>
              ...
      	<frontierRules name="buyFeathers"/>
      	</productionFrontier>
      
          <productionFrontier name="productionFeathered">
      	<frontierRules name="buyPterodactylusFeathered"/>
              ...
      	</productionFrontier>
      

      This is my first attempt writing a trigger. The complication is the unit count potentially messing up other game features. Can the conditionAttachment be ignored and the triggerAttachment activated from the purchase? If not, can the unit count be set to zero by the trigger? Thus, making the phantom unit vanish, while the productionFrontier gets changed.

          <attachment name="conditionAttachmentCallovianFeathers" attachTo="Callovian" javaClass="games.strategy.triplea.attachments.RulesAttachment" type="player">
              <option name="unit" value="feathers" count="1"/>
              </attachment>
      
          <attachment name="triggerAttachmentCallovianFeathers" attachTo="Callovian" javaClass="games.strategy.triplea.attachments.TriggerAttachment" type="player">
              <option name="conditions" value="conditionAttachmentCallovianFeathers"/>
              <option name="frontier" value="productionFeathered"/>
              <option name="unit" value="feathers" count="0"/>
              </attachment>
      

      The productionRule only reports a Result parameter in POS2.

          <productionRule name="buyFeathers">
              <cost resource="PUs" quantity="100"/>
              <result resourceOrUnit="feathers" quantity="1"/>
              <option name="maxBuiltPerPlayer" value="1"/>
              </productionRule>
      

      That should satisfy the Callovian Evolution condition and activate the trigger, but it needs to delete the feathers-unit purchased. OR, launch the trigger directly at time of purchase.

          <productionRule name="buyCallovianFeathers">
              <cost resource="PUs" quantity="100"/>
              <option name="activateTrigger" value="triggerAttachmentCallovianFeathers"/>
              </productionRule>
      

      This has to be close. It bypasses the rigid built-in tech advancements, and allows for orderly evolution if so desired. Note the old entities (unfeathered air units) still exist, but can no longer be purchased with the new productionFrontier; nor can feathers, a different purchasable evolution will take it's place.

      W 1 Reply Last reply Reply Quote 2
      • W
        wc_sumpton @GREGOREK last edited by

        @gregorek said in Buying Tech as Units:

        It controls the order of advancement. I'm very close to making it happen through productionFrontiers but have a couple glitches that need your guidance.

        Check "Age of Tribes" developed by @Frostion. Tech is done through purchasing and should have most of what you are looking for.

        I would suggest reviewing that xml. Questions are always welcome.

        Cheers...

        TheDog 1 Reply Last reply Reply Quote 3
        • TheDog
          TheDog @wc_sumpton last edited by

          @GREGOREK
          1888A Steal & Steam builds on Age of Tribes to show
          +Tech uses isSea & isAir so AI will target its Tech advances if it needs Sea or Air
          +Tech advances are shown on Tech grid on Players tab
          +Display grouping, Tech is prefixed with _DevL, _DevA, _DevS (Land, Air, Sea)

          Tech Tree shows the dependencies
          Tech_Trees.png

          1 Reply Last reply Reply Quote 3
          • 1 / 1
          • First post
            Last post
          Copyright © 2016-2018 TripleA-Devs | Powered by NodeBB Forums