Closed jtuu closed 7 years ago
Just 2 things Tech level... J/Z use negative multiplier? Just asking... I think I tried JZ on the players themselves and it showed ok without abs()
Why the null check? Monsters in that list should never be null as they are not added unless they were properly populated. Also, if anything... your null check will not work because of this:
local monster = monsterList[i] // Extract current monster to local variable
if monster.display then // Check if we have to display this monster, if monster is null, we're done for...
// ...
if options.mhpShowStatus then
if monster ~= nil then // This check makes no sense because we'd have already crashed (and monsters should never be null here)```
I'll remove that null check (unless you really were having issues with it). Also I just pushed the status checks to my characters.lua library so I'll adjust for that too. Thank you for the feature!
Yeah J/Z uses a negative multiplier at least on monsters.
And yeah you're right the null check does seem misplaced now that I look at it. But I was having issues with it, the addon crashed once and the error log said it was because I passed a null value to GetPlayerTechStatus. After I added the check it hasn't crashed. Kinda weird.
By chance was this crash in De Rol Le or BarbaRay or was just any other random monster? Checking CopyMonster(), it doesn't copy the address of the monster and that might cause crashes trying to read their status.
Oh, that's what caused it most likely.
This adds an option in the monster HP reader to display status effects (jellen, zalure, frozen etc.) next to the health bar.
Also fixes a problem with jellen and zalure level calculation in GetPlayerTechStatus.