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

Gameplay Constants: Hero XP stuff

Status
Not open for further replies.
Level 2
Joined
Apr 19, 2006
Messages
28
Can someone just provide a short discription of each of the Hero XP game play constants shown below. I would really appreciate it. :) Thanks.

-Miz
 

Attachments

  • gameplay constants.JPG
    gameplay constants.JPG
    54.6 KB · Views: 434

Ralle

Owner
Level 77
Joined
Oct 6, 2004
Messages
10,106
sure..
Hero, Constant Factor - I guess this is just a constant of how much the hero get of xp the whole time, you could set this to 20 and it would take 5 times longer to level.
Hero, Level Factor - well wouldn't that be the same thing?
Hero, Prevoius Value Factor - Not sure
Hero, Table - This is the percentage of xp the hero gets from killing the units, at the first level he gets 100% of the xp, the 2nd level 120 etc..
 
Level 7
Joined
Nov 12, 2005
Messages
299
Well that's not exactly how those constants work...

Recommended read

When you kill an enemy hero how much XP would you get?
F(x) = cA * F(x-1) + cB * x + cC
This is the general formula you need (from the link I posted above).
x is the level of the unit you killed (lets say unit for now since it works differently for heroes, will explain that below)
F is the xp you are getting
cA is the Previous Value Factor
cB is the Level Factor
cC is the Constant Factor
Note though that you need the xp gained from a previous level. This also means you would need the xp you gain at level 1...this is actually the Table constant. It is the list of predefined values and overrides the formula above. This means that having 10, 20 and 30 on the table means that's how much you get from killing a level 1, level 2 and level 3 unit. But if you kill a level 4 unit? Then you need the formula and you need to know how much you would be getting at level 3.
Knowing that...
F(4)=1 * 30 + 5 * 4 + 5=30+20+5=55
So a level 4 unit gives you 55 xp.
What about level 5?
F(5)=1 * 55 + 5 * 5 + 5=55+25+5=85
Hope this is clear.

As for heroes...well it works the same way, but they have their own constants there. The ones with Normal, prefix affect normal units while the ones with Hero, affect killed heroes.
Lets take a look at that now.
The formula is of course the same, but this has some different constants.
F(x) = 1 * F(x-1) + 0 * x + 100=F(x-1)+100
Or lets just say 100 xp per level.
But this one has a longer table...it covers the xp all the way to level 5 (300).
And level 6, 7...? Well you have the formula. For a level 6 hero you gain 300+100=400 xp and for a level 7 you gain 300+100+100=500 xp.

Well anyway moving on...
Summoned Unit Factor is easy. When you kill a level 5 summon you get the same xp you would get from a level 5 unit, but multiplied by this constant. In this case you gain 2x less xp from summons.

Hero XP required works the same way xp gained does, but it affects the xp you need to gain a level.
The table only contains 200 meaning this is how much you need to advance from level 1.
Since constants are the same as xp gain from killing a hero, the formula is the same.
F(2) = 1 * 200 + 0 * x + 100=200+100

Woah this took quite some time...hope its clear now.
If you need any further explanation, just ask.
 
Status
Not open for further replies.
Top