• 🏆 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!

[General] Triggering - Hero gain size per level

Status
Not open for further replies.
Level 4
Joined
Aug 7, 2010
Messages
74
Hey lovely people, i am currently struggling on a simple trigger that would be:

When a hero gets a level up, triggering hero gains 5% size.


I know it is bloody easy but i just got stuck, please help me :xxd:
 
Level 28
Joined
Feb 18, 2014
Messages
3,576
  • Hero Level Size
    • Events
      • Unit - A unit Gains A Level
    • Conditions
    • Actions
      • Set ScaleSize = (ScaleSize + 5.00)
      • Animation - Change (Leveling Hero)'s size to (ScaleSize%, ScaleSize%, ScaleSize%) of its original size
ScaleSize is the current size of the hero which means if the size of your hero is 1.00 in the Object Editor then set ScaleSize to 100 in Variables.
 
Level 4
Joined
Aug 7, 2010
Messages
74
First of all, thank you so much for the ultra speed reply! I remember seeing your profile picture every now and then throughout the years xD very catchy and addictive to look at.



I did pretty much exactly this. But what happens in game is as follows: After level up, Hero shrinks down to 5% of its original size to then gain 5% more size per level. It may work halfway but it always seems to start from that 5% value first after triggering the trigger.

What i did:
-created a variable (type: real) with the initial amount: 100
-created this trigger you posted, except it reads a bit differently: Set VariableSet ScaleSize[100] = (ScaleSize[100] + 5)
Where the 100 is, there it asked for the "Index".
If this is wrong, i don't know where to find the right selection.


Best regards
 
Level 4
Joined
Aug 7, 2010
Messages
74
That's because you created an array instead of just one variable.
Clapped my head, changed the variable + trigger. Worked perfectly.

Ahahahaha man, laughing out so loud out of joy right now xD I knew somewhere must be the splinter in the feet.

Thank you so unbelievably much! :grin::ogre_love:
 
Status
Not open for further replies.
Top