• Check out the results of the Techtree Contest #19!
  • Listen to a special audio message from Bill Roper to the Hive Workshop community (Bill is a former Vice President of Blizzard Entertainment, Producer, Designer, Musician, Voice Actor) 🔗Click here to hear his message!
  • Read Evilhog's interview with Gregory Alper, the original composer of the music for WarCraft: Orcs & Humans 🔗Click here to read the full interview.
  • Create a void inspired texture for Warcraft 3 and enter Hive's 34th Texturing Contest: Void! Click here to enter!
  • The Hive's 22nd Icon Contest: Creep Abilities is now concluded, time to vote for your favourite set of icons! Click here to vote!

Maximum Hero lvl without

Status
Not open for further replies.
Level 3
Joined
Jul 19, 2014
Messages
38
Hi! Its the second time i creat a thread (not the same, of course) in less than 24 hours, so im a little bit ashamed and, well, whatever. My problem is i cant set a maximum lvl to my hero by normal mode. I only know setting that through gameplay constants, but if i do so, then i will unable to put heroes above that lvl.
Resumed: How do i put a maximum lvl just for 1 hero? (thanks for reading)
 
In order to customize max hero levels, you will probably need to do your own system.

You'll need a data structure attached to each hero, which has an integer value that tells you the maximum level that hero can reach. When that hero levels up, you check to see if it is over its maximum level. If so, take off all levels until it is at its maximum (if it went above maximum).

A more effective treatment would be to do your own exp system. That way, a hero cannot gain exp if they are already at their max level, which would give you the customization you want.

However there might be a more straightforward solution. Waiting on that.
 
seth, your system is not really that great because you will still see the xp bar moving up. There is however, GUI function that disables hero experience gain, you can use that with conjuction of the data structure(array is sufficient if you have unit indexer, hashtable otherwise I would guess) that seth mentioned
 
I think this probably fits your needs:
(of course you have to insert the numbers and units for your map)
  • Experience limit
    • Events
      • Unit - Blood Mage 0000 <gen> Gains a level
    • Conditions
      • (Hero level of Blood Mage 0000 <gen>) Equal to 2
    • Actions
      • Trigger - Turn off (This trigger)
      • Hero - Set Blood Mage 0000 <gen> experience to 499, Hide level-up graphics
      • Hero - Disable experience gain for Blood Mage 0000 <gen>
 
I think this probably fits your needs:
(of course you have to insert the numbers and units for your map)
  • Experience limit
    • Events
      • Unit - Blood Mage 0000 <gen> Gains a level
    • Conditions
      • (Hero level of Blood Mage 0000 <gen>) Equal to 2
    • Actions
      • Trigger - Turn off (This trigger)
      • Hero - Set Blood Mage 0000 <gen> experience to 499, Hide level-up graphics
      • Hero - Disable experience gain for Blood Mage 0000 <gen>
Yes! that would work perfectly! But... i cant find the condition you put there... where did you find it?
 
seth, your system is not really that great because you will still see the xp bar moving up. There is however, GUI function that disables hero experience gain, you can use that with conjuction of the data structure(array is sufficient if you have unit indexer, hashtable otherwise I would guess) that seth mentioned

I did not know there was a native that disabled exp gain for a hero. Very helpful.
 
Status
Not open for further replies.
Back
Top