Hats webpage: Fix another incorrect static hat check
authorWuzzy <Wuzzy2@mail.ru>
Sat, 16 May 2020 04:43:11 +0200
changeset 15590 de1b31c2d2f2
parent 15589 f22ebcd9f3fc
child 15591 4b2f3228f13b
Hats webpage: Fix another incorrect static hat check
misc/hats_js_anim.xhtml
--- a/misc/hats_js_anim.xhtml	Sat May 16 04:28:26 2020 +0200
+++ b/misc/hats_js_anim.xhtml	Sat May 16 04:43:11 2020 +0200
@@ -314,8 +314,9 @@
         // Hedgehog
         a[i].style.backgroundPosition=Math.floor(a[i].idle/16)*-32+"px "+(a[i].idle%16)*-32+"px";
 
+        var maskName = a[i].title;
         // Hat
-        if (staticMasks[masks[i]] === true) {
+        if (staticMasks[maskName] === true) {
             // Hat offset for static hats
             if (a[i].idle === 2 || a[i].idle === 7 || a[i].idle === 12)
                 a[i].firstChild.style.marginTop="-4px";