You must be logged in to post messages.
Please login or register

Scenario Design and Discussion
Moderated by Sebastien, Mr Wednesday

Hop to:    
loginhomeregisterhelprules
Bottom
Topic Subject: Enabling research via trigger?
posted 05-11-13 01:46 AM CT (US)   
I'm trying to make a map that does not allow aging up until it's unlocked at a specific time or researched via a trigger..

Basically when I add it to the disallowed list, the triggers do not seem to work? Is this possible? What am I doing wrong here?

Sorry if this has been asked before, I just couldn't word it properly to actually search this. I did look in the trigger tutorials but it doesn't mention how to do it.
Replies:
posted 05-11-13 10:06 AM CT (US)     1 / 8  
Hey Savas,

I managed to accomplish your goal using one solution that I found. It is likely not the only solution but it works.

The method is changing your Town Center's ownership to GAIA and then back again. This will cancel the research everytime and refund the resources.

Create a new Looping Trigger, and add the following:

Trigger 1
C: Researching Tech: Feudal Age (or w.e age)
E: Change Ownership: Player 1 to GAIA - Town Center (Do not set an actual object, this will change all TC's to GAIA briefly)
E: Send Chat: Player 1: "You cannot advance yet!"
E: Activate Trigger 2

Trigger 2
E: Change Ownership: GAIA to Player 1 - Town Center
posted 05-11-13 11:01 AM CT (US)     2 / 8  
Oh that's a very ingenious way to do it, thank you. But one down side to this is if they are queuing villagers on other town centres they will be reset. Is it possible to only reset the one researching the tech?

Oh and if there is other ways then I still would like to know.

[This message has been edited by savas101 (edited 05-11-2013 @ 11:13 AM).]

posted 05-11-13 11:23 AM CT (US)     3 / 8  
I think that's the only way to do it
posted 05-11-13 09:43 PM CT (US)     4 / 8  
Savas,

You can target the specific Town Center. This of course would only work up until Castle Age when the user is able to build other TC's.

You can limit your map to one town center, even though that takes away a lot from a typical RM type game.. I'm not sure what other ways could accomplish the same thing without other downsides. I would recommend a clear warning message, or possibly limiting this feature to pre-castle age, then you won't have the problem of multiple TC's.
posted 05-13-13 04:45 AM CT (US)     5 / 8  
i found this trick while updating the aokts .xml file



in order to advance to the next age, besides the tech cost, it also requires an amount of buildings created from the current age

when one of those buildings is created, it initializates one research (Shadow X), and there is one research that check if at least 2 (except for imperial age) of those buildings were built (Shadow Node for Age X). that research, the previous age and the food/gold cost are the requirements to advance to the next age

so all you need to disable the next age button is to disable one of these researches (use trigger studio):

120 - Shadow Node for Age Two
135 - Shadow Node for Age Three
142 - Shadow Node for Age Four

edit:

if instead you want to re-enable the button later, disable these techs (dont disable the Shadow Node for Age X):

- for feudal age
108 - Dock built
110 - Mill built
122 - Barracks built
258 - Lumber Camp built
282 - Mining Camp built

- for castle age
106 - Blacksmith built
128 - Market Built
130 - Stable built
132 - Archery Range built

- for imperial age
107 - Monastery built
138 - Siege Workshop built
146 - University built
266 - Castle built

and then manually research 'Shadow Node for Age X' via triggers

[This message has been edited by JustTesting1234 (edited 05-13-2013 @ 04:57 AM).]

posted 05-13-13 07:40 AM CT (US)     6 / 8  
Seems to me that the Shadow-node trick is the best solution. And it's neat!
posted 05-13-13 10:14 AM CT (US)     7 / 8  
Great find! Do they all work?
posted 11-13-13 06:32 PM CT (US)     8 / 8  
Thanks a lot, JustTesting1234.

Never really used Trigger Studio, as I'm not really a map expert, but I'll take a look and see if I can reproduce your method.

If you have the example still around, I'd love to download it.
Age of Kings Heaven » Forums » Scenario Design and Discussion » Enabling research via trigger?
Top
You must be logged in to post messages.
Please login or register
Hop to:    
Age of Kings Heaven | HeavenGames