From 431b1e6cd0c8636c913278f0c3e73c442b34b284 Mon Sep 17 00:00:00 2001 From: Eric Olsen Date: Sat, 5 Oct 2019 00:29:57 -0600 Subject: [PATCH] cleaned-up whitespace formatting to match the rest (tabs instead of spaces) --- CookieMonster.js | 30 +++++++++++++++--------------- src/Config.js | 2 +- src/Disp.js | 20 ++++++++++---------- src/Main.js | 8 ++++---- 4 files changed, 30 insertions(+), 30 deletions(-) diff --git a/CookieMonster.js b/CookieMonster.js index ab60b8b..e82666d 100644 --- a/CookieMonster.js +++ b/CookieMonster.js @@ -546,7 +546,7 @@ CM.ConfigData.FortuneFlash = {label: ['Fortune Cookie Flash OFF', 'Fortune Cooki CM.ConfigData.FortuneSound = {label: ['Fortune Cookie Sound OFF', 'Fortune Cookie Sound ON'], desc: 'Play a sound on Fortune Cookie', toggle: true}; CM.ConfigData.FortuneVolume = {label: [], desc: 'Volume of the Fortune Cookie sound'}; for (var i = 0; i < 101; i++) { - CM.ConfigData.FortuneVolume.label[i] = i + '%'; + CM.ConfigData.FortuneVolume.label[i] = i + '%'; } CM.ConfigData.FortuneSoundURL = {label: 'Fortune Cookie Sound URL:', desc: 'URL of the sound to be played when the Ticker has a Fortune Cookie'}; CM.ConfigData.SeaFlash = {label: ['Season Special Flash OFF', 'Season Special Flash ON'], desc: 'Flash screen on Season Popup', toggle: true}; @@ -1457,13 +1457,13 @@ CM.Disp.CheckGoldenCookie = function() { } CM.Disp.CheckTickerFortune = function() { - if (CM.Disp.lastTickerFortuneState != (Game.TickerEffect && Game.TickerEffect.type == 'fortune')) { - CM.Disp.lastTickerFortuneState = (Game.TickerEffect && Game.TickerEffect.type == 'fortune'); - if (CM.Disp.lastTickerFortuneState) { - CM.Disp.Flash(3, 'FortuneFlash'); - CM.Disp.PlaySound(CM.Config.FortuneSoundURL, 'FortuneSound', 'FortuneVolume'); - } - } + if (CM.Disp.lastTickerFortuneState != (Game.TickerEffect && Game.TickerEffect.type == 'fortune')) { + CM.Disp.lastTickerFortuneState = (Game.TickerEffect && Game.TickerEffect.type == 'fortune'); + if (CM.Disp.lastTickerFortuneState) { + CM.Disp.Flash(3, 'FortuneFlash'); + CM.Disp.PlaySound(CM.Config.FortuneSoundURL, 'FortuneSound', 'FortuneVolume'); + } + } } CM.Disp.CheckSeasonPopup = function() { @@ -1709,9 +1709,9 @@ CM.Disp.AddMenuPref = function(title) { frag.appendChild(listing('GCTimer')); frag.appendChild(listing('Favicon')); frag.appendChild(listing('FortuneFlash')); - frag.appendChild(listing('FortuneSound')); - frag.appendChild(vol('FortuneVolume')); - frag.appendChild(url('FortuneSoundURL')); + frag.appendChild(listing('FortuneSound')); + frag.appendChild(vol('FortuneVolume')); + frag.appendChild(url('FortuneSoundURL')); frag.appendChild(listing('SeaFlash')); frag.appendChild(listing('SeaSound')); frag.appendChild(vol('SeaVolume')); @@ -2926,10 +2926,10 @@ CM.ConfigDefault = { GCSoundURL: 'https://freesound.org/data/previews/66/66717_931655-lq.mp3', GCTimer: 1, Favicon: 1, - FortuneFlash: 1, - FortuneSound: 1, - FortuneVolume: 100, - FortuneSoundURL: 'https://freesound.org/data/previews/419/419594_7062176-lq.mp3', + FortuneFlash: 1, + FortuneSound: 1, + FortuneVolume: 100, + FortuneSoundURL: 'https://freesound.org/data/previews/419/419594_7062176-lq.mp3', SeaFlash: 1, SeaSound: 1, SeaVolume: 100, diff --git a/src/Config.js b/src/Config.js index a75f8f8..1598ebf 100644 --- a/src/Config.js +++ b/src/Config.js @@ -152,7 +152,7 @@ CM.ConfigData.FortuneFlash = {label: ['Fortune Cookie Flash OFF', 'Fortune Cooki CM.ConfigData.FortuneSound = {label: ['Fortune Cookie Sound OFF', 'Fortune Cookie Sound ON'], desc: 'Play a sound on Fortune Cookie', toggle: true}; CM.ConfigData.FortuneVolume = {label: [], desc: 'Volume of the Fortune Cookie sound'}; for (var i = 0; i < 101; i++) { - CM.ConfigData.FortuneVolume.label[i] = i + '%'; + CM.ConfigData.FortuneVolume.label[i] = i + '%'; } CM.ConfigData.FortuneSoundURL = {label: 'Fortune Cookie Sound URL:', desc: 'URL of the sound to be played when the Ticker has a Fortune Cookie'}; CM.ConfigData.SeaFlash = {label: ['Season Special Flash OFF', 'Season Special Flash ON'], desc: 'Flash screen on Season Popup', toggle: true}; diff --git a/src/Disp.js b/src/Disp.js index c8f98be..63caeba 100644 --- a/src/Disp.js +++ b/src/Disp.js @@ -870,13 +870,13 @@ CM.Disp.CheckGoldenCookie = function() { } CM.Disp.CheckTickerFortune = function() { - if (CM.Disp.lastTickerFortuneState != (Game.TickerEffect && Game.TickerEffect.type == 'fortune')) { - CM.Disp.lastTickerFortuneState = (Game.TickerEffect && Game.TickerEffect.type == 'fortune'); - if (CM.Disp.lastTickerFortuneState) { - CM.Disp.Flash(3, 'FortuneFlash'); - CM.Disp.PlaySound(CM.Config.FortuneSoundURL, 'FortuneSound', 'FortuneVolume'); - } - } + if (CM.Disp.lastTickerFortuneState != (Game.TickerEffect && Game.TickerEffect.type == 'fortune')) { + CM.Disp.lastTickerFortuneState = (Game.TickerEffect && Game.TickerEffect.type == 'fortune'); + if (CM.Disp.lastTickerFortuneState) { + CM.Disp.Flash(3, 'FortuneFlash'); + CM.Disp.PlaySound(CM.Config.FortuneSoundURL, 'FortuneSound', 'FortuneVolume'); + } + } } CM.Disp.CheckSeasonPopup = function() { @@ -1122,9 +1122,9 @@ CM.Disp.AddMenuPref = function(title) { frag.appendChild(listing('GCTimer')); frag.appendChild(listing('Favicon')); frag.appendChild(listing('FortuneFlash')); - frag.appendChild(listing('FortuneSound')); - frag.appendChild(vol('FortuneVolume')); - frag.appendChild(url('FortuneSoundURL')); + frag.appendChild(listing('FortuneSound')); + frag.appendChild(vol('FortuneVolume')); + frag.appendChild(url('FortuneSoundURL')); frag.appendChild(listing('SeaFlash')); frag.appendChild(listing('SeaSound')); frag.appendChild(vol('SeaVolume')); diff --git a/src/Main.js b/src/Main.js index 75c5bb7..8181f9a 100644 --- a/src/Main.js +++ b/src/Main.js @@ -269,10 +269,10 @@ CM.ConfigDefault = { GCSoundURL: 'https://freesound.org/data/previews/66/66717_931655-lq.mp3', GCTimer: 1, Favicon: 1, - FortuneFlash: 1, - FortuneSound: 1, - FortuneVolume: 100, - FortuneSoundURL: 'https://freesound.org/data/previews/419/419594_7062176-lq.mp3', + FortuneFlash: 1, + FortuneSound: 1, + FortuneVolume: 100, + FortuneSoundURL: 'https://freesound.org/data/previews/419/419594_7062176-lq.mp3', SeaFlash: 1, SeaSound: 1, SeaVolume: 100,