Ability Cooldowns Question
research question
Can the AI trigger a research automatically and in such a way as to not interfere with normal user generated research? Ultimately, I am trying to increase an ability's cooldown as the game progresses.
I have a planetary structure that automatically spawns free units via an ability. I first added another ability to automatically increase the AbilityCooldownRate at set intervals. It triggered automatically and worked about as well as could be expected. But there were two problems with this method. The first is that it creates an unsightly ability for the structure.
Even with no icons, it still displays all the other visual stuff for a passive ability.
useCostType "Passive"
researchPrerequisites
NumResearchPrerequisites 0
nameStringID "IDS_BLANK"
descStringID "IDS_BLANK"
hudIcon ""
smallHudIcon ""
infoCardIcon ""
The second problem is that the ability only activates when the structure is built. So if an instance of this structure is built later in the game, it starts out with the base cooldown rate, not the adjusted rate.
My next step was to use levels on the spawning ability (levelSourceType "ResearchWithBase"). It solved all the problems the ability had, but it created a new problem - you have to activate the research yourself. I want to increase the cooldowns on a free unit for gameplay mechanics - no one in their right mind is going to research something that only penalizes them! And even if I could somehow induce the player to conduct the research, they would have to waste all their research time on it (the first cooldown takes 15min to research, and they only take longer from there.)
So, I'm wondering if I can have an ability be researched automatically. I'm thinking it may be possible to "hide" it in an artifact and just give it to the player at the beginning of the game, but I haven't yet found a way to do this. The only other way I could think to solve this would be if there is another kind of "levelSourceType" that I don't yet know of. I currently use "ResearchWithBase", "Intrinsic", and "fixedLevel0". Is there a "Timed" or "OnDelay" kind of "levelSourceType"?
Hopefully someone knows the answer to this.
Thanks