Thread Tools Display Modes
04/13/15, 09:39 AM   #1
Garkin
 
Garkin's Avatar
AddOn Author - Click to view addons
Join Date: Mar 2014
Posts: 832
Attribute visuals (shields) bug

Did you notice that Unit Attrribute Visualizer for shields doesn't work correctly?

You can easily reproduce this bug if you renew two or more shields multiple times - old shields aren't crrectly removed, so your health bar looks like you have permanently applied shield. (Tested with Blazing Shield I + Healing Ward III)

If you take a look into values in PLAYER_ATTRIBUTE_BARS.attributeVisualizer.visualModules, shield value never gets to zero, there are artificial numbers like:
lastValue = 52151
maxValue = -15213
statusMax = 8114 (probably correct)
statusValue = 8114 (probably correct)
value = 52151

I have tried to track shield strength on my own (ShieldInfo addon), but it seems that this is not an UI bug, because event EVENT_UNIT_ATTRIBUTE_VISUAL_UPDATED returns invalid numbers. And also because of invalid shield value events EVENT_UNIT_ATTRIBUTE_VISUAL_ADDED and EVENT_UNIT_ATTRIBUTE_VISUAL_REMOVED are almost never fired (for ATTRIBUTE_VISUAL_POWER_SHIELDING).

Is it really game bug or did I miss something?
  Reply With Quote
04/13/15, 09:51 AM   #2
Garkin
 
Garkin's Avatar
AddOn Author - Click to view addons
Join Date: Mar 2014
Posts: 832
Debug info from this code:

Lua Code:
  1. local function UnitAttributeVisual(evt, unitTag, unitAttributeVisual, statType, attributeType, powerType, value1, value2, value3, value4)
  2.    if unitTag == "player" and unitAttributeVisual == ATTRIBUTE_VISUAL_POWER_SHIELDING and attributeType == ATTRIBUTE_HEALTH then
  3.       if evt == EVENT_UNIT_ATTRIBUTE_VISUAL_UPDATED then
  4.          d(zo_strformat("Shield Updated: <<1>>, <<2>>, <<3>>, <<4>>", value1, value2, value3, value4))
  5.       elseif evt == EVENT_UNIT_ATTRIBUTE_VISUAL_ADDED then
  6.          d(zo_strformat("Shield Added: <<1>>, <<2>>", value1, value2))
  7.       elseif evt == EVENT_UNIT_ATTRIBUTE_VISUAL_REMOVED then
  8.          d(zo_strformat("Shield Removed: <<1>>, <<2>>", value1, value2))
  9.       end
  10.    end
  11. end
  12.  
  13. EVENT_MANAGER:RegisterForEvent(EVENT_UNIT_ATTRIBUTE_VISUAL_ADDED, UnitAttributeVisual)
  14. EVENT_MANAGER:RegisterForEvent(EVENT_UNIT_ATTRIBUTE_VISUAL_REMOVED, UnitAttributeVisual)
  15. EVENT_MANAGER:RegisterForEvent(EVENT_UNIT_ATTRIBUTE_VISUAL_UPDATED, UnitAttributeVisual)

Used events:
Code:
* EVENT_UNIT_ATTRIBUTE_VISUAL_ADDED (*string* _unitTag_, *integer* _unitAttributeVisual_, *integer* _statType_, *integer* _attributeType_, *integer* _powerType_, *number* _value_, *number* _maxValue_)
* EVENT_UNIT_ATTRIBUTE_VISUAL_REMOVED (*string* _unitTag_, *integer* _unitAttributeVisual_, *integer* _statType_, *integer* _attributeType_, *integer* _powerType_, *number* _value_, *number* _maxValue_)
* EVENT_UNIT_ATTRIBUTE_VISUAL_UPDATED (*string* _unitTag_, *integer* _unitAttributeVisual_, *integer* _statType_, *integer* _attributeType_, *integer* _powerType_, *number* _oldValue_, *number* _newValue_, *number* _oldMaxValue_, *number* _newMaxValue_)
Output:
Code:
Shield Updated: 91789, 94453, -36461, -33797
Shield Updated: 94453, 99707, -33797, -28543
Shield Updated: 99707, 99398, -28543, -34007
Shield Updated: 99398, 102062, -34007, -31343
Shield Updated: 102062, 101753, -31343, -36807
Shield Updated: 101753, 107007, -36807, -31553
Shield Updated: 107007, 106698, -31553, -37017
Shield Updated: 106698, 109362, -37017, -34353
Shield Updated: 109362, 109053, -34353, -39817
Shield Updated: 109053, 114307, -39817, -34563
Shield Updated: 114307, 113998, -34563, -40027
Shield Updated: 113998, 116662, -40027, -37363
Shield Updated: 116662, 116353, -37363, -42827
Shield Updated: 116353, 121607, -42827, -37573
Shield Updated: 121607, 121298, -37573, -43037
Shield Updated: 121298, 123962, -43037, -40373
Shield Updated: 123962, 121298, -40373, -43037
Shield Updated: 121298, 123962, -43037, -40373
Shield Updated: 123962, 123653, -40373, -45837
Shield Updated: 123653, 128907, -45837, -40583
Shield Updated: 128907, 128598, -40583, -46047
Shield Updated: 128598, 131262, -46047, -43383
Shield Updated: 131262, 130953, -43383, -48847
Shield Updated: 130953, 136207, -48847, -43593
Shield Updated: 136207, 135898, -43593, -49057
Shield Updated: 135898, 130644, -49057, -54311
I have started with no shield active, it was after reload UI, so some values could be present somewhere.
What I did? Activate Blazing Shield, switch weapon set, activate Healing Ward, switch weapon set, renew Blazing Shield, switch weapons etc. until I run out of magicka.

As you can see, EVENT_UNIT_ATTRIBUTE_VISUAL_ADDED and EVENT_UNIT_ATTRIBUTE_VISUAL_REMOVED wasn't fired even once and shield values in EVENT_UNIT_ATTRIBUTE_VISUAL_UPDATED are, ...hm let's say odd. Max value is negative number?

Last edited by Garkin : 04/13/15 at 09:54 AM.
  Reply With Quote
04/14/15, 08:24 AM   #3
ZOS_ChipHilseberg
ZOS Staff!
Premium Member
Yes this person is from ZeniMax!
Join Date: Oct 2014
Posts: 551
This definitely sounds like a bug.
  Reply With Quote
04/14/15, 09:23 AM   #4
sirinsidiator
 
sirinsidiator's Avatar
AddOn Author - Click to view addons
Join Date: Apr 2014
Posts: 1,579
I also have this problem from time to time. Usually happens in Cyrodiil for me. Only goes away after I relog or crash (which happens a lot more often ).
  Reply With Quote
05/27/15, 08:37 AM   #5
XEVENEX
Join Date: Jan 2015
Posts: 6
Confirming this is a bug that I have been dealing with for a long time. The only thing you can do is log out and log back in again. Reloadui will not fix it. Please fix this ZOS!

EDIT:
Champion passives, abilities, and weapon enchants that provide small shields will also trigger this bug.
  Reply With Quote
06/09/15, 03:55 PM   #6
sirinsidiator
 
sirinsidiator's Avatar
AddOn Author - Click to view addons
Join Date: Apr 2014
Posts: 1,579
I added a workaround to my new addon sidWarTools. When you enter /resetshields in chat, it will take the current shield values and subtract them from whatever is returned by the API afterwards.
  Reply With Quote

ESOUI » Developer Discussions » General Authoring Discussion » Attribute visuals (shields) bug


Posting Rules
You may not post new threads
You may not post replies
You may not post attachments
You may not edit your posts

vB code is On
Smilies are On
[IMG] code is On
HTML code is Off