Limiting 1 hero-type for ALL players

luckbox

New Member
Reaction score
1
Does anyone know how to make it so its Limiting 1 hero-type for ALL players
not simplying using the -pick all player and limit hero for picked player trigger (i have that atm)

i want it so - similar to Dota,
where if you train a hero from ur alter (or hire from tavern) you are the only player with that hero, and u can have multiple heros types.

thanks.
 

tachiKC

New Member
Reaction score
3
I have actually been trying to figure this out myself to no avail. +rep to anyone who can help us out.
 

Hellohihi

New Member
Reaction score
42
Go to advance, gameplay constants.

In the field, Techtree - Dependancy Equivalents - Hero.

Remove all units from that field, and then add ALL of the heroes you have in your map to it.

Trigger:
  • Events
    • Time - Elapsed game time is 0.1 seconds
    • Conditions
    • Actions
      • For each integer A - 1 to 12 - do actions:
        • Player - Limit training of Heroes to 1 for Player(Integer A)
 

windale5

New Member
Reaction score
2
i have

i ahve a random hero arrary in my map and when i pick option all random will this affect it?
 

Komaqtion

You can change this now in User CP.
Reaction score
469
Nope ... But you can use this:

Trigger:
  • Limit Heroes
    • Events
      • Unit - A unit enters (Playable map area)
    • Conditions
      • ((Triggering unit) is A Hero) Equal to True
      • (Number of units in (Units owned by (Owner of (Triggering unit)) matching (((Matching unit) is A Hero) Equal to True))) Equal to 2
    • Actions
      • Unit - Remove (Triggering unit) from the game


Haven't tested though :S
 

windale5

New Member
Reaction score
2
ok

i have all random mode and 12 people automatically get 1 hero each will this affect it also what happens if u just keep randoming until u run out of heroes. do i also have to use the gamplay constatnt of limiting heroes or is that for taverns only.
 

luckbox

New Member
Reaction score
1
Hellohi, that its just limiting each player to 1 hero ..
and Komaquin that trigger doesnt look like it will work in the way i need it to..

thanks for trying anyways, ill keep looking
 

SkateuUp

Member
Reaction score
4
You have to add all heroes as variables to another variable and so forth its complicated if you are going for a DoTA like -ar feel. i suggest lookin at the DoTA Template by Acehart it has that mode in it.
 

LordXavier

TH.net Regular
Reaction score
16
you could try this. Temp_Ugroup is a unit group variable and Temp_Pgroup is a player group variable.
Trigger:
  • Limiting Heroes
    • Events
      • Unit - A unit Sells a unit
      • Unit - A unit Finishes training a unit
    • Conditions
      • ((Sold Unit) is A Hero) equal to True
      • ((Trained Unit) is A Hero) equal to True
    • Actions
      • Set Temp_Ugroup = (Units in (Playable map area))
      • Unit Group - Pick every unit in Temp_Ugroup and do (Actions)
        • Loop - Actions
          • Neutral Building - Remove (Unit-type of (Sold Unit)) from all marketplaces
      • Custom Script: call DestroyGroup (udg_Temp_Ugroup)
      • Set Temp_Pgroup = (All players)
      • Player Group - Pick every player in Temp_Pgroup and do (Actions)
        • Loop - Actions
          • Player - Make (Unit-type of (Trained unit) Unavailable for training/construction by (Picked Player)
      • Custom Script: call DestroyForce (udg_Temp_Pgroup)
 

Lightstalker

New Member
Reaction score
55
A unit sells a unit
Unit sold is hero = to true
remove sold unit from triggering unit

Important: make sure your Tavern has the "Sell Units" ability. If the above trigger still does not work, you may have to add the units via trigger to the Tavern during Map Initialization using "Add UnitType to MarketPlace".

Man, what's with everyone posting super long and complicated triggers :S... and why does everyone have red rep?
 

LordXavier

TH.net Regular
Reaction score
16
A unit sells a unit
Unit sold is hero = to true
remove sold unit from triggering unit

Important: make sure your Tavern has the "Sell Units" ability. If the above trigger still does not work, you may have to add the units via trigger to the Tavern during Map Initialization using "Add UnitType to MarketPlace".

Man, what's with everyone posting super long and complicated triggers :S... and why does everyone have red rep?

With what you did, the remove sold unit from triggering unit, all that does is remove the hero, not prevent it from being sold/trained, therefore wasting the money of whoever bought it.
my trigger i posted wont work unless the buildings that sell heroes have the "Sell Unit" ability, like Lightstalker said. My rep is red cuz of a double post a long time ago :banghead:
 

luckbox

New Member
Reaction score
1
Thx lord, ill try that , and ill see what i come up with

on another notE: i just re read my original post, i shouldnt have mentioned dota, i meant 'similar' as in 1 hero-type her player. not the game play or anything like it.
basically, its melee type game with a huge amount of heros to choose from and some races can choose 3 while others can choose 6.. andi want only 1 hero type during the game. eg: not having 5 pally's from 5 different players

thanks
 

LordXavier

TH.net Regular
Reaction score
16
No. The Hero cannot be trained/sold if it is removed from the building that sells it. :nuts:

oh i understand what you meant, but the way you showed it it didn't make any sense to me

Thx lord, ill try that , and ill see what i come up with

on another notE: i just re read my original post, i shouldnt have mentioned dota, i meant 'similar' as in 1 hero-type her player. not the game play or anything like it.
basically, its melee type game with a huge amount of heros to choose from and some races can choose 3 while others can choose 6.. andi want only 1 hero type during the game. eg: not having 5 pally's from 5 different players

thanks

np
 

windale5

New Member
Reaction score
2
it a neutral building

its a neutral build but when i press all random mode a hero appears immediately. Heres the trigger
Trigger:
  • AR Copy
    • Events
      • Dialog - A dialog button is clicked for Dialog1
    • Conditions
      • (Clicked dialog button) Equal to AR
    • Actions
      • Game - Display to (All players) the text: ALL RANDOM was sele...
      • Player Group - Pick every player in (All players) and do (Actions)
        • Loop - Actions
          • Set L = ((Picked player) start location)
          • Unit - Create 1 RANDOM_HERO_ARRAY[(Random integer number between 1 and NUM_HEROES)] for (Picked player) at L facing Default building facing degrees
          • Player - Add -1900 to (Picked player) Current gold
          • Hero - Create Scroll of Town Portal. and give it to (Last created unit)
          • Hero - Create Jaood's Amulet of Power and give it to (Last created unit)
          • Hero - Create Boots of Speed and give it to (Last created unit)
          • Custom script: call RemoveLocation(udg_L)
      • Countdown Timer - Destroy (Last created timer window)
      • Trigger - Run Create Taverns Trigger <gen> (checking conditions)
      • Unit - Unpause all units
      • Trigger - Turn off HOST AFK 2 <gen>
 

LordXavier

TH.net Regular
Reaction score
16
its a neutral build but when i press all random mode a hero appears immediately. Heres the trigger
Trigger:
  • AR Copy
    • Events
      • Dialog - A dialog button is clicked for Dialog1
    • Conditions
      • (Clicked dialog button) Equal to AR
    • Actions
      • Game - Display to (All players) the text: ALL RANDOM was sele...
      • Player Group - Pick every player in (All players) and do (Actions)
        • Loop - Actions
          • Set L = ((Picked player) start location)
          • Unit - Create 1 RANDOM_HERO_ARRAY[(Random integer number between 1 and NUM_HEROES)] for (Picked player) at L facing Default building facing degrees
          • Player - Add -1900 to (Picked player) Current gold
          • Hero - Create Scroll of Town Portal. and give it to (Last created unit)
          • Hero - Create Jaood's Amulet of Power and give it to (Last created unit)
          • Hero - Create Boots of Speed and give it to (Last created unit)
          • Custom script: call RemoveLocation(udg_L)
      • Countdown Timer - Destroy (Last created timer window)
      • Trigger - Run Create Taverns Trigger <gen> (checking conditions)
      • Unit - Unpause all units
      • Trigger - Turn off HOST AFK 2 <gen>

I find one problem with that one, there's a chance that multiple players will get the same hero, if you want to put in an All Random mode, try using SD_Ryoko's, it's with the attachments at the bottom of this. it's Ryoko Hero Tavern.w3x, it makes sure that when you do All Random it makes it so the hero cannot be randomed again, if you use and need help changing it to your map i wouldn't mind changing it for you
 

windale5

New Member
Reaction score
2
he uses taverns

I don't use taverns. That what i want to avoid due to people not buying a hero and using the gold to make it unfair for other players. Yes i know there are multiple instances of the same hero. I need them to spawn at once though.
 
General chit-chat
Help Users
  • No one is chatting at the moment.
  • Ghan Ghan:
    Still lurking
    +3
  • The Helper The Helper:
    I am great and it is fantastic to see you my friend!
    +1
  • The Helper The Helper:
    If you are new to the site please check out the Recipe and Food Forum https://www.thehelper.net/forums/recipes-and-food.220/
  • Monovertex Monovertex:
    How come you're so into recipes lately? Never saw this much interest in this topic in the old days of TH.net
  • Monovertex Monovertex:
    Hmm, how do I change my signature?
  • tom_mai78101 tom_mai78101:
    Signatures can be edit in your account profile. As for the old stuffs, I'm thinking it's because Blizzard is now under Microsoft, and because of Microsoft Xbox going the way it is, it's dreadful.
  • The Helper The Helper:
    I am not big on the recipes I am just promoting them - I use the site as a practice place promoting stuff
    +2
  • Monovertex Monovertex:
    @tom_mai78101 I must be blind. If I go on my profile I don't see any area to edit the signature; If I go to account details (settings) I don't see any signature area either.
  • The Helper The Helper:
    You can get there if you click the bell icon (alerts) and choose preferences from the bottom, signature will be in the menu on the left there https://www.thehelper.net/account/preferences
  • The Helper The Helper:
    I think I need to split the Sci/Tech news forum into 2 one for Science and one for Tech but I am hating all the moving of posts I would have to do
  • The Helper The Helper:
    What is up Old Mountain Shadow?
  • The Helper The Helper:
    Happy Thursday!
    +1
  • Varine Varine:
    Crazy how much 3d printing has come in the last few years. Sad that it's not as easily modifiable though
  • Varine Varine:
    I bought an Ender 3 during the pandemic and tinkered with it all the time. Just bought a Sovol, not as easy. I'm trying to make it use a different nozzle because I have a fuck ton of Volcanos, and they use what is basically a modified volcano that is just a smidge longer, and almost every part on this thing needs to be redone to make it work
  • Varine Varine:
    Luckily I have a 3d printer for that, I guess. But it's ridiculous. The regular volcanos are 21mm, these Sovol versions are about 23.5mm
  • Varine Varine:
    So, 2.5mm longer. But the thing that measures the bed is about 1.5mm above the nozzle, so if I swap it with a volcano then I'm 1mm behind it. So cool, new bracket to swap that, but THEN the fan shroud to direct air at the part is ALSO going to be .5mm to low, and so I need to redo that, but by doing that it is a little bit off where it should be blowing and it's throwing it at the heating block instead of the part, and fuck man
  • Varine Varine:
    I didn't realize they designed this entire thing to NOT be modded. I would have just got a fucking Bambu if I knew that, the whole point was I could fuck with this. And no one else makes shit for Sovol so I have to go through them, and they have... interesting pricing models. So I have a new extruder altogether that I'm taking apart and going to just design a whole new one to use my nozzles. Dumb design.
  • Varine Varine:
    Can't just buy a new heatblock, you need to get a whole hotend - so block, heater cartridge, thermistor, heatbreak, and nozzle. And they put this fucking paste in there so I can't take the thermistor or cartridge out with any ease, that's 30 dollars. Or you can get the whole extrudor with the direct driver AND that heatblock for like 50, but you still can't get any of it to come apart
  • Varine Varine:
    Partsbuilt has individual parts I found but they're expensive. I think I can get bits swapped around and make this work with generic shit though
  • Ghan Ghan:
    Heard Houston got hit pretty bad by storms last night. Hope all is well with TH.
  • The Helper The Helper:
    Power back on finally - all is good here no damage
    +2
  • V-SNES V-SNES:
    Happy Friday!
    +1
  • The Helper The Helper:
    New recipe is another summer dessert Berry and Peach Cheesecake - https://www.thehelper.net/threads/recipe-berry-and-peach-cheesecake.194169/

      The Helper Discord

      Staff online

      Members online

      Affiliates

      Hive Workshop NUON Dome World Editor Tutorials

      Network Sponsors

      Apex Steel Pipe - Buys and sells Steel Pipe.
      Top