• 🏆 Texturing Contest #33 is OPEN! Contestants must re-texture a SD unit model found in-game (Warcraft 3 Classic), recreating the unit into a peaceful NPC version. 🔗Click here to enter!
  • It's time for the first HD Modeling Contest of 2024. Join the theme discussion for Hive's HD Modeling Contest #6! Click here to post your idea!

How do I make a "Techtree choice"?

Status
Not open for further replies.
Level 6
Joined
Jul 10, 2016
Messages
167
Ask the title says, i want to make a techtree choice.
To make things easier to understand, Assume the following "variables":
Upgrade X - Purity
Upgrade Y - Corruption
Building X - Fountain
Building Y - Corrupted Fountain
Building Z - Upgrading or Triggering Building (Summoning Fountain)

At the start of the game, Both Building X and Y would be unavailable for construction. (This part I got using triggers)

Next step is this:
Scenario 1: You research Upgrade X which would result to:
  • Upgrade Y becomes unavailable for research
  • Building X becomes available for construction
Scenario 2: You research Upgrade Y which would result to:
  • Upgrade X becomes unavailable for research
  • Building Y becomes available for construction
Below are the triggers I used. Kindly ignore the Summoning Fountain part on the first trigger. Its irrelevant to this post.

  • Swamps Initialization
    • Events
      • Map initialization
    • Conditions
    • Actions
      • Player Group - Pick every player in (All players) and do (Actions)
        • Loop - Actions
          • Player - Make Corrupted Fountain Unavailable for training/construction by (Picked player)
          • Player - Make Fountain Unavailable for training/construction by (Picked player)
          • Player - Limit training of Summoning Fountain to 5 for (Picked player)
  • Corruption Fountain Availability
    • Events
      • Unit - A unit Finishes an upgrade
    • Conditions
      • (Unit-type of (Triggering unit)) Equal to Summoning Fountain
      • (Researched tech-type) Equal to Corruption
    • Actions
      • Player - Make Corrupted Fountain Available for training/construction by (Owner of (Triggering unit))
      • Player - Set the current research level of Purity to 1 for (Owner of (Triggering unit))
  • Fountain Availability
    • Events
      • Unit - A unit Finishes an upgrade
    • Conditions
      • (Researched tech-type) Equal to Purity
      • (Unit-type of (Triggering unit)) Equal to Summoning Fountain
    • Actions
      • Player - Make Fountain Available for training/construction by (Owner of (Triggering unit))
      • Player - Set the current research level of Corruption to 1 for (Owner of (Triggering unit))
 
Level 6
Joined
Jul 10, 2016
Messages
167
You would use set max research of the disabled one to 0 instead.
I'll try this later and get back to you.

As for techteee choice, I think it's already up to player to decide at this point no? Did I misunderstood something here?
I think you did misunderstood something. What I meant here is, the player in game, would choose the techtree that they want.

EDIT: It did work, but I had to change the event to "Finishes a research".
 
Last edited:
Status
Not open for further replies.
Top