| 08-27-2004, 07:19 PM | #1 |
I was wondering how i'd implement a system whereby the player is given the option of two different upgrades (for the sake of this example LIGHT and DARK) which results in different unit types becoming available. How would I make it so that when the player has researched one of the upgrades the other becomes unavailable so that they are only able to decide upon one? |
| 08-27-2004, 07:55 PM | #2 |
you can make a building and two upgrades of the building, one beeing for this example light and one dark. Then at the units set techtree - requirements to dark/light so they are only avaiable for dark/light. |
| 08-27-2004, 08:33 PM | #3 |
Yes, but how would I be able to prevent that player from building another building and gaining acess to the other lunits? |
| 08-27-2004, 08:49 PM | #4 |
Is that building built by a builder? What's the style of map? |
| 08-27-2004, 08:53 PM | #5 |
Essentially its a simple warcraft map with custom made forces with new techtrees and stuff. Like a large scale warcraft game. Yes, the building in question would be built by a worker unit and therefore the player would be capable of building multiple structures of the same type to gain acess to all the upgrades. What i want to know is whether you can restrict all the other upgrades by researching one of them. |
| 08-27-2004, 09:23 PM | #6 |
You could make it impossible to build the building twice, by using a trigger like this: Code:
Events
Unit - A unit Begins construction
Conditions
(Unit-type of (Constructing structure)) Equal to BUILDING
Actions
Player - Make BUILDING Unavailable for training/construction by (Owner of (Constructing structure))then you would have to use a trigger which makes the building avaiable again if the structure is destroyed I hope this helped. *edit* ahh sorry, this is not good, because if your structure gets killed you could then use the other upgrade, hmm, you could make it this way: You have two separate buildings, one for example the dark building and one the light. When you build the light it makes the dark unavaiable and vice versa. I think that's the best possible/easy to do way. |
