View Single Post
08-26-12, 10:04 AM   #1
zork
A Pyroguard Emberseer
 
zork's Avatar
AddOn Author - Click to view addons
Join Date: Jul 2008
Posts: 1,740
Possible bug with UPDATE_SHAPESHIFT_FORM event

When you log in a character for the first time that has any sort of stances and have "PLAYER_ENTERING_WORLD" and "UPDATE_SHAPESHIFT_FORM" events registered to a frame both will fire.

Problem:

If you use GetShapeshiftForm() in the the "PLAYER_ENTERING_WORLD" event on first loadup it will return the wrong result.
Doesn't matter much since "UPDATE_SHAPESHIFT_FORM" gets triggered thereafter and GetShapeshiftForm() delivers the correct result by then.

But the behaviour changes once you do a "/reload". "UPDATE_SHAPESHIFT_FORM" does not get triggered at all. Only "PLAYER_ENTERING_WORLD" does. But in this case on "/reload" when using GetShapeshiftForm() in the "PLAYER_ENTERING_WORLD" event it will return the correct result.

So when tracking stance information it is needed to register both events and to make sure that they work either on first login or on reload. Not sure why there is a difference between first login and reload.
__________________
| Simple is beautiful.
| WoWI AddOns | GitHub | Zork (WoW)

"I wonder what the non-pathetic people are doing tonight?" - Rajesh Koothrappali (The Big Bang Theory)