Merge pull request #412 from Aktanusa/master

Hotfix v3 #405
This commit is contained in:
DanielNoord authored and GitHub committed 2020-12-04 22:51:33 +01:00
commit 88b36becbb
2 files changed
+10 -6

No files matched your search

+5 -3
View File
@@ -1875,9 +1875,7 @@ CM.Disp.CheckGoldenCookie = function() {
CM.Disp.PlaySound(CM.Config.GCSoundURL, 'GCSound', 'GCVolume'); CM.Disp.PlaySound(CM.Config.GCSoundURL, 'GCSound', 'GCVolume');
CM.Disp.Notification('GCNotification', "Golden Cookie Spawned", "A Golden Cookie has spawned. Click it now!") CM.Disp.Notification('GCNotification', "Golden Cookie Spawned", "A Golden Cookie has spawned. Click it now!")
} }
CM.Disp.lastSpawnedGoldenCookieState = CM.Disp.currSpawnedGoldenCookieState
if (CM.Disp.currSpawnedGoldenCookieState == 0) CM.Disp.spawnedGoldenShimmer = 0;
CM.Disp.UpdateFavicon();
if (CM.Config.GCTimer == 1) { if (CM.Config.GCTimer == 1) {
for (var i in Game.shimmers) { for (var i in Game.shimmers) {
@@ -1892,6 +1890,10 @@ CM.Disp.CheckGoldenCookie = function() {
CM.Disp.GCTimers[i].style.display = 'none'; CM.Disp.GCTimers[i].style.display = 'none';
} }
} }
CM.Disp.lastSpawnedGoldenCookieState = CM.Disp.currSpawnedGoldenCookieState
if (CM.Disp.currSpawnedGoldenCookieState == 0) CM.Disp.spawnedGoldenShimmer = 0;
CM.Disp.UpdateFavicon();
} }
else if (CM.Config.GCTimer == 1 && CM.Disp.lastGoldenCookieState) { else if (CM.Config.GCTimer == 1 && CM.Disp.lastGoldenCookieState) {
for (var i in CM.Disp.GCTimers) { for (var i in CM.Disp.GCTimers) {
+5 -3
View File
@@ -1033,9 +1033,7 @@ CM.Disp.CheckGoldenCookie = function() {
CM.Disp.PlaySound(CM.Config.GCSoundURL, 'GCSound', 'GCVolume'); CM.Disp.PlaySound(CM.Config.GCSoundURL, 'GCSound', 'GCVolume');
CM.Disp.Notification('GCNotification', "Golden Cookie Spawned", "A Golden Cookie has spawned. Click it now!") CM.Disp.Notification('GCNotification', "Golden Cookie Spawned", "A Golden Cookie has spawned. Click it now!")
} }
CM.Disp.lastSpawnedGoldenCookieState = CM.Disp.currSpawnedGoldenCookieState
if (CM.Disp.currSpawnedGoldenCookieState == 0) CM.Disp.spawnedGoldenShimmer = 0;
CM.Disp.UpdateFavicon();
if (CM.Config.GCTimer == 1) { if (CM.Config.GCTimer == 1) {
for (var i in Game.shimmers) { for (var i in Game.shimmers) {
@@ -1050,6 +1048,10 @@ CM.Disp.CheckGoldenCookie = function() {
CM.Disp.GCTimers[i].style.display = 'none'; CM.Disp.GCTimers[i].style.display = 'none';
} }
} }
CM.Disp.lastSpawnedGoldenCookieState = CM.Disp.currSpawnedGoldenCookieState
if (CM.Disp.currSpawnedGoldenCookieState == 0) CM.Disp.spawnedGoldenShimmer = 0;
CM.Disp.UpdateFavicon();
} }
else if (CM.Config.GCTimer == 1 && CM.Disp.lastGoldenCookieState) { else if (CM.Config.GCTimer == 1 && CM.Disp.lastGoldenCookieState) {
for (var i in CM.Disp.GCTimers) { for (var i in CM.Disp.GCTimers) {