I thought about doing that, but there are so many units, I thought there must be a more efficient way.
Here's some more info
It's a TD where every Tower/Spell cost a certain type and amount of mana.
There are six different types.
I'm using upgrades to simulate each different type, and then adding it to a towers techtree requirements.
EX: Basic Tower costs 2 generic mana points.
techtree requirements - Generic Mana
techtree requirement levels - 2
Now, the idea is that when the tower begins construction, it will set the level of Generic Mana minus 2. Simulating the spending of generic mana, and preventing other towers that cost more generic mana to be unbuildable.
I know I could just make a trigger for each tower, or a giant if/then/else, but I was hoping for a more efficient way. Like the function that returns the techtree requirements.
Any suggestions for any other methods are welcome.
Thanks for your time.