• 🏆 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!
  • 🏆 Hive's 6th HD Modeling Contest: Mechanical is now open! Design and model a mechanical creature, mechanized animal, a futuristic robotic being, or anything else your imagination can tinker with! 📅 Submissions close on June 30, 2024. Don't miss this opportunity to let your creativity shine! Enter now and show us your mechanical masterpiece! 🔗 Click here to enter!

Team-shared upgrades

Status
Not open for further replies.
Level 7
Joined
May 30, 2018
Messages
290
So this is a big one I guess: Iam looking for a way, which allows that 1 player of the team is able to build/tech up/upgrade and the upgrades get applied on the whole team without the need to upgrade seperatly for themselfes.
Also: Is it possible that tech requirements (say like an upgrade which is needed to unlock something else) can be shared? So that 1 player researches/builds something and the other players of the team get access to the next techs?

I would really appreciate your help with this question. :)
Thank you.
 
Last edited:

Wrda

Spell Reviewer
Level 26
Joined
Nov 18, 2012
Messages
1,911
- Have the upgrade with a requirement: "Ally not researching this", just base this requirement as another upgrade, doesn't matter, just make it have no bonus effects.
- The requirement is there so a player can't click on the upgrade if another ally is already researching it
- Triggers: Have a trigger on map initialization which makes the requirement researched (level 1) for all players.
Have another trigger with the event: a unit starts researching; make condition to know if it is the upgrade we wanted; Make the requirement research level to 0 for all players except the one who is researching the global upgrade.
3rd Trigger with event a unit cancels researching; make condition to know if it is the upgrade we wanted; Make the requirement research level to 1 for all players except the one who is researching the global upgrade.
Last trigger with event a unit finishes researching; make condition to know if it is the upgrade we wanted; make the research level of the upgrade and requirement to 1 for all players
 
Level 40
Joined
Feb 27, 2007
Messages
5,112
As Wrda suggested having some way to prevent players from researching the same tech simultaneously would probably be smart. His method will work but you'll need a different 'player not researching this' dummy tech for each real tech in your map. Otherwise a player researching any tech will lock you out of researching any other tech simultaneously, not just the same tech. As for how to let others benefit from the tech:
  • Events
    • Unit - A unit finishes research
  • Conditions
  • Actions
    • Set TempPg = (Allies of (Triggering Player))
    • Set TempInt = (Current research level of (Researched tech type) for (Triggering Player))
    • Player Group - Pick every unit in TempPg and do (Actions)
      • Loop - Actions
        • Player - Set level of (Researched Tech type) for (Picked Player) to TempInt
    • Custom script: call DestroyForce(udg_TempPg) //cleaning the player group leak
 
Level 7
Joined
May 30, 2018
Messages
290
As Wrda suggested having some way to prevent players from researching the same tech simultaneously would probably be smart. His method will work but you'll need a different 'player not researching this' dummy tech for each real tech in your map. Otherwise a player researching any tech will lock you out of researching any other tech simultaneously, not just the same tech. As for how to let others benefit from the tech:
  • Events
    • Unit - A unit finishes research
  • Conditions
  • Actions
    • Set TempPg = (Allies of (Triggering Player))
    • Set TempInt = (Current research level of (Researched tech type) for (Triggering Player))
    • Player Group - Pick every unit in TempPg and do (Actions)
      • Loop - Actions
        • Player - Set level of (Researched Tech type) for (Picked Player) to TempInt
    • Custom script: call DestroyForce(udg_TempPg) //cleaning the player group leak

Thank you :).
Actually what I originally meant was that only one player can research anyways. Only player 1 of the team even has acces to the research buildings. So it's really just the issue that the upgrades researched, by said player 1, get applied to any player on the team. I hope you know what I mean by that.
 
Level 7
Joined
May 30, 2018
Messages
290
Looking for a way that 1 player is able to upgrade stuff, while the rest of the team benefits from these upgrades. Only said player 1 can research upgrades. The other players on the team don't even have access to research etc. : So it's just 1 player who upgrades for the whole team. That's what I need help with. Thank you.
 
Status
Not open for further replies.
Top