View Single Post
05/03/14, 06:42 PM   #7
mra4nii
AddOn Author - Click to view addons
Join Date: Apr 2014
Posts: 42
Oh my, that's what happens when the question is too vague
Sorry guys, my problem is to detect those units who have their health bar different from default one as first step. And such bar have not only Boss units.

Originally Posted by Iyanga View Post
Nope, that function is related to player names, not sure what it does anyway.

Originally Posted by Garkin View Post
Lua Code:
  1. if GetUnitDifficulty("reticleover") == MONSTER_DIFFICULTY_DEADLY then
  2.    d("This unit is boss!")
  3. end

All return values:
http://wiki.esoui.com/Globals#UIMonsterDifficulty

Default unit frames uses just 3 return values:
MONSTER_DIFFICULTY_NORMAL
MONSTER_DIFFICULTY_HARD
MONSTER_DIFFICULTY_DEADLY
Yep, i found this too on closer look to raw globals and turns out that this is exactly what i need.
There are 5, not 3 values:
["MONSTER_DIFFICULTY_NONE"] = 0 - snakes, caravan guars(enviroment mobs) and... Players. Perhaps in Cyrodiil enemy players have another difficulty. Didn't get there to check
["MONSTER_DIFFICULTY_EASY"] = 1 - regular mobs, npc
["MONSTER_DIFFICULTY_NORMAL"] = 2 - mobs what have health bar sides decorated with 1 square, solo dungeon boss
["MONSTER_DIFFICULTY_HARD"] = 3 - mobs what have health bar sides decorated with 2 square. location boss and its army. public dungeon bosses afaik have this rank too.
["MONSTER_DIFFICULTY_DEADLY"] = 4 - no idea, not sure what decoration it has, didn't have a chance to see such mobs.

Now second step is to understand how this difficulty coefficient affect the, let's call it, real level of mobs. Is lvl + difficulty * some_constant), or maybe difficulty * level.

I found GetUnitEffectiveLevel, but is not what i need. In fact, from what i've seen, this function always returns same value as GetUnitLevel.

Any thoughts?

Last edited by mra4nii : 05/03/14 at 06:48 PM.
  Reply With Quote