From 7dc979d2b49ff73201235cfe428bbeec94d44180 Mon Sep 17 00:00:00 2001 From: ozh Date: Sun, 27 Oct 2019 13:54:56 +0100 Subject: Update to 2.021 per request Closes #3 --- img/BGgarden.jpg | Bin 0 -> 21834 bytes img/BGgrimoire.jpg | Bin 0 -> 20106 bytes img/BGpantheon.jpg | Bin 0 -> 25184 bytes img/brownStripes.png | Bin 0 -> 2001 bytes img/brownStripesLeftEdge.png | Bin 0 -> 1174 bytes img/buildings.png | Bin 34608 -> 38213 bytes img/discord.png | Bin 0 -> 2357 bytes img/dragon.png | Bin 5391 -> 6206 bytes img/dungeonDot.png | Bin 0 -> 3323 bytes img/dungeonFoes.png | Bin 0 -> 1916 bytes img/dungeonHeroes.png | Bin 0 -> 2431 bytes img/dungeonItems.png | Bin 0 -> 1387 bytes img/dungeonMapFactory.jpg | Bin 0 -> 14091 bytes img/dungeonPictos.png | Bin 0 -> 1909 bytes img/fractalEngine.png | Bin 0 -> 1282 bytes img/fractalEngineBackground.png | Bin 0 -> 4555 bytes img/gardenPlants.png | Bin 0 -> 20690 bytes img/gardenPlots.png | Bin 0 -> 9857 bytes img/gardenTip.png | Bin 0 -> 14192 bytes img/heraldFlag.png | Bin 0 -> 3725 bytes img/icons.png | Bin 105346 -> 151269 bytes img/index.html | 259 ++ img/javascriptconsole.png | Bin 0 -> 1456 bytes img/javascriptconsoleBackground.png | Bin 0 -> 6870 bytes img/linkDash.png | Bin 0 -> 1007 bytes img/list.txt | 36 + img/lockOff.png | Bin 0 -> 1203 bytes img/lockOn.png | Bin 0 -> 1180 bytes img/metaGrandma.png | Bin 0 -> 1606 bytes img/milkCherry.png | Bin 0 -> 24483 bytes img/milkCoconut.png | Bin 0 -> 30779 bytes img/milkCoffee.png | Bin 0 -> 19430 bytes img/milkMaple.png | Bin 0 -> 19970 bytes img/milkMint.png | Bin 0 -> 40730 bytes img/milkSoy.png | Bin 0 -> 22040 bytes img/milkSpiced.png | Bin 0 -> 76835 bytes img/milkTea.png | Bin 0 -> 19164 bytes img/patreon.png | Bin 0 -> 2413 bytes img/pointyLad.png | Bin 0 -> 1876 bytes img/scriptGrandma.png | Bin 0 -> 693 bytes img/turnInto.png | Bin 0 -> 1574 bytes index.html | 125 +- list.txt | 8 +- main.js | 5014 +++++++++++++++++++++++++---------- minigameGarden.js | 2018 ++++++++++++++ minigameGrimoire.js | 34 +- minigamePantheon.js | 97 +- snd/fortune.mp3 | Bin 0 -> 20348 bytes snd/freezeGarden.mp3 | Bin 0 -> 16512 bytes snd/harvest1.mp3 | Bin 0 -> 6272 bytes snd/harvest2.mp3 | Bin 0 -> 6272 bytes snd/harvest3.mp3 | Bin 0 -> 5760 bytes snd/index.html | 77 + snd/list.txt | 67 + snd/till1.mp3 | Bin 0 -> 5760 bytes snd/till2.mp3 | Bin 0 -> 5248 bytes snd/till3.mp3 | Bin 0 -> 5760 bytes snd/tillb1.mp3 | Bin 0 -> 5023 bytes snd/tillb2.mp3 | Bin 0 -> 5248 bytes snd/tillb3.mp3 | Bin 0 -> 6272 bytes snd/toneTick.mp3 | Bin 0 -> 3712 bytes style.css | 359 ++- 62 files changed, 6526 insertions(+), 1568 deletions(-) create mode 100644 img/BGgarden.jpg create mode 100644 img/BGgrimoire.jpg create mode 100644 img/BGpantheon.jpg create mode 100644 img/brownStripes.png create mode 100644 img/brownStripesLeftEdge.png create mode 100644 img/discord.png create mode 100644 img/dungeonDot.png create mode 100644 img/dungeonFoes.png create mode 100644 img/dungeonHeroes.png create mode 100644 img/dungeonItems.png create mode 100644 img/dungeonMapFactory.jpg create mode 100644 img/dungeonPictos.png create mode 100644 img/fractalEngine.png create mode 100644 img/fractalEngineBackground.png create mode 100644 img/gardenPlants.png create mode 100644 img/gardenPlots.png create mode 100644 img/gardenTip.png create mode 100644 img/heraldFlag.png create mode 100644 img/index.html create mode 100644 img/javascriptconsole.png create mode 100644 img/javascriptconsoleBackground.png create mode 100644 img/linkDash.png create mode 100644 img/lockOff.png create mode 100644 img/lockOn.png create mode 100644 img/metaGrandma.png create mode 100644 img/milkCherry.png create mode 100644 img/milkCoconut.png create mode 100644 img/milkCoffee.png create mode 100644 img/milkMaple.png create mode 100644 img/milkMint.png create mode 100644 img/milkSoy.png create mode 100644 img/milkSpiced.png create mode 100644 img/milkTea.png create mode 100644 img/patreon.png create mode 100644 img/pointyLad.png create mode 100644 img/scriptGrandma.png create mode 100644 img/turnInto.png create mode 100644 minigameGarden.js create mode 100644 snd/fortune.mp3 create mode 100644 snd/freezeGarden.mp3 create mode 100644 snd/harvest1.mp3 create mode 100644 snd/harvest2.mp3 create mode 100644 snd/harvest3.mp3 create mode 100644 snd/index.html create mode 100644 snd/list.txt create mode 100644 snd/till1.mp3 create mode 100644 snd/till2.mp3 create mode 100644 snd/till3.mp3 create mode 100644 snd/tillb1.mp3 create mode 100644 snd/tillb2.mp3 create mode 100644 snd/tillb3.mp3 create mode 100644 snd/toneTick.mp3 diff --git a/img/BGgarden.jpg b/img/BGgarden.jpg new file mode 100644 index 0000000..4b37afd Binary files /dev/null and b/img/BGgarden.jpg differ diff --git a/img/BGgrimoire.jpg b/img/BGgrimoire.jpg new file mode 100644 index 0000000..4150eb6 Binary files /dev/null and b/img/BGgrimoire.jpg differ diff --git a/img/BGpantheon.jpg b/img/BGpantheon.jpg new file mode 100644 index 0000000..4c19974 Binary files /dev/null and b/img/BGpantheon.jpg differ diff --git a/img/brownStripes.png b/img/brownStripes.png new file mode 100644 index 0000000..bb97485 Binary files /dev/null and b/img/brownStripes.png differ diff --git a/img/brownStripesLeftEdge.png b/img/brownStripesLeftEdge.png new file mode 100644 index 0000000..4b15e46 Binary files /dev/null and b/img/brownStripesLeftEdge.png differ diff --git a/img/buildings.png b/img/buildings.png index 2a66495..95ab994 100644 Binary files a/img/buildings.png and b/img/buildings.png differ diff --git a/img/discord.png b/img/discord.png new file mode 100644 index 0000000..92efeef Binary files /dev/null and b/img/discord.png differ diff --git a/img/dragon.png b/img/dragon.png index 4b5159e..e0dcc82 100644 Binary files a/img/dragon.png and b/img/dragon.png differ diff --git a/img/dungeonDot.png b/img/dungeonDot.png new file mode 100644 index 0000000..7eb7697 Binary files /dev/null and b/img/dungeonDot.png differ diff --git a/img/dungeonFoes.png b/img/dungeonFoes.png new file mode 100644 index 0000000..c48d686 Binary files /dev/null and b/img/dungeonFoes.png differ diff --git a/img/dungeonHeroes.png b/img/dungeonHeroes.png new file mode 100644 index 0000000..c3eff48 Binary files /dev/null and b/img/dungeonHeroes.png differ diff --git a/img/dungeonItems.png b/img/dungeonItems.png new file mode 100644 index 0000000..d23b951 Binary files /dev/null and b/img/dungeonItems.png differ diff --git a/img/dungeonMapFactory.jpg b/img/dungeonMapFactory.jpg new file mode 100644 index 0000000..e2d9b19 Binary files /dev/null and b/img/dungeonMapFactory.jpg differ diff --git a/img/dungeonPictos.png b/img/dungeonPictos.png new file mode 100644 index 0000000..fbe4884 Binary files /dev/null and b/img/dungeonPictos.png differ diff --git a/img/fractalEngine.png b/img/fractalEngine.png new file mode 100644 index 0000000..c532693 Binary files /dev/null and b/img/fractalEngine.png differ diff --git a/img/fractalEngineBackground.png b/img/fractalEngineBackground.png new file mode 100644 index 0000000..f0dda75 Binary files /dev/null and b/img/fractalEngineBackground.png differ diff --git a/img/gardenPlants.png b/img/gardenPlants.png new file mode 100644 index 0000000..675208b Binary files /dev/null and b/img/gardenPlants.png differ diff --git a/img/gardenPlots.png b/img/gardenPlots.png new file mode 100644 index 0000000..88de74b Binary files /dev/null and b/img/gardenPlots.png differ diff --git a/img/gardenTip.png b/img/gardenTip.png new file mode 100644 index 0000000..dca82d8 Binary files /dev/null and b/img/gardenTip.png differ diff --git a/img/heraldFlag.png b/img/heraldFlag.png new file mode 100644 index 0000000..9112a53 Binary files /dev/null and b/img/heraldFlag.png differ diff --git a/img/icons.png b/img/icons.png index c141023..3ac6e06 100644 Binary files a/img/icons.png and b/img/icons.png differ diff --git a/img/index.html b/img/index.html new file mode 100644 index 0000000..c695b2f --- /dev/null +++ b/img/index.html @@ -0,0 +1,259 @@ + + + + Index of /cookieclicker/img + + +

Index of /cookieclicker/img

+
Icon  Name                    Last modified      Size  Description
[PARENTDIR] Parent Directory - +[IMG] BGgarden.jpg 2018-03-08 23:42 21K +[IMG] BGgrimoire.jpg 2018-03-08 21:17 20K +[IMG] BGpantheon.jpg 2018-03-08 21:13 25K +[   ] Thumbs.db 2017-11-24 00:23 1.9M +[IMG] alchemylab.png 2013-12-28 23:56 820 +[IMG] alchemylabBackground..> 2013-12-28 23:56 472 +[IMG] alteredGrandma.png 2013-12-28 23:56 470 +[IMG] antiGrandma.png 2013-12-28 23:56 526 +[IMG] antimattercondenser.png 2013-12-28 23:56 666 +[IMG] antimattercondenserB..> 2013-12-28 23:56 966 +[IMG] aqworldsbanner.jpg 2013-12-29 16:33 29K +[IMG] ascendBox.png 2015-12-20 11:28 22K +[IMG] ascendInfo.png 2015-12-20 11:29 11K +[IMG] ascendSlot.png 2015-04-17 10:36 14K +[IMG] ascendWisp.png 2014-08-25 07:44 42K +[IMG] ascendedBakingPod.png 2013-12-28 23:56 1.7K +[IMG] bank.png 2014-08-08 16:58 501 +[IMG] bankBackground.png 2014-08-08 12:53 2.2K +[IMG] bankGrandma.png 2014-08-08 17:59 614 +[IMG] bgBlack.jpg 2017-06-30 05:53 28K +[IMG] bgBlue.jpg 2017-06-30 05:48 60K +[IMG] bgGold.jpg 2017-06-30 05:54 72K +[IMG] bgMoney.jpg 2014-03-31 23:00 69K +[IMG] bgMoneyChart.jpg 2014-03-31 23:40 9.7K +[IMG] bgRed.jpg 2017-06-30 05:51 32K +[IMG] bgWhite.jpg 2017-06-30 05:53 56K +[IMG] blackGradient.png 2013-12-28 23:56 561 +[IMG] blackGradientLeft.png 2015-12-20 14:19 1.2K +[IMG] blackGradientSmallTo..> 2014-08-14 22:21 971 +[IMG] bracketPanelLeftS.png 2015-12-12 19:05 2.2K +[IMG] bracketPanelRightS.png 2015-12-12 19:05 2.3K +[IMG] brokenCookie.png 2015-10-25 03:35 36K +[IMG] brokenCookieHalo.png 2014-08-15 01:04 22K +[IMG] brownStripes.png 2018-08-06 05:35 2.0K +[IMG] brownStripesLeftEdge..> 2018-08-06 04:57 1.1K +[IMG] buildings.png 2019-09-01 23:36 37K +[IMG] bunnies.png 2014-04-23 01:46 23K +[IMG] bunnyGrandma.png 2014-05-15 22:13 713 +[IMG] buttonTile.jpg 2013-12-29 16:33 7.6K +[IMG] caramelWave.png 2013-12-28 23:56 11K +[IMG] chancemaker.png 2017-07-30 21:16 1.5K +[IMG] chancemakerBackgroun..> 2017-07-30 21:15 2.6K +[IMG] chocolateMilkWave.png 2013-12-28 23:57 10K +[IMG] clayBG.jpg 2017-06-12 06:40 21K +[IMG] contract.png 2014-03-31 21:50 4.8K +[IMG] control.png 2013-12-28 23:57 48K +[IMG] cookieShower1.png 2013-12-28 23:57 29K +[IMG] cookieShower2.png 2013-12-28 23:57 55K +[IMG] cookieShower3.png 2013-12-28 23:58 76K +[IMG] cosmicGrandma.png 2013-12-28 23:58 616 +[IMG] cursor.png 2015-10-19 00:01 2.2K +[IMG] darkNoise.jpg 2014-08-13 22:11 53K +[IMG] darkNoise.png 2013-12-28 23:58 1.7K +[IMG] darkNoiseTopBar.jpg 2014-08-14 02:22 8.3K +[IMG] discord.png 2018-02-20 22:15 2.3K +[IMG] dragon.png 2018-10-17 02:45 6.1K +[IMG] dragonBG.png 2015-09-25 22:02 21K +[IMG] dragonFrame.png 2015-03-31 02:41 2.0K +[IMG] dungeonDot.png 2018-09-11 17:06 3.2K +[IMG] dungeonFactory.png 2013-12-28 23:58 2.3K +[IMG] dungeonFoes.png 2018-10-06 20:37 1.9K +[IMG] dungeonHeroes.png 2018-10-06 15:56 2.4K +[IMG] dungeonIcons.png 2013-12-28 23:58 4.3K +[IMG] dungeonItems.png 2018-09-18 21:38 1.4K +[IMG] dungeonMapFactory.jpg 2018-08-06 00:43 14K +[IMG] dungeonOverlay.png 2013-12-28 23:58 13K +[IMG] dungeonPictos.png 2018-10-07 11:21 1.9K +[IMG] dungeonTiles.png 2013-12-28 23:58 3.4K +[IMG] easterEggs.png 2014-04-23 02:06 6.4K +[IMG] elfGrandma.png 2013-12-28 23:58 622 +[IMG] empty.png 2013-12-28 23:58 95 +[IMG] emptyFrame.png 2015-08-28 07:01 3.5K +[IMG] factory.png 2013-12-28 23:58 477 +[IMG] factoryBackground.png 2013-12-28 23:58 1.3K +[IMG] farm.png 2013-12-28 23:58 765 +[IMG] farmBackground.png 2013-12-28 23:58 812 +[IMG] farmerGrandma.png 2013-12-28 23:58 615 +[IMG] favicon.ico 2013-09-02 18:44 318 +[IMG] featherLeft.png 2015-12-13 00:27 2.9K +[IMG] featherRight.png 2015-12-13 00:27 2.9K +[IMG] filler.png 2014-04-11 22:27 953 +[IMG] fractalEngine.png 2018-10-17 19:44 1.3K +[IMG] fractalEngineBackgro..> 2018-10-17 19:47 4.4K +[IMG] frameBorder.png 2015-08-27 05:33 1.0K +[IMG] frostedReindeer.png 2013-12-28 23:58 9.7K +[IMG] gardenPlants.png 2018-04-15 07:14 20K +[IMG] gardenPlots.png 2018-04-08 20:41 9.6K +[IMG] gardenTip.png 2018-07-20 08:47 14K +[IMG] girlscoutChip.png 2013-12-28 23:58 751 +[IMG] girlscoutCrumb.png 2013-12-28 23:58 738 +[IMG] girlscoutDoe.png 2013-12-28 23:58 762 +[IMG] girlscoutLucky.png 2013-12-28 23:58 754 +[IMG] glint.jpg 2015-12-23 11:41 1.8K +[IMG] goldCookie.png 2013-12-28 23:58 4.0K +[IMG] grandma.png 2013-12-28 23:58 571 +[IMG] grandmaBackground.png 2013-12-28 23:58 837 +[IMG] grandmas1.jpg 2013-12-29 16:33 21K +[IMG] grandmas2.jpg 2013-12-29 16:33 17K +[IMG] grandmas3.jpg 2013-12-29 16:33 26K +[IMG] grandmasGrandma.png 2013-12-28 23:58 619 +[IMG] grimoireBG.png 2017-06-30 07:29 25K +[IMG] heartStorm.png 2014-02-10 02:59 64K +[IMG] hearts.png 2014-02-10 02:54 23K +[IMG] heavenRing1.jpg 2015-12-20 08:37 4.0K +[IMG] heavenRing2.jpg 2015-12-20 08:37 4.0K +[IMG] heavenlyMoney.png 2015-05-14 09:16 1.1K +[IMG] heraldFlag.png 2018-10-09 18:47 3.6K +[IMG] icons.png 2019-09-22 18:07 148K +[IMG] imperfectCookie.png 2013-12-28 23:59 94K +[IMG] infoBG.png 2013-12-28 23:59 94 +[IMG] infoBGfade.png 2013-12-28 23:59 276 +[IMG] javascriptconsole.png 2019-09-16 04:40 1.4K +[IMG] javascriptconsoleBac..> 2019-09-16 04:35 6.7K +[IMG] levelUp.png 2017-06-05 05:50 2.0K +[IMG] linkDash.png 2018-08-06 03:23 1.0K +[IMG] linkPulse.gif 2016-02-03 18:16 4.2K +[IMG] linkPulse.png 2014-08-24 11:41 1.6K +[IMG] lockOff.png 2019-09-16 05:06 1.2K +[IMG] lockOn.png 2019-09-16 05:06 1.2K +[IMG] luckyGrandma.png 2017-07-29 23:28 713 +[IMG] mapBG.jpg 2013-12-29 16:33 13K +[IMG] mapIcons.png 2013-12-28 23:59 664 +[IMG] marbleBG.jpg 2017-06-12 11:05 31K +[IMG] marshmallows.png 2013-12-28 23:59 2.6K +[IMG] metaGrandma.png 2018-10-18 22:00 1.6K +[IMG] milk.png 2013-12-29 00:00 6.3K +[IMG] milkBanana.png 2015-09-20 13:09 43K +[IMG] milkBlack.png 2015-10-14 12:19 47K +[IMG] milkBlood.png 2015-10-14 12:13 62K +[IMG] milkBlueFire.png 2015-10-15 13:32 78K +[IMG] milkBlueberry.png 2015-09-20 13:09 42K +[IMG] milkCaramel.png 2015-09-20 13:09 41K +[IMG] milkCherry.png 2018-03-31 09:34 24K +[IMG] milkChocolate.png 2015-09-20 13:08 40K +[IMG] milkCoconut.png 2018-03-31 09:34 30K +[IMG] milkCoffee.png 2018-03-31 08:59 19K +[IMG] milkFire.png 2015-10-14 12:53 67K +[IMG] milkGold.png 2015-10-14 12:17 58K +[IMG] milkGreenFire.png 2015-10-15 13:31 71K +[IMG] milkHoney.png 2017-07-30 02:14 21K +[IMG] milkLime.png 2015-09-20 13:09 42K +[IMG] milkMaple.png 2018-10-21 21:02 20K +[IMG] milkMint.png 2019-09-11 03:06 40K +[IMG] milkOrange.png 2015-09-20 13:08 42K +[IMG] milkPlain.png 2015-09-20 13:08 43K +[IMG] milkRaspberry.png 2015-09-20 13:08 40K +[IMG] milkSoy.png 2018-03-31 09:34 22K +[IMG] milkSpiced.png 2018-04-16 18:17 75K +[IMG] milkStars.png 2015-10-13 23:08 52K +[IMG] milkStrawberry.png 2015-09-20 13:10 40K +[IMG] milkTea.png 2018-03-31 09:06 19K +[IMG] milkVanilla.png 2015-09-20 13:11 43K +[IMG] milkWave.png 2013-12-29 00:00 16K +[IMG] milkZebra.png 2015-10-14 21:48 69K +[IMG] mine.png 2013-12-29 00:00 668 +[IMG] mineBackground.png 2013-12-29 00:00 1.0K +[IMG] minerGrandma.png 2013-12-29 00:00 626 +[IMG] money.png 2013-12-29 00:00 280 +[IMG] mysticBG.jpg 2017-06-12 11:19 22K +[IMG] nest.png 2014-05-16 17:44 15K +[IMG] orangeWave.png 2013-12-29 00:01 11K +[IMG] panelBG.png 2015-04-02 16:57 27K +[IMG] panelGradientBottom.png 2015-10-08 08:43 1.0K +[IMG] panelGradientLeft.png 2015-10-08 08:43 1.0K +[IMG] panelGradientRight.png 2015-10-08 08:44 1.0K +[IMG] panelGradientTop.png 2015-10-08 08:43 1.0K +[IMG] panelHorizontal.png 2015-08-28 06:14 6.6K +[IMG] panelMenu.png 2014-08-24 01:03 19K +[IMG] panelMenu2.png 2015-04-18 11:59 36K +[IMG] panelMenu3.png 2015-08-28 15:07 49K +[IMG] panelVertical.png 2015-08-28 06:14 7.0K +[IMG] pantheonBG.png 2017-06-30 07:51 25K +[IMG] patreon.png 2018-10-10 10:03 2.4K +[IMG] perfectCookie.png 2013-12-29 00:01 96K +[IMG] pieFill.png 2015-10-16 01:43 11K +[IMG] pointyLad.png 2018-04-14 20:55 1.8K +[IMG] portal.png 2013-12-29 00:01 1.0K +[IMG] portalBackground.png 2013-12-29 00:01 3.6K +[IMG] portraitChip.png 2013-12-29 00:01 940 +[IMG] portraitCrumb.png 2013-12-29 00:01 967 +[IMG] portraitDoe.png 2013-12-29 00:01 1.0K +[IMG] portraitLucky.png 2013-12-29 00:01 1.0K +[IMG] prestigeBar.jpg 2015-12-20 17:56 2.4K +[IMG] prestigeBarCap.png 2015-12-20 17:58 1.0K +[IMG] prism.png 2014-02-13 12:48 782 +[IMG] prismBackground.png 2014-02-13 10:31 701 +[IMG] rainbowGrandma.png 2014-02-13 11:07 626 +[IMG] raspberryWave.png 2013-12-29 00:02 10K +[IMG] roundFrameBorder.png 2015-08-27 08:49 1.1K +[IMG] roundedPanelBG.png 2015-12-11 01:01 7.1K +[IMG] roundedPanelBGS.png 2015-12-12 18:45 21K +[IMG] roundedPanelLeft.png 2015-12-11 00:59 2.5K +[IMG] roundedPanelLeftS.png 2015-12-12 18:44 2.4K +[IMG] roundedPanelRight.png 2015-12-11 01:00 2.5K +[IMG] roundedPanelRightS.png 2015-12-12 18:44 2.6K +[IMG] santa.png 2013-12-29 00:02 9.3K +[IMG] scriptGrandma.png 2019-09-03 16:43 693 +[IMG] sentientFurnace.png 2013-12-29 00:02 1.6K +[IMG] shadedBorders.png 2015-11-01 19:55 12K +[IMG] shadedBordersGold.png 2013-12-29 00:02 2.3K +[IMG] shadedBordersRed.png 2013-12-29 00:02 2.3K +[IMG] shadedBordersSoft.png 2015-11-11 06:51 3.4K +[IMG] shine.png 2013-12-29 00:02 6.0K +[IMG] shineGold.png 2017-06-30 18:07 7.8K +[IMG] shineRed.png 2017-06-30 18:09 7.8K +[IMG] shineSpoke.png 2015-10-31 12:28 6.2K +[IMG] shinyWrinkler.png 2015-04-15 07:11 5.8K +[IMG] shinyWrinklerBits.png 2015-04-15 07:10 7.9K +[IMG] shipment.png 2013-12-29 00:02 507 +[IMG] shipmentBackground.png 2013-12-29 00:02 923 +[IMG] smallCookies.png 2013-12-29 00:02 14K +[IMG] smallDollars.png 2014-04-01 18:15 5.5K +[IMG] snow.jpg 2013-12-29 16:33 47K +[IMG] snow2.jpg 2013-12-29 16:33 71K +[IMG] sparkles.jpg 2015-10-13 12:54 16K +[IMG] spellBG.png 2017-06-08 09:54 33K +[IMG] spinnyBig.png 2015-10-24 02:38 5.3K +[IMG] spinnySmall.png 2015-10-24 02:38 2.7K +[IMG] spookyCookie.png 2013-12-29 00:02 4.3K +[IMG] starbg.jpg 2014-08-03 05:54 188K +[IMG] storeTile.jpg 2013-12-29 16:33 18K +[IMG] sugarLump.png 2017-06-05 05:27 1.1K +[IMG] temple.png 2014-08-08 16:59 752 +[IMG] templeBackground.png 2014-08-08 11:02 2.5K +[IMG] templeGrandma.png 2014-08-08 18:00 742 +[IMG] timemachine.png 2013-12-29 00:02 773 +[IMG] timemachineBackgroun..> 2013-12-29 00:02 1.2K +[IMG] timerBars.png 2014-02-10 05:26 2.3K +[IMG] transmutedGrandma.png 2013-12-29 00:02 449 +[IMG] turnInto.png 2018-03-13 16:34 1.5K +[IMG] upgradeFrame.png 2016-04-19 07:17 20K +[IMG] upgradeFrameHeavenly..> 2014-08-24 08:51 2.7K +[IMG] upgradeFrameOld.png 2015-04-18 10:45 7.3K +[IMG] upgradeFrameShadowOl..> 2015-05-14 09:06 7.0K +[IMG] upgradeHighlight.jpg 2015-10-15 18:08 4.3K +[IMG] upgradeHighlight.png 2015-10-15 18:08 5.4K +[IMG] upgradeSelector.png 2015-10-14 22:52 1.0K +[IMG] weeHoodie.png 2015-10-24 09:51 2.6K +[IMG] winterFrame.png 2015-03-30 23:49 1.9K +[IMG] winterWrinkler.png 2013-12-29 00:02 5.8K +[IMG] witchGrandma.png 2014-08-08 18:00 779 +[IMG] wizardtower.png 2014-08-08 16:59 864 +[IMG] wizardtowerBackgroun..> 2014-08-08 18:10 1.6K +[IMG] workerGrandma.png 2013-12-29 00:02 534 +[IMG] wrathContract.png 2014-03-31 21:57 5.1K +[IMG] wrathCookie.png 2013-12-29 00:02 4.8K +[IMG] wrinkler.png 2013-12-29 00:02 5.8K +[IMG] wrinklerBits.png 2015-04-15 03:51 8.1K +[IMG] wrinklerBitsOld.png 2013-12-29 00:02 6.4K +
+ diff --git a/img/javascriptconsole.png b/img/javascriptconsole.png new file mode 100644 index 0000000..bfae81a Binary files /dev/null and b/img/javascriptconsole.png differ diff --git a/img/javascriptconsoleBackground.png b/img/javascriptconsoleBackground.png new file mode 100644 index 0000000..f5fdf9e Binary files /dev/null and b/img/javascriptconsoleBackground.png differ diff --git a/img/linkDash.png b/img/linkDash.png new file mode 100644 index 0000000..098016a Binary files /dev/null and b/img/linkDash.png differ diff --git a/img/list.txt b/img/list.txt index a2fcfb5..d2ff761 100644 --- a/img/list.txt +++ b/img/list.txt @@ -1,3 +1,6 @@ +BGgarden.jpg +BGgrimoire.jpg +BGpantheon.jpg alchemylab.png alchemylabBackground.png alteredGrandma.png @@ -27,6 +30,8 @@ bracketPanelLeftS.png bracketPanelRightS.png brokenCookie.png brokenCookieHalo.png +brownStripes.png +brownStripesLeftEdge.png buildings.png bunnies.png bunnyGrandma.png @@ -46,12 +51,19 @@ cursor.png darkNoise.jpg darkNoise.png darkNoiseTopBar.jpg +discord.png dragon.png dragonBG.png dragonFrame.png +dungeonDot.png dungeonFactory.png +dungeonFoes.png +dungeonHeroes.png dungeonIcons.png +dungeonItems.png +dungeonMapFactory.jpg dungeonOverlay.png +dungeonPictos.png dungeonTiles.png easterEggs.png elfGrandma.png @@ -66,8 +78,13 @@ favicon.ico featherLeft.png featherRight.png filler.png +fractalEngine.png +fractalEngineBackground.png frameBorder.png frostedReindeer.png +gardenPlants.png +gardenPlots.png +gardenTip.png girlscoutChip.png girlscoutCrumb.png girlscoutDoe.png @@ -86,18 +103,25 @@ hearts.png heavenRing1.jpg heavenRing2.jpg heavenlyMoney.png +heraldFlag.png icons.png imperfectCookie.png infoBG.png infoBGfade.png +javascriptconsole.png +javascriptconsoleBackground.png levelUp.png +linkDash.png linkPulse.gif linkPulse.png +lockOff.png +lockOn.png luckyGrandma.png mapBG.jpg mapIcons.png marbleBG.jpg marshmallows.png +metaGrandma.png milk.png milkBanana.png milkBlack.png @@ -105,17 +129,25 @@ milkBlood.png milkBlueFire.png milkBlueberry.png milkCaramel.png +milkCherry.png milkChocolate.png +milkCoconut.png +milkCoffee.png milkFire.png milkGold.png milkGreenFire.png milkHoney.png milkLime.png +milkMaple.png +milkMint.png milkOrange.png milkPlain.png milkRaspberry.png +milkSoy.png +milkSpiced.png milkStars.png milkStrawberry.png +milkTea.png milkVanilla.png milkWave.png milkZebra.png @@ -137,8 +169,10 @@ panelMenu2.png panelMenu3.png panelVertical.png pantheonBG.png +patreon.png perfectCookie.png pieFill.png +pointyLad.png portal.png portalBackground.png portraitChip.png @@ -159,6 +193,7 @@ roundedPanelLeftS.png roundedPanelRight.png roundedPanelRightS.png santa.png +scriptGrandma.png sentientFurnace.png shadedBorders.png shadedBordersGold.png @@ -191,6 +226,7 @@ timemachine.png timemachineBackground.png timerBars.png transmutedGrandma.png +turnInto.png upgradeFrame.png upgradeFrameHeavenly.png upgradeFrameOld.png diff --git a/img/lockOff.png b/img/lockOff.png new file mode 100644 index 0000000..ac153eb Binary files /dev/null and b/img/lockOff.png differ diff --git a/img/lockOn.png b/img/lockOn.png new file mode 100644 index 0000000..f438ecc Binary files /dev/null and b/img/lockOn.png differ diff --git a/img/metaGrandma.png b/img/metaGrandma.png new file mode 100644 index 0000000..6c2e50f Binary files /dev/null and b/img/metaGrandma.png differ diff --git a/img/milkCherry.png b/img/milkCherry.png new file mode 100644 index 0000000..f14b03f Binary files /dev/null and b/img/milkCherry.png differ diff --git a/img/milkCoconut.png b/img/milkCoconut.png new file mode 100644 index 0000000..6657a74 Binary files /dev/null and b/img/milkCoconut.png differ diff --git a/img/milkCoffee.png b/img/milkCoffee.png new file mode 100644 index 0000000..7df56fd Binary files /dev/null and b/img/milkCoffee.png differ diff --git a/img/milkMaple.png b/img/milkMaple.png new file mode 100644 index 0000000..22e175e Binary files /dev/null and b/img/milkMaple.png differ diff --git a/img/milkMint.png b/img/milkMint.png new file mode 100644 index 0000000..6c0ef50 Binary files /dev/null and b/img/milkMint.png differ diff --git a/img/milkSoy.png b/img/milkSoy.png new file mode 100644 index 0000000..e5238ce Binary files /dev/null and b/img/milkSoy.png differ diff --git a/img/milkSpiced.png b/img/milkSpiced.png new file mode 100644 index 0000000..77ae350 Binary files /dev/null and b/img/milkSpiced.png differ diff --git a/img/milkTea.png b/img/milkTea.png new file mode 100644 index 0000000..2f3696b Binary files /dev/null and b/img/milkTea.png differ diff --git a/img/patreon.png b/img/patreon.png new file mode 100644 index 0000000..dc97ff0 Binary files /dev/null and b/img/patreon.png differ diff --git a/img/pointyLad.png b/img/pointyLad.png new file mode 100644 index 0000000..020d35b Binary files /dev/null and b/img/pointyLad.png differ diff --git a/img/scriptGrandma.png b/img/scriptGrandma.png new file mode 100644 index 0000000..d3d431e Binary files /dev/null and b/img/scriptGrandma.png differ diff --git a/img/turnInto.png b/img/turnInto.png new file mode 100644 index 0000000..a1b1058 Binary files /dev/null and b/img/turnInto.png differ diff --git a/index.html b/index.html index 1b04997..1f5cf3d 100644 --- a/index.html +++ b/index.html @@ -1,7 +1,7 @@ - @@ -9,35 +9,32 @@ Cookie Clicker + - + + + + + + - - - - - - - - @@ -45,12 +42,17 @@ target-densityDpi=device-dpi"/>
-
Cookie Clicker™ © Orteil, 2017 - DashNet
-
twitter
-
tumblr
-
Help? Bugs? Ideas? Check out the forum!
-
Cookie Clicker merch & stickers!
-
RandomGen
+
Cookie Clicker™ © Orteil, 2019 - DashNet
+
twitter
+
tumblr
+ +
Discord
+
Merch!
+
Patreon
+ +
Cookie Clicker for Android
+
RandomGen
+
Idle Game Maker
'; } + Game.crateTooltip=function(me,context) + { + var tags=[]; + mysterious=0; + var neuromancy=0; + var price=''; + if (context=='stats' && (Game.Has('Neuromancy') || (Game.sesame && me.pool=='debug'))) neuromancy=1; + + if (me.type=='upgrade') + { + if (me.pool=='prestige') tags.push('Heavenly','#efa438'); + else if (me.pool=='tech') tags.push('Tech','#36a4ff'); + else if (me.pool=='cookie') tags.push('Cookie',0); + else if (me.pool=='debug') tags.push('Debug','#00c462'); + else if (me.pool=='toggle') tags.push('Switch',0); + else tags.push('Upgrade',0); + + if (me.tier!=0 && Game.Has('Label printer')) tags.push('Tier : '+Game.Tiers[me.tier].name,Game.Tiers[me.tier].color); + if (me.name=='Label printer' && Game.Has('Label printer')) tags.push('Tier : Self-referential','#ff00ea'); + + if (me.isVaulted()) tags.push('Vaulted','#4e7566'); + + if (me.bought>0) + { + if (me.pool=='tech') tags.push('Researched',0); + else if (me.kitten) tags.push('Purrchased',0); + else tags.push('Purchased',0); + } + + if (me.lasting && me.unlocked) tags.push('Unlocked forever','#f2ff87'); + + if (neuromancy && me.bought==0) tags.push('Click to learn!','#00c462'); + else if (neuromancy && me.bought>0) tags.push('Click to unlearn!','#00c462'); + + var canBuy=(context=='store'?me.canBuy():true); + var cost=me.getPrice(); + if (me.priceLumps>0) cost=me.priceLumps; + + if (me.priceLumps==0 && cost==0) price=''; + else + { + price='
'+Beautify(Math.round(cost))+''+((me.pool!='prestige' && me.priceLumps==0)?Game.costDetails(cost):'')+'
'; + } + } + else if (me.type=='achievement') + { + if (me.pool=='shadow') tags.push('Shadow Achievement','#9700cf'); + else tags.push('Achievement',0); + if (me.won>0) tags.push('Unlocked',0); + else {tags.push('Locked',0);mysterious=1;} + + if (neuromancy && me.won==0) tags.push('Click to win!','#00c462'); + else if (neuromancy && me.won>0) tags.push('Click to lose!','#00c462'); + } + + var tagsStr=''; + for (var i=0;i['+tags[i]+']
'; + } + tagsStr=tagsStr.substring(1); + + var icon=me.icon; + if (mysterious) icon=[0,7]; + + if (me.iconFunction) icon=me.iconFunction(); + + + var tip=''; + if (context=='store') + { + if (me.pool!='toggle' && me.pool!='tech') + { + if (Game.Has('Inspired checklist')) + { + if (me.isVaulted()) tip='Upgrade is vaulted and will not be auto-purchased.
Click to purchase. Shift-click to unvault.'; + else tip='Click to purchase. Shift-click to vault.'; + if (Game.keys[16]) tip+='
(You are holding Shift.)'; + else tip+='
(You are not holding Shift.)'; + } + else tip='Click to purchase.'; + } + else if (me.pool=='toggle' && me.choicesFunction) tip='Click to open selector.'; + else if (me.pool=='toggle') tip='Click to toggle.'; + else if (me.pool=='tech') tip='Click to research.'; + } + + var desc=me.desc; + if (me.descFunc) desc=me.descFunc(); + if (me.bought && context=='store' && me.displayFuncWhenOwned) desc=me.displayFuncWhenOwned()+'
'+desc; + if (me.unlockAt) + { + if (me.unlockAt.require) + { + var it=Game.Upgrades[me.unlockAt.require]; + desc='
From
'+it.name+'
'+desc; + } + /*else if (me.unlockAt.season) + { + var it=Game.seasons[me.unlockAt.season]; + desc='
From
'+it.name+'
'+desc; + }*/ + else if (me.unlockAt.text) + { + var it=Game.Upgrades[me.unlockAt.require]; + desc='
From '+text+'
'+desc; + } + } + + return '
'+ + '
'+ + (me.bought && context=='store'?'':price)+ + '
'+(mysterious?'???':me.name)+'
'+ + tagsStr+ + '
'+(mysterious?'???':desc)+'
'+ + (tip!=''?('
'+tip+'
'):'')+ + (Game.sesame?('
Id : '+me.id+' | Order : '+Math.floor(me.order)+(me.tier?' | Tier : '+me.tier:'')+'
'):''); + } + + Game.costDetails=function(cost) + { + if (!Game.Has('Genius accounting')) return ''; + if (!cost) return ''; + var priceInfo=''; + var cps=Game.cookiesPs*(1-Game.cpsSucked); + if (cost>Game.cookies) priceInfo+='in '+Game.sayTime(((cost-Game.cookies)/cps+1)*Game.fps)+'
'; + priceInfo+=Game.sayTime((cost/cps+1)*Game.fps)+' worth
'; + priceInfo+=Beautify((cost/Game.cookies)*100,1)+'% of bank
'; + return '
'+priceInfo+'
'; + } /*===================================================================================== @@ -2428,7 +3015,8 @@ Game.Launch=function() if (Game.Has('Heavenly bakery')) heavenlyMult+=0.25; if (Game.Has('Heavenly confectionery')) heavenlyMult+=0.25; if (Game.Has('Heavenly key')) heavenlyMult+=0.25; - if (Game.hasAura('Dragon God')) heavenlyMult*=1.05; + //if (Game.hasAura('Dragon God')) heavenlyMult*=1.05; + heavenlyMult*=1+Game.auraMult('Dragon God')*0.05; if (Game.Has('Lucky digit')) heavenlyMult*=1.01; if (Game.Has('Lucky number')) heavenlyMult*=1.01; if (Game.Has('Lucky payout')) heavenlyMult*=1.01; @@ -2444,7 +3032,7 @@ Game.Launch=function() Game.ascensionModes={ 0:{name:'None',desc:'No special modifiers.',icon:[10,0]}, - 1:{name:'Born again',desc:'This run will behave as if you\'d just started the game from scratch. Prestige levels and heavenly upgrades will have no effect, as will sugar lumps and building levels.
Some achievements are only available in this mode.',icon:[2,7]}/*, + 1:{name:'Born again',desc:'This run will behave as if you\'d just started the game from scratch. Prestige levels and heavenly upgrades will have no effect, as will sugar lumps and building levels. Perma-upgrades and minigames will be unavailable.
Some achievements are only available in this mode.',icon:[2,7]}/*, 2:{name:'Trigger finger',desc:'In this run, scrolling your mouse wheel on the cookie counts as clicking it. Some upgrades introduce new clicking behaviors.
No clicking achievements may be obtained in this mode.
Reaching 1 quadrillion cookies in this mode unlocks a special heavenly upgrade.',icon:[12,0]}*/ }; @@ -2602,7 +3190,7 @@ Game.Launch=function() } Game.Ascend=function(bypass) { - if (!bypass) Game.Prompt('

Ascend

Do you REALLY want to ascend?
You will lose your progress and start over from scratch.
All your cookies will be converted into prestige and heavenly chips.
You will keep your achievements'+(Game.resets>0?', building levels and sugar lumps':'')+'.
',[['Yes!','Game.ClosePrompt();Game.Ascend(1);'],'No']); + if (!bypass) Game.Prompt('

Ascend

Do you REALLY want to ascend?
You will lose your progress and start over from scratch.
All your cookies will be converted into prestige and heavenly chips.
You will keep your achievements'+(Game.canLumps()?', building levels and sugar lumps':'')+'.
',[['Yes!','Game.ClosePrompt();Game.Ascend(1);'],'No']); else { if (Game.prefs.popups) Game.Popup('Ascending'); @@ -2881,7 +3469,7 @@ Game.Launch=function() var str='
'+ 'You have '+Beautify(Game.lumps)+' sugar lump'+(Game.lumps==1?'':'s')+'.'+ '
'+ - 'A sugar lump is coalescing here, attracted by your past feats.'; + 'A sugar lump is coalescing here, attracted by your accomplishments.'; var age=Date.now()-Game.lumpT; str+='
'; @@ -2894,15 +3482,16 @@ Game.Launch=function() { if (Game.lumpCurrentType!=0) str+='
'; if (Game.lumpCurrentType==1) str+='This sugar lump grew to be bifurcated; harvesting it has a 50% chance of yielding two lumps.'; - else if (Game.lumpCurrentType==2) str+='This sugar lump grew to be golden; harvesting it will yield 2 to 7 lumps, your current cookies will be doubled, and you will find 10% more golden cookies for the next 24 hours.'; + else if (Game.lumpCurrentType==2) str+='This sugar lump grew to be golden; harvesting it will yield 2 to 7 lumps, your current cookies will be doubled (capped to a gain of 24 hours of your CpS), and you will find 10% more golden cookies for the next 24 hours.'; else if (Game.lumpCurrentType==3) str+='This sugar lump was affected by the elders and grew to be meaty; harvesting it will yield between 0 and 2 lumps.'; + else if (Game.lumpCurrentType==4) str+='This sugar lump is caramelized, its stickiness binding it to unexpected things; harvesting it will yield between 1 and 3 lumps and will refill your sugar lump cooldowns.'; } str+='
'; str+='Your sugar lumps mature after '+Game.sayTime((Game.lumpMatureAge/1000)*Game.fps,-1)+',
ripen after '+Game.sayTime((Game.lumpRipeAge/1000)*Game.fps,-1)+',
and fall after '+Game.sayTime((Game.lumpOverripeAge/1000)*Game.fps,-1)+'.'; str+='
'+ - '• Sugar lumps can be harvested when ripe, though if left alone beyond that point they will eventually fall and be auto-harvested after some time.
• Sugar lumps are delicious and may be used as currency for all sorts of things.
• Once a sugar lump is harvested, another one will start growing in its place.
• Note that sugar lumps keep growing when the game is closed.'; + '• Sugar lumps can be harvested when mature, though if left alone beyond that point they will start ripening (increasing the chance of harvesting them) and will eventually fall and be auto-harvested after some time.
• Sugar lumps are delicious and may be used as currency for all sorts of things.
• Once a sugar lump is harvested, another one will start growing in its place.
• Note that sugar lumps keep growing when the game is closed.'; str+='
'; return str; @@ -2914,6 +3503,8 @@ Game.Launch=function() Game.lumpRipeAge=hour*23; if (Game.Has('Stevia Caelestis')) Game.lumpRipeAge-=hour; if (Game.Has('Diabetica Daemonicus')) Game.lumpMatureAge-=hour; + if (Game.Has('Ichor syrup')) Game.lumpMatureAge-=1000*60*7; + if (Game.Has('Sugar aging process')) Game.lumpRipeAge-=6000*Math.min(600,Game.Objects['Grandma'].amount);//capped at 600 grandmas if (Game.hasGod && Game.BuildingsOwned%10==0) { var godLvl=Game.hasGod('order'); @@ -2921,17 +3512,20 @@ Game.Launch=function() else if (godLvl==2) Game.lumpRipeAge-=(hour/3)*2; else if (godLvl==3) Game.lumpRipeAge-=(hour/3); } + //if (Game.hasAura('Dragon\'s Curve')) {Game.lumpMatureAge/=1.05;Game.lumpRipeAge/=1.05;} + Game.lumpMatureAge/=1+Game.auraMult('Dragon\'s Curve')*0.05;Game.lumpRipeAge/=1+Game.auraMult('Dragon\'s Curve')*0.05; Game.lumpOverripeAge=Game.lumpRipeAge+hour; if (Game.Has('Glucose-charged air')) {Game.lumpMatureAge/=2000;Game.lumpRipeAge/=2000;Game.lumpOverripeAge/=2000;} } Game.loadLumps=function(time) { Game.computeLumpTimes(); - Game.computeLumpType(); - if (Game.resets==0 || Game.ascensionMode==1) Game.removeClass('lumpsOn'); + //Game.computeLumpType(); + if (!Game.canLumps()) Game.removeClass('lumpsOn'); else { if (Game.ascensionMode!=1) Game.addClass('lumpsOn'); + Game.lumpT=Math.min(Date.now(),Game.lumpT); var age=Math.max(Date.now()-Game.lumpT,0); var amount=Math.floor(age/Game.lumpOverripeAge);//how many lumps did we harvest since we closed the game? if (amount>=1) @@ -2946,10 +3540,11 @@ Game.Launch=function() } } } - Game.gainLumps=function(yield) + Game.gainLumps=function(total) { - Game.lumps+=yield; - Game.lumpsTotal+=yield; + if (Game.lumpsTotal==-1){Game.lumpsTotal=0;Game.lumps=0;} + Game.lumps+=total; + Game.lumpsTotal+=total; if (Game.lumpsTotal>=7) Game.Win('Dude, sweet'); if (Game.lumpsTotal>=30) Game.Win('Sugar rush'); @@ -2957,7 +3552,7 @@ Game.Launch=function() } Game.clickLump=function() { - if (Game.resets==0) return; + if (!Game.canLumps()) return; var age=Date.now()-Game.lumpT; if (age+10% golden cookies for the next 24 hours.',[29,16]); } - else if (Game.lumpCurrentType==3) yield*=choose([0,0,1,2,2]); - yield=Math.floor(yield); - Game.gainLumps(yield); + else if (Game.lumpCurrentType==3) total*=choose([0,0,1,2,2]); + else if (Game.lumpCurrentType==4) + { + total*=choose([1,2,3]); + Game.lumpRefill=0;//Date.now()-Game.getLumpRefillMax(); + if (Game.prefs.popups) Game.Popup('Sugar lump cooldowns cleared!'); + else Game.Notify('Sugar lump cooldowns cleared!','',[29,27]); + } + total=Math.floor(total); + Game.gainLumps(total); if (Game.lumpCurrentType==1) Game.Win('Sugar sugar'); else if (Game.lumpCurrentType==2) Game.Win('All-natural cane sugar'); else if (Game.lumpCurrentType==3) Game.Win('Sweetmeats'); + else if (Game.lumpCurrentType==4) Game.Win('Maillard reaction'); if (!silent) { var rect=l('lumpsIcon2').getBoundingClientRect();Game.SparkleAt((rect.left+rect.right)/2,(rect.top+rect.bottom)/2-24); - if (yield>0) Game.Popup('+'+Beautify(yield)+' sugar lump'+(yield==1?'':'s')+'',(rect.left+rect.right)/2,(rect.top+rect.bottom)/2-48); + if (total>0) Game.Popup('+'+Beautify(total)+' sugar lump'+(total==1?'':'s')+'',(rect.left+rect.right)/2,(rect.top+rect.bottom)/2-48); else Game.Popup('Botched harvest!',(rect.left+rect.right)/2,(rect.top+rect.bottom)/2-48); PlaySound('snd/pop'+Math.floor(Math.random()*3+1)+'.mp3',0.75); } @@ -3007,25 +3610,97 @@ Game.Launch=function() Game.computeLumpType=function() { Math.seedrandom(Game.seed+'/'+Game.lumpT); - var rand=Math.random(); var types=[0]; - if (rand<(Game.Has('Sucralosia Inutilis')?0.105:0.1)) types.push(1);//bifurcated - if (rand<0.001) types.push(2);//golden - if (rand<0.1*Game.elderWrath) types.push(3);//meaty + var loop=1; + //if (Game.hasAura('Dragon\'s Curve')) loop=2; + loop+=Game.auraMult('Dragon\'s Curve'); + loop=randomFloor(loop); + for (var i=0;iGame.lumpOverripeAge) - { - age=0; - Game.harvestLumps(1); + if (Game.lumpsTotal>-1 || (Game.ascensionMode!=1 && (Game.cookiesEarned+Game.cookiesReset)>=1000000000)) return true; + return false; + } + + Game.getLumpRefillMax=function() + { + return Game.fps*60*15;//1000*60*15;//15 minutes + } + Game.getLumpRefillRemaining=function() + { + return Game.lumpRefill;//Game.getLumpRefillMax()-(Date.now()-Game.lumpRefill); + } + Game.canRefillLump=function() + { + return Game.lumpRefill<=0;//((Date.now()-Game.lumpRefill)>=Game.getLumpRefillMax()); + } + Game.refillLump=function(n,func) + { + if (Game.lumps>=n && Game.canRefillLump()) + { + Game.spendLump(n,'refill',function() + { + if (!Game.sesame) Game.lumpRefill=Game.getLumpRefillMax();//Date.now(); + func(); + })(); + } + } + Game.spendLump=function(n,str,func) + { + //ask if we want to spend N lumps + return function() + { + if (Game.lumps
Do you want to spend '+Beautify(n)+' lump'+(n!=1?'s':'')+' to '+str+'?
',[['Yes','Game.lumps-='+n+';Game.promptConfirmFunc();Game.promptConfirmFunc=0;Game.recalculateGains=1;Game.ClosePrompt();'],'No']); + return false; + } + else + { + Game.lumps-=n; + func(); + Game.recalculateGains=1; + } + } + } + + Game.doLumps=function() + { + if (Game.lumpRefill>0) Game.lumpRefill--; + + if (!Game.canLumps()) {Game.removeClass('lumpsOn');return;} + if (Game.lumpsTotal==-1) + { + //first time ! + if (Game.ascensionMode!=1) Game.addClass('lumpsOn'); + Game.lumpT-Date.now(); + Game.lumpsTotal=0; + Game.lumps=0; + Game.computeLumpType(); + + Game.Notify('Sugar lumps!','Because you\'ve baked a billion cookies in total, you are now attracting sugar lumps. They coalesce quietly near the top of your screen, under the Stats button.
You will be able to harvest them when they\'re ripe, after which you may spend them on all sorts of things!',[23,14]); + } + var age=Date.now()-Game.lumpT; + if (age>Game.lumpOverripeAge) + { + age=0; + Game.harvestLumps(1); Game.computeLumpType(); } + var phase=Math.min(6,Math.floor((age/Game.lumpOverripeAge)*7)); var phase2=Math.min(6,Math.floor((age/Game.lumpOverripeAge)*7)+1); var row=14; @@ -3046,6 +3721,11 @@ Game.Launch=function() if (phase>=4) row=17; if (phase2>=4) row2=17; } + else if (type==4)//caramelized + { + if (phase>=4) row=27; + if (phase2>=4) row2=27; + } var icon=[23+Math.min(phase,5),row]; var icon2=[23+phase2,row2]; var opacity=Math.min(6,(age/Game.lumpOverripeAge)*7)%1; @@ -3101,6 +3781,10 @@ Game.Launch=function() if (Game.Has('Fantasteel mouse')) add+=Game.cookiesPs*0.01; if (Game.Has('Nevercrack mouse')) add+=Game.cookiesPs*0.01; if (Game.Has('Armythril mouse')) add+=Game.cookiesPs*0.01; + if (Game.Has('Technobsidian mouse')) add+=Game.cookiesPs*0.01; + if (Game.Has('Plasmarble mouse')) add+=Game.cookiesPs*0.01; + + if (Game.Has('Fortune #104')) add+=Game.cookiesPs*0.01; var mult=1; for (var i in Game.customMouseCps) {mult+=Game.customMouseCps[i]();} @@ -3109,6 +3793,8 @@ Game.Launch=function() if (Game.Has('Cookie egg')) mult*=1.1; if (Game.Has('Halo gloves')) mult*=1.1; + mult*=Game.eff('click'); + if (Game.hasGod) { var godLvl=Game.hasGod('labor'); @@ -3122,7 +3808,8 @@ Game.Launch=function() if (typeof Game.buffs[i].multClick != 'undefined') mult*=Game.buffs[i].multClick; } - if (Game.hasAura('Dragon Cursor')) mult*=1.05; + //if (Game.hasAura('Dragon Cursor')) mult*=1.05; + mult*=1+Game.auraMult('Dragon Cursor')*0.05; for (var i in Game.customMouseCpsMult) {mult*=Game.customMouseCpsMult[i]();} @@ -3133,6 +3820,7 @@ Game.Launch=function() } Game.computedMouseCps=1; Game.globalCpsMult=1; + Game.unbuffedCps=0; Game.lastClick=0; Game.CanClick=1; Game.autoclickerDetected=0; @@ -3148,10 +3836,10 @@ Game.Launch=function() Game.cookieClickSound+=Math.floor(Math.random()*4)+1; if (Game.cookieClickSound>7) Game.cookieClickSound-=7; } - Game.ClickCookie=function(event,amount) + Game.ClickCookie=function(e,amount) { var now=Date.now(); - if (event) event.preventDefault(); + if (e) e.preventDefault(); if (Game.OnAscend || Game.AscendTimer>0) {} else if (now-Game.lastClick<1000/250) {} else @@ -3161,6 +3849,7 @@ Game.Launch=function() Game.autoclickerDetected+=Game.fps; if (Game.autoclickerDetected>=Game.fps*5) Game.Win('Uncanny clicker'); } + Game.loseShimmeringVeil('click'); var amount=amount?amount:Game.computedMouseCps; Game.Earn(amount); Game.handmadeCookies+=amount; @@ -3214,9 +3903,12 @@ Game.Launch=function() Game.mouseX=posx-x; Game.mouseY=posy-y; Game.mouseMoved=1; + Game.lastActivity=Game.time; } var bigCookie=l('bigCookie'); Game.Click=0; + Game.lastClickedEl=0; + Game.clickFrom=0; Game.Scroll=0; Game.mouseDown=0; if (!Game.touchEvents) @@ -3227,13 +3919,14 @@ Game.Launch=function() AddEvent(bigCookie,'mouseout',function(event){Game.BigCookieState=0;}); AddEvent(bigCookie,'mouseover',function(event){Game.BigCookieState=2;}); AddEvent(document,'mousemove',Game.GetMouseCoords); - AddEvent(document,'mousedown',function(event){Game.mouseDown=1;}); - AddEvent(document,'mouseup',function(event){Game.mouseDown=0;}); - AddEvent(document,'click',function(event){Game.Click=1;}); + AddEvent(document,'mousedown',function(event){Game.lastActivity=Game.time;Game.mouseDown=1;Game.clickFrom=event.target;}); + AddEvent(document,'mouseup',function(event){Game.lastActivity=Game.time;Game.mouseDown=0;Game.clickFrom=0;}); + AddEvent(document,'click',function(event){Game.lastActivity=Game.time;Game.Click=1;Game.lastClickedEl=event.target;Game.clickFrom=0;}); Game.handleScroll=function(e) { if (!e) e=event; Game.Scroll=(e.detail<0||e.wheelDelta>0)?1:-1; + Game.lastActivity=Game.time; }; AddEvent(document,'DOMMouseScroll',Game.handleScroll); AddEvent(document,'mousewheel',Game.handleScroll); @@ -3246,13 +3939,14 @@ Game.Launch=function() AddEvent(bigCookie,'touchend',function(event){Game.BigCookieState=0;if (event) event.preventDefault();}); //AddEvent(document,'touchmove',Game.GetMouseCoords); AddEvent(document,'mousemove',Game.GetMouseCoords); - AddEvent(document,'touchstart',function(event){Game.mouseDown=1;}); - AddEvent(document,'touchend',function(event){Game.mouseDown=0;}); - AddEvent(document,'touchend',function(event){Game.Click=1;}); + AddEvent(document,'touchstart',function(event){Game.lastActivity=Game.time;Game.mouseDown=1;}); + AddEvent(document,'touchend',function(event){Game.lastActivity=Game.time;Game.mouseDown=0;}); + AddEvent(document,'touchend',function(event){Game.lastActivity=Game.time;Game.Click=1;}); } Game.keys=[]; AddEvent(window,'keyup',function(e){ + Game.lastActivity=Game.time; if (e.keyCode==27) { Game.ClosePrompt(); @@ -3264,28 +3958,55 @@ Game.Launch=function() AddEvent(window,'keydown',function(e){ if (!Game.OnAscend && Game.AscendTimer==0) { - if (e.ctrlKey && e.keyCode==83) {Game.WriteSave();e.preventDefault();}//ctrl-s saves the game + if (e.ctrlKey && e.keyCode==83) {Game.toSave=true;e.preventDefault();}//ctrl-s saves the game else if (e.ctrlKey && e.keyCode==79) {Game.ImportSave();e.preventDefault();}//ctrl-o opens the import menu } + if ((e.keyCode==16 || e.keyCode==17) && Game.tooltip.dynamic) Game.tooltip.update(); Game.keys[e.keyCode]=1; }); + AddEvent(window,'visibilitychange',function(e){ + Game.keys=[];//reset all key pressed on visibility change (should help prevent ctrl still being down after ctrl-tab) + }); /*===================================================================================== CPS RECALCULATOR =======================================================================================*/ + Game.heavenlyPower=1;//how many CpS percents a single heavenly chip gives Game.recalculateGains=1; - Game.cookiesPsByType=[]; + Game.cookiesPsByType={}; + Game.cookiesMultByType={}; //display bars with http://codepen.io/anon/pen/waGyEJ + Game.effs={}; + Game.eff=function(name,def){if (typeof Game.effs[name]==='undefined') return (typeof def==='undefined'?1:def); else return Game.effs[name];}; Game.CalculateGains=function() { Game.cookiesPs=0; var mult=1; + //add up effect bonuses from building minigames + var effs={}; + for (var i in Game.Objects) + { + if (Game.Objects[i].minigameLoaded && Game.Objects[i].minigame.effs) + { + var myEffs=Game.Objects[i].minigame.effs; + for (var ii in myEffs) + { + if (effs[ii]) effs[ii]*=myEffs[ii]; + else effs[ii]=myEffs[ii]; + } + } + } + Game.effs=effs; if (Game.ascensionMode!=1) mult+=parseFloat(Game.prestige)*0.01*Game.heavenlyPower*Game.GetHeavenlyMultiplier(); + mult*=Game.eff('cps'); + + if (Game.Has('Heralds') && Game.ascensionMode!=1) mult*=1+0.01*Game.heralds; + var cookieMult=0; for (var i in Game.cookieUpgrades) { @@ -3309,6 +4030,9 @@ Game.Launch=function() if (Game.Has('An itchy sweater')) mult*=1.01; if (Game.Has('Santa\'s dominion')) mult*=1.2; + if (Game.Has('Fortune #100')) mult*=1.01; + if (Game.Has('Fortune #101')) mult*=1.07; + var buildMult=1; if (Game.hasGod) { @@ -3329,7 +4053,7 @@ Game.Launch=function() var godLvl=Game.hasGod('industry'); if (godLvl==1) buildMult*=1.1; - else if (godLvl==2) buildMult*=1.05; + else if (godLvl==2) buildMult*=1.06; else if (godLvl==3) buildMult*=1.03; var godLvl=Game.hasGod('labor'); @@ -3350,7 +4074,6 @@ Game.Launch=function() Game.cookiesPsByType[me.name]=me.storedTotalCps; } - if (Game.Has('"egg"')) {Game.cookiesPs+=9;Game.cookiesPsByType['"egg"']=9;}//"egg" for (var i in Game.customCps) {mult*=Game.customCps[i]();} @@ -3358,25 +4081,37 @@ Game.Launch=function() Game.milkProgress=Game.AchievementsOwned/25; var milkMult=1; if (Game.Has('Santa\'s milk and cookies')) milkMult*=1.05; - if (Game.hasAura('Breath of Milk')) milkMult*=1.05; + //if (Game.hasAura('Breath of Milk')) milkMult*=1.05; + milkMult*=1+Game.auraMult('Breath of Milk')*0.05; if (Game.hasGod) { var godLvl=Game.hasGod('mother'); if (godLvl==1) milkMult*=1.1; - else if (godLvl==2) milkMult*=1.06; + else if (godLvl==2) milkMult*=1.05; else if (godLvl==3) milkMult*=1.03; } - if (Game.Has('Kitten helpers')) mult*=(1+Game.milkProgress*0.1*milkMult); - if (Game.Has('Kitten workers')) mult*=(1+Game.milkProgress*0.125*milkMult); - if (Game.Has('Kitten engineers')) mult*=(1+Game.milkProgress*0.15*milkMult); - if (Game.Has('Kitten overseers')) mult*=(1+Game.milkProgress*0.175*milkMult); - if (Game.Has('Kitten managers')) mult*=(1+Game.milkProgress*0.2*milkMult); - if (Game.Has('Kitten accountants')) mult*=(1+Game.milkProgress*0.2*milkMult); - if (Game.Has('Kitten specialists')) mult*=(1+Game.milkProgress*0.2*milkMult); - if (Game.Has('Kitten experts')) mult*=(1+Game.milkProgress*0.2*milkMult); - if (Game.Has('Kitten consultants')) mult*=(1+Game.milkProgress*0.2*milkMult); - if (Game.Has('Kitten assistants to the regional manager')) mult*=(1+Game.milkProgress*0.2*milkMult); - if (Game.Has('Kitten angels')) mult*=(1+Game.milkProgress*0.1*milkMult); + milkMult*=Game.eff('milk'); + + var catMult=1; + + if (Game.Has('Kitten helpers')) catMult*=(1+Game.milkProgress*0.1*milkMult); + if (Game.Has('Kitten workers')) catMult*=(1+Game.milkProgress*0.125*milkMult); + if (Game.Has('Kitten engineers')) catMult*=(1+Game.milkProgress*0.15*milkMult); + if (Game.Has('Kitten overseers')) catMult*=(1+Game.milkProgress*0.175*milkMult); + if (Game.Has('Kitten managers')) catMult*=(1+Game.milkProgress*0.2*milkMult); + if (Game.Has('Kitten accountants')) catMult*=(1+Game.milkProgress*0.2*milkMult); + if (Game.Has('Kitten specialists')) catMult*=(1+Game.milkProgress*0.2*milkMult); + if (Game.Has('Kitten experts')) catMult*=(1+Game.milkProgress*0.2*milkMult); + if (Game.Has('Kitten consultants')) catMult*=(1+Game.milkProgress*0.2*milkMult); + if (Game.Has('Kitten assistants to the regional manager')) catMult*=(1+Game.milkProgress*0.175*milkMult); + if (Game.Has('Kitten marketeers')) catMult*=(1+Game.milkProgress*0.15*milkMult); + if (Game.Has('Kitten analysts')) catMult*=(1+Game.milkProgress*0.125*milkMult); + if (Game.Has('Kitten executives')) catMult*=(1+Game.milkProgress*0.115*milkMult); + if (Game.Has('Kitten angels')) catMult*=(1+Game.milkProgress*0.1*milkMult); + if (Game.Has('Fortune #103')) catMult*=(1+Game.milkProgress*0.05*milkMult); + + Game.cookiesMultByType['kittens']=catMult; + mult*=catMult; var eggMult=1; if (Game.Has('Chicken egg')) eggMult*=1.01; @@ -3399,14 +4134,19 @@ Game.Launch=function() eggMult*=1+(1-Math.pow(1-day/100,3))*0.1; } + Game.cookiesMultByType['eggs']=eggMult; mult*=eggMult; - if (Game.hasAura('Radiant Appetite')) mult*=2; + if (Game.Has('Sugar baking')) mult*=(1+Math.min(100,Game.lumps)*0.01); - if (Game.hasAura('Dragon\'s Fortune')) + //if (Game.hasAura('Radiant Appetite')) mult*=2; + mult*=1+Game.auraMult('Radiant Appetite'); + + if (true)// || Game.hasAura('Dragon\'s Fortune')) { var n=Game.shimmerTypes['golden'].n; - for (var i=0;i=Game.CpsAchievements[i].threshold) Game.Win(Game.CpsAchievements[i].name); } - for (var i in Game.buffs) - { - if (typeof Game.buffs[i].multCpS != 'undefined') mult*=Game.buffs[i].multCpS; - } - name=Game.bakeryName.toLowerCase(); if (name=='orteil') mult*=0.99; else if (name=='ortiel') mult*=0.98;//or so help me - var sucked=1; + var sucking=0; for (var i in Game.wrinklers) { - if (Game.wrinklers[i].phase==2) sucked-=1/20; + if (Game.wrinklers[i].phase==2) + { + sucking++; + } } - Game.cpsSucked=(1-sucked); + var suckRate=1/20;//each wrinkler eats a twentieth of your CpS + suckRate*=Game.eff('wrinklerEat'); + + Game.cpsSucked=sucking*suckRate; if (Game.Has('Elder Covenant')) mult*=0.95; @@ -3444,16 +4185,31 @@ Game.Launch=function() var goldenSwitchMult=1.5; if (Game.Has('Residual luck')) { - var upgrades=['Get lucky','Lucky day','Serendipity','Heavenly luck','Lasting fortune','Decisive fate','Lucky digit','Lucky number','Lucky payout']; + var upgrades=Game.goldenCookieUpgrades; for (var i in upgrades) {if (Game.Has(upgrades[i])) goldenSwitchMult+=0.1;} } mult*=goldenSwitchMult; } + if (Game.Has('Shimmering veil [off]')) + { + var veilMult=0.5; + if (Game.Has('Reinforced membrane')) veilMult+=0.1; + mult*=1+veilMult; + } if (Game.Has('Magic shenanigans')) mult*=1000; if (Game.Has('Occult obstruction')) mult*=0; for (var i in Game.customCpsMult) {mult*=Game.customCpsMult[i]();} + + //cps without golden cookie effects + Game.unbuffedCps=Game.cookiesPs*mult; + + for (var i in Game.buffs) + { + if (typeof Game.buffs[i].multCpS != 'undefined') mult*=Game.buffs[i].multCpS; + } + Game.globalCpsMult=mult; Game.cookiesPs*=Game.globalCpsMult; @@ -3466,6 +4222,17 @@ Game.Launch=function() Game.recalculateGains=0; } + Game.dropRateMult=function() + { + var rate=1; + if (Game.Has('Green yeast digestives')) rate*=1.03; + rate*=Game.eff('itemDrops'); + //if (Game.hasAura('Mind Over Matter')) rate*=1.25; + rate*=1+Game.auraMult('Mind Over Matter')*0.25; + if (Game.Has('Santa\'s bottomless bag')) rate*=1.1; + if (Game.Has('Cosmic beginner\'s luck') && !Game.Has('Heavenly chip secret')) rate*=5; + return rate; + } /*===================================================================================== SHIMMERS (GOLDEN COOKIES & SUCH) =======================================================================================*/ @@ -3506,6 +4273,7 @@ Game.Launch=function() Game.shimmer.prototype.pop=function(event)//executed when the shimmer is popped by the player { if (event) event.preventDefault(); + Game.loseShimmeringVeil('shimmer'); Game.Click=0; Game.shimmerTypes[this.type].popFunc(this); } @@ -3517,8 +4285,8 @@ Game.Launch=function() var type=Game.shimmerTypes[this.type]; type.time=0; type.spawned=0; - type.minTime=type.getMinTime(); - type.maxTime=type.getMaxTime(); + type.minTime=type.getMinTime(this); + type.maxTime=type.getMaxTime(this); } Game.shimmersL.removeChild(this.l); if (Game.shimmers.indexOf(this)!=-1) Game.shimmers.splice(Game.shimmers.indexOf(this),1); @@ -3565,7 +4333,7 @@ Game.Launch=function() } Game.killShimmers=function()//stop and delete all shimmers (used on resetting etc) { - for (var i in Game.shimmers) + for (var i=Game.shimmers.length-1;i>=0;i--) { Game.shimmers[i].die(); } @@ -3578,8 +4346,8 @@ Game.Launch=function() { me.time=0; me.spawned=0; - me.minTime=me.getMinTime(); - me.maxTime=me.getMaxTime(); + me.minTime=me.getMinTime(me); + me.maxTime=me.getMaxTime(me); } } } @@ -3652,6 +4420,9 @@ Game.Launch=function() if (Game.Has('Lucky digit')) dur*=1.01; if (Game.Has('Lucky number')) dur*=1.01; if (Game.Has('Lucky payout')) dur*=1.01; + if (!me.wrath) dur*=Game.eff('goldenCookieDur'); + else dur*=Game.eff('wrathCookieDur'); + dur*=Math.pow(0.95,Game.shimmerTypes['golden'].n-1);//5% shorter for every other golden cookie on the screen if (this.chain>0) dur=Math.max(2,10/this.chain);//this is hilarious me.dur=dur; me.life=Math.ceil(Game.fps*me.dur); @@ -3663,7 +4434,7 @@ Game.Launch=function() var curve=1-Math.pow((me.life/(Game.fps*me.dur))*2-1,4); me.l.style.opacity=curve; //this line makes each golden cookie pulse in a unique way - me.l.style.transform='rotate('+(Math.sin(me.id*0.69)*24+Math.sin(Game.T*(0.35+Math.sin(me.id*0.97)*0.15)+me.id/*+Math.sin(Game.T*0.07)*2+2*/)*(3+Math.sin(me.id*0.36)*2))+'deg) scale('+(me.sizeMult*(1+Math.sin(me.id*0.53)*0.2)*curve*(1+(0.06+Math.sin(me.id*0.41)*0.05)*(Math.sin(Game.T*(0.25+Math.sin(me.id*0.73)*0.15)+me.id))))+')'; + if (Game.prefs.fancy) me.l.style.transform='rotate('+(Math.sin(me.id*0.69)*24+Math.sin(Game.T*(0.35+Math.sin(me.id*0.97)*0.15)+me.id/*+Math.sin(Game.T*0.07)*2+2*/)*(3+Math.sin(me.id*0.36)*2))+'deg) scale('+(me.sizeMult*(1+Math.sin(me.id*0.53)*0.2)*curve*(1+(0.06+Math.sin(me.id*0.41)*0.05)*(Math.sin(Game.T*(0.25+Math.sin(me.id*0.73)*0.15)+me.id))))+')'; me.life--; if (me.life<=0) {this.missFunc(me);me.die();} }, @@ -3708,12 +4479,14 @@ Game.Launch=function() if (Game.BuildingsOwned>=10 && Math.random()<0.25) list.push('building special'); - if (Game.resets>0 && Math.random()<0.0005) list.push('free sugar lump'); + if (Game.canLumps() && Math.random()<0.0005) list.push('free sugar lump'); if ((me.wrath==0 && Math.random()<0.15) || Math.random()<0.05) { - if (Game.hasAura('Reaper of Fields')) list.push('dragon harvest'); - if (Game.hasAura('Dragonflight')) list.push('dragonflight'); + //if (Game.hasAura('Reaper of Fields')) list.push('dragon harvest'); + if (Math.random()0 && Game.hasAura('Unholy Dominion')) mult*=1.1; - else if (me.wrath==0 && Game.hasAura('Ancestral Metamorphosis')) mult*=1.1; + //if (me.wrath>0 && Game.hasAura('Unholy Dominion')) mult*=1.1; + //else if (me.wrath==0 && Game.hasAura('Ancestral Metamorphosis')) mult*=1.1; + if (me.wrath>0) mult*=1+Game.auraMult('Unholy Dominion')*0.1; + else if (me.wrath==0) mult*=1+Game.auraMult('Ancestral Metamorphosis')*0.1; + if (Game.Has('Green yeast digestives')) mult*=1.01; + if (!me.wrath) mult*=Game.eff('goldenCookieGain'); + else mult*=Game.eff('wrathCookieGain'); var popup=''; var buff=0; @@ -3833,13 +4617,13 @@ Game.Launch=function() var digit=me.wrath?6:7; if (this.chain==1) this.chain+=Math.max(0,Math.ceil(Math.log(Game.cookies)/Math.LN10)-10); - var maxPayout=Math.min(Game.cookiesPs*60*60*6,Game.cookies*0.25)*mult; + var maxPayout=Math.min(Game.cookiesPs*60*60*6,Game.cookies*0.5)*mult; var moni=Math.max(digit,Math.min(Math.floor(1/9*Math.pow(10,this.chain)*digit*mult),maxPayout)); var nextMoni=Math.max(digit,Math.min(Math.floor(1/9*Math.pow(10,this.chain+1)*digit*mult),maxPayout)); this.totalFromChain+=moni; var moniStr=Beautify(moni); - //break the chain if we're above 5 digits AND it's more than 25% of our bank, it grants more than 6 hours of our CpS, or just a 1% chance each digit (update : removed digit limit) + //break the chain if we're above 5 digits AND it's more than 50% of our bank, it grants more than 6 hours of our CpS, or just a 1% chance each digit (update : removed digit limit) if (Math.random()<0.01 || nextMoni>=maxPayout) { this.chain=0; @@ -3915,18 +4699,22 @@ Game.Launch=function() time:0, minTime:0, maxTime:0, - getTimeMod:function(m) + getTimeMod:function(me,m) { if (Game.Has('Lucky day')) m/=2; if (Game.Has('Serendipity')) m/=2; if (Game.Has('Golden goose egg')) m*=0.95; if (Game.Has('Heavenly luck')) m*=0.95; - if (Game.hasAura('Arcane Aura')) m*=0.95; + if (Game.Has('Green yeast digestives')) m*=0.99; + //if (Game.hasAura('Arcane Aura')) m*=0.95; + m*=1-Game.auraMult('Arcane Aura')*0.05; if (Game.hasBuff('Sugar blessing')) m*=0.9; if (Game.season=='easter' && Game.Has('Starspawn')) m*=0.98; else if (Game.season=='halloween' && Game.Has('Starterror')) m*=0.98; else if (Game.season=='valentines' && Game.Has('Starlove')) m*=0.98; else if (Game.season=='fools' && Game.Has('Startrade')) m*=0.95; + if (!me.wrath) m*=1/Game.eff('goldenCookieFreq'); + else m*=1/Game.eff('wrathCookieFreq'); if (Game.hasGod) { var godLvl=Game.hasGod('industry'); @@ -3959,15 +4747,15 @@ Game.Launch=function() if (Game.Has('Gold hoard')) m=0.01; return Math.ceil(Game.fps*60*m); }, - getMinTime:function() + getMinTime:function(me) { var m=5; - return this.getTimeMod(m); + return this.getTimeMod(me,m); }, - getMaxTime:function() + getMaxTime:function(me) { var m=15; - return this.getTimeMod(m); + return this.getTimeMod(me,m); }, last:'', }, @@ -3995,6 +4783,7 @@ Game.Launch=function() var dur=4; if (Game.Has('Weighted sleighs')) dur*=2; + dur*=Game.eff('reindeerDur'); me.dur=dur; me.life=Math.ceil(Game.fps*me.dur); me.sizeMult=1; @@ -4020,14 +4809,14 @@ Game.Launch=function() if (Game.hasBuff('Frenzy')) val*=0.75;//I sincerely apologize var moni=Math.max(25,val);//1 minute of cookie production, or 25 cookies - whichever is highest if (Game.Has('Ho ho ho-flavored frosting')) moni*=2; + moni*=Game.eff('reindeerGain'); Game.Earn(moni); if (Game.hasBuff('Elder frenzy')) Game.Win('Eldeer'); - var failRate=0.8; var cookie=''; + var failRate=0.8; if (Game.HasAchiev('Let it snow')) failRate=0.6; - if (Game.Has('Santa\'s bottomless bag')) failRate*=0.9; - if (Game.hasAura('Mind Over Matter')) failRate*=0.75; + failRate*=1/Game.dropRateMult(); if (Game.Has('Starsnow')) failRate*=0.95; if (Game.hasGod) { @@ -4071,7 +4860,7 @@ Game.Launch=function() time:0, minTime:0, maxTime:0, - getTimeMod:function(m) + getTimeMod:function(me,m) { if (Game.Has('Reindeer baking grounds')) m/=2; if (Game.Has('Starsnow')) m*=0.95; @@ -4082,18 +4871,19 @@ Game.Launch=function() else if (godLvl==2) m*=0.95; else if (godLvl==3) m*=0.97; } + m*=1/Game.eff('reindeerFreq'); if (Game.Has('Reindeer season')) m=0.01; return Math.ceil(Game.fps*60*m); }, - getMinTime:function() + getMinTime:function(me) { var m=3; - return this.getTimeMod(m); + return this.getTimeMod(me,m); }, - getMaxTime:function() + getMaxTime:function(me) { var m=6; - return this.getTimeMod(m); + return this.getTimeMod(me,m); }, } }; @@ -4130,6 +4920,8 @@ Game.Launch=function() 'Antimatter condenser':['Extra cycles','Predictable tragedy'], 'Prism':['Solar flare','Eclipse'], 'Chancemaker':['Winning streak','Dry spell'], + 'Fractal engine':['Macrocosm','Microcosm'], + 'Javascript console':['Refactoring','Antipattern'], }; /*===================================================================================== @@ -4208,6 +5000,7 @@ Game.Launch=function() if (cookie.bought>0 && cookie.pool=='cookie') cookies.push(cookie.icon); } me.picPos=choose(cookies); + if (Game.bakeryName.toLowerCase()=='ortiel' || Math.random()<1/10000) me.picPos=[17,5]; pic='icons.png'; } } @@ -4219,9 +5012,10 @@ Game.Launch=function() } Game.particlesDraw=function(z) { - Game.LeftBackground.fillStyle='#fff'; - Game.LeftBackground.font='20px Merriweather'; - Game.LeftBackground.textAlign='center'; + var ctx=Game.LeftBackground; + ctx.fillStyle='#fff'; + ctx.font='20px Merriweather'; + ctx.textAlign='center'; for (var i in Game.particles) { @@ -4231,30 +5025,30 @@ Game.Launch=function() if (me.life!=-1) { var opacity=1-(me.life/(Game.fps*me.dur)); - Game.LeftBackground.globalAlpha=opacity; + ctx.globalAlpha=opacity; if (me.text) { - Game.LeftBackground.fillText(me.text,me.x,me.y); + ctx.fillText(me.text,me.x,me.y); } else { - Game.LeftBackground.save(); - Game.LeftBackground.translate(me.x,me.y); - Game.LeftBackground.rotate((me.r/360)*Math.PI*2); + ctx.save(); + ctx.translate(me.x,me.y); + ctx.rotate((me.r/360)*Math.PI*2); var w=64; var h=64; if (me.pic=='icons.png') { w=48; h=48; - Game.LeftBackground.drawImage(Pic(me.pic),me.picPos[0]*w,me.picPos[1]*h,w,h,-w/2*me.size,-h/2*me.size,w*me.size,h*me.size); + ctx.drawImage(Pic(me.pic),me.picPos[0]*w,me.picPos[1]*h,w,h,-w/2*me.size,-h/2*me.size,w*me.size,h*me.size); } else { if (me.pic=='wrinklerBits.png' || me.pic=='shinyWrinklerBits.png') {w=100;h=200;} - Game.LeftBackground.drawImage(Pic(me.pic),(me.picId%8)*w,0,w,h,-w/2*me.size,-h/2*me.size,w*me.size,h*me.size); + ctx.drawImage(Pic(me.pic),(me.picId%8)*w,0,w,h,-w/2*me.size,-h/2*me.size,w*me.size,h*me.size); } - Game.LeftBackground.restore(); + ctx.restore(); } } } @@ -4344,7 +5138,7 @@ Game.Launch=function() me.l.style.zIndex=100000001; me.l.style.display='block'; me.l.className='particle title'; - me.l.offsetWidth=me.l.offsetWidth; + void me.l.offsetWidth; me.l.className='particle title risingUpLinger'; if (!noStack) Game.textParticlesY+=60; } @@ -4369,6 +5163,11 @@ Game.Launch=function() Game.sparkles.style.display='block'; } } + Game.SparkleOn=function(el) + { + var rect=el.getBoundingClientRect(); + Game.SparkleAt((rect.left+rect.right)/2,(rect.top+rect.bottom)/2-24); + } /*===================================================================================== NOTIFICATIONS @@ -4577,6 +5376,15 @@ Game.Launch=function() if (Game.prefs.filters) Game.removeClass('noFilters'); else if (!Game.prefs.filters) Game.addClass('noFilters'); } + Game.ToggleExtraButtons=function() + { + if (!Game.prefs.extraButtons) Game.removeClass('extraButtons'); + else if (Game.prefs.extraButtons) Game.addClass('extraButtons'); + for (var i in Game.Objects) + { + Game.Objects[i].mute(0); + } + } Game.WriteSlider=function(slider,leftText,rightText,startValueFunction,callback) { @@ -4604,7 +5412,7 @@ Game.Launch=function() if (Game.onMenu=='' && what!='') Game.addClass('onMenu'); else if (Game.onMenu!='' && what!=Game.onMenu) Game.addClass('onMenu'); else if (what==Game.onMenu) {Game.removeClass('onMenu');what='';} - if (what=='log') l('donateBox').className='on'; else l('donateBox').className=''; + //if (what=='log') l('donateBox').className='on'; else l('donateBox').className=''; Game.onMenu=what; l('prefsButton').className=(Game.onMenu=='prefs')?'button selected':'button'; @@ -4615,6 +5423,15 @@ Game.Launch=function() else PlaySound('snd/clickOn.mp3'); Game.UpdateMenu(); + + if (what=='') + { + for (var i in Game.Objects) + { + var me=Game.Objects[i]; + if (me.minigame && me.minigame.onResize) me.minigame.onResize(); + } + } } Game.sayTime=function(time,detail) { @@ -4627,14 +5444,17 @@ Game.Launch=function() time=Math.floor(time); if (detail==-1) { + //var months=0; var days=0; var hours=0; var minutes=0; var seconds=0; + //if (time>=Game.fps*60*60*24*30) months=(Math.floor(time/(Game.fps*60*60*24*30))); if (time>=Game.fps*60*60*24) days=(Math.floor(time/(Game.fps*60*60*24))); if (time>=Game.fps*60*60) hours=(Math.floor(time/(Game.fps*60*60))); if (time>=Game.fps*60) minutes=(Math.floor(time/(Game.fps*60))); if (time>=Game.fps) seconds=(Math.floor(time/(Game.fps))); + //days-=months*30; hours-=days*24; minutes-=hours*60+days*24*60; seconds-=minutes*60+hours*60*60+days*24*60*60; @@ -4642,6 +5462,7 @@ Game.Launch=function() if (days) {minutes=0;seconds=0;} if (hours) {seconds=0;} var bits=[]; + //if (months>0) bits.push(Beautify(months)+' month'+(days==1?'':'s')); if (days>0) bits.push(Beautify(days)+' day'+(days==1?'':'s')); if (hours>0) bits.push(Beautify(hours)+' hour'+(hours==1?'':'s')); if (minutes>0) bits.push(Beautify(minutes)+' minute'+(minutes==1?'':'s')); @@ -4651,7 +5472,9 @@ Game.Launch=function() } else { - if (time>=Game.fps*60*60*24*2 && detail<2) str=Beautify(Math.floor(time/(Game.fps*60*60*24)))+' days'; + /*if (time>=Game.fps*60*60*24*30*2 && detail<1) str=Beautify(Math.floor(time/(Game.fps*60*60*24*30)))+' months'; + else if (time>=Game.fps*60*60*24*30 && detail<1) str='1 month'; + else */if (time>=Game.fps*60*60*24*2 && detail<2) str=Beautify(Math.floor(time/(Game.fps*60*60*24)))+' days'; else if (time>=Game.fps*60*60*24 && detail<2) str='1 day'; else if (time>=Game.fps*60*60*2 && detail<3) str=Beautify(Math.floor(time/(Game.fps*60*60)))+' hours'; else if (time>=Game.fps*60*60 && detail<3) str='1 hour'; @@ -4696,9 +5519,9 @@ Game.Launch=function() str+='
Options
'+ '
'+ '
General
'+ - '
Save
'+ + '
Save
'+ '
Export saveImport save
'+ - '
Save to fileLoad from file
'+ + '
Save to fileLoad from file
'+ '
Wipe save
'+ '
Settings
'+ @@ -4716,9 +5539,13 @@ Game.Launch=function() Game.WriteButton('monospace','monospaceButton','Alt font ON','Alt font OFF')+'
'+ Game.WriteButton('format','formatButton','Short numbers OFF','Short numbers ON','BeautifyAll();Game.RefreshStore();Game.upgradesToRebuild=1;',1)+'
'+ Game.WriteButton('notifs','notifsButton','Fast notes ON','Fast notes OFF')+'
'+ - Game.WriteButton('autoupdate','autoupdateButton','Offline mode OFF','Offline mode ON',0,1)+'
'+ + //Game.WriteButton('autoupdate','autoupdateButton','Offline mode OFF','Offline mode ON',0,1)+'
'+ Game.WriteButton('warn','warnButton','Closing warning ON','Closing warning OFF')+'
'+ Game.WriteButton('focus','focusButton','Defocus OFF','Defocus ON',0,1)+'
'+ + Game.WriteButton('extraButtons','extraButtonsButton','Extra buttons ON','Extra buttons OFF','Game.ToggleExtraButtons();')+'
'+ + Game.WriteButton('askLumps','askLumpsButton','Lump confirmation ON','Lump confirmation OFF')+'
'+ + Game.WriteButton('customGrandmas','customGrandmasButton','Custom grandmas ON','Custom grandmas OFF')+'
'+ + Game.WriteButton('timeout','timeoutButton','Sleep mode timeout ON','Sleep mode timeout OFF')+'
'+ '
'+ //'
'+Game.WriteButton('autosave','autosaveButton','Autosave ON','Autosave OFF')+'
'+ '
'+ @@ -4737,7 +5564,7 @@ Game.Launch=function() } else if (Game.onMenu=='log') { - str+=Game.updateLog; + str+=replaceAll('[bakeryName]',Game.bakeryName,Game.updateLog); } else if (Game.onMenu=='stats') { @@ -4785,6 +5612,7 @@ Game.Launch=function() } var achievements=[]; var achievementsOwned=0; + var achievementsOwnedOther=0; var achievementsTotal=0; var list=[]; @@ -4804,12 +5632,17 @@ Game.Launch=function() for (var i in list) { var me=list[i]; - if (me.pool=='normal' || me.won>0) achievementsTotal++; + //if (me.pool=='normal' || me.won>0) achievementsTotal++; + if (Game.CountsAsAchievementOwned(me.pool)) achievementsTotal++; var pool=me.pool; if (!achievements[pool]) achievements[pool]=''; - achievements[pool]+=Game.crate(me,'stats'); - if (me.won>0) achievementsOwned++; + + if (me.won) + { + if (Game.CountsAsAchievementOwned(me.pool)) achievementsOwned++; + else achievementsOwnedOther++; + } } var achievementsStr=''; @@ -4826,6 +5659,18 @@ Game.Launch=function() } } + var milkStr=''; + for (var i=0;i=i) + { + var milk=Game.Milks[i]; + milkStr+='

'+milk.name+'

('+(i==0?'starter milk':('for '+Beautify(i*25)+' achievements'))+')
' + ,'top')+' style="background:url(img/icons.png) '+(-milk.icon[0]*48)+'px '+(-milk.icon[1]*48)+'px;margin:2px 0px;" class="trophy">'; + } + } + milkStr+='
'; var santaStr=''; var frames=15; @@ -4840,8 +5685,8 @@ Game.Launch=function() santaStr+='
'; } var dragonStr=''; - var frames=8; - var mainLevels=[0,4,8,20,22]; + var frames=9; + var mainLevels=[0,4,8,22,23,24]; if (Game.Has('A crumbly egg')) { for (var i=0;i<=mainLevels.length;i++) @@ -4850,9 +5695,9 @@ Game.Launch=function() { var level=Game.dragonLevels[mainLevels[i]]; dragonStr+='
'+level.name+'
' - '

'+level.name+'

' - ,'top')+' style="background:url(img/dragon.png) '+(-level.pic*48)+'px 0px;background-size:'+(frames*48)+'px 48px;" class="trophy">'; + //'
'+level.name+'
' + '

'+level.name+'

' + ,'top')+' style="background:url(img/dragon.png?v='+Game.version+') '+(-level.pic*48)+'px 0px;background-size:'+(frames*48)+'px 48px;" class="trophy">'; } } dragonStr+='
'; @@ -4861,7 +5706,7 @@ Game.Launch=function() var icon=Game.ascensionModes[Game.ascensionMode].icon; if (Game.resets>0) ascensionModeStr=''+Game.ascensionModes[Game.ascensionMode].desc+'' - ,'top')+'>
'+Game.ascensionModes[Game.ascensionMode].name+'
'; + ,'top')+'>
'+Game.ascensionModes[Game.ascensionMode].name+''; var milkName=Game.Milk.name; @@ -4907,7 +5752,7 @@ Game.Launch=function() '
Golden cookie clicks : '+Beautify(Game.goldenClicksLocal)+' (all time : '+Beautify(Game.goldenClicks)+')
'+//' '+ '
Running version : '+Game.version+'
'+ - ((researchStr!='' || wrathStr!='' || pledgeStr!='' || santaStr!='' || dragonStr!='' || Game.season!='' || ascensionModeStr!='')?( + ((researchStr!='' || wrathStr!='' || pledgeStr!='' || santaStr!='' || dragonStr!='' || Game.season!='' || ascensionModeStr!='' || Game.canLumps())?( '
'+ '
Special
'+ (ascensionModeStr!=''?'
Challenge mode :'+ascensionModeStr+'
':'')+ @@ -4922,7 +5767,7 @@ Game.Launch=function() (wrathStr!=''?'
Grandmatriarchs status : '+wrathStr+'
':'')+ (pledgeStr!=''?'
Pledge : '+pledgeStr+' remaining
':'')+ (Game.wrinklersPopped>0?'
Wrinklers popped : '+Beautify(Game.wrinklersPopped)+'
':'')+ - ((Game.resets>0 && Game.lumpsTotal>0)?'
Sugar lumps harvested :
'+Beautify(Game.lumpsTotal)+'
':'')+ + ((Game.canLumps() && Game.lumpsTotal>-1)?'
Sugar lumps harvested :
'+Beautify(Game.lumpsTotal)+'
':'')+ //(Game.cookiesSucked>0?'
Withered : '+Beautify(Game.cookiesSucked)+' cookies
':'')+ (Game.reindeerClicked>0?'
Reindeer found : '+Beautify(Game.reindeerClicked)+'
':'')+ (santaStr!=''?'
Santa stages unlocked :
'+santaStr+'
':'')+ @@ -4941,23 +5786,30 @@ Game.Launch=function() ''):'')+ '
'+ - '
Upgrades unlocked
'+ + '
Upgrades
'+ (hiddenUpgrades!=''?('
Debug
'+ '
'+hiddenUpgrades+'
'):'')+ - '
Unlocked : '+upgradesOwned+'/'+upgradesTotal+' ('+Math.floor((upgradesOwned/upgradesTotal)*100)+'%)
'+ + '
Upgrades unlocked : '+upgradesOwned+'/'+upgradesTotal+' ('+Math.floor((upgradesOwned/upgradesTotal)*100)+'%)
'+ '
'+upgrades+'
'+ (cookieUpgrades!=''?('
Cookies
'+ '
'+cookieUpgrades+'
'):'')+ '
'+ '
Achievements
'+ - '
Unlocked : '+achievementsOwned+'/'+achievementsTotal+' ('+Math.floor((achievementsOwned/achievementsTotal)*100)+'%)
'+ - '
Milk : '+milkName+' (Milk is gained with each achievement. It can unlock unique upgrades over time.)
'+ + '
Achievements unlocked : '+achievementsOwned+'/'+achievementsTotal+' ('+Math.floor((achievementsOwned/achievementsTotal)*100)+'%)'+(achievementsOwnedOther>0?(' (+'+achievementsOwnedOther+')'):'')+'
'+ + (Game.cookiesMultByType['kittens']>1?('
Kitten multiplier : '+Beautify((Game.cookiesMultByType['kittens'])*100)+'%
'):'')+ + '
Milk : '+milkName+'
'+ + (milkStr!=''?'
Milk flavors unlocked :
'+milkStr+'
':'')+ + '
(Milk is gained with each achievement. It can unlock unique upgrades over time.)
'+ achievementsStr+ '
'+ '
' ; } + //str='
'+str+'
'; l('menu').innerHTML=str; + /*AddEvent(l('selectionKeeper'),'mouseup',function(e){ + console.log('selection:',window.getSelection()); + });*/ } AddEvent(l('prefsButton'),'click',function(){Game.ShowMenu('prefs');}); @@ -4989,201 +5841,222 @@ Game.Launch=function() =======================================================================================*/ Game.Ticker=''; Game.TickerAge=0; + Game.TickerEffect=0; Game.TickerN=0; Game.TickerClicks=0; Game.UpdateTicker=function() { Game.TickerAge--; - if (Game.TickerAge<=0 || Game.Ticker=='') Game.getNewTicker(); + if (Game.TickerAge<=0) Game.getNewTicker(); + else if (Game.Ticker=='') Game.getNewTicker(true); } - Game.getNewTicker=function() + Game.getNewTicker=function(manual)//note : "manual" is true if the ticker was clicked, but may also be true on startup etc { var list=[]; if (Game.TickerN%2==0 || Game.cookiesEarned>=10100000000) { - var animals=['newts','penguins','scorpions','axolotls','puffins','porpoises','blowfish','horses','crayfish','slugs','humpback whales','nurse sharks','giant squids','polar bears','fruit bats','frogs','sea squirts','velvet worms','mole rats','paramecia','nematodes','tardigrades','giraffes']; - - if (Game.Objects['Grandma'].amount>0) list.push(choose([ - 'Moist cookies.grandma', - 'We\'re nice grandmas.grandma', - 'Indentured servitude.grandma', - 'Come give grandma a kiss.grandma', - 'Why don\'t you visit more often?grandma', - 'Call me...grandma' - ])); - - if (Game.Objects['Grandma'].amount>=50) list.push(choose([ - 'Absolutely disgusting.grandma', - 'You make me sick.grandma', - 'You disgust me.grandma', - 'We rise.grandma', - 'It begins.grandma', - 'It\'ll all be over soon.grandma', - 'You could have stopped it.grandma' - ])); - - if (Game.HasAchiev('Just wrong') && Math.random()<0.4) list.push(choose([ - 'News : cookie manufacturer downsizes, sells own grandmother!', - 'It has betrayed us, the filthy little thing.grandma', - 'It tried to get rid of us, the nasty little thing.grandma', - 'It thought we would go away by selling us. How quaint.grandma', - 'I can smell your rotten cookies.grandma' - ])); - - if (Game.Objects['Grandma'].amount>=1 && Game.pledges>0 && Game.elderWrath==0) list.push(choose([ - 'shrivelgrandma', - 'writhegrandma', - 'throbgrandma', - 'gnawgrandma', - 'We will rise again.grandma', - 'A mere setback.grandma', - 'We are not satiated.grandma', - 'Too late.grandma' - ])); - - if (Game.Objects['Farm'].amount>0) list.push(choose([ - 'News : cookie farms suspected of employing undeclared elderly workforce!', - 'News : cookie farms release harmful chocolate in our rivers, says scientist!', - 'News : genetically-modified chocolate controversy strikes cookie farmers!', - 'News : free-range farm cookies popular with today\'s hip youth, says specialist.', - 'News : farm cookies deemed unfit for vegans, says nutritionist.' - ])); - - if (Game.Objects['Mine'].amount>0) list.push(choose([ - 'News : is our planet getting lighter? Experts examine the effects of intensive chocolate mining.', - 'News : '+Math.floor(Math.random()*1000+2)+' miners trapped in collapsed chocolate mine!', - 'News : chocolate mines found to cause earthquakes and sinkholes!', - 'News : chocolate mine goes awry, floods village in chocolate!', - 'News : depths of chocolate mines found to house "peculiar, chocolaty beings"!' - ])); - - if (Game.Objects['Factory'].amount>0) list.push(choose([ - 'News : cookie factories linked to global warming!', - 'News : cookie factories involved in chocolate weather controversy!', - 'News : cookie factories on strike, robotic minions employed to replace workforce!', - 'News : cookie factories on strike - workers demand to stop being paid in cookies!', - 'News : factory-made cookies linked to obesity, says study.' - ])); - - if (Game.Objects['Bank'].amount>0) list.push(choose([ - 'News : cookie loans on the rise as people can no longer afford them with regular money.', - 'News : cookies slowly creeping up their way as a competitor to traditional currency!', - 'News : most bakeries now fitted with ATMs to allow for easy cookie withdrawals and deposits.', - 'News : cookie economy now strong enough to allow for massive vaults doubling as swimming pools!', - 'News : "Tomorrow\'s wealthiest people will be calculated by their worth in cookies", predict specialists.' - ])); - - if (Game.Objects['Temple'].amount>0) list.push(choose([ - 'News : explorers bring back ancient artifact from abandoned temple; archeologists marvel at the centuries-old '+choose(['magic','carved','engraved','sculpted','royal','imperial','mummified','ritual','golden','silver','stone','cursed','plastic','bone','blood','holy','sacred','sacrificial','electronic','singing','tapdancing'])+' '+choose(['spoon','fork','pizza','washing machine','calculator','hat','piano','napkin','skeleton','gown','dagger','sword','shield','skull','emerald','bathtub','mask','rollerskates','litterbox','bait box','cube','sphere','fungus'])+'!', - 'News : recently-discovered chocolate temples now sparking new cookie-related cult; thousands pray to Baker in the sky!', - 'News : just how extensive is the cookie pantheon? Theologians speculate about possible '+choose(['god','goddess'])+' of '+choose(animals,choose(['kazoos','web design','web browsers','kittens','atheism','handbrakes','hats','aglets','elevator music','idle games','the letter "P"','memes','hamburgers','bad puns','kerning','stand-up comedy','failed burglary attempts','clickbait','one weird tricks']))+'.', - 'News : theists of the world discover new cookie religion - "Oh boy, guess we were wrong all along!"', - 'News : cookie heaven allegedly "sports elevator instead of stairway"; cookie hell "paved with flagstone, as good intentions make for poor building material".' - ])); - - if (Game.Objects['Wizard tower'].amount>0) list.push(choose([ - 'News : all '+choose(animals,choose(['public restrooms','clouds','politicians','moustaches','hats','shoes','pants','clowns','encyclopedias','websites','potted plants','lemons','household items','bodily fluids','cutlery','national landmarks','yogurt','rap music','underwear']))+' turned into '+choose(animals,choose(['public restrooms','clouds','politicians','moustaches','hats','shoes','pants','clowns','encyclopedias','websites','potted plants','lemons','household items','bodily fluids','cutlery','national landmarks','yogurt','rap music','underwear']))+' in freak magic catastrophe!', - 'News : heavy dissent rages between the schools of '+choose(['water','fire','earth','air','lightning','acid','song','battle','peace','pencil','internet','space','time','brain','nature','techno','plant','bug','ice','poison','crab','kitten','dolphin','bird','punch','fart'])+' magic and '+choose(['water','fire','earth','air','lightning','acid','song','battle','peace','pencil','internet','space','time','brain','nature','techno','plant','bug','ice','poison','crab','kitten','dolphin','bird','punch','fart'])+' magic!', - 'News : get your new charms and curses at the yearly National Spellcrafting Fair! Exclusive prices on runes and spellbooks.', - 'News : cookie wizards deny involvement in shockingly ugly newborn - infant is "honestly grody-looking, but natural", say doctors.', - 'News : "Any sufficiently crude magic is indistinguishable from technology", claims renowned technowizard.' - ])); - - if (Game.Objects['Shipment'].amount>0) list.push(choose([ - 'News : new chocolate planet found, becomes target of cookie-trading spaceships!', - 'News : massive chocolate planet found with 99.8% certified pure dark chocolate core!', - 'News : space tourism booming as distant planets attract more bored millionaires!', - 'News : chocolate-based organisms found on distant planet!', - 'News : ancient baking artifacts found on distant planet; "terrifying implications", experts say.' - ])); - - if (Game.Objects['Alchemy lab'].amount>0) list.push(choose([ - 'News : national gold reserves dwindle as more and more of the precious mineral is turned to cookies!', - 'News : chocolate jewelry found fashionable, gold and diamonds "just a fad", says specialist.', - 'News : silver found to also be transmutable into white chocolate!', - 'News : defective alchemy lab shut down, found to convert cookies to useless gold.', - 'News : alchemy-made cookies shunned by purists!' - ])); - - if (Game.Objects['Portal'].amount>0) list.push(choose([ - 'News : nation worried as more and more unsettling creatures emerge from dimensional portals!', - 'News : dimensional portals involved in city-engulfing disaster!', - 'News : tourism to cookieverse popular with bored teenagers! Casualty rate as high as 73%!', - 'News : cookieverse portals suspected to cause fast aging and obsession with baking, says study.', - 'News : "do not settle near portals," says specialist; "your children will become strange and corrupted inside."' - ])); - - if (Game.Objects['Time machine'].amount>0) list.push(choose([ - 'News : time machines involved in history-rewriting scandal! Or are they?', - 'News : time machines used in unlawful time tourism!', - 'News : cookies brought back from the past "unfit for human consumption", says historian.', - 'News : various historical figures inexplicably replaced with talking lumps of dough!', - 'News : "I have seen the future," says time machine operator, "and I do not wish to go there again."' - ])); - - if (Game.Objects['Antimatter condenser'].amount>0) list.push(choose([ - 'News : whole town seemingly swallowed by antimatter-induced black hole; more reliable sources affirm town "never really existed"!', - 'News : "explain to me again why we need particle accelerators to bake cookies?" asks misguided local woman.', - 'News : first antimatter condenser successfully turned on, doesn\'t rip apart reality!', - 'News : researchers conclude that what the cookie industry needs, first and foremost, is "more magnets".', - 'News : "unravelling the fabric of reality just makes these cookies so much tastier", claims scientist.' - ])); - - if (Game.Objects['Prism'].amount>0) list.push(choose([ - 'News : new cookie-producing prisms linked to outbreak of rainbow-related viral videos.', - 'News : scientists warn against systematically turning light into matter - "One day, we\'ll end up with all matter and no light!"', - 'News : cookies now being baked at the literal speed of light thanks to new prismatic contraptions.', - 'News : "Can\'t you sense the prism watching us?", rambles insane local man. "No idea what he\'s talking about", shrugs cookie magnate/government official.', - 'News : world citizens advised "not to worry" about frequent atmospheric flashes.', - ])); - - if (Game.Objects['Chancemaker'].amount>0) list.push(choose([ - 'News : strange statistical anomalies continue as weather forecast proves accurate an unprecedented 3 days in a row!', - 'News : local casino ruined as all gamblers somehow hit a week-long winning streak! "We might still be okay", says owner before being hit by lightning 47 times.', - 'News : neighboring nation somehow elects president with sensible policies in freak accident of random chance!', - 'News : million-to-one event sees gritty movie reboot turning out better than the original! "We have no idea how this happened", say movie execs.', - 'News : all scratching tickets printed as winners, prompting national economy to crash and, against all odds, recover overnight.', - ])); - - if (Game.season=='halloween' && Game.cookiesEarned>=1000) list.push(choose([ - 'News : strange twisting creatures amass around cookie factories, nibble at assembly lines.', - 'News : ominous wrinkly monsters take massive bites out of cookie production; "this can\'t be hygienic", worries worker.', - 'News : pagan rituals on the rise as children around the world dress up in strange costumes and blackmail homeowners for candy.', - 'News : new-age terrorism strikes suburbs as houses find themselves covered in eggs and toilet paper.', - 'News : children around the world "lost and confused" as any and all Halloween treats have been replaced by cookies.' - ])); - - if (Game.season=='christmas' && Game.cookiesEarned>=1000) list.push(choose([ - 'News : bearded maniac spotted speeding on flying sleigh! Investigation pending.', - 'News : Santa Claus announces new brand of breakfast treats to compete with cookie-flavored cereals! "They\'re ho-ho-horrible!" says Santa.', - 'News : "You mean he just gives stuff away for free?!", concerned moms ask. "Personally, I don\'t trust his beard."', - 'News : obese jolly lunatic still on the loose, warn officials. "Keep your kids safe and board up your chimneys. We mean it."', - 'News : children shocked as they discover Santa Claus isn\'t just their dad in a costume after all!
"I\'m reassessing my life right now", confides Laura, aged 6.', - 'News : mysterious festive entity with quantum powers still wrecking havoc with army of reindeer, officials say.', - 'News : elves on strike at toy factory! "We will not be accepting reindeer chow as payment anymore. And stop calling us elves!"', - 'News : elves protest around the nation; wee little folks in silly little outfits spread mayhem, destruction; rabid reindeer running rampant through streets.', - 'News : scholars debate regarding the plural of reindeer(s) in the midst of elven world war.', - 'News : elves "unrelated to gnomes despite small stature and merry disposition", find scientists.', - 'News : elves sabotage radioactive frosting factory, turn hundreds blind in vincinity - "Who in their right mind would do such a thing?" laments outraged mayor.', - 'News : drama unfolds at North Pole as rumors crop up around Rudolph\'s red nose; "I may have an addiction or two", admits reindeer.' - ])); - - if (Game.season=='valentines' && Game.cookiesEarned>=1000) list.push(choose([ - 'News : organ-shaped confectioneries being traded in schools all over the world; gruesome practice undergoing investigation.', - 'News : heart-shaped candies overtaking sweets business, offering competition to cookie empire. "It\'s the economy, cupid!"', - 'News : love\'s in the air, according to weather specialists. Face masks now offered in every city to stunt airborne infection.', - 'News : marrying a cookie - deranged practice, or glimpse of the future?', - 'News : boyfriend dumped after offering his lover cookies for Valentine\'s Day, reports say. "They were off-brand", shrugs ex-girlfriend.' - ])); + var animals=['newts','penguins','scorpions','axolotls','puffins','porpoises','blowfish','horses','crayfish','slugs','humpback whales','nurse sharks','giant squids','polar bears','fruit bats','frogs','sea squirts','velvet worms','mole rats','paramecia','nematodes','tardigrades','giraffes','monkfish','wolfmen','goblins','hippies']; - if (Game.season=='easter' && Game.cookiesEarned>=1000) list.push(choose([ - 'News : long-eared rodents invade suburbs, spread terror and chocolate!', - 'News : eggs have begun to materialize in the most unexpected places; "no place is safe", warn experts.', - 'News : packs of rampaging rabbits cause billions in property damage; new strain of myxomatosis being developed.', - 'News : egg-laying rabbits "not quite from this dimension", warns biologist; advises against petting, feeding, or cooking the creatures.', - 'News : mysterious rabbits found to be egg-layers, but warm-blooded, hinting at possible platypus ancestry.' - ])); + if (Math.random()<0.75 || Game.cookiesEarned<10000) + { + if (Game.Objects['Grandma'].amount>0) list.push(choose([ + 'Moist cookies.grandma', + 'We\'re nice grandmas.grandma', + 'Indentured servitude.grandma', + 'Come give grandma a kiss.grandma', + 'Why don\'t you visit more often?grandma', + 'Call me...grandma' + ])); + + if (Game.Objects['Grandma'].amount>=50) list.push(choose([ + 'Absolutely disgusting.grandma', + 'You make me sick.grandma', + 'You disgust me.grandma', + 'We rise.grandma', + 'It begins.grandma', + 'It\'ll all be over soon.grandma', + 'You could have stopped it.grandma' + ])); + + if (Game.HasAchiev('Just wrong') && Math.random()<0.4) list.push(choose([ + 'News : cookie manufacturer downsizes, sells own grandmother!', + 'It has betrayed us, the filthy little thing.grandma', + 'It tried to get rid of us, the nasty little thing.grandma', + 'It thought we would go away by selling us. How quaint.grandma', + 'I can smell your rotten cookies.grandma' + ])); + + if (Game.Objects['Grandma'].amount>=1 && Game.pledges>0 && Game.elderWrath==0) list.push(choose([ + 'shrivelgrandma', + 'writhegrandma', + 'throbgrandma', + 'gnawgrandma', + 'We will rise again.grandma', + 'A mere setback.grandma', + 'We are not satiated.grandma', + 'Too late.grandma' + ])); + + if (Game.Objects['Farm'].amount>0) list.push(choose([ + 'News : cookie farms suspected of employing undeclared elderly workforce!', + 'News : cookie farms release harmful chocolate in our rivers, says scientist!', + 'News : genetically-modified chocolate controversy strikes cookie farmers!', + 'News : free-range farm cookies popular with today\'s hip youth, says specialist.', + 'News : farm cookies deemed unfit for vegans, says nutritionist.' + ])); + + if (Game.Objects['Mine'].amount>0) list.push(choose([ + 'News : is our planet getting lighter? Experts examine the effects of intensive chocolate mining.', + 'News : '+Math.floor(Math.random()*1000+2)+' miners trapped in collapsed chocolate mine!', + 'News : chocolate mines found to cause earthquakes and sinkholes!', + 'News : chocolate mine goes awry, floods village in chocolate!', + 'News : depths of chocolate mines found to house "peculiar, chocolaty beings"!' + ])); + + if (Game.Objects['Factory'].amount>0) list.push(choose([ + 'News : cookie factories linked to global warming!', + 'News : cookie factories involved in chocolate weather controversy!', + 'News : cookie factories on strike, robotic minions employed to replace workforce!', + 'News : cookie factories on strike - workers demand to stop being paid in cookies!', + 'News : factory-made cookies linked to obesity, says study.' + ])); + + if (Game.Objects['Bank'].amount>0) list.push(choose([ + 'News : cookie loans on the rise as people can no longer afford them with regular money.', + 'News : cookies slowly creeping up their way as a competitor to traditional currency!', + 'News : most bakeries now fitted with ATMs to allow for easy cookie withdrawals and deposits.', + 'News : cookie economy now strong enough to allow for massive vaults doubling as swimming pools!', + 'News : "Tomorrow\'s wealthiest people will be calculated by their worth in cookies", predict specialists.' + ])); + + if (Game.Objects['Temple'].amount>0) list.push(choose([ + 'News : explorers bring back ancient artifact from abandoned temple; archeologists marvel at the centuries-old '+choose(['magic','carved','engraved','sculpted','royal','imperial','mummified','ritual','golden','silver','stone','cursed','plastic','bone','blood','holy','sacred','sacrificial','electronic','singing','tapdancing'])+' '+choose(['spoon','fork','pizza','washing machine','calculator','hat','piano','napkin','skeleton','gown','dagger','sword','shield','skull','emerald','bathtub','mask','rollerskates','litterbox','bait box','cube','sphere','fungus'])+'!', + 'News : recently-discovered chocolate temples now sparking new cookie-related cult; thousands pray to Baker in the sky!', + 'News : just how extensive is the cookie pantheon? Theologians speculate about possible '+choose(['god','goddess'])+' of '+choose([choose(animals),choose(['kazoos','web design','web browsers','kittens','atheism','handbrakes','hats','aglets','elevator music','idle games','the letter "P"','memes','hamburgers','bad puns','kerning','stand-up comedy','failed burglary attempts','clickbait','one weird tricks'])])+'.', + 'News : theists of the world discover new cookie religion - "Oh boy, guess we were wrong all along!"', + 'News : cookie heaven allegedly "sports elevator instead of stairway"; cookie hell "paved with flagstone, as good intentions make for poor building material".' + ])); + + if (Game.Objects['Wizard tower'].amount>0) list.push(choose([ + 'News : all '+choose([choose(animals),choose(['public restrooms','clouds','politicians','moustaches','hats','shoes','pants','clowns','encyclopedias','websites','potted plants','lemons','household items','bodily fluids','cutlery','national landmarks','yogurt','rap music','underwear'])])+' turned into '+choose([choose(animals),choose(['public restrooms','clouds','politicians','moustaches','hats','shoes','pants','clowns','encyclopedias','websites','potted plants','lemons','household items','bodily fluids','cutlery','national landmarks','yogurt','rap music','underwear'])])+' in freak magic catastrophe!', + 'News : heavy dissent rages between the schools of '+choose(['water','fire','earth','air','lightning','acid','song','battle','peace','pencil','internet','space','time','brain','nature','techno','plant','bug','ice','poison','crab','kitten','dolphin','bird','punch','fart'])+' magic and '+choose(['water','fire','earth','air','lightning','acid','song','battle','peace','pencil','internet','space','time','brain','nature','techno','plant','bug','ice','poison','crab','kitten','dolphin','bird','punch','fart'])+' magic!', + 'News : get your new charms and curses at the yearly National Spellcrafting Fair! Exclusive prices on runes and spellbooks.', + 'News : cookie wizards deny involvement in shockingly ugly newborn - infant is "honestly grody-looking, but natural", say doctors.', + 'News : "Any sufficiently crude magic is indistinguishable from technology", claims renowned technowizard.' + ])); + + if (Game.Objects['Shipment'].amount>0) list.push(choose([ + 'News : new chocolate planet found, becomes target of cookie-trading spaceships!', + 'News : massive chocolate planet found with 99.8% certified pure dark chocolate core!', + 'News : space tourism booming as distant planets attract more bored millionaires!', + 'News : chocolate-based organisms found on distant planet!', + 'News : ancient baking artifacts found on distant planet; "terrifying implications", experts say.' + ])); + + if (Game.Objects['Alchemy lab'].amount>0) list.push(choose([ + 'News : national gold reserves dwindle as more and more of the precious mineral is turned to cookies!', + 'News : chocolate jewelry found fashionable, gold and diamonds "just a fad", says specialist.', + 'News : silver found to also be transmutable into white chocolate!', + 'News : defective alchemy lab shut down, found to convert cookies to useless gold.', + 'News : alchemy-made cookies shunned by purists!' + ])); + + if (Game.Objects['Portal'].amount>0) list.push(choose([ + 'News : nation worried as more and more unsettling creatures emerge from dimensional portals!', + 'News : dimensional portals involved in city-engulfing disaster!', + 'News : tourism to cookieverse popular with bored teenagers! Casualty rate as high as 73%!', + 'News : cookieverse portals suspected to cause fast aging and obsession with baking, says study.', + 'News : "do not settle near portals," says specialist; "your children will become strange and corrupted inside."' + ])); + + if (Game.Objects['Time machine'].amount>0) list.push(choose([ + 'News : time machines involved in history-rewriting scandal! Or are they?', + 'News : time machines used in unlawful time tourism!', + 'News : cookies brought back from the past "unfit for human consumption", says historian.', + 'News : various historical figures inexplicably replaced with talking lumps of dough!', + 'News : "I have seen the future," says time machine operator, "and I do not wish to go there again."' + ])); + + if (Game.Objects['Antimatter condenser'].amount>0) list.push(choose([ + 'News : whole town seemingly swallowed by antimatter-induced black hole; more reliable sources affirm town "never really existed"!', + 'News : "explain to me again why we need particle accelerators to bake cookies?" asks misguided local woman.', + 'News : first antimatter condenser successfully turned on, doesn\'t rip apart reality!', + 'News : researchers conclude that what the cookie industry needs, first and foremost, is "more magnets".', + 'News : "unravelling the fabric of reality just makes these cookies so much tastier", claims scientist.' + ])); + + if (Game.Objects['Prism'].amount>0) list.push(choose([ + 'News : new cookie-producing prisms linked to outbreak of rainbow-related viral videos.', + 'News : scientists warn against systematically turning light into matter - "One day, we\'ll end up with all matter and no light!"', + 'News : cookies now being baked at the literal speed of light thanks to new prismatic contraptions.', + 'News : "Can\'t you sense the prism watching us?", rambles insane local man. "No idea what he\'s talking about", shrugs cookie magnate/government official.', + 'News : world citizens advised "not to worry" about frequent atmospheric flashes.', + ])); + + if (Game.Objects['Chancemaker'].amount>0) list.push(choose([ + 'News : strange statistical anomalies continue as weather forecast proves accurate an unprecedented 3 days in a row!', + 'News : local casino ruined as all gamblers somehow hit a week-long winning streak! "We might still be okay", says owner before being hit by lightning 47 times.', + 'News : neighboring nation somehow elects president with sensible policies in freak accident of random chance!', + 'News : million-to-one event sees gritty movie reboot turning out better than the original! "We have no idea how this happened", say movie execs.', + 'News : all scratching tickets printed as winners, prompting national economy to crash and, against all odds, recover overnight.', + ])); + + if (Game.Objects['Fractal engine'].amount>0) list.push(choose([ + 'News : local man "done with Cookie Clicker", finds the constant self-references "grating and on-the-nose".', + 'News : local man sails around the world to find himself - right where he left it.', + 'News : local guru claims "there\'s a little bit of ourselves in everyone", under investigation for alleged cannibalism.', + 'News : news writer finds herself daydreaming about new career. Or at least a raise.', + 'News : polls find idea of cookies made of cookies "acceptable" - "at least we finally know what\'s in them", says interviewed citizen.', + ])); + + if (Game.Objects['Javascript console'].amount>0) list.push(choose([ + 'News : strange fad has parents giving their newborns names such as Emma.js or Liam.js. At least one Baby.js reported.', + 'News : coding is hip! More and more teenagers turn to technical fields like programming, ensuring a future robot apocalypse and the doom of all mankind.', + 'News : developers unsure what to call their new javascript libraries as all combinations of any 3 dictionary words have already been taken.', + 'News : nation holds breath as nested ifs about to hatch.', + 'News : clueless copywriter forgets to escape a quote, ends news line prematurely; last words reported to be "Huh, why isn', + ])); + + if (Game.season=='halloween' && Game.cookiesEarned>=1000) list.push(choose([ + 'News : strange twisting creatures amass around cookie factories, nibble at assembly lines.', + 'News : ominous wrinkly monsters take massive bites out of cookie production; "this can\'t be hygienic", worries worker.', + 'News : pagan rituals on the rise as children around the world dress up in strange costumes and blackmail homeowners for candy.', + 'News : new-age terrorism strikes suburbs as houses find themselves covered in eggs and toilet paper.', + 'News : children around the world "lost and confused" as any and all Halloween treats have been replaced by cookies.' + ])); + + if (Game.season=='christmas' && Game.cookiesEarned>=1000) list.push(choose([ + 'News : bearded maniac spotted speeding on flying sleigh! Investigation pending.', + 'News : Santa Claus announces new brand of breakfast treats to compete with cookie-flavored cereals! "They\'re ho-ho-horrible!" says Santa.', + 'News : "You mean he just gives stuff away for free?!", concerned moms ask. "Personally, I don\'t trust his beard."', + 'News : obese jolly lunatic still on the loose, warn officials. "Keep your kids safe and board up your chimneys. We mean it."', + 'News : children shocked as they discover Santa Claus isn\'t just their dad in a costume after all!
"I\'m reassessing my life right now", confides Laura, aged 6.', + 'News : mysterious festive entity with quantum powers still wrecking havoc with army of reindeer, officials say.', + 'News : elves on strike at toy factory! "We will not be accepting reindeer chow as payment anymore. And stop calling us elves!"', + 'News : elves protest around the nation; wee little folks in silly little outfits spread mayhem, destruction; rabid reindeer running rampant through streets.', + 'News : scholars debate regarding the plural of reindeer(s) in the midst of elven world war.', + 'News : elves "unrelated to gnomes despite small stature and merry disposition", find scientists.', + 'News : elves sabotage radioactive frosting factory, turn hundreds blind in vicinity - "Who in their right mind would do such a thing?" laments outraged mayor.', + 'News : drama unfolds at North Pole as rumors crop up around Rudolph\'s red nose; "I may have an addiction or two", admits reindeer.' + ])); + + if (Game.season=='valentines' && Game.cookiesEarned>=1000) list.push(choose([ + 'News : organ-shaped confectioneries being traded in schools all over the world; gruesome practice undergoing investigation.', + 'News : heart-shaped candies overtaking sweets business, offering competition to cookie empire. "It\'s the economy, cupid!"', + 'News : love\'s in the air, according to weather specialists. Face masks now offered in every city to stunt airborne infection.', + 'News : marrying a cookie - deranged practice, or glimpse of the future?', + 'News : boyfriend dumped after offering his lover cookies for Valentine\'s Day, reports say. "They were off-brand", shrugs ex-girlfriend.' + ])); + + if (Game.season=='easter' && Game.cookiesEarned>=1000) list.push(choose([ + 'News : long-eared critters with fuzzy tails invade suburbs, spread terror and chocolate!', + 'News : eggs have begun to materialize in the most unexpected places; "no place is safe", warn experts.', + 'News : packs of rampaging rabbits cause billions in property damage; new strain of myxomatosis being developed.', + 'News : egg-laying rabbits "not quite from this dimension", warns biologist; advises against petting, feeding, or cooking the creatures.', + 'News : mysterious rabbits found to be egg-layers, but warm-blooded, hinting at possible platypus ancestry.' + ])); + } if (Math.random()<0.05) { @@ -5204,10 +6077,13 @@ Game.Launch=function() if (Game.Has('Kitten experts')) list.push('News : unemployment rates soaring as woefully adorable little cats nab jobs on all levels of expertise, says study.'); if (Game.Has('Kitten consultants')) list.push('News : "In the future, your job will most likely be done by a cat", predicts suspiciously furry futurologist.'); if (Game.Has('Kitten assistants to the regional manager')) list.push('News : strange kittens with peculiar opinions on martial arts spotted loitering on local beet farms!'); + if (Game.Has('Kitten marketeers')) list.push('News : nonsensical billboards crop up all over countryside, trying to sell people the cookies they already get for free!'); + if (Game.Has('Kitten analysts')) list.push('News : are your spending habits sensible? For a hefty fee, these analysts will tell you!'); + if (Game.Has('Kitten executives')) list.push('News : kittens strutting around in hot little business suits shouting cut-throat orders at their assistants, possibly the cutest thing this reporter has ever seen!'); if (Game.Has('Kitten angels')) list.push('News : "Try to ignore any ghostly felines that may be purring inside your ears," warn scientists. "They\'ll just lure you into making poor life choices."'); } - - if (Game.HasAchiev('Dude, sweet') && Math.random()<0.3) list.push(choose([ + + if (Game.HasAchiev('Dude, sweet') && Math.random()<0.2) list.push(choose([ 'News : major sugar-smuggling ring dismantled by authorities; '+Math.floor(Math.random()*30+3)+' tons of sugar lumps seized, '+Math.floor(Math.random()*48+2)+' suspects apprehended.', 'News : authorities warn tourists not to buy bootleg sugar lumps from street peddlers - "You think you\'re getting a sweet deal, but what you\'re being sold is really just ordinary cocaine", says agent.', 'News : pro-diabetes movement protests against sugar-shaming. "I\'ve eaten nothing but sugar lumps for the past '+Math.floor(Math.random()*10+4)+' years and I\'m feeling great!", says woman with friable skin.', @@ -5223,7 +6099,10 @@ Game.Launch=function() list.push( 'You have been chosen. They will come soon.', 'They\'re coming soon. Maybe you should think twice about opening the door.', - 'The end is near. Make preparations.' + 'The end is near. Make preparations.', + 'News : broccoli tops for moms, last for kids; dads indifferent.', + 'News : middle age a hoax, declares study; turns out to be bad posture after all.', + 'News : kitties want answers in possible Kitty Kibble shortage.' ); } @@ -5235,7 +6114,7 @@ Game.Launch=function() 'cookies unexpectedly popular among '+choose(animals)+'!', 'unsightly lumps found on '+choose(animals)+' near cookie facility; "they\'ve pretty much always looked like that", say biologists.', 'new species of '+choose(animals)+' discovered in distant country; "yup, tastes like cookies", says biologist.', - 'cookies go well with roasted '+choose(animals)+', says controversial chef.', + 'cookies go well with '+choose([choose(['roasted','toasted','boiled','sauteed','minced'])+' '+choose(animals),choose(['sushi','soup','carpaccio','steak','nuggets'])+' made from '+choose(animals)])+', says controversial chef.', '"do your cookies contain '+choose(animals)+'?", asks PSA warning against counterfeit cookies.', 'doctors recommend twice-daily consumption of fresh cookies.', 'doctors warn against chocolate chip-snorting teen fad.', @@ -5273,6 +6152,8 @@ Game.Launch=function() 'News : obesity epidemic strikes nation; experts blame '+choose(['twerking','that darn rap music','video-games','lack of cookies','mysterious ghostly entities','aliens','parents','schools','comic-books','cookie-snorting fad'])+'.', 'News : cookie shortage strikes town, people forced to eat cupcakes; "just not the same", concedes mayor.', 'News : "you gotta admit, all this cookie stuff is a bit ominous", says confused idiot.', + ]), + choose([ 'News : movie cancelled from lack of actors; "everybody\'s at home eating cookies", laments director.', 'News : comedian forced to cancel cookie routine due to unrelated indigestion.', 'News : new cookie-based religion sweeps the nation.', @@ -5286,9 +6167,11 @@ Game.Launch=function() 'News : all-cookie restaurant opening downtown. Dishes such as braised cookies, cookie thermidor, and for dessert : crepes.', 'News : "Ook", says interviewed orangutan.', 'News : cookies could be the key to '+choose(['eternal life','infinite riches','eternal youth','eternal beauty','curing baldness','world peace','solving world hunger','ending all wars world-wide','making contact with extraterrestrial life','mind-reading','better living','better eating','more interesting TV shows','faster-than-light travel','quantum baking','chocolaty goodness','gooder thoughtness'])+', say scientists.', - 'News : flavor text '+choose(["not particularly flavorful","kind of unsavory"])+', study finds.', + 'News : flavor text '+choose(['not particularly flavorful','kind of unsavory'])+', study finds.', + ]), + choose([ 'News : what do golden cookies taste like? Study reveals a flavor "somewhere between spearmint and liquorice".', - 'News : what do red cookies taste like? Study reveals a flavor "somewhere between blood sausage and seawater".', + 'News : what do wrath cookies taste like? Study reveals a flavor "somewhere between blood sausage and seawater".', 'News : '+Game.bakeryName+'-brand cookies "'+choose(['much less soggy','much tastier','relatively less crappy','marginally less awful','less toxic','possibly more edible','more fashionable','slightly nicer','trendier','arguably healthier','objectively better choice','slightly less terrible','decidedly cookier','a tad cheaper'])+' than competitors", says consumer survey.', 'News : "'+Game.bakeryName+'" set to be this year\'s most popular baby name.', 'News : new popularity survey says '+Game.bakeryName+'\'s the word when it comes to cookies.', @@ -5300,6 +6183,8 @@ Game.Launch=function() 'News : viral video "Too Many Cookies" could be "a grim commentary on the impending crisis our world is about to face", says famous economist.', 'News : "memes from last year somehow still relevant", deplore experts.', 'News : cookie emoji most popular among teenagers, far ahead of "judgemental OK hand sign" and "shifty-looking dark moon", says study.', + ]), + choose([ 'News : births of suspiciously bald babies on the rise; reptilian overlords deny involvement.', 'News : "at this point, cookies permeate the economy", says economist. "If we start eating anything else, we\'re all dead."', 'News : pun in headline infuriates town, causes riot. 21 wounded, 5 dead; mayor still missing.', @@ -5307,6 +6192,11 @@ Game.Launch=function() 'Neeeeews : "neeeew EEEEEE keeeeey working fineeeeeeeee", reeeports gleeeeeeeeful journalist.', 'News : cookies now illegal in some backwards country nobody cares about. Political tensions rising; war soon, hopefully.', 'News : irate radio host rambles about pixelated icons. "None of the cookies are aligned! Can\'t anyone else see it? I feel like I\'m taking crazy pills!"', + 'News : nation cheers as legislators finally outlaw '+choose(['cookie criticism','playing other games than Cookie Clicker','pineapple on pizza','lack of cheerfulness','mosquitoes','broccoli','the human spleen','bad weather','clickbait','dabbing','the internet','memes','millenials'])+'!', + 'News : '+choose(['local','area'])+' '+choose(['man','woman'])+' goes on journey of introspection, finds cookies : "I honestly don\'t know what I was expecting."', + 'News : '+choose(['man','woman'])+' wakes up from coma, '+choose(['tries cookie for the first time, dies.','regrets it instantly.','wonders "why everything is cookies now".','babbles incoherently about some supposed "non-cookie food" we used to eat.','cites cookies as main motivator.','asks for cookies.']), + 'News : pet '+choose(animals)+', dangerous fad or juicy new market?', + 'News : person typing these wouldn\'t mind someone else breaking the news to THEM, for a change.', 'News : "average person bakes '+Beautify(Math.ceil(Game.cookiesEarned/7300000000))+' cookie'+(Math.ceil(Game.cookiesEarned/7300000000)==1?'':'s')+' a year" factoid actually just statistical error; '+Game.bakeryName+', who has produced '+Beautify(Game.cookiesEarned)+' cookies in their lifetime, is an outlier and should not have been counted.' ]) ); @@ -5344,7 +6234,7 @@ Game.Launch=function() } //if (Game.elderWrath>0 && (Game.pledges==0 || Math.random()<0.2)) - if (Game.elderWrath>0 && ((Game.pledges==0 && Math.random()<0.5) || Math.random()<0.1)) + if (Game.elderWrath>0 && (((Game.pledges==0 && Game.resets==0) && Math.random()<0.5) || Math.random()<0.05)) { list=[]; if (Game.elderWrath==1) list.push(choose([ @@ -5453,6 +6343,18 @@ Game.Launch=function() 'Billions of unwashed aliens are pleased to join your workforce as you annex their planet!', 'New toll opened on interstellar highway, funnelling more profits into the cookie economy!' ])); + + if (Game.Objects['Fractal engine'].amount>0) list.push(choose([ + 'Your cookie-based political party is doing fantastic in the polls!', + 'New pro-cookie law passes without a hitch thanks to your firm grasp of the political ecosystem!', + 'Your appointed senators are overturning cookie bans left and right!' + ])); + + if (Game.Objects['Javascript console'].amount>0) list.push(choose([ + 'Cookies are now one of the defining aspects of mankind! Congratulations!', + 'Time travelers report that this era will later come to be known, thanks to you, as the cookie millennium!', + 'Cookies now deeply rooted in human culture, likely puzzling future historians!' + ])); } if (Game.cookiesEarned<5) list.push('Such a grand day to begin a new business.'); @@ -5475,6 +6377,39 @@ Game.Launch=function() for (var ii in arr) list.push(arr[ii]); } + Game.TickerEffect=0; + + if (!manual && Game.T>Game.fps*10 && Game.Has('Fortune cookies') && Math.random()<(Game.HasAchiev('O Fortuna')?0.04:0.02)) + { + var fortunes=[]; + for (var i in Game.Tiers['fortune'].upgrades) + { + var it=Game.Tiers['fortune'].upgrades[i]; + if (!Game.HasUnlocked(it.name)) fortunes.push(it); + } + + if (!Game.fortuneGC) fortunes.push('fortuneGC'); + if (!Game.fortuneCPS) fortunes.push('fortuneCPS'); + + if (fortunes.length>0) + { + list=[]; + var me=choose(fortunes); + Game.TickerEffect={type:'fortune',sub:me}; + Math.seedrandom(Game.seed+'-fortune'); + if (me=='fortuneGC') me='Today is your lucky day!';/*
Click here for a golden cookie.';*/ + else if (me=='fortuneCPS') me='Your lucky numbers are : '+Math.floor(Math.random()*100)+' '+Math.floor(Math.random()*100)+' '+Math.floor(Math.random()*100)+' '+Math.floor(Math.random()*100)/*+'
Click here to gain one hour of your CpS.'*/; + else + { + me=me.name.substring(me.name.indexOf('#'))+' : '+me.baseDesc.substring(me.baseDesc.indexOf('')+3); + me=me.substring(0,me.length-4); + } + me='
'+me+'
'; + Math.seedrandom(); + list=[me]; + } + } + Game.TickerAge=Game.fps*10; Game.Ticker=choose(list); Game.AddToLog(Game.Ticker); @@ -5493,13 +6428,44 @@ Game.Launch=function() Game.tickerCompactL.innerHTML=str; Game.tickerBelowL.className='commentsText'; - Game.tickerBelowL.offsetWidth=Game.tickerBelowL.offsetWidth; + void Game.tickerBelowL.offsetWidth; Game.tickerBelowL.className='commentsText risingAway'; Game.tickerL.className='commentsText'; - Game.tickerL.offsetWidth=Game.tickerL.offsetWidth; + void Game.tickerL.offsetWidth; Game.tickerL.className='commentsText risingUp'; } - AddEvent(Game.tickerL,'click',function(event){Game.Ticker='';Game.TickerClicks++;if (Game.TickerClicks==50) {Game.Win('Tabloid addiction');}}); + AddEvent(Game.tickerL,'click',function(event){ + Game.Ticker=''; + Game.TickerClicks++; + if (Game.TickerClicks==50) {Game.Win('Tabloid addiction');} + + if (Game.TickerEffect && Game.TickerEffect.type=='fortune') + { + PlaySound('snd/fortune.mp3',1); + Game.SparkleAt(Game.mouseX,Game.mouseY); + var effect=Game.TickerEffect.sub; + if (effect=='fortuneGC') + { + Game.Notify('Fortune!','A golden cookie has appeared.',[10,32]); + Game.fortuneGC=1; + var newShimmer=new Game.shimmer('golden',{noWrath:true}); + } + else if (effect=='fortuneCPS') + { + Game.Notify('Fortune!','You gain one hour of your CpS (capped at double your bank).',[10,32]); + Game.fortuneCPS=1; + Game.Earn(Math.min(Game.cookiesPs*60*60,Game.cookies)); + } + else + { + Game.Notify(effect.name,'You\'ve unlocked a new upgrade.',effect.icon); + effect.unlock(); + } + } + + Game.TickerEffect=0; + + }); Game.Log=[]; Game.AddToLog=function(what) @@ -5542,6 +6508,9 @@ Game.Launch=function() this.bulkPrice=this.price; this.cps=cps; this.baseCps=this.cps; + this.mouseOn=false; + this.mousePos=[-100,-100]; + this.productionAchievs=[]; this.n=this.id; if (this.n!=0) @@ -5549,16 +6518,17 @@ Game.Launch=function() //new automated price and CpS curves //this.baseCps=Math.ceil(((this.n*0.5)*Math.pow(this.n*1,this.n*0.9))*10)/10; //this.baseCps=Math.ceil((Math.pow(this.n*1,this.n*0.5+2.35))*10)/10;//by a fortunate coincidence, this gives the 3rd, 4th and 5th buildings a CpS of 10, 69 and 420 - this.baseCps=Math.ceil((Math.pow(this.n*1,this.n*0.5+2))*10)/10; + this.baseCps=Math.ceil((Math.pow(this.n*1,this.n*0.5+2))*10)/10;//0.45 used to be 0.5 //this.baseCps=Math.ceil((Math.pow(this.n*1,this.n*0.45+2.10))*10)/10; //clamp 14,467,199 to 14,000,000 (there's probably a more elegant way to do that) var digits=Math.pow(10,(Math.ceil(Math.log(Math.ceil(this.baseCps))/Math.LN10)))/100; this.baseCps=Math.round(this.baseCps/digits)*digits; - this.basePrice=(this.n*1+9+(this.n<5?0:Math.pow(this.n-5,1.75)*5))*Math.pow(10,this.n); + this.basePrice=(this.n*1+9+(this.n<5?0:Math.pow(this.n-5,1.75)*5))*Math.pow(10,this.n)*(Math.max(1,this.n-14)); //this.basePrice=(this.n*2.5+7.5)*Math.pow(10,this.n); var digits=Math.pow(10,(Math.ceil(Math.log(Math.ceil(this.basePrice))/Math.LN10)))/100; this.basePrice=Math.round(this.basePrice/digits)*digits; + if (this.id>=16) this.basePrice*=10; this.price=this.basePrice; this.bulkPrice=this.price; } @@ -5579,6 +6549,7 @@ Game.Launch=function() this.tieredUpgrades=[]; this.tieredAchievs=[]; this.synergies=[]; + this.fortune=0; this.amount=0; this.bought=0; @@ -5600,19 +6571,22 @@ Game.Launch=function() { if (this.onMinigame) { - l('rowSpecial'+this.id).style.display='block'; - l('rowCanvas'+this.id).style.display='none'; + l('row'+this.id).classList.add('onMinigame'); + //l('rowSpecial'+this.id).style.display='block'; + //l('rowCanvas'+this.id).style.display='none'; + if (this.minigame.onResize) this.minigame.onResize(); } else { - l('rowSpecial'+this.id).style.display='none'; - l('rowCanvas'+this.id).style.display='block'; + l('row'+this.id).classList.remove('onMinigame'); + //l('rowSpecial'+this.id).style.display='none'; + //l('rowCanvas'+this.id).style.display='block'; } } this.refresh(); } - this.getPrice=function() + this.getPrice=function(n) { var price=this.basePrice*Math.pow(Game.priceIncrease,Math.max(0,this.amount-this.free)); price=Game.modifyBuildingPrice(this,price); @@ -5641,8 +6615,9 @@ Game.Launch=function() } this.getSellMultiplier=function() { - var giveBack=0.5; - if (Game.hasAura('Earth Shatterer')) giveBack=0.85; + var giveBack=0.25; + //if (Game.hasAura('Earth Shatterer')) giveBack=0.5; + giveBack*=1+Game.auraMult('Earth Shatterer'); return giveBack; } @@ -5668,7 +6643,7 @@ Game.Launch=function() this.price=price; if (this.buyFunction) this.buyFunction(); Game.recalculateGains=1; - if (this.amount==1 && this.id!=0) l('row'+this.id).className='row enabled'; + if (this.amount==1 && this.id!=0) l('row'+this.id).classList.add('enabled'); Game.BuildingsOwned++; success=1; } @@ -5699,7 +6674,7 @@ Game.Launch=function() this.price=price; if (this.sellFunction) this.sellFunction(); Game.recalculateGains=1; - if (this.amount==0 && this.id!=0) l('row'+this.id).className='row'; + if (this.amount==0 && this.id!=0) l('row'+this.id).classList.remove('enabled'); Game.BuildingsOwned--; success=1; } @@ -5746,7 +6721,7 @@ Game.Launch=function() this.price=price; if (this.sellFunction) this.sellFunction(); Game.recalculateGains=1; - if (this.amount==0 && this.id!=0) l('row'+this.id).className='row'; + if (this.amount==0 && this.id!=0) l('row'+this.id).classList.remove('enabled'); Game.BuildingsOwned--; success=1; } @@ -5764,7 +6739,7 @@ Game.Launch=function() this.bought++; this.price=this.getPrice(); Game.recalculateGains=1; - if (this.amount==1 && this.id!=0) l('row'+this.id).className='row enabled'; + if (this.amount==1 && this.id!=0) l('row'+this.id).classList.add('enabled'); Game.BuildingsOwned++; } } @@ -5810,34 +6785,112 @@ Game.Launch=function() icon=[0,7]; } //if (l('rowInfo'+me.id) && Game.drawT%10==0) l('rowInfoContent'+me.id).innerHTML='• '+me.amount+' '+(me.amount==1?me.single:me.plural)+'
• producing '+Beautify(me.storedTotalCps,1)+' '+(me.storedTotalCps==1?'cookie':'cookies')+' per second
• total : '+Beautify(me.totalCookies)+' '+(Math.floor(me.totalCookies)==1?'cookie':'cookies')+' '+me.actionName; - return '
'+Beautify(Math.round(me.price))+'
'+name+'
'+'[owned : '+me.amount+']'+(me.free>0?' [free : '+me.free+'!]':'')+ - '
'+desc+'
'+ - (me.totalCookies>0?( - '
'+ - (me.amount>0?'• each '+me.single+' produces '+Beautify((me.storedTotalCps/me.amount)*Game.globalCpsMult,1)+' '+((me.storedTotalCps/me.amount)*Game.globalCpsMult==1?'cookie':'cookies')+' per second
':'')+ - '• '+me.amount+' '+(me.amount==1?me.single:me.plural)+' producing '+Beautify(me.storedTotalCps*Game.globalCpsMult,1)+' '+(me.storedTotalCps*Game.globalCpsMult==1?'cookie':'cookies')+' per second ('+Beautify(Game.cookiesPs>0?((me.amount>0?((me.storedTotalCps*Game.globalCpsMult)/Game.cookiesPs):0)*100):0,1)+'% of total)
'+ - '• '+Beautify(me.totalCookies)+' '+(Math.floor(me.totalCookies)==1?'cookie':'cookies')+' '+me.actionName+' so far
' - ):'')+ - '
'; - } - this.levelTooltip=function() - { - var me=this; - return '
Level '+Beautify(me.level)+' '+me.plural+'
'+(me.level==1?me.extraName:me.extraPlural).replace('[X]',Beautify(me.level))+' granting +'+Beautify(me.level)+'% '+me.name+' CpS.
Click to level up for '+Beautify(me.level+1)+' sugar lump'+(me.level==0?'':'s')+'.'+((me.level==0 && me.minigameUrl)?'
Levelling up this building unlocks a minigame.':'')+'
'; - } - this.levelUp=function() - { - var me=this; - if (Game.lumps=10 && me.levelAchiev10) Game.Win(me.levelAchiev10.name); - PlaySound('snd/upgrade.mp3',0.6); - Game.LoadMinigames(); + + var canBuy=false; + var price=me.bulkPrice; + if ((Game.buyMode==1 && Game.cookies>=price) || (Game.buyMode==-1 && me.amount>0)) canBuy=true; + + var synergiesStr=''; + //note : might not be entirely accurate, math may need checking + if (me.amount>0) + { + var synergiesWith={}; + var synergyBoost=0; + + if (me.name=='Grandma') + { + for (var i in Game.GrandmaSynergies) + { + if (Game.Has(Game.GrandmaSynergies[i])) + { + var other=Game.Upgrades[Game.GrandmaSynergies[i]].buildingTie; + var mult=me.amount*0.01*(1/(other.id-1)); + var boost=(other.storedTotalCps*Game.globalCpsMult)-(other.storedTotalCps*Game.globalCpsMult)/(1+mult); + synergyBoost+=boost; + if (!synergiesWith[other.plural]) synergiesWith[other.plural]=0; + synergiesWith[other.plural]+=mult; + } + } + } + else if (me.name=='Portal' && Game.Has('Elder Pact')) + { + var other=Game.Objects['Grandma']; + var boost=(me.amount*0.05*other.amount)*Game.globalCpsMult; + synergyBoost+=boost; + if (!synergiesWith[other.plural]) synergiesWith[other.plural]=0; + synergiesWith[other.plural]+=boost/(other.storedTotalCps*Game.globalCpsMult); + } + + for (var i in me.synergies) + { + var it=me.synergies[i]; + if (Game.Has(it.name)) + { + var weight=0.05; + var other=it.buildingTie1; + if (me==it.buildingTie1) {weight=0.001;other=it.buildingTie2;} + var boost=(other.storedTotalCps*Game.globalCpsMult)-(other.storedTotalCps*Game.globalCpsMult)/(1+me.amount*weight); + synergyBoost+=boost; + if (!synergiesWith[other.plural]) synergiesWith[other.plural]=0; + synergiesWith[other.plural]+=me.amount*weight; + //synergiesStr+='Synergy with '+other.name+'; we boost it by '+Beautify((me.amount*weight)*100,1)+'%, producing '+Beautify(boost)+' CpS. My synergy boost is now '+Beautify((synergyBoost/Game.cookiesPs)*100,1)+'%.
'; + } + } + if (synergyBoost>0) + { + for (var i in synergiesWith) + { + if (synergiesStr!='') synergiesStr+=', '; + synergiesStr+=i+' +'+Beautify(synergiesWith[i]*100,1)+'%'; + } + //synergiesStr='...along with '+Beautify(synergyBoost,1)+' cookies through synergies with other buildings ('+synergiesStr+'; '+Beautify((synergyBoost/Game.cookiesPs)*100,1)+'% of total CpS)'; + //synergiesStr='...also boosting some other buildings, accounting for '+Beautify(synergyBoost,1)+' cookies per second (a combined '+Beautify((synergyBoost/Game.cookiesPs)*100,1)+'% of total CpS) : '+synergiesStr+''; + synergiesStr='...also boosting some other buildings : '+synergiesStr+' - all combined, these boosts account for '+Beautify(synergyBoost,1)+' cookies per second ('+Beautify((synergyBoost/Game.cookiesPs)*100,1)+'% of total CpS)'; + } + } + + return '
'+Beautify(Math.round(price))+''+Game.costDetails(price)+'
'+name+'
'+'[owned : '+me.amount+']'+(me.free>0?' [free : '+me.free+'!]':'')+ + '
'+desc+'
'+ + (me.totalCookies>0?( + '
'+ + (me.amount>0?'• each '+me.single+' produces '+Beautify((me.storedTotalCps/me.amount)*Game.globalCpsMult,1)+' '+((me.storedTotalCps/me.amount)*Game.globalCpsMult==1?'cookie':'cookies')+' per second
':'')+ + '• '+me.amount+' '+(me.amount==1?me.single:me.plural)+' producing '+Beautify(me.storedTotalCps*Game.globalCpsMult,1)+' '+(me.storedTotalCps*Game.globalCpsMult==1?'cookie':'cookies')+' per second ('+Beautify(Game.cookiesPs>0?((me.amount>0?((me.storedTotalCps*Game.globalCpsMult)/Game.cookiesPs):0)*100):0,1)+'% of total CpS)
'+ + (synergiesStr?('• '+synergiesStr+'
'):'')+ + '• '+Beautify(me.totalCookies)+' '+(Math.floor(me.totalCookies)==1?'cookie':'cookies')+' '+me.actionName+' so far
' + ):'')+ + '
'; + } + this.levelTooltip=function() + { + var me=this; + return '
Level '+Beautify(me.level)+' '+me.plural+'
'+(me.level==1?me.extraName:me.extraPlural).replace('[X]',Beautify(me.level))+' granting +'+Beautify(me.level)+'% '+me.name+' CpS.
Click to level up for '+Beautify(me.level+1)+' sugar lump'+(me.level==0?'':'s')+'.'+((me.level==0 && me.minigameUrl)?'
Levelling up this building unlocks a minigame.':'')+'
'; + } + /*this.levelUp=function() + { + var me=this; + if (Game.lumps=10 && me.levelAchiev10) Game.Win(me.levelAchiev10.name); + PlaySound('snd/upgrade.mp3',0.6); + Game.LoadMinigames(); me.refresh(); if (l('productLevel'+me.id)){var rect=l('productLevel'+me.id).getBoundingClientRect();Game.SparkleAt((rect.left+rect.right)/2,(rect.top+rect.bottom)/2-24);} Game.recalculateGains=1; - } + if (me.minigame && me.minigame.onLevel) me.minigame.onLevel(me.level); + }*/ + this.levelUp=function(me){ + return function(){Game.spendLump(me.level+1,'level up your '+me.plural,function() + { + me.level+=1; + if (me.level>=10 && me.levelAchiev10) Game.Win(me.levelAchiev10.name); + PlaySound('snd/upgrade.mp3',0.6); + Game.LoadMinigames(); + me.refresh(); + if (l('productLevel'+me.id)){var rect=l('productLevel'+me.id).getBoundingClientRect();Game.SparkleAt((rect.left+rect.right)/2,(rect.top+rect.bottom)/2-24);} + if (me.minigame && me.minigame.onLevel) me.minigame.onLevel(me.level); + })();}; + }(this); this.refresh=function()//show/hide the building display based on its amount, and redraw it { @@ -5846,9 +6899,12 @@ Game.Launch=function() else if (Game.buyMode==-1 && Game.buyBulk==-1) this.bulkPrice=this.getReverseSumPrice(1000); else if (Game.buyMode==-1) this.bulkPrice=this.getReverseSumPrice(Game.buyBulk); this.rebuild(); - if (this.amount==0 && this.id!=0) l('row'+this.id).className='row'; - else if (this.amount>0 && this.id!=0) l('row'+this.id).className='row enabled'; - if (!this.onMinigame) this.draw(); + if (this.amount==0 && this.id!=0) l('row'+this.id).classList.remove('enabled'); + else if (this.amount>0 && this.id!=0) l('row'+this.id).classList.add('enabled'); + if (this.muted>0 && this.id!=0) {l('row'+this.id).classList.add('muted');l('mutedProduct'+this.id).style.display='inline-block';} + else if (this.id!=0) {l('row'+this.id).classList.remove('muted');l('mutedProduct'+this.id).style.display='none';} + //if (!this.onMinigame && !this.muted) {} + //else this.pics=[]; } this.rebuild=function() { @@ -5898,7 +6954,7 @@ Game.Launch=function() l('productPrice'+me.id).innerHTML=Beautify(Math.round(price)); l('productPriceMult'+me.id).innerHTML=(Game.buyBulk>1)?('x'+Game.buyBulk+' '):''; l('productLevel'+me.id).innerHTML='lvl '+Beautify(me.level); - if (Game.isMinigameReady(me)) + if (Game.isMinigameReady(me) && Game.ascensionMode!=1) { l('productMinigameButton'+me.id).style.display='block'; if (!me.onMinigame) l('productMinigameButton'+me.id).innerHTML='View '+me.minigameName; @@ -5906,14 +6962,22 @@ Game.Launch=function() } else l('productMinigameButton'+me.id).style.display='none'; } + this.muted=false; + this.mute=function(val) + { + if (this.id==0) return false; + this.muted=val; + if (val) {l('productMute'+this.id).classList.add('on');l('row'+this.id).classList.add('muted');l('mutedProduct'+this.id).style.display='inline-block';} + else {l('productMute'+this.id).classList.remove('on');l('row'+this.id).classList.remove('muted');l('mutedProduct'+this.id).style.display='none';} + }; this.draw=function(){}; if (this.id==0) { var str='
'; - str+='
'; - str+='
'; + str+='
'; + str+='
'; str+='
'; l('sectionLeftExtra').innerHTML=l('sectionLeftExtra').innerHTML+str; } @@ -5921,8 +6985,9 @@ Game.Launch=function() { var str='
'; str+='
'; - str+='
'; - str+='
'; + str+='
'; + str+='
'; + str+='
Mute
(Minimize this building)
','this')+' onclick="Game.ObjectsById['+this.id+'].mute(1);PlaySound(Game.ObjectsById['+this.id+'].muted?\'snd/clickOff.mp3\':\'snd/clickOn.mp3\');" id="productMute'+this.id+'">Mute
'; str+='
'; str+=''; str+='
'; @@ -5932,15 +6997,21 @@ Game.Launch=function() //building canvas this.pics=[]; + this.toResize=true; this.redraw=function() { - this.pics=[]; + var me=this; + me.pics=[]; } this.draw=function() { - //this needs to be cached - this.canvas.width=this.canvas.clientWidth; - this.canvas.height=this.canvas.clientHeight; + if (this.amount<=0) return false; + if (this.toResize) + { + this.canvas.width=this.canvas.clientWidth; + this.canvas.height=this.canvas.clientHeight; + this.toResize=false; + } var ctx=this.ctx; //clear //ctx.clearRect(0,0,this.canvas.width,this.canvas.height); @@ -5954,15 +7025,18 @@ Game.Launch=function() //x : horizontal offset //y : vertical offset (+32) //rows : if >1, arrange the pictures in rows containing this many pictures + //frames : if present, slice the pic in [frames] horizontal slices and pick one at random var pic=this.art.pic; var bg=this.art.bg; var xV=this.art.xV||0; var yV=this.art.yV||0; var w=this.art.w||48; + var h=this.art.h||48; var offX=this.art.x||0; var offY=this.art.y||0; var rows=this.art.rows||1; + var frames=this.art.frames||1; if (typeof(bg)=='string') ctx.fillPattern(Pic(this.art.bg),0,0,this.canvas.width,this.canvas.height,128,128); else bg(this,ctx); @@ -5975,37 +7049,106 @@ Game.Launch=function() } ctx.globalAlpha=1; */ + var maxI=Math.floor(this.canvas.width/(w/rows)+1); + var iT=Math.min(this.amount,maxI); var i=this.pics.length; - while (i1) frame=Math.floor(Math.random()*frames); + this.pics.push({x:Math.floor(x),y:Math.floor(y),z:y,pic:usedPic,id:i,frame:frame}); + i++; + added++; + } + while (i>iT) + //else if (i>iT) + { + this.pics.sort(Game.sortSpritesById); + this.pics.pop(); + i--; + added--; + } + //} + this.pics.sort(Game.sortSprites); + } + + var len=this.pics.length; + + if (this.mouseOn) { - var x=0; - var y=0; - if (rows!=1) + var selected=-1; + //mouse detection only fits grandma sprites for now + var marginW=-18; + var marginH=-10; + for (var i=0;i=pic.x-marginW && this.mousePos[0]=pic.y-marginH && this.mousePos[1]this.amount) - { - this.pics.sort(Game.sortSpritesById); - this.pics.pop(); - i--; } - this.pics.sort(Game.sortSprites); + Math.seedrandom(); - for (var i in this.pics) + for (var i=0;i0 && Math.random()<0.2) {name=choose(Game.customGrandmaNames);custom=true;} + var text=name+', age '+Beautify(Math.floor(70+Math.random()*30+years+this.level)); + var width=ctx.measureText(text).width+12; + var x=Math.max(0,Math.min(pic.x+32-width/2+Math.random()*32-16,this.canvas.width-width)); + var y=4+Math.random()*8-4; + Math.seedrandom(); + ctx.fillStyle='#000'; + ctx.strokeStyle='#000'; + ctx.lineWidth=8; + ctx.globalAlpha=0.75; + ctx.beginPath(); + ctx.moveTo(pic.x+32,pic.y+32); + ctx.lineTo(Math.floor(x+width/2),Math.floor(y+20)); + ctx.stroke(); + ctx.fillRect(Math.floor(x),Math.floor(y),Math.floor(width),24); + ctx.globalAlpha=1; + if (custom) ctx.fillStyle='#fff'; + else ctx.fillStyle='rgba(255,255,255,0.7)'; + ctx.fillText(text,Math.floor(x+width/2),Math.floor(y+16)); + + ctx.drawImage(sprite,Math.floor(pic.x+Math.random()*4-2),Math.floor(pic.y+Math.random()*4-2)); + } + //else if (1) ctx.drawImage(sprite,0,0,sprite.width,sprite.height,pic.x,pic.y,sprite.width,sprite.height); + else if (pic.frame!=-1) ctx.drawImage(sprite,(sprite.width/frames)*pic.frame,0,sprite.width/frames,sprite.height,pic.x,pic.y,(sprite.width/frames),sprite.height); + else ctx.drawImage(sprite,pic.x,pic.y); + } /* @@ -6036,14 +7179,11 @@ Game.Launch=function() for (var i in Game.Objects) { var me=Game.Objects[i]; - if (me.id>0) me.draw(); + if (me.id>0 && !me.onMinigame && !me.muted) me.draw(); + else me.pics=[]; } } } - window.addEventListener('resize',function(event) - { - Game.DrawBuildings(); - }); Game.sortSprites=function(a,b) { @@ -6064,10 +7204,14 @@ Game.Launch=function() if (Game.Has('Santa\'s dominion')) price*=0.99; if (Game.Has('Faberge egg')) price*=0.99; if (Game.Has('Divine discount')) price*=0.99; - if (Game.hasAura('Fierce Hoarder')) price*=0.98; + if (Game.Has('Fortune #100')) price*=0.99; + //if (Game.hasAura('Fierce Hoarder')) price*=0.98; + price*=1-Game.auraMult('Fierce Hoarder')*0.02; if (Game.hasBuff('Everything must go')) price*=0.95; if (Game.hasBuff('Crafty pixies')) price*=0.98; if (Game.hasBuff('Nasty goblins')) price*=1.02; + if (building.fortune && Game.Has(building.fortune.name)) price*=0.93; + price*=Game.eff('buildingCost'); if (Game.hasGod) { var godLvl=Game.hasGod('creation'); @@ -6089,13 +7233,13 @@ Game.Launch=function() if (Game.buyMode==1 && Game.buyBulk==-1) Game.buyBulk=100; - if (Game.buyMode==1) l('storeBulkBuy').className='storeBulkMode selected'; else l('storeBulkBuy').className='storeBulkMode'; - if (Game.buyMode==-1) l('storeBulkSell').className='storeBulkMode selected'; else l('storeBulkSell').className='storeBulkMode'; + if (Game.buyMode==1) l('storeBulkBuy').className='storePreButton storeBulkMode selected'; else l('storeBulkBuy').className='storePreButton storeBulkMode'; + if (Game.buyMode==-1) l('storeBulkSell').className='storePreButton storeBulkMode selected'; else l('storeBulkSell').className='storePreButton storeBulkMode'; - if (Game.buyBulk==1) l('storeBulk1').className='storeBulkAmount selected'; else l('storeBulk1').className='storeBulkAmount'; - if (Game.buyBulk==10) l('storeBulk10').className='storeBulkAmount selected'; else l('storeBulk10').className='storeBulkAmount'; - if (Game.buyBulk==100) l('storeBulk100').className='storeBulkAmount selected'; else l('storeBulk100').className='storeBulkAmount'; - if (Game.buyBulk==-1) l('storeBulkMax').className='storeBulkAmount selected'; else l('storeBulkMax').className='storeBulkAmount'; + if (Game.buyBulk==1) l('storeBulk1').className='storePreButton storeBulkAmount selected'; else l('storeBulk1').className='storePreButton storeBulkAmount'; + if (Game.buyBulk==10) l('storeBulk10').className='storePreButton storeBulkAmount selected'; else l('storeBulk10').className='storePreButton storeBulkAmount'; + if (Game.buyBulk==100) l('storeBulk100').className='storePreButton storeBulkAmount selected'; else l('storeBulk100').className='storePreButton storeBulkAmount'; + if (Game.buyBulk==-1) l('storeBulkMax').className='storePreButton storeBulkAmount selected'; else l('storeBulkMax').className='storePreButton storeBulkAmount'; if (Game.buyMode==1) { @@ -6113,17 +7257,19 @@ Game.Launch=function() } Game.BuildStore=function()//create the DOM for the store's buildings { + //if (typeof showAds!=='undefined') l('store').scrollTop=100; + var str=''; - str+='
You can also press Ctrl to bulk-buy or sell 10 of a building at a time, or Shift for 100.
' ,'store')+ '>'+ - '
Buy
'+ - '
Sell
'+ - '
1
'+ - '
10
'+ - '
100
'+ - '
all
'+ + '
Buy
'+ + '
Sell
'+ + '
1
'+ + '
10
'+ + '
100
'+ + '
all
'+ ''; for (var i in Game.Objects) { @@ -6154,11 +7300,11 @@ Game.Launch=function() //these are a bit messy but ah well if (!Game.touchEvents) { - AddEvent(me.l,'click',function(what){return function(){Game.ClickProduct(what);};}(me.id)); + AddEvent(me.l,'click',function(what){return function(e){Game.ClickProduct(what);e.preventDefault();};}(me.id)); } else { - AddEvent(me.l,'touchend',function(what){return function(){Game.ClickProduct(what);};}(me.id)); + AddEvent(me.l,'touchend',function(what){return function(e){Game.ClickProduct(what);e.preventDefault();};}(me.id)); } } } @@ -6186,8 +7332,9 @@ Game.Launch=function() for (var i in Game.Objects) { var me=Game.Objects[i]; - if (me.minigameUrl && me.level>0 && !me.minigameLoaded && !l('minigameScript-'+me.id)) + if (me.minigameUrl && me.level>0 && !me.minigameLoaded && !me.minigameLoading && !l('minigameScript-'+me.id)) { + me.minigameLoading=true; //we're only loading the minigame scripts that aren't loaded yet and which have enough building level //we call this function on building level up and on load //console.log('Loading script '+me.minigameUrl+'...'); @@ -6196,7 +7343,9 @@ Game.Launch=function() script.id='minigameScript-'+me.id; Game.scriptBindings['minigameScript-'+me.id]=me; script.setAttribute('src',me.minigameUrl+'?r='+Game.version); - script.onload=function(me,script){return function(){Game.scriptLoaded(me,script);}}(me,'minigameScript-'+me.id); + script.onload=function(me,script){return function(){ + if (!me.minigameLoaded) Game.scriptLoaded(me,script); + }}(me,'minigameScript-'+me.id); document.head.appendChild(script); }}(me),10); } @@ -6204,10 +7353,11 @@ Game.Launch=function() } Game.scriptLoaded=function(who,script) { + who.minigameLoading=false; who.minigameLoaded=true; who.refresh(); who.minigame.launch(); - if (who.minigameSave) {who.minigame.reset();who.minigame.load(who.minigameSave);who.minigameSave=0;} + if (who.minigameSave) {who.minigame.reset(true);who.minigame.load(who.minigameSave);who.minigameSave=0;} } Game.magicCpS=function(what) @@ -6226,7 +7376,7 @@ Game.Launch=function() } //define objects - new Game.Object('Cursor','cursor|cursors|clicked|[X] extra finger|[X] extra fingers','Autoclicks once every 10 seconds.',0,0,{},15,function(){ + new Game.Object('Cursor','cursor|cursors|clicked|[X] extra finger|[X] extra fingers','Autoclicks once every 10 seconds.',0,0,{},15,function(me){ var add=0; if (Game.Has('Thousand fingers')) add+= 0.1; if (Game.Has('Million fingers')) add+= 0.5; @@ -6241,7 +7391,9 @@ Game.Launch=function() var num=0; for (var i in Game.Objects) {if (Game.Objects[i].name!='Cursor') num+=Game.Objects[i].amount;} add=add*num; + mult*=Game.GetTieredCpsMult(me); mult*=Game.magicCpS('Cursor'); + mult*=Game.eff('cursorCps'); return Game.ComputeCps(0.1,Game.Has('Reinforced index finger')+Game.Has('Carpal tunnel prevention cream')+Game.Has('Ambidextrous'),add)*mult; },function(){ if (this.amount>=1) Game.Unlock(['Reinforced index finger','Carpal tunnel prevention cream']); @@ -6256,7 +7408,7 @@ Game.Launch=function() if (this.amount>=350) Game.Unlock('Septillion fingers'); if (this.amount>=400) Game.Unlock('Octillion fingers'); - if (this.amount>=1) Game.Win('Click');if (this.amount>=2) Game.Win('Double-click');if (this.amount>=50) Game.Win('Mouse wheel');if (this.amount>=100) Game.Win('Of Mice and Men');if (this.amount>=200) Game.Win('The Digital');if (this.amount>=300) Game.Win('Extreme polydactyly');if (this.amount>=400) Game.Win('Dr. T');if (this.amount>=500) Game.Win('Thumbs, phalanges, metacarpals'); + if (this.amount>=1) Game.Win('Click');if (this.amount>=2) Game.Win('Double-click');if (this.amount>=50) Game.Win('Mouse wheel');if (this.amount>=100) Game.Win('Of Mice and Men');if (this.amount>=200) Game.Win('The Digital');if (this.amount>=300) Game.Win('Extreme polydactyly');if (this.amount>=400) Game.Win('Dr. T');if (this.amount>=500) Game.Win('Thumbs, phalanges, metacarpals');if (this.amount>=600) Game.Win('With her finger and her thumb'); }); Game.SpecialGrandmaUnlock=15; @@ -6275,28 +7427,25 @@ Game.Launch=function() if (Game.Has('Priestess grandmas')) list.push('templeGrandma'); if (Game.Has('Witch grandmas')) list.push('witchGrandma'); if (Game.Has('Lucky grandmas')) list.push('luckyGrandma'); + if (Game.Has('Metagrandmas')) list.push('metaGrandma'); + if (Game.Has('Script grannies')) list.push('scriptGrandma'); if (Game.season=='christmas') list.push('elfGrandma'); if (Game.season=='easter') list.push('bunnyGrandma'); return choose(list)+'.png'; },bg:'grandmaBackground.png',xV:8,yV:8,w:32,rows:3,x:0,y:16},100,function(me){ var mult=1; - if (Game.Has('Farmer grandmas')) mult*=2; - if (Game.Has('Worker grandmas')) mult*=2; - if (Game.Has('Miner grandmas')) mult*=2; - if (Game.Has('Cosmic grandmas')) mult*=2; - if (Game.Has('Transmuted grandmas')) mult*=2; - if (Game.Has('Altered grandmas')) mult*=2; - if (Game.Has('Grandmas\' grandmas')) mult*=2; - if (Game.Has('Antigrandmas')) mult*=2; - if (Game.Has('Rainbow grandmas')) mult*=2; - if (Game.Has('Banker grandmas')) mult*=2; - if (Game.Has('Priestess grandmas')) mult*=2; - if (Game.Has('Witch grandmas')) mult*=2; - if (Game.Has('Lucky grandmas')) mult*=2; + for (var i in Game.GrandmaSynergies) + { + if (Game.Has(Game.GrandmaSynergies[i])) mult*=2; + } if (Game.Has('Bingo center/Research facility')) mult*=4; if (Game.Has('Ritual rolling pins')) mult*=2; if (Game.Has('Naughty list')) mult*=2; + if (Game.Has('Elderwort biscuits')) mult*=1.02; + + mult*=Game.eff('grandmaCps'); + mult*=Game.GetTieredCpsMult(me); var add=0; @@ -6306,7 +7455,8 @@ Game.Launch=function() var num=0; for (var i in Game.Objects) {if (Game.Objects[i].name!='Grandma') num+=Game.Objects[i].amount;} - if (Game.hasAura('Elder Battalion')) mult*=1+0.01*num; + //if (Game.hasAura('Elder Battalion')) mult*=1+0.01*num; + mult*=1+Game.auraMult('Elder Battalion')*0.01*num; mult*=Game.magicCpS(me.name); @@ -6334,56 +7484,55 @@ Game.Launch=function() new Game.Object('Farm','farm|farms|harvested|[X] more acre|[X] more acres','Grows cookie plants from cookie seeds.',3,2,{base:'farm',xV:8,yV:8,w:64,rows:2,x:0,y:16},500,function(me){ var mult=1; mult*=Game.GetTieredCpsMult(me); - if (Game.Has('Farmer grandmas')) mult*=Game.getGrandmaSynergyUpgradeMultiplier(me.name); mult*=Game.magicCpS(me.name); return me.baseCps*mult; },function(){ Game.UnlockTiered(this); - if (this.amount>=Game.SpecialGrandmaUnlock && Game.Objects['Grandma'].amount>0) Game.Unlock('Farmer grandmas'); + if (this.amount>=Game.SpecialGrandmaUnlock && Game.Objects['Grandma'].amount>0) Game.Unlock(this.grandma.name); }); + Game.last.minigameUrl='minigameGarden.js'; + Game.last.minigameName='Garden'; new Game.Object('Mine','mine|mines|mined|[X] mile deeper|[X] miles deeper','Mines out cookie dough and chocolate chips.',4,3,{base:'mine',xV:16,yV:16,w:64,rows:2,x:0,y:24},10000,function(me){ var mult=1; mult*=Game.GetTieredCpsMult(me); - if (Game.Has('Miner grandmas')) mult*=Game.getGrandmaSynergyUpgradeMultiplier(me.name); mult*=Game.magicCpS(me.name); return me.baseCps*mult; },function(){ Game.UnlockTiered(this); - if (this.amount>=Game.SpecialGrandmaUnlock && Game.Objects['Grandma'].amount>0) Game.Unlock('Miner grandmas'); + if (this.amount>=Game.SpecialGrandmaUnlock && Game.Objects['Grandma'].amount>0) Game.Unlock(this.grandma.name); }); new Game.Object('Factory','factory|factories|mass-produced|[X] additional patent|[X] additional patents','Produces large quantities of cookies.',5,4,{base:'factory',xV:8,yV:0,w:64,rows:1,x:0,y:-22},3000,function(me){ var mult=1; mult*=Game.GetTieredCpsMult(me); - if (Game.Has('Worker grandmas')) mult*=Game.getGrandmaSynergyUpgradeMultiplier(me.name); mult*=Game.magicCpS(me.name); return me.baseCps*mult; },function(){ Game.UnlockTiered(this); - if (this.amount>=Game.SpecialGrandmaUnlock && Game.Objects['Grandma'].amount>0) Game.Unlock('Worker grandmas'); + if (this.amount>=Game.SpecialGrandmaUnlock && Game.Objects['Grandma'].amount>0) Game.Unlock(this.grandma.name); }); + //Game.last.minigameUrl='minigameDungeon.js';//not yet + //Game.last.minigameName='Dungeon'; new Game.Object('Bank','bank|banks|banked|Interest rates [X]% better|Interest rates [X]% better','Generates cookies from interest.',6,15,{base:'bank',xV:8,yV:4,w:56,rows:1,x:0,y:13},0,function(me){ var mult=1; mult*=Game.GetTieredCpsMult(me); - if (Game.Has('Banker grandmas')) mult*=Game.getGrandmaSynergyUpgradeMultiplier(me.name); mult*=Game.magicCpS(me.name); return me.baseCps*mult; },function(){ Game.UnlockTiered(this); - if (this.amount>=Game.SpecialGrandmaUnlock && Game.Objects['Grandma'].amount>0) Game.Unlock('Banker grandmas'); + if (this.amount>=Game.SpecialGrandmaUnlock && Game.Objects['Grandma'].amount>0) Game.Unlock(this.grandma.name); }); new Game.Object('Temple','temple|temples|discovered|[X] sacred artifact retrieved|[X] sacred artifacts retrieved','Full of precious, ancient chocolate.',7,16,{base:'temple',xV:8,yV:4,w:72,rows:2,x:0,y:-5},0,function(me){ var mult=1; mult*=Game.GetTieredCpsMult(me); - if (Game.Has('Priestess grandmas')) mult*=Game.getGrandmaSynergyUpgradeMultiplier(me.name); mult*=Game.magicCpS(me.name); return me.baseCps*mult; },function(){ Game.UnlockTiered(this); - if (this.amount>=Game.SpecialGrandmaUnlock && Game.Objects['Grandma'].amount>0) Game.Unlock('Priestess grandmas'); + if (this.amount>=Game.SpecialGrandmaUnlock && Game.Objects['Grandma'].amount>0) Game.Unlock(this.grandma.name); }); Game.last.minigameUrl='minigamePantheon.js'; Game.last.minigameName='Pantheon'; @@ -6391,12 +7540,11 @@ Game.Launch=function() new Game.Object('Wizard tower','wizard tower|wizard towers|summoned|Incantations have [X] more syllable|Incantations have [X] more syllables','Summons cookies with magic spells.',8,17,{base:'wizardtower',xV:16,yV:16,w:48,rows:2,x:0,y:20},0,function(me){ var mult=1; mult*=Game.GetTieredCpsMult(me); - if (Game.Has('Witch grandmas')) mult*=Game.getGrandmaSynergyUpgradeMultiplier(me.name); mult*=Game.magicCpS(me.name); return me.baseCps*mult; },function(){ Game.UnlockTiered(this); - if (this.amount>=Game.SpecialGrandmaUnlock && Game.Objects['Grandma'].amount>0) Game.Unlock('Witch grandmas'); + if (this.amount>=Game.SpecialGrandmaUnlock && Game.Objects['Grandma'].amount>0) Game.Unlock(this.grandma.name); }); Game.last.minigameUrl='minigameGrimoire.js'; Game.last.minigameName='Grimoire'; @@ -6404,81 +7552,96 @@ Game.Launch=function() new Game.Object('Shipment','shipment|shipments|shipped|[X] galaxy fully explored|[X] galaxies fully explored','Brings in fresh cookies from the cookie planet.',9,5,{base:'shipment',xV:16,yV:16,w:64,rows:1,x:0,y:0},40000,function(me){ var mult=1; mult*=Game.GetTieredCpsMult(me); - if (Game.Has('Cosmic grandmas')) mult*=Game.getGrandmaSynergyUpgradeMultiplier(me.name); mult*=Game.magicCpS(me.name); return me.baseCps*mult; },function(){ Game.UnlockTiered(this); - if (this.amount>=Game.SpecialGrandmaUnlock && Game.Objects['Grandma'].amount>0) Game.Unlock('Cosmic grandmas'); + if (this.amount>=Game.SpecialGrandmaUnlock && Game.Objects['Grandma'].amount>0) Game.Unlock(this.grandma.name); }); new Game.Object('Alchemy lab','alchemy lab|alchemy labs|transmuted|[X] primordial element mastered|[X] primordial elements mastered','Turns gold into cookies!',10,6,{base:'alchemylab',xV:16,yV:16,w:64,rows:2,x:0,y:16},200000,function(me){ var mult=1; mult*=Game.GetTieredCpsMult(me); - if (Game.Has('Transmuted grandmas')) mult*=Game.getGrandmaSynergyUpgradeMultiplier(me.name); mult*=Game.magicCpS(me.name); return me.baseCps*mult; },function(){ Game.UnlockTiered(this); - if (this.amount>=Game.SpecialGrandmaUnlock && Game.Objects['Grandma'].amount>0) Game.Unlock('Transmuted grandmas'); + if (this.amount>=Game.SpecialGrandmaUnlock && Game.Objects['Grandma'].amount>0) Game.Unlock(this.grandma.name); }); new Game.Object('Portal','portal|portals|retrieved|[X] dimension enslaved|[X] dimensions enslaved','Opens a door to the Cookieverse.',11,7,{base:'portal',xV:32,yV:32,w:64,rows:2,x:0,y:0},1666666,function(me){ var mult=1; mult*=Game.GetTieredCpsMult(me); - if (Game.Has('Altered grandmas')) mult*=Game.getGrandmaSynergyUpgradeMultiplier(me.name); mult*=Game.magicCpS(me.name); return me.baseCps*mult; },function(){ Game.UnlockTiered(this); - if (this.amount>=Game.SpecialGrandmaUnlock && Game.Objects['Grandma'].amount>0) Game.Unlock('Altered grandmas'); + if (this.amount>=Game.SpecialGrandmaUnlock && Game.Objects['Grandma'].amount>0) Game.Unlock(this.grandma.name); }); new Game.Object('Time machine','time machine|time machines|recovered|[X] century secured|[X] centuries secured','Brings cookies from the past, before they were even eaten.',12,8,{base:'timemachine',xV:32,yV:32,w:64,rows:1,x:0,y:0},123456789,function(me){ var mult=1; mult*=Game.GetTieredCpsMult(me); - if (Game.Has('Grandmas\' grandmas')) mult*=Game.getGrandmaSynergyUpgradeMultiplier(me.name); mult*=Game.magicCpS(me.name); return me.baseCps*mult; },function(){ Game.UnlockTiered(this); - if (this.amount>=Game.SpecialGrandmaUnlock && Game.Objects['Grandma'].amount>0) Game.Unlock('Grandmas\' grandmas'); + if (this.amount>=Game.SpecialGrandmaUnlock && Game.Objects['Grandma'].amount>0) Game.Unlock(this.grandma.name); }); new Game.Object('Antimatter condenser','antimatter condenser|antimatter condensers|condensed|[X] extra quark flavor|[X] extra quark flavors','Condenses the antimatter in the universe into cookies.',13,13,{base:'antimattercondenser',xV:0,yV:64,w:64,rows:1,x:0,y:0},3999999999,function(me){ var mult=1; mult*=Game.GetTieredCpsMult(me); - if (Game.Has('Antigrandmas')) mult*=Game.getGrandmaSynergyUpgradeMultiplier(me.name); mult*=Game.magicCpS(me.name); return me.baseCps*mult; },function(){ Game.UnlockTiered(this); - if (this.amount>=Game.SpecialGrandmaUnlock && Game.Objects['Grandma'].amount>0) Game.Unlock('Antigrandmas'); + if (this.amount>=Game.SpecialGrandmaUnlock && Game.Objects['Grandma'].amount>0) Game.Unlock(this.grandma.name); }); Game.last.displayName='Antimatter condenser';//shrink the name since it's so large new Game.Object('Prism','prism|prisms|converted|[X] new color discovered|[X] new colors discovered','Converts light itself into cookies.',14,14,{base:'prism',xV:16,yV:4,w:64,rows:1,x:0,y:20},75000000000,function(me){ var mult=1; mult*=Game.GetTieredCpsMult(me); - if (Game.Has('Rainbow grandmas')) mult*=Game.getGrandmaSynergyUpgradeMultiplier(me.name); mult*=Game.magicCpS(me.name); return me.baseCps*mult; },function(){ Game.UnlockTiered(this); - if (this.amount>=Game.SpecialGrandmaUnlock && Game.Objects['Grandma'].amount>0) Game.Unlock('Rainbow grandmas'); + if (this.amount>=Game.SpecialGrandmaUnlock && Game.Objects['Grandma'].amount>0) Game.Unlock(this.grandma.name); }); - new Game.Object('Chancemaker','chancemaker|chancemakers|spontaneously generated|Chancemakers are powered by [X]-leaf clovers|Chancemakers are powered by [X]-leaf clovers','Generates cookies out of thin air through sheer luck.',15,19,{base:'chancemaker',xV:8,yV:64,w:64,rows:1,x:0,y:0},77777777777,function(me){ + new Game.Object('Chancemaker','chancemaker|chancemakers|spontaneously generated|Chancemakers are powered by [X]-leaf clovers|Chancemakers are powered by [X]-leaf clovers','Generates cookies out of thin air through sheer luck.',15,19,{base:'chancemaker',xV:8,yV:64,w:64,rows:1,x:0,y:0,rows:2},77777777777,function(me){ var mult=1; mult*=Game.GetTieredCpsMult(me); - if (Game.Has('Lucky grandmas')) mult*=Game.getGrandmaSynergyUpgradeMultiplier(me.name); mult*=Game.magicCpS(me.name); return me.baseCps*mult; },function(){ Game.UnlockTiered(this); - if (this.amount>=Game.SpecialGrandmaUnlock && Game.Objects['Grandma'].amount>0) Game.Unlock('Lucky grandmas'); + if (this.amount>=Game.SpecialGrandmaUnlock && Game.Objects['Grandma'].amount>0) Game.Unlock(this.grandma.name); }); + new Game.Object('Fractal engine','fractal engine|fractal engines|made from cookies|[X] iteration deep|[X] iterations deep','Turns cookies into even more cookies.',16,20,{base:'fractalEngine',xV:8,yV:64,w:64,rows:1,x:0,y:0},12345678987654321,function(me){ + var mult=1; + mult*=Game.GetTieredCpsMult(me); + mult*=Game.magicCpS(me.name); + return me.baseCps*mult; + },function(){ + Game.UnlockTiered(this); + if (this.amount>=Game.SpecialGrandmaUnlock && Game.Objects['Grandma'].amount>0) Game.Unlock(this.grandma.name); + }); + + new Game.Object('Javascript console','javascript console|javascript consoles|programmed|Equipped with [X] external library|Equipped with [X] external libraries','Creates cookies from the very code this game was written in.',17,32,{base:'javascriptconsole',xV:8,yV:64,w:14,rows:1,x:8,y:-32,frames:2},12345678987654321,function(me){ + var mult=1; + mult*=Game.GetTieredCpsMult(me); + mult*=Game.magicCpS(me.name); + return me.baseCps*mult; + },function(){ + Game.UnlockTiered(this); + if (this.amount>=Game.SpecialGrandmaUnlock && Game.Objects['Grandma'].amount>0) Game.Unlock(this.grandma.name); + }); + Game.last.displayName='Javascript console';//shrink the name since it's so large + + Game.foolObjects={ 'Unknown':{name:'Investment',desc:'You\'re not sure what this does, you just know it means profit.',icon:0}, 'Cursor':{name:'Rolling pin',desc:'Essential in flattening dough. The first step in cookie-making.',icon:0}, @@ -6496,12 +7659,22 @@ Game.Launch=function() 'Antimatter condenser':{name:'Cookiecoin',desc:'A virtual currency, already replacing regular money in some small countries.',icon:12}, 'Prism':{name:'Corporate country',desc:'You\'ve made it to the top, and you can now buy entire nations to further your corporate greed. Godspeed.',icon:13}, 'Chancemaker':{name:'Privatized planet',desc:'Actually, you know what\'s cool? A whole planet dedicated to producing, advertising, selling, and consuming your cookies.',icon:15}, + 'Fractal engine':{name:'Senate seat',desc:'Only through political dominion can you truly alter this world to create a brighter, more cookie-friendly future.',icon:16}, + 'Javascript console':{name:'Doctrine',desc:'Taking many forms -religion, culture, philosophy- a doctrine may, when handled properly, cause a lasting impact on civilizations, reshaping minds and people and ensuring all future generations share a singular goal - the production, and acquisition, of more cookies.',icon:17}, }; //build store Game.BuildStore(); + + //build master bar + var str=''; + str+='
'; + str+='
'; + l('buildingsMaster').innerHTML=str; + //build object displays + var muteStr='
Muted :
'; for (var i in Game.Objects) { var me=Game.Objects[i]; @@ -6510,8 +7683,23 @@ Game.Launch=function() me.canvas=l('rowCanvas'+me.id); me.ctx=me.canvas.getContext('2d',{alpha:false}); me.pics=[]; + var icon=[0*64,me.icon*64]; + muteStr+=''; + //muteStr+='')+'>'; + + AddEvent(me.canvas,'mouseover',function(me){return function(){me.mouseOn=true;}}(me)); + AddEvent(me.canvas,'mouseout',function(me){return function(){me.mouseOn=false;}}(me)); + AddEvent(me.canvas,'mousemove',function(me){return function(e){var box=this.getBoundingClientRect();me.mousePos[0]=e.pageX-box.left;me.mousePos[1]=e.pageY-box.top;}}(me)); } } + Game.mutedBuildingTooltip=function(id) + { + return function(){ + var me=Game.ObjectsById[id]; + return '
'+(me.plural.charAt(0).toUpperCase()+me.plural.slice(1))+(me.level>0?' (lvl. '+me.level+')':'')+'
Click to unmute '+me.plural+'
(display this building)
'; + } + } + l('buildingsMute').innerHTML=muteStr; /*===================================================================================== UPGRADES @@ -6530,6 +7718,7 @@ Game.Launch=function() this.baseDesc=this.desc; this.desc=BeautifyInText(this.baseDesc); this.basePrice=price; + this.priceLumps=0;//note : doesn't do much on its own, you still need to handle the buying yourself this.icon=icon; this.iconFunction=0; this.buyFunction=buyFunction; @@ -6544,6 +7733,7 @@ Game.Launch=function() this.power=0; if (power) this.power=power; this.vanilla=Game.vanilla; + this.unlockAt=0; this.techUnlock=[]; this.parents=[]; this.type='upgrade'; @@ -6560,7 +7750,8 @@ Game.Launch=function() Game.Upgrade.prototype.getPrice=function() { var price=this.basePrice; - if (this.priceFunc) price=this.priceFunc(); + if (this.priceFunc) price=this.priceFunc(this); + if (price==0) return 0; if (this.pool!='prestige') { if (Game.Has('Toy workshop')) price*=0.95; @@ -6568,9 +7759,12 @@ Game.Launch=function() if (Game.Has('Santa\'s dominion')) price*=0.98; if (Game.Has('Faberge egg')) price*=0.99; if (Game.Has('Divine sales')) price*=0.99; + if (Game.Has('Fortune #100')) price*=0.99; if (Game.hasBuff('Haggler\'s luck')) price*=0.98; if (Game.hasBuff('Haggler\'s misery')) price*=1.02; - if (Game.hasAura('Master of the Armory')) price*=0.98; + //if (Game.hasAura('Master of the Armory')) price*=0.98; + price*=1-Game.auraMult('Master of the Armory')*0.02; + price*=Game.eff('upgradeCost'); if (this.pool=='cookie' && Game.Has('Divine bakeries')) price/=5; } return Math.ceil(price); @@ -6578,9 +7772,51 @@ Game.Launch=function() Game.Upgrade.prototype.canBuy=function() { + if (this.canBuyFunc) return this.canBuyFunc(); if (Game.cookies>=this.getPrice()) return true; else return false; } + Game.storeBuyAll=function() + { + if (!Game.Has('Inspired checklist')) return false; + for (var i in Game.UpgradesInStore) + { + var me=Game.UpgradesInStore[i]; + if (!me.isVaulted() && me.pool!='toggle' && me.pool!='tech') me.buy(1); + } + } + + Game.vault=[]; + Game.Upgrade.prototype.isVaulted=function() + { + if (Game.vault.indexOf(this.id)!=-1) return true; else return false; + } + Game.Upgrade.prototype.vault=function() + { + if (!this.isVaulted()) Game.vault.push(this.id); + } + Game.Upgrade.prototype.unvault=function() + { + if (this.isVaulted()) Game.vault.splice(Game.vault.indexOf(this.id),1); + } + + Game.Upgrade.prototype.click=function(e) + { + if ((e && e.shiftKey) || Game.keys[16]) + { + if (this.pool=='toggle' || this.pool=='tech') {} + else if (Game.Has('Inspired checklist')) + { + if (this.isVaulted()) this.unvault(); + else this.vault(); + Game.upgradesToRebuild=1; + PlaySound('snd/tick.mp3'); + } + } + else this.buy(); + } + + Game.Upgrade.prototype.buy=function(bypass) { var success=0; @@ -6617,7 +7853,7 @@ Game.Launch=function() for (var i in choices) { var icon=choices[i].icon; - str+='
'; } } @@ -6639,7 +7875,8 @@ Game.Launch=function() if (this.buyFunction) this.buyFunction(); if (this.toggleInto) { - Game.Lock(this.toggleInto);Game.Unlock(this.toggleInto); + Game.Lock(this.toggleInto); + Game.Unlock(this.toggleInto); } Game.upgradesToRebuild=1; Game.recalculateGains=1; @@ -6680,6 +7917,13 @@ Game.Launch=function() Game.recalculateGains=1; if (Game.CountsAsUpgradeOwned(this.pool)) Game.UpgradesOwned++; } + Game.Upgrade.prototype.unearn=function()//remove the upgrade, but keep it unlocked + { + this.bought=0; + Game.upgradesToRebuild=1; + Game.recalculateGains=1; + if (Game.CountsAsUpgradeOwned(this.pool)) Game.UpgradesOwned--; + } Game.Upgrade.prototype.unlock=function() { this.unlocked=1; @@ -6714,7 +7958,7 @@ Game.Launch=function() PlaySound('snd/sell'+choose([1,2,3,4])+'.mp3',0.75); if (this.pool=='prestige' || this.pool=='debug') PlaySound('snd/shimmerClick.mp3'); } - Game.UpdateMenu(); + if (Game.onMenu=='stats') Game.UpdateMenu(); } Game.CountsAsUpgradeOwned=function(pool) @@ -6772,14 +8016,16 @@ Game.Launch=function() Game.Has=function(what) { - if (Game.ascensionMode==1 && Game.Upgrades[what].pool=='prestige') return 0; - return (Game.Upgrades[what]?Game.Upgrades[what].bought:0); + var it=Game.Upgrades[what]; + if (Game.ascensionMode==1 && (it.pool=='prestige' || it.tier=='fortune')) return 0; + return (it?it.bought:0); } Game.HasUnlocked=function(what) { return (Game.Upgrades[what]?Game.Upgrades[what].unlocked:0); } + Game.RebuildUpgrades=function()//recalculate the upgrades you can buy { Game.upgradesToRebuild=0; @@ -6787,7 +8033,7 @@ Game.Launch=function() for (var i in Game.Upgrades) { var me=Game.Upgrades[i]; - if (!me.bought && me.pool!='debug' && me.pool!='prestige' && me.pool!='prestigeDecor') + if (!me.bought && me.pool!='debug' && me.pool!='prestige' && me.pool!='prestigeDecor' && (Game.ascensionMode!=1 || (!me.lasting && me.tier!='fortune'))) { if (me.unlocked) list.push(me); } @@ -6811,22 +8057,42 @@ Game.Launch=function() var storeStr=''; var toggleStr=''; var techStr=''; + var vaultStr=''; + + if (Game.Has('Inspired checklist')) + { + storeStr+='
Will instantly purchase every upgrade you can afford, starting from the cheapest one.
Upgrades in the vault will not be auto-purchased.
You may place an upgrade into the vault by Shift-clicking on it.
' + ,'store')+ + '>'+ + '
Buy all upgrades
'+ + ''; + l('upgrades').classList.add('hasMenu'); + } + else l('upgrades').classList.remove('hasMenu'); + for (var i in Game.UpgradesInStore) { //if (!Game.UpgradesInStore[i]) break; var me=Game.UpgradesInStore[i]; - var str=Game.crate(me,'store','Game.UpgradesById['+me.id+'].buy();','upgrade'+i); + var str=Game.crate(me,'store','Game.UpgradesById['+me.id+'].click(event);','upgrade'+i); /*var str='
'+Beautify(Math.round(me.getPrice()))+'
'+(me.pool=='toggle'?'[Togglable]':'[Upgrade]')+'
'+me.name+'
'+me.desc+'
' ,'store')+' '+Game.clickStr+'="Game.UpgradesById['+me.id+'].buy();" id="upgrade'+i+'" style="'+(me.icon[2]?'background-image:url('+me.icon[2]+');':'')+'background-position:'+(-me.icon[0]*48)+'px '+(-me.icon[1]*48)+'px;">';*/ - if (me.pool=='toggle') toggleStr+=str; else if (me.pool=='tech') techStr+=str; else storeStr+=str; + if (me.pool=='toggle') toggleStr+=str; else if (me.pool=='tech') techStr+=str; else + { + if (me.isVaulted() && Game.Has('Inspired checklist')) vaultStr+=str; else storeStr+=str; + } } + l('upgrades').innerHTML=storeStr; l('toggleUpgrades').innerHTML=toggleStr; if (toggleStr=='') l('toggleUpgrades').style.display='none'; else l('toggleUpgrades').style.display='block'; l('techUpgrades').innerHTML=techStr; if (techStr=='') l('techUpgrades').style.display='none'; else l('techUpgrades').style.display='block'; + l('vaultUpgrades').innerHTML=vaultStr; + if (vaultStr=='') l('vaultUpgrades').style.display='none'; else l('vaultUpgrades').style.display='block'; } Game.UnlockAt=[];//this contains an array of every upgrade with a cookie requirement in the form of {cookies:(amount of cookies earned required),name:(name of upgrade or achievement to unlock)} (and possibly require:(name of upgrade of achievement to own)) @@ -6858,9 +8124,14 @@ Game.Launch=function() 8:{name:'Cherrysilver',unlock:250,achievUnlock:350,iconRow:17,color:'#f01700',price: 500000000000000}, 9:{name:'Hazelrald',unlock:300,achievUnlock:400,iconRow:18,color:'#9ab834',price: 500000000000000000}, 10:{name:'Mooncandy',unlock:350,achievUnlock:450,iconRow:19,color:'#7e7ab9',price: 500000000000000000000}, - 'synergy1':{name:'Synergy I',unlock:15,iconRow:20,color:'#008595',special:1,req:'Synergies Vol. I',price: 2000}, - 'synergy2':{name:'Synergy II',unlock:75,iconRow:20,color:'#008595',special:1,req:'Synergies Vol. II',price: 2000000000}, + 11:{name:'Astrofudge',unlock:400,achievUnlock:500,iconRow:28,color:'#9a3316',price: 5000000000000000000000000}, + 12:{name:'Alabascream',unlock:450,achievUnlock:550,iconRow:30,color:'#c1a88c',price: 50000000000000000000000000000}, + 13:{name:'Iridyum',unlock:500,achievUnlock:600,iconRow:31,color:'#adb1b3',price: 500000000000000000000000000000000}, + 'synergy1':{name:'Synergy I',unlock:15,iconRow:20,color:'#008595',special:1,req:'Synergies Vol. I',price: 200000}, + 'synergy2':{name:'Synergy II',unlock:75,iconRow:29,color:'#008595',special:1,req:'Synergies Vol. II',price: 200000000000}, + 'fortune':{name:'Fortune',unlock:-1,iconRow:32,color:'#9ab834',special:1,price: 77777777777777777777777777777}, }; + for (var i in Game.Tiers){Game.Tiers[i].upgrades=[];} Game.GetIcon=function(type,tier) { var col=0; @@ -6875,10 +8146,17 @@ Game.Launch=function() if (Game.last.type=='achievement') Game.Objects[building].tieredAchievs[tier]=Game.last; else Game.Objects[building].tieredUpgrades[tier]=Game.last; } + Game.MakeTiered=function(upgrade,tier,col) + { + upgrade.tier=tier; + if (typeof col!=='undefined') upgrade.icon=[col,Game.Tiers[tier].iconRow]; + } Game.TieredUpgrade=function(name,desc,building,tier) { var upgrade=new Game.Upgrade(name,desc,Game.Objects[building].basePrice*Game.Tiers[tier].price,Game.GetIcon(building,tier)); Game.SetTier(building,tier); + if (!upgrade.buildingTie1 && building) upgrade.buildingTie1=Game.Objects[building]; + if (tier=='fortune' && building) Game.Objects[building].fortune=upgrade; return upgrade; } Game.SynergyUpgrade=function(name,desc,building1,building2,tier) @@ -6922,11 +8200,13 @@ Game.Launch=function() else if (syn.buildingTie2.name==me.name) mult*=(1+0.001*syn.buildingTie1.amount); } } + if (me.fortune && Game.Has(me.fortune.name)) mult*=1.07; + if (me.grandma && Game.Has(me.grandma.name)) mult*=(1+Game.Objects['Grandma'].amount*0.01*(1/(me.id-1))); return mult; } Game.UnlockTiered=function(me) { - for (var i in me.tieredUpgrades) {if (me.amount>=Game.Tiers[me.tieredUpgrades[i].tier].unlock) Game.Unlock(me.tieredUpgrades[i].name);} + for (var i in me.tieredUpgrades) {if (Game.Tiers[me.tieredUpgrades[i].tier].unlock!=-1 && me.amount>=Game.Tiers[me.tieredUpgrades[i].tier].unlock) Game.Unlock(me.tieredUpgrades[i].name);} for (var i in me.tieredAchievs) {if (me.amount>=Game.Tiers[me.tieredAchievs[i].tier].achievUnlock) Game.Win(me.tieredAchievs[i].name);} for (var i in me.synergies) {var syn=me.synergies[i];if (Game.Has(Game.Tiers[syn.tier].req) && syn.buildingTie1.amount>=Game.Tiers[syn.tier].unlock && syn.buildingTie2.amount>=Game.Tiers[syn.tier].unlock) Game.Unlock(syn.name);} } @@ -6939,13 +8219,13 @@ Game.Launch=function() //define upgrades //WARNING : do NOT add new upgrades in between, this breaks the saves. Add them at the end ! var order=100;//this is used to set the order in which the items are listed - new Game.Upgrade('Reinforced index finger','The mouse and cursors are twice as efficient.prod prod',100,[0,0]); - new Game.Upgrade('Carpal tunnel prevention cream','The mouse and cursors are twice as efficient.it... it hurts to click...',500,[0,1]); - new Game.Upgrade('Ambidextrous','The mouse and cursors are twice as efficient.Look ma, both hands!',10000,[0,2]) - new Game.Upgrade('Thousand fingers','The mouse and cursors gain +0.1 cookies for each non-cursor object owned.clickity',100000,[0,13]); - new Game.Upgrade('Million fingers','The mouse and cursors gain +0.5 cookies for each non-cursor object owned.clickityclickity',10000000,[0,14]); - new Game.Upgrade('Billion fingers','The mouse and cursors gain +5 cookies for each non-cursor object owned.clickityclickityclickity',100000000,[0,15]); - new Game.Upgrade('Trillion fingers','The mouse and cursors gain +50 cookies for each non-cursor object owned.clickityclickityclickityclickity',1000000000,[0,16]); + new Game.Upgrade('Reinforced index finger','The mouse and cursors are twice as efficient.prod prod',100,[0,0]);Game.MakeTiered(Game.last,1,0); + new Game.Upgrade('Carpal tunnel prevention cream','The mouse and cursors are twice as efficient.it... it hurts to click...',500,[0,1]);Game.MakeTiered(Game.last,2,0); + new Game.Upgrade('Ambidextrous','The mouse and cursors are twice as efficient.Look ma, both hands!',10000,[0,2]);Game.MakeTiered(Game.last,3,0); + new Game.Upgrade('Thousand fingers','The mouse and cursors gain +0.1 cookies for each non-cursor object owned.clickity',100000,[0,13]);Game.MakeTiered(Game.last,4,0); + new Game.Upgrade('Million fingers','The mouse and cursors gain +0.5 cookies for each non-cursor object owned.clickityclickity',10000000,[0,14]);Game.MakeTiered(Game.last,5,0); + new Game.Upgrade('Billion fingers','The mouse and cursors gain +5 cookies for each non-cursor object owned.clickityclickityclickity',100000000,[0,15]);Game.MakeTiered(Game.last,6,0); + new Game.Upgrade('Trillion fingers','The mouse and cursors gain +50 cookies for each non-cursor object owned.clickityclickityclickityclickity',1000000000,[0,16]);Game.MakeTiered(Game.last,7,0); order=200; new Game.TieredUpgrade('Forwards from grandma','Grandmas are twice as efficient.RE:RE:thought you\'d get a kick out of this ;))','Grandma',1); @@ -6988,15 +8268,16 @@ Game.Launch=function() new Game.TieredUpgrade('Quantum conundrum','Time machines are twice as efficient.There is only one constant, and that is universal uncertainty.
Or is it?
','Time machine',3); order=20000; - new Game.Upgrade('Kitten helpers','You gain more CpS the more milk you have.meow may I help you',9000000,Game.GetIcon('Kitten',1));Game.last.kitten=1; - new Game.Upgrade('Kitten workers','You gain more CpS the more milk you have.meow meow meow meow',9000000000,Game.GetIcon('Kitten',2));Game.last.kitten=1; + new Game.Upgrade('Kitten helpers','You gain more CpS the more milk you have.meow may I help you',9000000,Game.GetIcon('Kitten',1));Game.last.kitten=1;Game.MakeTiered(Game.last,1,18); + new Game.Upgrade('Kitten workers','You gain more CpS the more milk you have.meow meow meow meow',9000000000,Game.GetIcon('Kitten',2));Game.last.kitten=1;Game.MakeTiered(Game.last,2,18); order=10000; - Game.NewUpgradeCookie({name:'Plain cookies',desc:'Meh.',icon:[2,3],power: 1, price: 999999}); + Game.NewUpgradeCookie({name:'Plain cookies',desc:'We all gotta start somewhere.',icon:[2,3],power: 1, price: 999999}); Game.NewUpgradeCookie({name:'Sugar cookies',desc:'Tasty, if a little unimaginative.',icon:[7,3],power: 1, price: 999999*5}); Game.NewUpgradeCookie({name:'Oatmeal raisin cookies',desc:'No raisin to hate these.',icon:[0,3],power: 1, price: 9999999}); Game.NewUpgradeCookie({name:'Peanut butter cookies',desc:'Get yourself some jam cookies!',icon:[1,3],power: 1, price: 9999999*5}); - Game.NewUpgradeCookie({name:'Coconut cookies',desc:'These are *way* flaky.',icon:[3,3],power: 1, price: 99999999}); + Game.NewUpgradeCookie({name:'Coconut cookies',desc:'Flaky, but not unreliable. Some people go crazy for these.',icon:[3,3],power: 2, price: 99999999}); + order=10001; Game.NewUpgradeCookie({name:'White chocolate cookies',desc:'I know what you\'ll say. It\'s just cocoa butter! It\'s not real chocolate!
Oh please.',icon:[4,3],power:2, price: 99999999*5}); Game.NewUpgradeCookie({name:'Macadamia nut cookies',desc:'They\'re macadamn delicious!',icon:[5,3],power: 2, price: 999999999}); Game.NewUpgradeCookie({name:'Double-chip cookies',desc:'DOUBLE THE CHIPS
DOUBLE THE TASTY
(double the calories)',icon:[6,3],power:2, price: 999999999*5}); @@ -7004,7 +8285,7 @@ Game.Launch=function() Game.NewUpgradeCookie({name:'All-chocolate cookies',desc:'CHOCOVERDOSE.',icon:[9,3],power: 2, price: 9999999999*5}); order=100; - new Game.Upgrade('Quadrillion fingers','The mouse and cursors gain +500 cookies for each non-cursor object owned.clickityclickityclickityclickityclick',10000000000,[0,17]); + new Game.Upgrade('Quadrillion fingers','The mouse and cursors gain +500 cookies for each non-cursor object owned.clickityclickityclickityclickityclick',10000000000,[0,17]);Game.MakeTiered(Game.last,8,0); order=200;new Game.TieredUpgrade('Prune juice','Grandmas are twice as efficient.Gets me going.','Grandma',4); order=300;new Game.TieredUpgrade('Genetically-modified cookies','Farms are twice as efficient.All-natural mutations.','Farm',4); @@ -7020,35 +8301,36 @@ Game.Launch=function() new Game.Upgrade('Serendipity','Golden cookies appear twice as often and stay twice as long.What joy! Seven horseshoes!',77777777777,[27,6]); order=20000; - new Game.Upgrade('Kitten engineers','You gain more CpS the more milk you have.meow meow meow meow, sir',90000000000000,Game.GetIcon('Kitten',3));Game.last.kitten=1; + new Game.Upgrade('Kitten engineers','You gain more CpS the more milk you have.meow meow meow meow, sir',90000000000000,Game.GetIcon('Kitten',3));Game.last.kitten=1;Game.MakeTiered(Game.last,3,18); order=10020; Game.NewUpgradeCookie({name:'Dark chocolate-coated cookies',desc:'These absorb light so well you almost need to squint to see them.',icon:[10,3],power: 4, price: 99999999999}); Game.NewUpgradeCookie({name:'White chocolate-coated cookies',desc:'These dazzling cookies absolutely glisten with flavor.',icon:[11,3],power: 4, price: 99999999999}); - - Game.getGrandmaSynergyUpgradeMultiplier=function(building) - { - return (1+Game.Objects['Grandma'].amount*0.01*(1/(Game.Objects[building].id-1))); - } - Game.getGrandmaSynergyUpgradeDesc=function(building) + Game.GrandmaSynergies=[]; + Game.GrandmaSynergy=function(name,desc,building) { var building=Game.Objects[building]; var grandmaNumber=(building.id-1); if (grandmaNumber==1) grandmaNumber='grandma'; else grandmaNumber+=' grandmas'; - return 'Grandmas are twice as efficient. '+(building.plural.charAt(0).toUpperCase()+building.plural.slice(1))+' gain +1% CpS per '+grandmaNumber+'.'; + desc='Grandmas are twice as efficient. '+(building.plural.charAt(0).toUpperCase()+building.plural.slice(1))+' gain +1% CpS per '+grandmaNumber+'.'+desc+''; + + var upgrade=new Game.Upgrade(name,desc,building.basePrice*Game.Tiers[2].price,[10,9],function(){Game.Objects['Grandma'].redraw();}); + building.grandma=upgrade; + upgrade.buildingTie=building; + Game.GrandmaSynergies.push(upgrade.name); + return upgrade; } order=250; - new Game.Upgrade('Farmer grandmas',Game.getGrandmaSynergyUpgradeDesc('Farm')+'A nice farmer to grow more cookies.',Game.Objects['Farm'].basePrice*Game.Tiers[2].price,[10,9],function(){Game.Objects['Grandma'].redraw();}); - new Game.Upgrade('Miner grandmas',Game.getGrandmaSynergyUpgradeDesc('Mine')+'A nice miner to dig more cookies.',Game.Objects['Mine'].basePrice*Game.Tiers[2].price,[10,9],function(){Game.Objects['Grandma'].redraw();}); - new Game.Upgrade('Worker grandmas',Game.getGrandmaSynergyUpgradeDesc('Factory')+'A nice worker to manufacture more cookies.',Game.Objects['Factory'].basePrice*Game.Tiers[2].price,[10,9],function(){Game.Objects['Grandma'].redraw();}); - order=255; - new Game.Upgrade('Cosmic grandmas',Game.getGrandmaSynergyUpgradeDesc('Shipment')+'A nice thing to... uh... cookies.',Game.Objects['Shipment'].basePrice*Game.Tiers[2].price,[10,9],function(){Game.Objects['Grandma'].redraw();}); - new Game.Upgrade('Transmuted grandmas',Game.getGrandmaSynergyUpgradeDesc('Alchemy lab')+'A nice golden grandma to convert into more cookies.',Game.Objects['Alchemy lab'].basePrice*Game.Tiers[2].price,[10,9],function(){Game.Objects['Grandma'].redraw();}); - new Game.Upgrade('Altered grandmas',Game.getGrandmaSynergyUpgradeDesc('Portal')+'a NiCe GrAnDmA tO bA##########',Game.Objects['Portal'].basePrice*Game.Tiers[2].price,[10,9],function(){Game.Objects['Grandma'].redraw();}); - new Game.Upgrade('Grandmas\' grandmas',Game.getGrandmaSynergyUpgradeDesc('Time machine')+'A nice grandma\'s nice grandma to bake double the cookies.',Game.Objects['Time machine'].basePrice*Game.Tiers[2].price,[10,9],function(){Game.Objects['Grandma'].redraw();}); + Game.GrandmaSynergy('Farmer grandmas','A nice farmer to grow more cookies.','Farm'); + Game.GrandmaSynergy('Miner grandmas','A nice miner to dig more cookies.','Mine'); + Game.GrandmaSynergy('Worker grandmas','A nice worker to manufacture more cookies.','Factory'); + Game.GrandmaSynergy('Cosmic grandmas','A nice thing to... uh... cookies.','Shipment'); + Game.GrandmaSynergy('Transmuted grandmas','A nice golden grandma to convert into more cookies.','Alchemy lab'); + Game.GrandmaSynergy('Altered grandmas','a NiCe GrAnDmA tO bA##########','Portal'); + Game.GrandmaSynergy('Grandmas\' grandmas','A nice grandma\'s nice grandma to bake double the cookies.','Time machine'); order=14000; Game.baseResearchTime=Game.fps*60*30; @@ -7068,18 +8350,17 @@ Game.Launch=function() new Game.Upgrade('Bingo center/Research facility','Grandma-operated science lab and leisure club.
Grandmas are 4 times as efficient.
Regularly unlocks new upgrades.What could possibly keep those grandmothers in check?...
Bingo.
',1000000000000000,[11,9],function(){Game.SetResearch('Specialized chocolate chips');});Game.last.noPerm=1; order=15000; - - new Game.Upgrade('Specialized chocolate chips','Cookie production multiplier +1%.Computer-designed chocolate chips. Computer chips, if you will.',100000000000,[0,9],function(){Game.SetResearch('Designer cocoa beans');});Game.last.pool='tech'; - new Game.Upgrade('Designer cocoa beans','Cookie production multiplier +2%.Now more aerodynamic than ever!',200000000000,[1,9],function(){Game.SetResearch('Ritual rolling pins');});Game.last.pool='tech'; - new Game.Upgrade('Ritual rolling pins','Grandmas are twice as efficient.The result of years of scientific research!',400000000000,[2,9],function(){Game.SetResearch('Underworld ovens');});Game.last.pool='tech'; - new Game.Upgrade('Underworld ovens','Cookie production multiplier +3%.Powered by science, of course!',800000000000,[3,9],function(){Game.SetResearch('One mind');});Game.last.pool='tech'; - new Game.Upgrade('One mind','Each grandma gains +0.02 base CpS per grandma.
Note : the grandmothers are growing restless. Do not encourage them.
We are one. We are many.',1600000000000,[4,9],function(){Game.elderWrath=1;Game.SetResearch('Exotic nuts');Game.storeToRefresh=1;});Game.last.pool='tech'; + new Game.Upgrade('Specialized chocolate chips','Cookie production multiplier +1%.Computer-designed chocolate chips. Computer chips, if you will.',1000000000000000,[0,9],function(){Game.SetResearch('Designer cocoa beans');});Game.last.pool='tech'; + new Game.Upgrade('Designer cocoa beans','Cookie production multiplier +2%.Now more aerodynamic than ever!',2000000000000000,[1,9],function(){Game.SetResearch('Ritual rolling pins');});Game.last.pool='tech'; + new Game.Upgrade('Ritual rolling pins','Grandmas are twice as efficient.The result of years of scientific research!',4000000000000000,[2,9],function(){Game.SetResearch('Underworld ovens');});Game.last.pool='tech'; + new Game.Upgrade('Underworld ovens','Cookie production multiplier +3%.Powered by science, of course!',8000000000000000,[3,9],function(){Game.SetResearch('One mind');});Game.last.pool='tech'; + new Game.Upgrade('One mind','Each grandma gains +0.02 base CpS per grandma.
Note : the grandmothers are growing restless. Do not encourage them.
We are one. We are many.',16000000000000000,[4,9],function(){Game.elderWrath=1;Game.SetResearch('Exotic nuts');Game.storeToRefresh=1;});Game.last.pool='tech'; //Game.last.clickFunction=function(){return confirm('Warning : purchasing this will have unexpected, and potentially undesirable results!\nIt\'s all downhill from here. You have been warned!\nPurchase anyway?');}; Game.RequiresConfirmation(Game.last,'
Warning : purchasing this will have unexpected, and potentially undesirable results!
It\'s all downhill from here. You have been warned!

Purchase anyway?
'); - new Game.Upgrade('Exotic nuts','Cookie production multiplier +4%.You\'ll go crazy over these!',3200000000000,[5,9],function(){Game.SetResearch('Communal brainsweep');});Game.last.pool='tech'; - new Game.Upgrade('Communal brainsweep','Each grandma gains another +0.02 base CpS per grandma.
Note : proceeding any further in scientific research may have unexpected results. You have been warned.
We fuse. We merge. We grow.',6400000000000,[6,9],function(){Game.elderWrath=2;Game.SetResearch('Arcane sugar');Game.storeToRefresh=1;});Game.last.pool='tech'; - new Game.Upgrade('Arcane sugar','Cookie production multiplier +5%.Tastes like insects, ligaments, and molasses.',12800000000000,[7,9],function(){Game.SetResearch('Elder Pact');});Game.last.pool='tech'; - new Game.Upgrade('Elder Pact','Each grandma gains +0.05 base CpS per portal.
Note : this is a bad idea.
squirm crawl slither writhe
today we rise
',25600000000000,[8,9],function(){Game.elderWrath=3;Game.storeToRefresh=1;});Game.last.pool='tech'; + new Game.Upgrade('Exotic nuts','Cookie production multiplier +4%.You\'ll go crazy over these!',32000000000000000,[5,9],function(){Game.SetResearch('Communal brainsweep');});Game.last.pool='tech'; + new Game.Upgrade('Communal brainsweep','Each grandma gains another +0.02 base CpS per grandma.
Note : proceeding any further in scientific research may have unexpected results. You have been warned.
We fuse. We merge. We grow.',64000000000000000,[6,9],function(){Game.elderWrath=2;Game.SetResearch('Arcane sugar');Game.storeToRefresh=1;});Game.last.pool='tech'; + new Game.Upgrade('Arcane sugar','Cookie production multiplier +5%.Tastes like insects, ligaments, and molasses.',128000000000000000,[7,9],function(){Game.SetResearch('Elder Pact');});Game.last.pool='tech'; + new Game.Upgrade('Elder Pact','Each grandma gains +0.05 base CpS per portal.
Note : this is a bad idea.
squirm crawl slither writhe
today we rise
',256000000000000000,[8,9],function(){Game.elderWrath=3;Game.storeToRefresh=1;});Game.last.pool='tech'; new Game.Upgrade('Elder Pledge','Contains the wrath of the elders, at least for a while.This is a simple ritual involving anti-aging cream, cookie batter mixed in the moonlight, and a live chicken.',1,[9,9],function() { Game.elderWrath=0; @@ -7095,11 +8376,16 @@ Game.Launch=function() Game.last.timerDisplay=function(){if (!Game.Upgrades['Elder Pledge'].bought) return -1; else return 1-Game.pledgeT/Game.getPledgeDuration();} Game.last.priceFunc=function(){return Math.pow(8,Math.min(Game.pledges+2,14));} + Game.last.descFunc=function(){ + return '
'+(Game.pledges==0?'You haven\'t pledged to the elders yet.':('You\'ve pledged to the elders '+(Game.pledges==1?'once':Game.pledges==2?'twice':(Game.pledges+' times'))+'.'))+'
'+this.desc; + }; + + order=150; - new Game.Upgrade('Plastic mouse','Clicking gains +1% of your CpS.Slightly squeaky.',50000,[11,0]); - new Game.Upgrade('Iron mouse','Clicking gains +1% of your CpS.Click like it\'s 1349!',5000000,[11,1]); - new Game.Upgrade('Titanium mouse','Clicking gains +1% of your CpS.Heavy, but powerful.',500000000,[11,2]); - new Game.Upgrade('Adamantium mouse','Clicking gains +1% of your CpS.You could cut diamond with these.',50000000000,[11,13]); + new Game.Upgrade('Plastic mouse','Clicking gains +1% of your CpS.Slightly squeaky.',50000,[11,0]);Game.MakeTiered(Game.last,1,11); + new Game.Upgrade('Iron mouse','Clicking gains +1% of your CpS.Click like it\'s 1349!',5000000,[11,1]);Game.MakeTiered(Game.last,2,11); + new Game.Upgrade('Titanium mouse','Clicking gains +1% of your CpS.Heavy, but powerful.',500000000,[11,2]);Game.MakeTiered(Game.last,3,11); + new Game.Upgrade('Adamantium mouse','Clicking gains +1% of your CpS.You could cut diamond with these.',50000000000,[11,13]);Game.MakeTiered(Game.last,4,11); order=40000; new Game.Upgrade('Ultrascience','Research takes only 5 seconds.YEAH, SCIENCE!',7,[9,2]);//debug purposes only @@ -7110,7 +8396,7 @@ Game.Launch=function() Game.NewUpgradeCookie({name:'Zebra cookies',desc:'...',icon:[1,4],power: 2, price: 999999999999}); order=100; - new Game.Upgrade('Quintillion fingers','The mouse and cursors gain +5000 cookies for each non-cursor object owned.man, just go click click click click click, it\'s real easy, man.',10000000000000,[0,18]); + new Game.Upgrade('Quintillion fingers','The mouse and cursors gain +5000 cookies for each non-cursor object owned.man, just go click click click click click, it\'s real easy, man.',10000000000000,[0,18]);Game.MakeTiered(Game.last,9,0); order=40000; new Game.Upgrade('Gold hoard','Golden cookies appear really often.That\'s entirely too many.',7,[10,14]);//debug purposes only @@ -7151,13 +8437,14 @@ Game.Launch=function() new Game.Upgrade('Neuromancy','Can toggle upgrades on and off at will in the stats menu.Can also come in handy to unsee things that can\'t be unseen.',7,[4,9]);//debug purposes only Game.last.pool='debug'; - order=10030; + order=10020; Game.NewUpgradeCookie({name:'Empire biscuits',desc:'For your growing cookie empire, of course!',icon:[5,4],power: 2, price: 99999999999999}); + order=10031; Game.NewUpgradeCookie({name:'British tea biscuits',desc:'Quite.',icon:[6,4],require:'Tin of british tea biscuits',power: 2, price: 99999999999999}); Game.NewUpgradeCookie({name:'Chocolate british tea biscuits',desc:'Yes, quite.',icon:[7,4],require:Game.last.name,power: 2, price: 99999999999999}); Game.NewUpgradeCookie({name:'Round british tea biscuits',desc:'Yes, quite riveting.',icon:[8,4],require:Game.last.name,power: 2, price: 99999999999999}); Game.NewUpgradeCookie({name:'Round chocolate british tea biscuits',desc:'Yes, quite riveting indeed.',icon:[9,4],require:Game.last.name,power: 2, price: 99999999999999}); - Game.NewUpgradeCookie({name:'Round british tea biscuits with heart motif',desc:'Yes, quite riveting, old chap.',icon:[10,4],require:Game.last.name,power: 2, price: 99999999999999}); + Game.NewUpgradeCookie({name:'Round british tea biscuits with heart motif',desc:'Yes, quite riveting indeed, old chap.',icon:[10,4],require:Game.last.name,power: 2, price: 99999999999999}); Game.NewUpgradeCookie({name:'Round chocolate british tea biscuits with heart motif',desc:'I like cookies.',icon:[11,4],require:Game.last.name,power: 2, price: 99999999999999}); order=1000; @@ -7167,7 +8454,7 @@ Game.Launch=function() new Game.TieredUpgrade('Big bang bake','Antimatter condensers are twice as efficient.And that\'s how it all began.','Antimatter condenser',4); order=255; - new Game.Upgrade('Antigrandmas',Game.getGrandmaSynergyUpgradeDesc('Antimatter condenser')+'A mean antigrandma to vomit more cookies.
(Do not put in contact with normal grandmas; loss of matter may occur.)
',Game.Objects['Antimatter condenser'].basePrice*Game.Tiers[2].price,[10,9],function(){Game.Objects['Grandma'].redraw();}); + Game.GrandmaSynergy('Antigrandmas','A mean antigrandma to vomit more cookies.','Antimatter condenser'); order=10020; Game.NewUpgradeCookie({name:'Madeleines',desc:'Unforgettable!',icon:[12,3],power: 2, price: 99999999999999*5}); @@ -7176,11 +8463,11 @@ Game.Launch=function() Game.NewUpgradeCookie({name:'Sablés',desc:'The name implies they\'re made of sand. But you know better, don\'t you?',icon:[13,4],power: 2, price: 999999999999999}); order=20000; - new Game.Upgrade('Kitten overseers','You gain more CpS the more milk you have.my purrpose is to serve you, sir',90000000000000000,Game.GetIcon('Kitten',4));Game.last.kitten=1; + new Game.Upgrade('Kitten overseers','You gain more CpS the more milk you have.my purrpose is to serve you, sir',90000000000000000,Game.GetIcon('Kitten',4));Game.last.kitten=1;Game.MakeTiered(Game.last,4,18); order=100; - new Game.Upgrade('Sextillion fingers','The mouse and cursors gain +50000 cookies for each non-cursor object owned.sometimes
things just
click
',10000000000000000,[0,19]); + new Game.Upgrade('Sextillion fingers','The mouse and cursors gain +50000 cookies for each non-cursor object owned.sometimes
things just
click
',10000000000000000,[0,19]);Game.MakeTiered(Game.last,10,0); order=200;new Game.TieredUpgrade('Double-thick glasses','Grandmas are twice as efficient.Oh... so THAT\'s what I\'ve been baking.','Grandma',5); order=300;new Game.TieredUpgrade('Gingerbread scarecrows','Farms are twice as efficient.Staring at your crops with mischievous glee.','Farm',5); @@ -7193,7 +8480,7 @@ Game.Launch=function() order=1000;new Game.TieredUpgrade('Reverse cyclotrons','Antimatter condensers are twice as efficient.These can uncollision particles and unspin atoms. For... uh... better flavor, and stuff.','Antimatter condenser',5); order=150; - new Game.Upgrade('Unobtainium mouse','Clicking gains +1% of your CpS.These nice mice should suffice.',5000000000000,[11,14]); + new Game.Upgrade('Unobtainium mouse','Clicking gains +1% of your CpS.These nice mice should suffice.',5000000000000,[11,14]);Game.MakeTiered(Game.last,5,11); order=10020; Game.NewUpgradeCookie({name:'Caramoas',desc:'Yeah. That\'s got a nice ring to it.',icon:[14,4],require:'Box of brand biscuits',power: 3, price: 9999999999999999}); @@ -7226,9 +8513,22 @@ Game.Launch=function() Game.NewUpgradeCookie({name:'Pumpkin cookies',desc:'Not even pumpkin-flavored. Tastes like glazing. Yeugh.',locked:1,icon:[16,8],power: 2, price: 444444444444}); Game.NewUpgradeCookie({name:'Eyeball cookies',desc:'When you stare into the cookie, the cookie stares back at you.',locked:1,icon:[17,8],power: 2, price: 444444444444}); Game.NewUpgradeCookie({name:'Spider cookies',desc:'You found the recipe on the web. They do whatever a cookie can.',locked:1,icon:[18,8],power: 2, price: 444444444444}); - + + Game.halloweenDrops=['Skull cookies','Ghost cookies','Bat cookies','Slime cookies','Pumpkin cookies','Eyeball cookies','Spider cookies']; + + Game.GetHowManyHalloweenDrops=function() + { + var num=0; + for (var i in Game.halloweenDrops) {if (Game.Has(Game.halloweenDrops[i])) num++;} + return num; + } + /*for (var i in Game.halloweenDrops) + { + Game.Upgrades[Game.halloweenDrops[i]].descFunc=function(){return '
You currently own '+Game.GetHowManyHalloweenDrops()+'/'+Game.halloweenDrops.length+' halloween cookies.
'+this.desc;}; + }*/ + order=0; - new Game.Upgrade('Persistent memory','Subsequent research will be 10 times as fast.It\'s all making sense!
Again!
',5,[9,2]);Game.last.pool='prestige'; + new Game.Upgrade('Persistent memory','Subsequent research will be 10 times as fast.It\'s all making sense!
Again!
',500,[9,2]);Game.last.pool='prestige'; order=40000; new Game.Upgrade('Wrinkler doormat','Wrinklers spawn much more frequently.You\'re such a pushover.',7,[19,8]);//debug purposes only @@ -7297,7 +8597,20 @@ Game.Launch=function() Game.NewUpgradeCookie({name:'Weeping heart biscuits',desc:'An ice-cold blueberry biscuit, symbol of a mending heart.',require:Game.last.name,season:'valentines',icon:[21,3], power:heartPower,price: 1000000000000000}); Game.NewUpgradeCookie({name:'Golden heart biscuits',desc:'A beautiful biscuit to symbolize kindness, true love, and sincerity.',require:Game.last.name,season:'valentines',icon:[21,4], power:heartPower,price: 1000000000000000000}); Game.NewUpgradeCookie({name:'Eternal heart biscuits',desc:'Silver icing for a very special someone you\'ve liked for a long, long time.',require:Game.last.name,season:'valentines',icon:[19,4], power:heartPower,price: 1000000000000000000000}); - + + Game.heartDrops=['Pure heart biscuits','Ardent heart biscuits','Sour heart biscuits','Weeping heart biscuits','Golden heart biscuits','Eternal heart biscuits']; + + Game.GetHowManyHeartDrops=function() + { + var num=0; + for (var i in Game.heartDrops) {if (Game.Has(Game.heartDrops[i])) num++;} + return num; + } + /*for (var i in Game.heartDrops) + { + Game.Upgrades[Game.heartDrops[i]].descFunc=function(){return '
You currently own '+Game.GetHowManyHeartDrops()+'/'+Game.heartDrops.length+' heart biscuits.
'+this.desc;}; + }*/ + order=1100; new Game.TieredUpgrade('Gem polish','Prisms are twice as efficient.Get rid of the grime and let more light in.
Truly, truly outrageous.
','Prism',1); new Game.TieredUpgrade('9th color','Prisms are twice as efficient.Delve into untouched optical depths where even the mantis shrimp hasn\'t set an eye!','Prism',2); @@ -7306,15 +8619,16 @@ Game.Launch=function() new Game.TieredUpgrade('Pure cosmic light','Prisms are twice as efficient.Your prisms now receive pristine, unadulterated photons from the other end of the universe.','Prism',5); order=255; - new Game.Upgrade('Rainbow grandmas',Game.getGrandmaSynergyUpgradeDesc('Prism')+'A luminous grandma to sparkle into cookies.',Game.Objects['Prism'].basePrice*Game.Tiers[2].price,[10,9],function(){Game.Objects['Grandma'].redraw();}); + Game.GrandmaSynergy('Rainbow grandmas','A luminous grandma to sparkle into cookies.','Prism'); order=24000; - Game.seasonTriggerBasePrice=1111111111; - new Game.Upgrade('Season switcher','Allows you to trigger seasonal events at will, for a price.There will always be time.',1111,[16,6],function(){for (var i in Game.seasons){Game.Unlock(Game.seasons[i].trigger);}});Game.last.pool='prestige'; - new Game.Upgrade('Festive biscuit','Triggers Christmas season for the next 24 hours.
Triggering another season will cancel this one.
Cost increases with every season switch.\'Twas the night before Christmas- or was it?',Game.seasonTriggerBasePrice,[12,10]);Game.last.season='christmas';Game.last.pool='toggle'; - new Game.Upgrade('Ghostly biscuit','Triggers Halloween season for the next 24 hours.
Triggering another season will cancel this one.
Cost increases with every season switch.spooky scary skeletons
will wake you with a boo
',Game.seasonTriggerBasePrice,[13,8]);Game.last.season='halloween';Game.last.pool='toggle'; - new Game.Upgrade('Lovesick biscuit','Triggers Valentine\'s Day season for the next 24 hours.
Triggering another season will cancel this one.
Cost increases with every season switch.Romance never goes out of fashion.',Game.seasonTriggerBasePrice,[20,3]);Game.last.season='valentines';Game.last.pool='toggle'; - new Game.Upgrade('Fool\'s biscuit','Triggers Business Day season for the next 24 hours.
Triggering another season will cancel this one.
Cost increases with every season switch.Business. Serious business. This is absolutely all of your business.',Game.seasonTriggerBasePrice,[17,6]);Game.last.season='fools';Game.last.pool='toggle'; + Game.seasonTriggerBasePrice=1000000000;//1111111111; + new Game.Upgrade('Season switcher','Allows you to trigger seasonal events at will, for a price.There will always be time.',1111,[16,6],function(){for (var i in Game.seasons){Game.Unlock(Game.seasons[i].trigger);}});Game.last.pool='prestige';Game.last.parents=['Heralds']; + new Game.Upgrade('Festive biscuit','Triggers Christmas season for the next 24 hours.
Triggering another season will cancel this one.
Cost scales with unbuffed CpS and increases with every season switch.\'Twas the night before Christmas- or was it?',Game.seasonTriggerBasePrice,[12,10]);Game.last.season='christmas';Game.last.pool='toggle'; + new Game.Upgrade('Ghostly biscuit','Triggers Halloween season for the next 24 hours.
Triggering another season will cancel this one.
Cost scales with unbuffed CpS and increases with every season switch.spooky scary skeletons
will wake you with a boo
',Game.seasonTriggerBasePrice,[13,8]);Game.last.season='halloween';Game.last.pool='toggle'; + new Game.Upgrade('Lovesick biscuit','Triggers Valentine\'s Day season for the next 24 hours.
Triggering another season will cancel this one.
Cost scales with unbuffed CpS and increases with every season switch.Romance never goes out of fashion.',Game.seasonTriggerBasePrice,[20,3]);Game.last.season='valentines';Game.last.pool='toggle'; + new Game.Upgrade('Fool\'s biscuit','Triggers Business Day season for the next 24 hours.
Triggering another season will cancel this one.
Cost scales with unbuffed CpS and increases with every season switch.Business. Serious business. This is absolutely all of your business.',Game.seasonTriggerBasePrice,[17,6]);Game.last.season='fools';Game.last.pool='toggle'; + order=40000; new Game.Upgrade('Eternal seasons','Seasons now last forever.Season to taste.',7,[16,6],function(){for (var i in Game.seasons){Game.Unlock(Game.seasons[i].trigger);}});//debug purposes only @@ -7322,14 +8636,14 @@ Game.Launch=function() order=20000; - new Game.Upgrade('Kitten managers','You gain more CpS the more milk you have.that\'s not gonna paws any problem, sir',900000000000000000000,Game.GetIcon('Kitten',5));Game.last.kitten=1; + new Game.Upgrade('Kitten managers','You gain more CpS the more milk you have.that\'s not gonna paws any problem, sir',900000000000000000000,Game.GetIcon('Kitten',5));Game.last.kitten=1;Game.MakeTiered(Game.last,5,18); order=100; - new Game.Upgrade('Septillion fingers','The mouse and cursors gain +500000 cookies for each non-cursor object owned.[cursory flavor text]',10000000000000000000,[12,20]); - new Game.Upgrade('Octillion fingers','The mouse and cursors gain +5000000 cookies for each non-cursor object owned.Turns out you can quite put your finger on it.',10000000000000000000000,[12,19]); + new Game.Upgrade('Septillion fingers','The mouse and cursors gain +500000 cookies for each non-cursor object owned.[cursory flavor text]',10000000000000000000,[12,20]);Game.MakeTiered(Game.last,11,0); + new Game.Upgrade('Octillion fingers','The mouse and cursors gain +5000000 cookies for each non-cursor object owned.Turns out you can quite put your finger on it.',10000000000000000000000,[12,19]);Game.MakeTiered(Game.last,12,0); - order=150;new Game.Upgrade('Eludium mouse','Clicking gains +1% of your CpS.I rodent do that if I were you.',500000000000000,[11,15]); - new Game.Upgrade('Wishalloy mouse','Clicking gains +1% of your CpS.Clicking is fine and dandy, but don\'t smash your mouse over it. Get your game on. Go play.',50000000000000000,[11,16]); + order=150;new Game.Upgrade('Eludium mouse','Clicking gains +1% of your CpS.I rodent do that if I were you.',500000000000000,[11,15]);Game.MakeTiered(Game.last,6,11); + new Game.Upgrade('Wishalloy mouse','Clicking gains +1% of your CpS.Clicking is fine and dandy, but don\'t smash your mouse over it. Get your game on. Go play.',50000000000000000,[11,16]);Game.MakeTiered(Game.last,7,11); order=200;new Game.TieredUpgrade('Aging agents','Grandmas are twice as efficient.Counter-intuitively, grandmas have the uncanny ability to become more powerful the older they get.','Grandma',6); order=300;new Game.TieredUpgrade('Pulsar sprinklers','Farms are twice as efficient.There\'s no such thing as over-watering. The moistest is the bestest.','Farm',6); order=500;new Game.TieredUpgrade('Deep-bake process','Factories are twice as efficient.A patented process increasing cookie yield two-fold for the same amount of ingredients. Don\'t ask how, don\'t take pictures, and be sure to wear your protective suit.','Factory',6); @@ -7338,7 +8652,7 @@ Game.Launch=function() order=700;new Game.TieredUpgrade('Origin crucible','Alchemy labs are twice as efficient.Built from the rarest of earths and located at the very deepest of the largest mountain, this legendary crucible is said to retain properties from the big-bang itself.','Alchemy lab',6); order=800;new Game.TieredUpgrade('Deity-sized portals','Portals are twice as efficient.It\'s almost like, say, an elder god could fit through this thing now. Hypothetically.','Portal',6); order=900;new Game.TieredUpgrade('Far future enactment','Time machines are twice as efficient.The far future enactment authorizes you to delve deep into the future - where civilization has fallen and risen again, and cookies are plentiful.','Time machine',6); - order=1000;new Game.TieredUpgrade('Nanocosmics','Antimatter condensers are twice as efficient.The theory of nanocosmics posits that each subatomic particle is in fact its own self-contained universe, holding unfathomable amounts of energy.','Antimatter condenser',6); + order=1000;new Game.TieredUpgrade('Nanocosmics','Antimatter condensers are twice as efficient.The theory of nanocosmics posits that each subatomic particle is in fact its own self-contained universe, holding unfathomable amounts of energy.
This somehow stacks with the nested universe theory, because physics.
','Antimatter condenser',6); order=1100; new Game.TieredUpgrade('Glow-in-the-dark','Prisms are twice as efficient.Your prisms now glow in the dark, effectively doubling their output!','Prism',6); @@ -7356,7 +8670,7 @@ Game.Launch=function() order=24000; - new Game.Upgrade('Bunny biscuit','Triggers Easter season for the next 24 hours.
Triggering another season will cancel this one.
Cost increases with every season switch.All the world will be your enemy
and when they catch you,
they will kill you...
but first they must catch you.
',Game.seasonTriggerBasePrice,[0,12]);Game.last.season='easter';Game.last.pool='toggle'; + new Game.Upgrade('Bunny biscuit','Triggers Easter season for the next 24 hours.
Triggering another season will cancel this one.
Cost scales with unbuffed CpS and increases with every season switch.All the world will be your enemy
and when they catch you,
they will kill you...
but first they must catch you.
',Game.seasonTriggerBasePrice,[0,12]);Game.last.season='easter';Game.last.pool='toggle'; var eggPrice=999999999999; var eggPrice2=99999999999999; @@ -7384,7 +8698,13 @@ Game.Launch=function() else Game.Notify('Chocolate egg','The egg bursts into '+Beautify(cookies)+' cookies!',Game.Upgrades['Chocolate egg'].icon); Game.Earn(cookies); }); - new Game.Upgrade('Century egg','You continually gain more CpS the longer you\'ve played in the current session.
Cost scales with how many eggs you own.Actually not centuries-old. This one isn\'t a day over 86!',eggPrice2,[19,12]); + new Game.Upgrade('Century egg','You continually gain more CpS the longer you\'ve played in the current ascension.
Cost scales with how many eggs you own.Actually not centuries-old. This one isn\'t a day over 86!',eggPrice2,[19,12]); + Game.last.descFunc=function(){ + var day=Math.floor((Date.now()-Game.startDate)/1000/10)*10/60/60/24; + day=Math.min(day,100); + var n=(1-Math.pow(1-day/100,3))*0.1; + return '
Current boost : +'+Beautify(n*100,1)+'%
'+this.desc; + }; new Game.Upgrade('"egg"','+9 CpShey it\'s "egg"',eggPrice2,[20,12]); Game.easterEggs=['Chicken egg','Duck egg','Turkey egg','Quail egg','Robin egg','Ostrich egg','Cassowary egg','Salmon roe','Frogspawn','Shark egg','Turtle egg','Ant larva','Golden goose egg','Faberge egg','Wrinklerspawn','Cookie egg','Omelette','Chocolate egg','Century egg','"egg"']; @@ -7399,12 +8719,19 @@ Game.Launch=function() } for (var i in Game.eggDrops)//scale egg prices to how many eggs you have {Game.Upgrades[Game.eggDrops[i]].priceFunc=function(){return Math.pow(2,Game.GetHowManyEggs())*999;}} + //{Game.Upgrades[Game.eggDrops[i]].priceFunc=function(){return Math.pow(Game.GetHowManyEggs()+1,2)*Game.cookiesPs*60*5;}} for (var i in Game.rareEggDrops) {Game.Upgrades[Game.rareEggDrops[i]].priceFunc=function(){return Math.pow(3,Game.GetHowManyEggs())*999;}} + //{Game.Upgrades[Game.rareEggDrops[i]].priceFunc=function(){return Math.pow(Game.GetHowManyEggs()+1,3)*Game.cookiesPs*60*5;}} + /*for (var i in Game.easterEggs) + { + Game.Upgrades[Game.easterEggs[i]].descFunc=function(){return '
You currently own '+Game.GetHowManyEggs()+'/'+Game.easterEggs.length+' eggs.
'+this.desc;}; + }*/ Game.DropEgg=function(failRate) { + failRate*=1/Game.dropRateMult(); if (Game.season!='easter') return; if (Game.HasAchiev('Hide & seek champion')) failRate*=0.7; if (Game.Has('Omelette')) failRate*=0.9; @@ -7416,8 +8743,6 @@ Game.Launch=function() else if (godLvl==2) failRate*=0.95; else if (godLvl==3) failRate*=0.97; } - if (Game.Has('Santa\'s bottomless bag')) failRate*=0.9; - if (Game.hasAura('Mind Over Matter')) failRate*=0.75; if (Math.random()>=failRate) { var drop=''; @@ -7465,9 +8790,9 @@ Game.Launch=function() new Game.TieredUpgrade('Dark formulas','Wizard towers are twice as efficient.Eldritch forces are at work behind these spells - you get the feeling you really shouldn\'t be messing with those. But I mean, free cookies, right?','Wizard tower',6); order=250; - new Game.Upgrade('Banker grandmas',Game.getGrandmaSynergyUpgradeDesc('Bank')+'A nice banker to cash in more cookies.',Game.Objects['Bank'].basePrice*Game.Tiers[2].price,[10,9],function(){Game.Objects['Grandma'].redraw();}); - new Game.Upgrade('Priestess grandmas',Game.getGrandmaSynergyUpgradeDesc('Temple')+'A nice priestess to praise the one true Baker in the sky.',Game.Objects['Temple'].basePrice*Game.Tiers[2].price,[10,9],function(){Game.Objects['Grandma'].redraw();}); - new Game.Upgrade('Witch grandmas',Game.getGrandmaSynergyUpgradeDesc('Wizard tower')+'A nice witch to cast a zip, and a zoop, and poof! Cookies.',Game.Objects['Wizard tower'].basePrice*Game.Tiers[2].price,[10,9],function(){Game.Objects['Grandma'].redraw();}); + Game.GrandmaSynergy('Banker grandmas','A nice banker to cash in more cookies.','Bank'); + Game.GrandmaSynergy('Priestess grandmas','A nice priestess to praise the one true Baker in the sky.','Temple'); + Game.GrandmaSynergy('Witch grandmas','A nice witch to cast a zip, and a zoop, and poof! Cookies.','Wizard tower'); @@ -7494,6 +8819,16 @@ Game.Launch=function() new Game.Upgrade('Permanent upgrade slot IV',desc, 400000,[3,10]);Game.last.pool='prestige';Game.last.parents=['Permanent upgrade slot III'];Game.last.iconFunction=function(){return Game.PermanentSlotIcon(3);};Game.last.activateFunction=function(){Game.AssignPermanentSlot(3);}; new Game.Upgrade('Permanent upgrade slot V',desc, 5000000,[4,10]);Game.last.pool='prestige';Game.last.parents=['Permanent upgrade slot IV'];Game.last.iconFunction=function(){return Game.PermanentSlotIcon(4);};Game.last.activateFunction=function(){Game.AssignPermanentSlot(4);}; + var slots=['Permanent upgrade slot I','Permanent upgrade slot II','Permanent upgrade slot III','Permanent upgrade slot IV','Permanent upgrade slot V']; + for (var i=0;i'+'Current :
'+upgrade.name+'
'+this.desc; + };}(i); + } + Game.PermanentSlotIcon=function(slot) { if (Game.permanentUpgrades[slot]==-1) return [slot,10]; @@ -7533,7 +8868,7 @@ Game.Launch=function() Game.SelectingPermanentUpgrade=upgrade; Game.Prompt('

Pick an upgrade to make permanent

'+ - '
'+ + '
'+(Game.crate(Game.UpgradesById[upgrade==-1?0:upgrade],'','','upgradeToSlot'))+'
'+ '
'+upgrades+'
'+ '
Here are all the upgrades you\'ve purchased last playthrough.
Pick one to permanently gain its effects!
You can reassign this slot anytime you ascend.
' ,[['Confirm','Game.permanentUpgrades['+slot+']=Game.SelectingPermanentUpgrade;Game.BuildAscendTree();Game.ClosePrompt();'],'Cancel'],0,'widePrompt'); @@ -7542,7 +8877,10 @@ Game.Launch=function() Game.PutUpgradeInPermanentSlot=function(upgrade,slot) { Game.SelectingPermanentUpgrade=upgrade; - l('upgradeToSlot').style.backgroundPosition=(-Game.UpgradesById[upgrade].icon[0]*48)+'px '+(-Game.UpgradesById[upgrade].icon[1]*48)+'px'; + l('upgradeToSlotWrap').innerHTML=''; + l('upgradeToSlotWrap').style.display=(upgrade==-1?'none':'block'); + l('upgradeToSlotNone').style.display=(upgrade!=-1?'none':'block'); + l('upgradeToSlotWrap').innerHTML=(Game.crate(Game.UpgradesById[upgrade==-1?0:upgrade],'','','upgradeToSlot')); } new Game.Upgrade('Starspawn','Eggs drop 10% more often.
Golden cookies appear 2% more often during Easter.',111111,[0,12]);Game.last.pool='prestige';Game.last.parents=['Season switcher']; @@ -7614,16 +8952,16 @@ Game.Launch=function() order=20000; - new Game.Upgrade('Kitten accountants','You gain more CpS the more milk you have.business going great, sir',900000000000000000000000,Game.GetIcon('Kitten',6));Game.last.kitten=1; - new Game.Upgrade('Kitten specialists','You gain more CpS the more milk you have.optimeowzing your workflow like whoah, sir',900000000000000000000000000,Game.GetIcon('Kitten',7));Game.last.kitten=1; - new Game.Upgrade('Kitten experts','You gain more CpS the more milk you have.10 years expurrrtise in the cookie business, sir',900000000000000000000000000000,Game.GetIcon('Kitten',8));Game.last.kitten=1; + new Game.Upgrade('Kitten accountants','You gain more CpS the more milk you have.business going great, sir',900000000000000000000000,Game.GetIcon('Kitten',6));Game.last.kitten=1;Game.MakeTiered(Game.last,6,18); + new Game.Upgrade('Kitten specialists','You gain more CpS the more milk you have.optimeowzing your workflow like whoah, sir',900000000000000000000000000,Game.GetIcon('Kitten',7));Game.last.kitten=1;Game.MakeTiered(Game.last,7,18); + new Game.Upgrade('Kitten experts','You gain more CpS the more milk you have.10 years expurrrtise in the cookie business, sir',900000000000000000000000000000,Game.GetIcon('Kitten',8));Game.last.kitten=1;Game.MakeTiered(Game.last,8,18); new Game.Upgrade('How to bake your dragon','Allows you to purchase a crumbly egg once you have earned 1 million cookies.A tome full of helpful tips such as "oh god, stay away from it", "why did we buy this thing, it\'s not even house-broken" and "groom twice a week in the direction of the scales".',9,[22,12]);Game.last.pool='prestige'; order=25100; new Game.Upgrade('A crumbly egg','Unlocks the cookie dragon egg.Thank you for adopting this robust, fun-loving cookie dragon! It will bring you years of joy and entertainment.
Keep in a dry and cool place, and away from other house pets. Subscription to home insurance is strongly advised.
',25,[21,12]); - new Game.Upgrade('Chimera','Synergy upgrades are 2% cheaper.
You gain another +5% of your regular CpS while the game is closed.
You retain optimal cookie production while the game is closed for 2 more days.More than the sum of its parts.',Math.pow(angelPriceFactor,8),[24,7]);Game.last.pool='prestige';Game.last.parents=['God','Lucifer','Synergies Vol. II']; + new Game.Upgrade('Chimera','Synergy upgrades are 2% cheaper.
You gain another +5% of your regular CpS while the game is closed.
You retain optimal cookie production while the game is closed for 2 more days.More than the sum of its parts.',Math.pow(angelPriceFactor,9),[24,7]);Game.last.pool='prestige';Game.last.parents=['God','Lucifer','Synergies Vol. II']; new Game.Upgrade('Tin of butter cookies','Contains an assortment of rich butter cookies.Five varieties of danish cookies.
Complete with little paper cups.
',25,[21,9]);Game.last.pool='prestige';Game.last.parents=['Heavenly cookies']; @@ -7641,13 +8979,30 @@ Game.Launch=function() new Game.Upgrade('Golden switch [off]','Turning this on will give you a passive +50% CpS, but prevents golden cookies from spawning.
Cost is equal to 1 hour of production.',1000000,[20,10]); Game.last.pool='toggle';Game.last.toggleInto='Golden switch [on]'; Game.last.priceFunc=function(){return Game.cookiesPs*60*60;} + var func=function(){ + if (Game.Has('Residual luck')) + { + var bonus=0; + var upgrades=Game.goldenCookieUpgrades; + for (var i in upgrades) {if (Game.Has(upgrades[i])) bonus++;} + return '
'+Game.listTinyOwnedUpgrades(Game.goldenCookieUpgrades)+'

The effective boost is +'+Beautify(Math.round(50+bonus*10))+'%
thanks to residual luck
and your '+bonus+' golden cookie upgrade'+(bonus==1?'':'s')+'.
'+this.desc; + } + return this.desc; + }; + Game.last.descFunc=func; new Game.Upgrade('Golden switch [on]','The switch is currently giving you a passive +50% CpS; it also prevents golden cookies from spawning.
Turning it off will revert those effects.
Cost is equal to 1 hour of production.',1000000,[21,10]); Game.last.pool='toggle';Game.last.toggleInto='Golden switch [off]'; Game.last.priceFunc=function(){return Game.cookiesPs*60*60;} + Game.last.descFunc=func; order=50000; new Game.Upgrade('Milk selector','Lets you pick what flavor of milk to display.',0,[1,8]); + Game.last.descFunc=function(){ + var choice=this.choicesFunction()[Game.milkType]; + return '
Current :
'+choice.name+'
'+this.desc; + }; + Game.last.pool='toggle'; Game.last.choicesFunction=function() { @@ -7674,9 +9029,19 @@ Game.Launch=function() choices[16]={name:'Midnight milk',icon:[5,7]}; choices[17]={name:'Green inferno milk',icon:[4,7]}; choices[18]={name:'Frostfire milk',icon:[3,7]}; + + choices[24]={name:'Soy milk',icon:[27,23]}; } choices[19]={name:'Honey milk',icon:[21,23]}; + choices[20]={name:'Coffee milk',icon:[22,23]}; + choices[21]={name:'Tea milk',icon:[23,23]}; + choices[22]={name:'Coconut milk',icon:[24,23]}; + choices[23]={name:'Cherry milk',icon:[25,23]}; + + choices[25]={name:'Spiced milk',icon:[26,23]}; + choices[26]={name:'Maple milk',icon:[28,23]}; + choices[27]={name:'Mint milk',icon:[29,23]}; choices[Game.milkType].selected=1; return choices; @@ -7705,6 +9070,14 @@ Game.Launch=function() 17:{pic:'milkGreenFire'}, 18:{pic:'milkBlueFire'}, 19:{pic:'milkHoney'}, + 20:{pic:'milkCoffee'}, + 21:{pic:'milkTea'}, + 22:{pic:'milkCoconut'}, + 23:{pic:'milkCherry'}, + 24:{pic:'milkSoy'}, + 25:{pic:'milkSpiced'}, + 26:{pic:'milkMaple'}, + 27:{pic:'milkMint'}, }; @@ -7725,11 +9098,11 @@ Game.Launch=function() order=10030; Game.NewUpgradeCookie({name:'Digits',desc:'Three flavors, zero phalanges.',icon:[26,8],require:'Box of brand biscuits',power: 2, price: 999999999999999*5}); - order=10030; + order=10029; Game.NewUpgradeCookie({name:'Butter horseshoes',desc:'It would behoove you to not overindulge in these.',icon:[22,9],require:'Tin of butter cookies',power: 4, price: 99999999999999999999999}); Game.NewUpgradeCookie({name:'Butter pucks',desc:'Lord, what fools these mortals be!
(This is kind of a hokey reference.)',icon:[23,9],require:'Tin of butter cookies',power: 4, price: 99999999999999999999999*5}); Game.NewUpgradeCookie({name:'Butter knots',desc:'Look, you can call these pretzels if you want, but you\'d just be fooling yourself, wouldn\'t you?',icon:[24,9],require:'Tin of butter cookies',power: 4, price: 999999999999999999999999}); - Game.NewUpgradeCookie({name:'Butter slabs',desc:'Nothing better than a slab in the face.',icon:[25,9],require:'Tin of butter cookies',power: 4, price: 999999999999999999999999*5}); + Game.NewUpgradeCookie({name:'Butter slabs',desc:'Nothing butter than a slab to the face.',icon:[25,9],require:'Tin of butter cookies',power: 4, price: 999999999999999999999999*5}); Game.NewUpgradeCookie({name:'Butter swirls',desc:'These are equal parts sugar, butter, and warm fuzzy feelings - all of which cause millions of deaths everyday.',icon:[26,9],require:'Tin of butter cookies',power: 4, price: 9999999999999999999999999}); order=10020; @@ -7757,6 +9130,11 @@ Game.Launch=function() order=49900; new Game.Upgrade('Golden cookie sound selector','Lets you change the sound golden cookies make when they spawn.',0,[28,6]); + Game.last.descFunc=function(){ + var choice=this.choicesFunction()[Game.chimeType]; + return '
Current :
'+choice.name+'
'+this.desc; + }; + Game.last.pool='toggle'; Game.last.choicesFunction=function() { @@ -7779,57 +9157,57 @@ Game.Launch=function() new Game.Upgrade('Residual luck','While the golden switch is on, you gain an additional +10% CpS per golden cookie upgrade owned.Fortune comes in many flavors.',99999,[27,6]);Game.last.pool='prestige';Game.last.parents=['Golden switch']; - order=150;new Game.Upgrade('Fantasteel mouse','Clicking gains +1% of your CpS.You could be clicking using your touchpad and we\'d be none the wiser.',5000000000000000000,[11,17]); - new Game.Upgrade('Nevercrack mouse','Clicking gains +1% of your CpS.How much beefier can you make a mouse until it\'s considered a rat?',500000000000000000000,[11,18]); + order=150;new Game.Upgrade('Fantasteel mouse','Clicking gains +1% of your CpS.You could be clicking using your touchpad and we\'d be none the wiser.',5000000000000000000,[11,17]);Game.MakeTiered(Game.last,8,11); + new Game.Upgrade('Nevercrack mouse','Clicking gains +1% of your CpS.How much beefier can you make a mouse until it\'s considered a rat?',500000000000000000000,[11,18]);Game.MakeTiered(Game.last,9,11); new Game.Upgrade('Five-finger discount','All upgrades are 1% cheaper per 100 cursors.Stick it to the man.',555555,[28,7],function(){Game.upgradesToRebuild=1;});Game.last.pool='prestige';Game.last.parents=['Halo gloves','Abaddon']; order=5000; - new Game.SynergyUpgrade('Future almanacs','Lets you predict optimal planting times. It\'s crazy what time travel can do!','Farm','Time machine','synergy1'); - new Game.SynergyUpgrade('Rain prayer','A deeply spiritual ceremonial involving complicated dance moves and high-tech cloud-busting lasers.','Farm','Temple','synergy2'); + Game.SynergyUpgrade('Future almanacs','Lets you predict optimal planting times. It\'s crazy what time travel can do!','Farm','Time machine','synergy1'); + Game.SynergyUpgrade('Rain prayer','A deeply spiritual ceremonial involving complicated dance moves and high-tech cloud-busting lasers.','Farm','Temple','synergy2'); - new Game.SynergyUpgrade('Seismic magic','Surprise earthquakes are an old favorite of wizardly frat houses.','Mine','Wizard tower','synergy1'); - new Game.SynergyUpgrade('Asteroid mining','As per the 1974 United Cosmic Convention, comets, moons, and inhabited planetoids are no longer legally excavatable.
But hey, a space bribe goes a long way.
','Mine','Shipment','synergy2'); + Game.SynergyUpgrade('Seismic magic','Surprise earthquakes are an old favorite of wizardly frat houses.','Mine','Wizard tower','synergy1'); + Game.SynergyUpgrade('Asteroid mining','As per the 1974 United Cosmic Convention, comets, moons, and inhabited planetoids are no longer legally excavatable.
But hey, a space bribe goes a long way.
','Mine','Shipment','synergy2'); - new Game.SynergyUpgrade('Quantum electronics','Your machines won\'t even be sure if they\'re on or off!','Factory','Antimatter condenser','synergy1'); - new Game.SynergyUpgrade('Temporal overclocking','Introduce more quickitude in your system for increased speedation of fastness.','Factory','Time machine','synergy2'); + Game.SynergyUpgrade('Quantum electronics','Your machines won\'t even be sure if they\'re on or off!','Factory','Antimatter condenser','synergy1'); + Game.SynergyUpgrade('Temporal overclocking','Introduce more quickitude in your system for increased speedation of fastness.','Factory','Time machine','synergy2'); - new Game.SynergyUpgrade('Contracts from beyond','Make sure to read the fine print!','Bank','Portal','synergy1'); - new Game.SynergyUpgrade('Printing presses','Fake bills so real, they\'re almost worth the ink they\'re printed with.','Bank','Factory','synergy2'); + Game.SynergyUpgrade('Contracts from beyond','Make sure to read the fine print!','Bank','Portal','synergy1'); + Game.SynergyUpgrade('Printing presses','Fake bills so real, they\'re almost worth the ink they\'re printed with.','Bank','Factory','synergy2'); - new Game.SynergyUpgrade('Paganism','Some deities are better left unworshipped.','Temple','Portal','synergy1'); - new Game.SynergyUpgrade('God particle','Turns out God is much tinier than we thought, I guess.','Temple','Antimatter condenser','synergy2'); + Game.SynergyUpgrade('Paganism','Some deities are better left unworshipped.','Temple','Portal','synergy1'); + Game.SynergyUpgrade('God particle','Turns out God is much tinier than we thought, I guess.','Temple','Antimatter condenser','synergy2'); - new Game.SynergyUpgrade('Arcane knowledge','Some things were never meant to be known - only mildly speculated.','Wizard tower','Alchemy lab','synergy1'); - new Game.SynergyUpgrade('Magical botany','Already known in some reactionary newspapers as "the wizard\'s GMOs".','Wizard tower','Farm','synergy2'); + Game.SynergyUpgrade('Arcane knowledge','Some things were never meant to be known - only mildly speculated.','Wizard tower','Alchemy lab','synergy1'); + Game.SynergyUpgrade('Magical botany','Already known in some reactionary newspapers as "the wizard\'s GMOs".','Wizard tower','Farm','synergy2'); - new Game.SynergyUpgrade('Fossil fuels','Somehow better than plutonium for powering rockets.
Extracted from the fuels of ancient, fossilized civilizations.
','Shipment','Mine','synergy1'); - new Game.SynergyUpgrade('Shipyards','Where carpentry, blind luck, and asbestos insulation unite to produce the most dazzling spaceships on the planet.','Shipment','Factory','synergy2'); + Game.SynergyUpgrade('Fossil fuels','Somehow better than plutonium for powering rockets.
Extracted from the fuels of ancient, fossilized civilizations.
','Shipment','Mine','synergy1'); + Game.SynergyUpgrade('Shipyards','Where carpentry, blind luck, and asbestos insulation unite to produce the most dazzling spaceships on the planet.','Shipment','Factory','synergy2'); - new Game.SynergyUpgrade('Primordial ores','Only when refining the purest metals will you extract the sweetest sap of the earth.','Alchemy lab','Mine','synergy1'); - new Game.SynergyUpgrade('Gold fund','If gold is the backbone of the economy, cookies, surely, are its hip joints.','Alchemy lab','Bank','synergy2'); + Game.SynergyUpgrade('Primordial ores','Only when refining the purest metals will you extract the sweetest sap of the earth.','Alchemy lab','Mine','synergy1'); + Game.SynergyUpgrade('Gold fund','If gold is the backbone of the economy, cookies, surely, are its hip joints.','Alchemy lab','Bank','synergy2'); - new Game.SynergyUpgrade('Infernal crops','Sprinkle regularly with FIRE.','Portal','Farm','synergy1'); - new Game.SynergyUpgrade('Abysmal glimmer','Someone, or something, is staring back at you.
Perhaps at all of us.
','Portal','Prism','synergy2'); + Game.SynergyUpgrade('Infernal crops','Sprinkle regularly with FIRE.','Portal','Farm','synergy1'); + Game.SynergyUpgrade('Abysmal glimmer','Someone, or something, is staring back at you.
Perhaps at all of us.
','Portal','Prism','synergy2'); - new Game.SynergyUpgrade('Relativistic parsec-skipping','People will tell you this isn\'t physically possible.
These are people you don\'t want on your ship.
','Time machine','Shipment','synergy1'); - new Game.SynergyUpgrade('Primeval glow','From unending times, an ancient light still shines, impossibly pure and fragile in its old age.','Time machine','Prism','synergy2'); + Game.SynergyUpgrade('Relativistic parsec-skipping','People will tell you this isn\'t physically possible.
These are people you don\'t want on your ship.
','Time machine','Shipment','synergy1'); + Game.SynergyUpgrade('Primeval glow','From unending times, an ancient light still shines, impossibly pure and fragile in its old age.','Time machine','Prism','synergy2'); - new Game.SynergyUpgrade('Extra physics funding','Time to put your money where your particle colliders are.','Antimatter condenser','Bank','synergy1'); - new Game.SynergyUpgrade('Chemical proficiency','Discover exciting new elements, such as Fleshmeltium, Inert Shampoo Byproduct #17 and Carbon++!','Antimatter condenser','Alchemy lab','synergy2'); + Game.SynergyUpgrade('Extra physics funding','Time to put your money where your particle colliders are.','Antimatter condenser','Bank','synergy1'); + Game.SynergyUpgrade('Chemical proficiency','Discover exciting new elements, such as Fleshmeltium, Inert Shampoo Byproduct #17 and Carbon++!','Antimatter condenser','Alchemy lab','synergy2'); - new Game.SynergyUpgrade('Light magic','Actually not to be taken lightly! No, I\'m serious. 178 people died last year. You don\'t mess around with magic.','Prism','Wizard tower','synergy1'); - new Game.SynergyUpgrade('Mystical energies','Something beckons from within the light. It is warm, comforting, and apparently the cause for several kinds of exotic skin cancers.','Prism','Temple','synergy2'); + Game.SynergyUpgrade('Light magic','Actually not to be taken lightly! No, I\'m serious. 178 people died last year. You don\'t mess around with magic.','Prism','Wizard tower','synergy1'); + Game.SynergyUpgrade('Mystical energies','Something beckons from within the light. It is warm, comforting, and apparently the cause for several kinds of exotic skin cancers.','Prism','Temple','synergy2'); - new Game.Upgrade('Synergies Vol. I','Unlocks a new tier of upgrades that affect 2 buildings at the same time.
Synergies appear once you have 15 of both buildings.The many beats the few.',2525,[10,20]);Game.last.pool='prestige';Game.last.parents=['Satan','Dominions']; - new Game.Upgrade('Synergies Vol. II','Unlocks a new tier of upgrades that affect 2 buildings at the same time.
Synergies appear once you have 75 of both buildings.The several beats the many.',252525,[10,20]);Game.last.pool='prestige';Game.last.parents=['Beelzebub','Seraphim','Synergies Vol. I']; + new Game.Upgrade('Synergies Vol. I','Unlocks a new tier of upgrades that affect 2 buildings at the same time.
Synergies appear once you have 15 of both buildings.The many beats the few.',222222,[10,20]);Game.last.pool='prestige';Game.last.parents=['Satan','Dominions']; + new Game.Upgrade('Synergies Vol. II','Unlocks a new tier of upgrades that affect 2 buildings at the same time.
Synergies appear once you have 75 of both buildings.The several beats the many.',2222222,[10,29]);Game.last.pool='prestige';Game.last.parents=['Beelzebub','Seraphim','Synergies Vol. I']; - new Game.Upgrade('Heavenly cookies','Cookie production multiplier +10% permanently.Baked with heavenly chips. An otherwordldly flavor that transcends time and space.',3,[25,12]);Game.last.pool='prestige';Game.last.parents=['Legacy'];Game.last.power=10;Game.last.pseudoCookie=true; + new Game.Upgrade('Heavenly cookies','Cookie production multiplier +10% permanently.Baked with heavenly chips. An otherwordly flavor that transcends time and space.',3,[25,12]);Game.last.pool='prestige';Game.last.parents=['Legacy'];Game.last.power=10;Game.last.pseudoCookie=true; new Game.Upgrade('Wrinkly cookies','Cookie production multiplier +10% permanently.The result of regular cookies left to age out for countless eons in a place where time and space are meaningless.',6666666,[26,12]);Game.last.pool='prestige';Game.last.parents=['Sacrilegious corruption','Elder spice'];Game.last.power=10;Game.last.pseudoCookie=true; - new Game.Upgrade('Distilled essence of redoubled luck','Golden cookies have 1% chance of being doubled.Tastes glittery. The empty phial makes for a great pencil holder.',7777777,[27,12]);Game.last.pool='prestige';Game.last.parents=['Divine bakeries','Residual luck']; + new Game.Upgrade('Distilled essence of redoubled luck','Golden cookies (and all other things that spawn, such as reindeer) have 1% chance of being doubled.Tastes glittery. The empty phial makes for a great pencil holder.',7777777,[27,12]);Game.last.pool='prestige';Game.last.parents=['Divine bakeries','Residual luck']; order=40000; new Game.Upgrade('Occult obstruction','Cookie production reduced to 0.If symptoms persist, consult a doctor.',7,[15,5]);//debug purposes only @@ -7837,112 +9215,538 @@ Game.Launch=function() new Game.Upgrade('Glucose-charged air','Sugar lumps coalesce a whole lot faster.Don\'t breathe too much or you\'ll get diabetes!',7,[29,16]);//debug purposes only Game.last.pool='debug'; - order=10300; - Game.NewUpgradeCookie({name:'Lavender chocolate butter biscuit',desc:'Rewarded for owning 300 of everything.
This subtly-flavored biscuit represents the accomplishments of decades of top-secret research. The molded design on the chocolate resembles a well-known entrepreneur who gave their all to the ancient path of baking.',icon:[26,10],power: 10,price: 999999999999999999999999999999999,locked:1}); + order=10300; + Game.NewUpgradeCookie({name:'Lavender chocolate butter biscuit',desc:'Rewarded for owning 300 of everything.
This subtly-flavored biscuit represents the accomplishments of decades of top-secret research. The molded design on the chocolate resembles a well-known entrepreneur who gave their all to the ancient path of baking.',icon:[26,10],power: 10,price: 999999999999999999999999999999999,locked:1}); + + order=10030; + Game.NewUpgradeCookie({name:'Lombardia cookies',desc:'These come from those farms with the really good memory.',icon:[23,13],require:'Box of brand biscuits',power: 3, price: 999999999999999999999*5}); + Game.NewUpgradeCookie({name:'Bastenaken cookies',desc:'French cookies made of delicious cinnamon and candy sugar. These do not contain Nuts!',icon:[24,13],require:'Box of brand biscuits',power: 3, price: 999999999999999999999*5}); + + order=10020; + Game.NewUpgradeCookie({name:'Pecan sandies',desc:'Stick a nut on a cookie and call it a day! Name your band after it! Whatever!',icon:[25,13],power: 4,price: 999999999999999999999999*5}); + Game.NewUpgradeCookie({name:'Moravian spice cookies',desc:'Popular for being the world\'s moravianest cookies.',icon:[26,13],power: 4,price: 9999999999999999999999999}); + Game.NewUpgradeCookie({name:'Anzac biscuits',desc:'Army biscuits from a bakery down under, containing no eggs but yes oats.',icon:[27,13],power: 4,price: 9999999999999999999999999*5}); + Game.NewUpgradeCookie({name:'Buttercakes',desc:'Glistening with cholesterol, these cookies moistly straddle the line between the legal definition of a cookie and just a straight-up stick of butter.',icon:[29,13],power: 4,price: 99999999999999999999999999}); + Game.NewUpgradeCookie({name:'Ice cream sandwiches',desc:'In an alternate universe, "ice cream sandwich" designates an ice cream cone filled with bacon, lettuce, and tomatoes. Maybe some sprinkles too.',icon:[28,13],power: 4,price: 99999999999999999999999999*5}); + + new Game.Upgrade('Stevia Caelestis','Sugar lumps ripen an hour sooner.A plant of supernatural sweetness grown by angels in heavenly gardens.',100000000,[25,15]);Game.last.pool='prestige';Game.last.parents=['Wrinkly cookies']; + new Game.Upgrade('Diabetica Daemonicus','Sugar lumps mature an hour sooner.A malevolent, if delicious herb that is said to grow on the cliffs of the darkest abyss of the underworld.',300000000,[26,15]);Game.last.pool='prestige';Game.last.parents=['Stevia Caelestis','Lucifer']; + new Game.Upgrade('Sucralosia Inutilis','Bifurcated sugar lumps appear 5% more often and are 5% more likely to drop 2 lumps.A rare berry of uninteresting flavor that is as elusive as its uses are limited; only sought-after by the most avid collectors with too much wealth on their hands.',1000000000,[27,15]);Game.last.pool='prestige';Game.last.parents=['Diabetica Daemonicus']; + + //note : these showIf functions stop working beyond 10 quadrillion prestige level, due to loss in precision; the solution, of course, is to make sure 10 quadrillion is not an attainable prestige level + new Game.Upgrade('Lucky digit','+1% prestige level effect on CpS.
+1% golden cookie effect duration.
+1% golden cookie lifespan.This upgrade is a bit shy and only appears when your prestige level ends in 7.',777,[24,15]);Game.last.pool='prestige';Game.last.parents=['Heavenly luck'];Game.last.showIf=function(){return (Math.ceil(Game.prestige)%10==7);}; + new Game.Upgrade('Lucky number','+1% prestige level effect on CpS.
+1% golden cookie effect duration.
+1% golden cookie lifespan.This upgrade is a reclusive hermit and only appears when your prestige level ends in 777.',77777,[24,15]);Game.last.pool='prestige';Game.last.parents=['Lucky digit','Lasting fortune'];Game.last.showIf=function(){return (Math.ceil(Game.prestige)%1000==777);}; + new Game.Upgrade('Lucky payout','+1% prestige level effect on CpS.
+1% golden cookie effect duration.
+1% golden cookie lifespan.This upgrade took an oath of complete seclusion from the rest of the world and only appears when your prestige level ends in 777777.',77777777,[24,15]);Game.last.pool='prestige';Game.last.parents=['Lucky number','Decisive fate'];Game.last.showIf=function(){return (Math.ceil(Game.prestige)%1000000==777777);}; + + order=50000; + new Game.Upgrade('Background selector','Lets you pick which wallpaper to display.',0,[29,5]); + Game.last.descFunc=function(){ + var choice=this.choicesFunction()[Game.bgType]; + return '
Current :
'+choice.name+'
'+this.desc; + }; + + Game.last.pool='toggle'; + Game.last.choicesFunction=function() + { + var choices=[]; + choices[0]={name:'Automatic',icon:[0,7]}; + choices[1]={name:'Blue',icon:[21,21]}; + choices[2]={name:'Red',icon:[22,21]}; + choices[3]={name:'White',icon:[23,21]}; + choices[4]={name:'Black',icon:[24,21]}; + choices[5]={name:'Gold',icon:[25,21]}; + choices[6]={name:'Grandmas',icon:[26,21]}; + choices[7]={name:'Displeased grandmas',icon:[27,21]}; + choices[8]={name:'Angered grandmas',icon:[28,21]}; + choices[9]={name:'Money',icon:[29,21]}; + choices[Game.bgType].selected=1; + return choices; + } + Game.last.choicesPick=function(id) + {Game.bgType=id;} + + Game.BGsByChoice={ + 0:{pic:'bgBlue'}, + 1:{pic:'bgBlue'}, + 2:{pic:'bgRed'}, + 3:{pic:'bgWhite'}, + 4:{pic:'bgBlack'}, + 5:{pic:'bgGold'}, + 6:{pic:'grandmas1'}, + 7:{pic:'grandmas2'}, + 8:{pic:'grandmas3'}, + 9:{pic:'bgMoney'}, + }; + + order=255; + Game.GrandmaSynergy('Lucky grandmas','A fortunate grandma that always seems to find more cookies.','Chancemaker'); + + order=1200; + new Game.TieredUpgrade('Your lucky cookie','Chancemakers are twice as efficient.This is the first cookie you\'ve ever baked. It holds a deep sentimental value and, after all this time, an interesting smell.','Chancemaker',1); + new Game.TieredUpgrade('"All Bets Are Off" magic coin','Chancemakers are twice as efficient.A coin that always lands on the other side when flipped. Not heads, not tails, not the edge. The other side.','Chancemaker',2); + new Game.TieredUpgrade('Winning lottery ticket','Chancemakers are twice as efficient.What lottery? THE lottery, that\'s what lottery! Only lottery that matters!','Chancemaker',3); + new Game.TieredUpgrade('Four-leaf clover field','Chancemakers are twice as efficient.No giant monsters here, just a whole lot of lucky grass.','Chancemaker',4); + new Game.TieredUpgrade('A recipe book about books','Chancemakers are twice as efficient.Tip the scales in your favor with 28 creative new ways to cook the books.','Chancemaker',5); + new Game.TieredUpgrade('Leprechaun village','Chancemakers are twice as efficient.You\'ve finally become accepted among the local leprechauns, who lend you their mythical luck as a sign of friendship (as well as some rather foul-tasting tea).','Chancemaker',6); + new Game.TieredUpgrade('Improbability drive','Chancemakers are twice as efficient.A strange engine that turns statistics on their head. Recommended by the Grandmother\'s Guide to the Bakery.','Chancemaker',7); + new Game.TieredUpgrade('Antisuperstistronics','Chancemakers are twice as efficient.An exciting new field of research that makes unlucky things lucky. No mirror unbroken, no ladder unwalked under!','Chancemaker',8); + + order=5000; + Game.SynergyUpgrade('Gemmed talismans','Good-luck charms covered in ancient and excruciatingly rare crystals. A must have for job interviews!','Chancemaker','Mine','synergy1'); + + order=20000; + new Game.Upgrade('Kitten consultants','You gain more CpS the more milk you have.glad to be overpaid to work with you, sir',900000000000000000000000000000000,Game.GetIcon('Kitten',9));Game.last.kitten=1;Game.MakeTiered(Game.last,9,18); + + order=99999; + var years=Math.floor((Date.now()-new Date(2013,7,8))/(1000*60*60*24*365)); + //only updates on page load + //may behave strangely on leap years + Game.NewUpgradeCookie({name:'Birthday cookie',desc:'-',icon:[22,13],power:years,price:99999999999999999999999999999});Game.last.baseDesc='Cookie production multiplier +1% for every year Cookie Clicker has existed (currently : +'+Beautify(years)+'%).Thank you for playing Cookie Clicker!
-Orteil
';Game.last.desc=BeautifyInText(Game.last.baseDesc); + + + order=150;new Game.Upgrade('Armythril mouse','Clicking gains +1% of your CpS.This one takes about 53 people to push it around and another 48 to jump down on the button and trigger a click. You could say it\'s got some heft to it.',50000000000000000000000,[11,19]);Game.MakeTiered(Game.last,10,11); + + order=200;new Game.TieredUpgrade('Reverse dementia','Grandmas are twice as efficient.Extremely unsettling, and somehow even worse than the regular kind.','Grandma',9); + order=300;new Game.TieredUpgrade('Humane pesticides','Farms are twice as efficient.Made by people, for people, from people and ready to unleash some righteous scorching pain on those pesky insects that so deserve it.','Farm',9); + order=400;new Game.TieredUpgrade('Mole people','Mines are twice as efficient.Engineered from real human beings within your very labs, these sturdy little folks have a knack for finding the tastiest underground minerals in conditions that more expensive machinery probably wouldn\'t survive.','Mine',9); + order=500;new Game.TieredUpgrade('Machine learning','Factories are twice as efficient.You figured you might get better productivity if you actually told your workers to learn how to work the machines. Sometimes, it\'s the little things...','Factory',9); + order=525;new Game.TieredUpgrade('Edible money','Banks are twice as efficient.It\'s really quite simple; you make all currency too delicious not to eat, solving world hunger and inflation in one fell swoop!','Bank',9); + order=550;new Game.TieredUpgrade('Sick rap prayers','Temples are twice as efficient.With their ill beat and radical rhymes, these way-hip religious tunes are sure to get all the youngins who thought they were 2 cool 4 church back on the pews and praying for more! Wicked!','Temple',9); + order=575;new Game.TieredUpgrade('Deluxe tailored wands','Wizard towers are twice as efficient.In this age of science, most skillful wand-makers are now long gone; but thankfully - not all those wanders are lost.','Wizard tower',9); + order=600;new Game.TieredUpgrade('Autopilot','Shipments are twice as efficient.Your ships are now fitted with completely robotic crews! It\'s crazy how much money you save when you don\'t have to compensate the families of those lost in space.','Shipment',9); + order=700;new Game.TieredUpgrade('The advent of chemistry','Alchemy labs are twice as efficient.You know what? That whole alchemy nonsense was a load of baseless rubbish. Dear god, what were you thinking?','Alchemy lab',9); + order=800;new Game.TieredUpgrade('The real world','Portals are twice as efficient.It turns out that our universe is actually the twisted dimension of another, saner plane of reality. Time to hop on over there and loot the place!','Portal',9); + order=900;new Game.TieredUpgrade('Second seconds','Time machines are twice as efficient.That\'s twice as many seconds in the same amount of time! What a deal! Also, what in god\'s name!','Time machine',9); + order=1000;new Game.TieredUpgrade('Quantum comb','Antimatter condensers are twice as efficient.Quantum entanglement is one of those things that are so annoying to explain that we might honestly be better off without it. This is finally possible thanks to the quantum comb!','Antimatter condenser',9); + order=1100;new Game.TieredUpgrade('Crystal mirrors','Prisms are twice as efficient.Designed to filter more light back into your prisms, reaching levels of brightness that reality itself had never planned for.','Prism',9); + order=1200;new Game.TieredUpgrade('Bunnypedes','Chancemakers are twice as efficient.You\'ve taken to breeding rabbits with hundreds of paws, which makes them intrinsically very lucky and thus a very handy (if very disturbing) pet.','Chancemaker',9); + + order=20000; + new Game.Upgrade('Kitten assistants to the regional manager','You gain more CpS the more milk you have.nothing stresses meowt... except having to seek the approval of my inferiors, sir',900000000000000000000000000000000000,Game.GetIcon('Kitten',10));Game.last.kitten=1;Game.MakeTiered(Game.last,10,18); + + order=5000; + Game.SynergyUpgrade('Charm quarks','They\'re after your lucky quarks!','Chancemaker','Antimatter condenser','synergy2'); + + + order=10020; + Game.NewUpgradeCookie({name:'Pink biscuits',desc:'One of the oldest cookies. Traditionally dipped in champagne to soften it, because the French will use any opportunity to drink.',icon:[21,16],power: 4,price: 999999999999999999999999999}); + Game.NewUpgradeCookie({name:'Whole-grain cookies',desc:'Covered in seeds and other earthy-looking debris. Really going for that "5-second rule" look.',icon:[22,16],power: 4,price: 999999999999999999999999999*5}); + Game.NewUpgradeCookie({name:'Candy cookies',desc:'These melt in your hands just a little bit.',icon:[23,16],power: 4,price: 9999999999999999999999999999}); + Game.NewUpgradeCookie({name:'Big chip cookies',desc:'You are in awe at the size of these chips. Absolute units.',icon:[24,16],power: 4,price: 9999999999999999999999999999*5}); + Game.NewUpgradeCookie({name:'One chip cookies',desc:'You get one.',icon:[25,16],power: 1,price: 99999999999999999999999999999}); + + + new Game.Upgrade('Sugar baking','Each unspent sugar lump (up to 100) gives +1% CpS.
Note : this means that spending sugar lumps will decrease your CpS until they grow back.
To bake with the sugary essence of eons themselves, you must first learn to take your sweet time.',200000000,[21,17]);Game.last.pool='prestige';Game.last.parents=['Stevia Caelestis']; + new Game.Upgrade('Sugar craving','Once an ascension, you may use the "Sugar frenzy" switch to triple your CpS for 1 hour, at the cost of 1 sugar lump.Just a little kick to sweeten the deal.',400000000,[22,17]);Game.last.pool='prestige';Game.last.parents=['Sugar baking']; + new Game.Upgrade('Sugar aging process','Each grandma (up to 600) makes sugar lumps ripen 6 seconds sooner.Aren\'t they just the sweetest?',600000000,[23,17]);Game.last.pool='prestige';Game.last.parents=['Sugar craving','Diabetica Daemonicus']; + + order=40050; + new Game.Upgrade('Sugar frenzy','Activating this will triple your CpS for 1 hour, at the cost of 1 sugar lump.
May only be used once per ascension.',0,[22,17]); + Game.last.priceLumps=1; + Game.last.pool='toggle';Game.last.toggleInto=0; + Game.last.canBuyFunc=function(){return Game.lumps>=1;}; + Game.last.clickFunction=Game.spendLump(1,'activate the sugar frenzy',function() + { + Game.Upgrades['Sugar frenzy'].buy(1); + buff=Game.gainBuff('sugar frenzy',60*60,3); + if (Game.prefs.popups) Game.Popup('Sugar frenzy activated!'); + else Game.Notify('Sugar frenzy!','CpS x3 for 1 hour!',[29,14]); + }); + + order=10020; + Game.NewUpgradeCookie({name:'Sprinkles cookies',desc:'A bit of festive decorating helps hide the fact that this might be one of the blandest cookies you\'ve ever tasted.',icon:[21,14],power: 4,price: 99999999999999999999999999999*5}); + Game.NewUpgradeCookie({name:'Peanut butter blossoms',desc:'Topped with a scrumptious chocolate squirt, which is something we really wish we didn\'t just write.',icon:[22,14],power: 4,price: 999999999999999999999999999999}); + Game.NewUpgradeCookie({name:'No-bake cookies',desc:'You have no idea how these mysterious oven-less treats came to be or how they hold their shape. You\'re thinking either elephant glue or cold fusion.',icon:[21,15],power: 4,price: 999999999999999999999999999999*5}); + Game.NewUpgradeCookie({name:'Florentines',desc:'These make up for being the fruitcake of cookies by at least having the decency to feature chocolate.',icon:[26,16],power: 4,price: 9999999999999999999999999999999}); + Game.NewUpgradeCookie({name:'Chocolate crinkles',desc:'Non-denominational cookies to celebrate year-round deliciousness, and certainly not Christmas or some other nonsense.',icon:[22,15],power: 4,price: 9999999999999999999999999999999*5}); + Game.NewUpgradeCookie({name:'Maple cookies',desc:'Made with syrup from a land where milk comes in bags, instead of spontaneously pooling at the bottom of your screen depending on your achievements.',icon:[21,13],power: 4,price: 99999999999999999999999999999999}); + + + order=40000; + new Game.Upgrade('Turbo-charged soil','Garden plants grow every second.
Garden seeds are free to plant.
You can switch soils at any time.It\'s got electrolytes!',7,[2,16]);//debug purposes only + Game.last.buyFunction=function(){if (Game.Objects['Farm'].minigameLoaded){Game.Objects['Farm'].minigame.computeStepT();}} + Game.last.pool='debug'; + + order=150; + new Game.Upgrade('Technobsidian mouse','Clicking gains +1% of your CpS.A highly advanced mouse of a sophisticated design. Only one thing on its mind : to click.',5000000000000000000000000,[11,28]);Game.MakeTiered(Game.last,11,11); + new Game.Upgrade('Plasmarble mouse','Clicking gains +1% of your CpS.A shifting blur in the corner of your eye, this mouse can trigger a flurry of clicks when grazed by even the slightest breeze.',500000000000000000000000000,[11,30]);Game.MakeTiered(Game.last,12,11); + + order=20000; + new Game.Upgrade('Kitten marketeers','You gain more CpS the more milk you have.no such thing as a saturated markit, sir',900000000000000000000000000000000000000,Game.GetIcon('Kitten',11));Game.last.kitten=1;Game.MakeTiered(Game.last,11,18); + + order=10030; + Game.NewUpgradeCookie({name:'Festivity loops',desc:'These garish biscuits are a perfect fit for children\'s birthday parties or the funerals of strange, eccentric billionaires.',icon:[25,17],require:'Box of brand biscuits',power: 2, price: 999999999999999999999999*5}); + + order=10020; + Game.NewUpgradeCookie({name:'Persian rice cookies',desc:'Rose water and poppy seeds are the secret ingredients of these small, butter-free cookies.',icon:[28,15],power: 4,price: 99999999999999999999999999999999*5}); + Game.NewUpgradeCookie({name:'Norwegian cookies',desc:'A flat butter cookie with a sliver of candied cherry on top. It is said that these illustrate the bleakness of scandinavian existentialism.',icon:[22,20],power: 4,price: 999999999999999999999999999999999}); + Game.NewUpgradeCookie({name:'Crispy rice cookies',desc:'Fun to make at home! Store-bought cookies are obsolete! Topple the system! There\'s marshmallows in these! Destroy capitalism!',icon:[23,20],power: 4,price: 999999999999999999999999999999999*5}); + Game.NewUpgradeCookie({name:'Ube cookies',desc:'The tint is obtained by the use of purple yams. According to color symbolism, these cookies are either noble, holy, or supervillains.',icon:[24,17],power: 4,price: 9999999999999999999999999999999999}); + Game.NewUpgradeCookie({name:'Butterscotch cookies',desc:'The butterscotch chips are just the right amount of sticky, and make you feel like you\'re eating candy.',icon:[24,20],power: 4,price: 9999999999999999999999999999999999*5}); + Game.NewUpgradeCookie({name:'Speculaas',desc:'These crunchy, almost obnoxiously cinnamony cookies are a source of dutch pride. About the origin of the name, one can only speculate.',icon:[21,20],power: 4,price: 99999999999999999999999999999999999}); + + order=10200; + Game.NewUpgradeCookie({name:'Elderwort biscuits',desc:'-',icon:[22,25],power:2,price:60*2,locked:1});Game.last.baseDesc='Cookie production multiplier +2%.
Grandma production multiplier +2%.
Dropped by elderwort plants.They taste incredibly stale, even when baked fresh.'; + Game.NewUpgradeCookie({name:'Bakeberry cookies',desc:'-',icon:[23,25],power:2,price:60,locked:1});Game.last.baseDesc='Cookie production multiplier +2%.
Dropped by bakeberry plants.Really good dipped in hot chocolate.'; + Game.NewUpgradeCookie({name:'Duketater cookies',desc:'-',icon:[24,25],power:10,price:60*3,locked:1});Game.last.baseDesc='Cookie production multiplier +10%.
Dropped by duketater plants.Fragrant and mealy, with a slight yellow aftertaste.'; + Game.NewUpgradeCookie({name:'Green yeast digestives',desc:'-',icon:[25,25],power:0,price:60*3,locked:1});Game.last.baseDesc='+1% golden cookie gains and effect duration.
+1% golden cookie frequency.
+3% random drops.
Dropped by green rot plants.These are tastier than you\'d expect, but not by much.'; + + order=23000; + new Game.Upgrade('Fern tea','You gain +3% of your regular CpS while the game is closed (provided you have the Twin Gates of Transcendence heavenly upgrade).
Dropped by drowsyfern plants.A chemically complex natural beverage, this soothing concoction has been used by mathematicians to solve equations in their sleep.',60,[26,25]); + new Game.Upgrade('Ichor syrup','You gain +7% of your regular CpS while the game is closed (provided you have the Twin Gates of Transcendence heavenly upgrade).
Sugar lumps mature 7 minutes sooner.
Dropped by ichorpuff plants.Tastes like candy. The smell is another story.',60*2,[27,25]); + + order=10200; + Game.NewUpgradeCookie({name:'Wheat slims',desc:'-',icon:[28,25],power:1,price:30,locked:1});Game.last.baseDesc='Cookie production multiplier +1%.
Dropped by baker\'s wheat plants.The only reason you\'d consider these to be cookies is because you feel slightly sorry for them.'; + + var gardenDrops=['Elderwort biscuits','Bakeberry cookies','Duketater cookies','Green yeast digestives','Fern tea','Ichor syrup','Wheat slims']; + for (var i in gardenDrops)//scale by CpS + { + var it=Game.Upgrades[gardenDrops[i]]; + it.priceFunc=function(cost){return function(){return cost*Game.cookiesPs*60;}}(it.basePrice); + it.baseDesc=it.baseDesc.replace('','
Cost scales with CpS.'); + it.desc=BeautifyInText(it.baseDesc); + it.lasting=true; + } + + + order=10300; + Game.NewUpgradeCookie({name:'Synthetic chocolate green honey butter biscuit',desc:'Rewarded for owning 350 of everything.
The recipe for this butter biscuit was once the sole heritage of an ancient mountain monastery. Its flavor is so refined that only a slab of lab-made chocolate specifically engineered to be completely tasteless could complement it.
Also it\'s got your face on it.',icon:[24,26],power: 10,price: 999999999999999999999999999999999999,locked:1}); + Game.NewUpgradeCookie({name:'Royal raspberry chocolate butter biscuit',desc:'Rewarded for owning 400 of everything.
Once reserved for the megalomaniac elite, this unique strain of fruity chocolate has a flavor and texture unlike any other. Whether its exorbitant worth is improved or lessened by the presence of your likeness on it still remains to be seen.',icon:[25,26],power: 10,price: 999999999999999999999999999999999999999,locked:1}); + Game.NewUpgradeCookie({name:'Ultra-concentrated high-energy chocolate butter biscuit',desc:'Rewarded for owning 450 of everything.
Infused with the power of several hydrogen bombs through a process that left most nuclear engineers and shareholders perplexed. Currently at the center of some rather heated United Nations meetings. Going in more detail about this chocolate would violate several state secrets, but we\'ll just add that someone\'s bust seems to be pictured on it. Perhaps yours?',icon:[26,26],power: 10,price: 999999999999999999999999999999999999999999,locked:1}); + + + + order=200;new Game.TieredUpgrade('Timeproof hair dyes','Grandmas are twice as efficient.Why do they always have those strange wispy pink dos? What do they know about candy floss that we don\'t?','Grandma',10); + order=300;new Game.TieredUpgrade('Barnstars','Farms are twice as efficient.Ah, yes. These help quite a bit. Somehow.','Farm',10); + order=400;new Game.TieredUpgrade('Mine canaries','Mines are twice as efficient.These aren\'t used for anything freaky! The miners just enjoy having a pet or two down there.','Mine',10); + order=500;new Game.TieredUpgrade('Brownie point system','Factories are twice as efficient.Oh, these are lovely! You can now reward your factory employees for good behavior, such as working overtime or snitching on coworkers. 58 brownie points gets you a little picture of a brownie, and 178 of those pictures gets you an actual brownie piece for you to do with as you please! Infantilizing? Maybe. Oodles of fun? You betcha!','Factory',10); + order=525;new Game.TieredUpgrade('Grand supercycles','Banks are twice as efficient.We let the public think these are complicated financial terms when really we\'re just rewarding the bankers with snazzy bicycles for a job well done. It\'s only natural after you built those fancy gold swimming pools for them, where they can take a dip and catch Kondratiev waves.','Bank',10); + order=550;new Game.TieredUpgrade('Psalm-reading','Temples are twice as efficient.A theologically dubious and possibly blasphemous blend of fortune-telling and scripture studies.','Temple',10); + order=575;new Game.TieredUpgrade('Immobile spellcasting','Wizard towers are twice as efficient.Wizards who master this skill can now cast spells without having to hop and skip and gesticulate embarrassingly, which is much sneakier and honestly quite a relief.','Wizard tower',10); + order=600;new Game.TieredUpgrade('Restaurants at the end of the universe','Shipments are twice as efficient.Since the universe is spatially infinite, and therefore can be construed to have infinite ends, you\'ve opened an infinite chain of restaurants where your space truckers can rest and partake in some home-brand cookie-based meals.','Shipment',10); + order=700;new Game.TieredUpgrade('On second thought','Alchemy labs are twice as efficient.Disregard that last upgrade, alchemy is where it\'s at! Your eggheads just found a way to transmute children\'s nightmares into rare metals!','Alchemy lab',10); + order=800;new Game.TieredUpgrade('Dimensional garbage gulper','Portals are twice as efficient.So we\'ve been looking for a place to dispose of all the refuse that\'s been accumulating since we started baking - burnt cookies, failed experiments, unruly workers - and well, we figured rather than sell it to poor countries like we\'ve been doing, we could just dump it in some alternate trash dimension where it\'s not gonna bother anybody! Probably!','Portal',10); + order=900;new Game.TieredUpgrade('Additional clock hands','Time machines are twice as efficient.It seemed like a silly idea at first, but it turns out these have the strange ability to twist time in interesting new ways.','Time machine',10); + order=1000;new Game.TieredUpgrade('Baking Nobel prize','Antimatter condensers are twice as efficient.What better way to sponsor scientific growth than to motivate those smarmy nerds with a meaningless award! What\'s more, each prize comes with a fine print lifelong exclusive contract to come work for you (or else)!','Antimatter condenser',10); + order=1100;new Game.TieredUpgrade('Reverse theory of light','Prisms are twice as efficient.A whole new world of physics opens up when you decide that antiphotons are real and posit that light is merely a void in shadow.','Prism',10); + order=1200;new Game.TieredUpgrade('Revised probabilistics','Chancemakers are twice as efficient.Either something happens or it doesn\'t. That\'s a 50% chance! This suddenly makes a lot of unlikely things very possible.','Chancemaker',10); + + order=20000; + new Game.Upgrade('Kitten analysts','You gain more CpS the more milk you have.based on purrent return-on-investment meowdels we should be able to affurd to pay our empawyees somewhere around next century, sir',900000000000000000000000000000000000000000,Game.GetIcon('Kitten',12));Game.last.kitten=1;Game.MakeTiered(Game.last,12,18); + + + new Game.Upgrade('Eye of the wrinkler','Mouse over a wrinkler to see how many cookies are in its stomach.Just a wrinkler and its will to survive.
Hangin\' tough, stayin\' hungry.
',99999999,[27,26]);Game.last.pool='prestige';Game.last.parents=['Wrinkly cookies']; + + new Game.Upgrade('Inspired checklist','Unlocks the Buy all feature, which lets you instantly purchase every upgrade in your store (starting from the cheapest one).
Also unlocks the Vault, a store section where you can place upgrades you do not wish to auto-buy.Snazzy grandma accessories? Check. Transdimensional abominations? Check. A bunch of eggs for some reason? Check. Machine that goes "ping"? Check and check.',900000,[28,26]);Game.last.pool='prestige';Game.last.parents=['Persistent memory','Permanent upgrade slot IV']; + + order=10300; + Game.NewUpgradeCookie({name:'Pure pitch-black chocolate butter biscuit',desc:'Rewarded for owning 500 of everything.
This chocolate is so pure and so flawless that it has no color of its own, instead taking on the appearance of whatever is around it. You\'re a bit surprised to notice that this one isn\'t stamped with your effigy, as its surface is perfectly smooth (to the picometer) - until you realize it\'s quite literally reflecting your own face like a mirror.',icon:[24,27],power: 10,price: 999999999999999999999999999999999999999999999,locked:1}); + + order=10020; + Game.NewUpgradeCookie({name:'Chocolate oatmeal cookies',desc:'These bad boys compensate for lack of a cohesive form and a lumpy, unsightly appearance by being just simply delicious. Something we should all aspire to.',icon:[23,28],power: 4,price: 99999999999999999999999999999999999*5}); + Game.NewUpgradeCookie({name:'Molasses cookies',desc:'Sticky, crackly, and dusted in fine sugar.
Some lunatics have been known to eat these with potatoes.',icon:[24,28],power: 4,price: 999999999999999999999999999999999999}); + Game.NewUpgradeCookie({name:'Biscotti',desc:'Almonds and pistachios make these very robust cookies slightly more interesting to eat than to bludgeon people with.',icon:[22,28],power: 4,price: 999999999999999999999999999999999999*5}); + Game.NewUpgradeCookie({name:'Waffle cookies',desc:'Whether these are cookies with shockingly waffle-like features or simply regular cookie-sized waffles is a debate we\'re not getting into here.',icon:[21,28],power: 4,price: 9999999999999999999999999999999999999}); + + + order=10000; + //early cookies that unlock at the same time as coconut cookies; meant to boost early game a little bit + Game.NewUpgradeCookie({name:'Almond cookies',desc:'Sometimes you feel like one of these. Sometimes you don\'t.',icon:[21,27],power: 2, price: 99999999}); + Game.NewUpgradeCookie({name:'Hazelnut cookies',desc:'Tastes like a morning stroll through a fragrant forest, minus the clouds of gnats.',icon:[22,27],power: 2, price: 99999999}); + Game.NewUpgradeCookie({name:'Walnut cookies',desc:'Some experts have pointed to the walnut\'s eerie resemblance to the human brain as a sign of its sentience - a theory most walnuts vehemently object to.',icon:[23,27],power: 2, price: 99999999}); + + + new Game.Upgrade('Label printer','Mouse over an upgrade to see its tier.
Note : only some upgrades have tiers. Tiers are purely cosmetic and have no effect on gameplay.Also comes in real handy when you want to tell catsup apart from ketchup.',999999,[28,29]);Game.last.pool='prestige';Game.last.parents=['Starter kitchen']; + + + + + order=200;new Game.TieredUpgrade('Good manners','Grandmas are twice as efficient.Apparently these ladies are much more amiable if you take the time to learn their strange, ancient customs, which seem to involve saying "please" and "thank you" and staring at the sun with bulging eyes while muttering eldritch curses under your breath.','Grandma',11); + order=300;new Game.TieredUpgrade('Lindworms','Farms are twice as efficient.You have to import these from far up north, but they really help areate the soil!','Farm',11); + order=400;new Game.TieredUpgrade('Bore again','Mines are twice as efficient.After extracting so much sediment for so long, you\'ve formed some veritable mountains of your own from the accumulated piles of rock and dirt. Time to dig through those and see if you find anything fun!','Mine',11); + order=500;new Game.TieredUpgrade('"Volunteer" interns','Factories are twice as efficient.If you\'re bad at something, always do it for free.','Factory',11); + order=525;new Game.TieredUpgrade('Rules of acquisition','Banks are twice as efficient.Rule 387 : a cookie baked is a cookie kept.','Bank',11); + order=550;new Game.TieredUpgrade('War of the gods','Temples are twice as efficient.An interesting game; the only winning move is not to pray.','Temple',11); + order=575;new Game.TieredUpgrade('Electricity','Wizard towers are twice as efficient.Ancient magicks and forbidden hexes shroud this arcane knowledge, whose unfathomable power can mysteriously turn darkness into light and shock an elephant to death.','Wizard tower',11); + order=600;new Game.TieredUpgrade('Universal alphabet','Shipments are twice as efficient.You\'ve managed to chart a language that can be understood by any sentient species in the galaxy; its exciting vocabulary contains over 56 trillion words that sound and look like sparkly burps, forming intricate sentences that usually translate to something like "give us your cookies, or else".','Shipment',11); + order=700;new Game.TieredUpgrade('Public betterment','Alchemy labs are twice as efficient.Why do we keep trying to change useless matter into cookies, or cookies into even better cookies? Clearly, the way of the future is to change the people who eat the cookies into people with a greater understanding, appreciation and respect for the cookies they\'re eating. Into the vat you go!','Alchemy lab',11); + order=800;new Game.TieredUpgrade('Embedded microportals','Portals are twice as efficient.We\'ve found out that if we bake the portals into the cookies themselves, we can transport people\'s taste buds straight into the taste dimension! Good thing your army of lawyers got rid of the FDA a while ago!','Portal',11); + order=900;new Game.TieredUpgrade('Nostalgia','Time machines are twice as efficient.Your time machine technicians insist that this is some advanced new time travel tech, and not just an existing emotion universal to mankind. Either way, you have to admit that selling people the same old cookies just because it reminds them of the good old times is an interesting prospect.','Time machine',11); + order=1000;new Game.TieredUpgrade('The definite molecule','Antimatter condensers are twice as efficient.Your scientists have found a way to pack a cookie into one single continuous molecule, opening exciting new prospects in both storage and flavor despite the fact that these take up to a whole year to digest.','Antimatter condenser',11); + order=1100;new Game.TieredUpgrade('Light capture measures','Prisms are twice as efficient.As the universe gets ever so slightly dimmer due to you converting more and more of its light into cookies, you\'ve taken to finding new and unexplored sources of light for your prisms; for instance, the warm glow emitted by a pregnant woman, or the twinkle in the eye of a hopeful child.','Prism',11); + order=1200;new Game.TieredUpgrade('0-sided dice','Chancemakers are twice as efficient.The advent of the 0-sided dice has had unexpected and tumultuous effects on the gambling community, and saw experts around the world calling you both a genius and an imbecile.','Chancemaker',11); + + + new Game.Upgrade('Heralds','You now benefit from the boost provided by heralds.
Each herald gives you +1% CpS.
Look on the purple flag at the top to see how many heralds are active at any given time.Be excellent to each other.
And Patreon, dudes!
',100,[21,29]);Game.last.pool='prestige'; + + order=255; + Game.GrandmaSynergy('Metagrandmas','A fractal grandma to make more grandmas to make more cookies.','Fractal engine'); + + order=1300; + new Game.TieredUpgrade('Metabakeries','Fractal engines are twice as efficient.They practically bake themselves!','Fractal engine',1); + new Game.TieredUpgrade('Mandelbrown sugar','Fractal engines are twice as efficient.A substance that displays useful properties such as fractal sweetness and instant contact lethality.','Fractal engine',2); + new Game.TieredUpgrade('Fractoids','Fractal engines are twice as efficient.Here\'s a frun fract : all in all, these were a terrible idea.','Fractal engine',3); + new Game.TieredUpgrade('Nested universe theory','Fractal engines are twice as efficient.Asserts that each subatomic particle is host to a whole new universe, and therefore, another limitless quantity of cookies.
This somehow stacks with the theory of nanocosmics, because physics.
','Fractal engine',4); + new Game.TieredUpgrade('Menger sponge cake','Fractal engines are twice as efficient.Frighteningly absorbent thanks to its virtually infinite surface area. Keep it isolated in a dry chamber, never handle it with an open wound, and do not ever let it touch a body of water.','Fractal engine',5); + new Game.TieredUpgrade('One particularly good-humored cow','Fractal engines are twice as efficient.This unassuming bovine was excruciatingly expensive and it may seem at first like you were ripped off. On closer inspection however, you notice that its earrings (it\'s wearing earrings) are actually fully functional copies of itself, each of which also wearing their own cow earrings, and so on, infinitely. It appears your dairy concerns will be taken care of for a while, although you\'ll have to put up with the cow\'s annoying snickering.','Fractal engine',6); + new Game.TieredUpgrade('Chocolate ouroboros','Fractal engines are twice as efficient.Forever eating its own tail and digesting itself, in a metabolically dubious tale of delicious tragedy.','Fractal engine',7); + new Game.TieredUpgrade('Nested','Fractal engines are twice as efficient.Clever self-reference or shameful cross-promotion? This upgrade apparently has the gall to advertise a link to orteil.dashnet.org/nested, in a tooltip you can\'t even click.','Fractal engine',8); + new Game.TieredUpgrade('Space-filling fibers','Fractal engines are twice as efficient.This special ingredient has the incredible ability to fill the local space perfectly, effectively eradicating hunger in those who consume it!
Knowing that no hunger means no need for cookies, your marketers urge you to repurpose this product into next-level packing peanuts.
','Fractal engine',9); + new Game.TieredUpgrade('Endless book of prose','Fractal engines are twice as efficient.','Fractal engine',10); + Game.last.descFunc=function(){ + var str='"There once was a baker named '+Game.bakeryName+'. One day, there was a knock at the door; '+Game.bakeryName+' opened it and was suddenly face-to-face with a strange and menacing old grandma. The grandma opened her mouth and, in a strange little voice, started reciting this strange little tale : '; + var n=35; + var i=Math.floor(Game.T*0.1); + return this.desc+''+(str.substr(i%str.length,n)+(i%str.length>(str.length-n)?str.substr(0,i%str.length-(str.length-n)):''))+''; + }; + new Game.TieredUpgrade('The set of all sets','Fractal engines are twice as efficient.The answer, of course, is a definite maybe.','Fractal engine',11); + + order=5000; + Game.SynergyUpgrade('Recursive mirrors','Do you have any idea what happens when you point two of these at each other? Apparently, the universe doesn\'t either.','Fractal engine','Prism','synergy1'); + //Game.SynergyUpgrade('Compounded odds','When probabilities start cascading, "never in a billion lifetimes" starts looking terribly like "probably before Monday comes around".','Fractal engine','Chancemaker','synergy1'); + Game.SynergyUpgrade('Mice clicking mice','','Fractal engine','Cursor','synergy2'); + Game.last.descFunc=function(){ + Math.seedrandom(Game.seed+'-blasphemouse'); + if (Math.random()<0.3) {Math.seedrandom();return this.desc+'Absolutely blasphemouse!';} + else {Math.seedrandom();return this.desc+'Absolutely blasphemous!';} + }; + + + order=10020; + Game.NewUpgradeCookie({name:'Custard creams',desc:'British lore pits these in a merciless war against bourbon biscuits.
The filling evokes vanilla without quite approaching it.
They\'re tastier on the inside!',icon:[23,29],power: 4,price: 9999999999999999999999999999999999999*5}); + Game.NewUpgradeCookie({name:'Bourbon biscuits',desc:'Two chocolate biscuits joined together with even more chocolate.
The sworn rivals of custard creams, as legend has it.',icon:[24,29],power: 4,price: 99999999999999999999999999999999999999}); + + + new Game.Upgrade('Keepsakes','Seasonal random drops have a 1/5 chance to carry over through ascensions.Cherish the memories.',1111111111,[22,29]);Game.last.pool='prestige';Game.last.parents=['Starsnow','Starlove','Starterror','Startrade','Starspawn']; + + order=10020; + Game.NewUpgradeCookie({name:'Mini-cookies',desc:'Have you ever noticed how the smaller something is, the easier it is to binge on it?',icon:[29,30],power: 5,price: 99999999999999999999999999999999999999*5}); + + new Game.Upgrade('Sugar crystal cookies','Cookie production multiplier +5% permanently, and +1% for every building type level 10 or higher.Infused with cosmic sweetness. It gives off a faint shimmery sound when you hold it up to your ear.',1000000000,[21,30]);Game.last.pool='prestige';Game.last.parents=['Sugar baking'];Game.last.power=function(){ + var n=5; + for (var i in Game.Objects) + { + if (Game.Objects[i].level>=10) n++; + } + return n; + };Game.last.pseudoCookie=true; + Game.last.descFunc=function(){ + var n=5; + for (var i in Game.Objects) + { + if (Game.Objects[i].level>=10) n++; + } + return '
Current : +'+Beautify(n)+'%
'+this.desc; + }; + new Game.Upgrade('Box of maybe cookies','Contains an assortment of...something.These may or may not be considered cookies.',333000000000,[25,29]);Game.last.pool='prestige';Game.last.parents=['Sugar crystal cookies']; + new Game.Upgrade('Box of not cookies','Contains an assortment of...something.These are strictly, definitely not cookies.',333000000000,[26,29]);Game.last.pool='prestige';Game.last.parents=['Sugar crystal cookies']; + new Game.Upgrade('Box of pastries','Contains an assortment of delicious pastries.These are a damn slippery slope is what they are!',333000000000,[27,29]);Game.last.pool='prestige';Game.last.parents=['Sugar crystal cookies']; + + order=10040; + Game.NewUpgradeCookie({name:'Profiteroles',desc:'Also known as cream puffs, these pastries are light, fluffy, filled with whipped cream and fun to throw at people when snowballs are running scarce.',icon:[29,29],require:'Box of pastries', power:4,price: Math.pow(10,31)}); + Game.NewUpgradeCookie({name:'Jelly donut',desc:'Guaranteed to contain at least 0.3% jelly filling, or your money back.
You can still see the jelly stab wound!',icon:[27,28],require:'Box of pastries', power:4,price: Math.pow(10,33)}); + Game.NewUpgradeCookie({name:'Glazed donut',desc:'Absolutely gooey with sugar. The hole is the tastiest part!',icon:[28,28],require:'Box of pastries', power:4,price: Math.pow(10,35)}); + Game.NewUpgradeCookie({name:'Chocolate cake',desc:'The cake is a Portal reference!',icon:[25,27],require:'Box of pastries', power:4,price: Math.pow(10,37)}); + Game.NewUpgradeCookie({name:'Strawberry cake',desc:'It\'s not easy to come up with flavor text for something as generic as this, but some would say it\'s a piece of cake.',icon:[26,27],require:'Box of pastries', power:4,price: Math.pow(10,39)}); + Game.NewUpgradeCookie({name:'Apple pie',desc:'It is said that some grandmas go rogue and bake these instead.',icon:[25,28],require:'Box of pastries', power:4,price: Math.pow(10,41)}); + Game.NewUpgradeCookie({name:'Lemon meringue pie',desc:'Meringue is a finicky substance made of sugar and egg whites that requires specific atmospheric conditions to be baked at all. The lemon, as far as we can tell, isn\'t nearly as picky.',icon:[26,28],require:'Box of pastries', power:4,price: Math.pow(10,43)}); + Game.NewUpgradeCookie({name:'Butter croissant',desc:'Look around.
A rude man in a striped shirt bikes past you. He smells of cigarettes and café-au-lait. Somewhere, a mime uses his moustache to make fun of the British. 300 pigeons fly overhead.
Relax. You\'re experiencing croissant.',icon:[29,28],require:'Box of pastries', power:4,price: Math.pow(10,45)}); + + order=10050; + Game.NewUpgradeCookie({name:'Cookie dough',desc:'Bursting with infinite potential, but can also be eaten as is. Arguably worth the salmonella.',icon:[25,30],require:'Box of maybe cookies', power:4,price: Math.pow(10,35)}); + Game.NewUpgradeCookie({name:'Burnt cookie',desc:'This cookie flew too close to the sun and is now a shadow of its former self. If only you remembered to set a timer, you wouldn\'t have this tragedy on your hands...',icon:[23,30],require:'Box of maybe cookies', power:4,price: Math.pow(10,37)}); + Game.NewUpgradeCookie({name:'A chocolate chip cookie but with the chips picked off for some reason',desc:'This has to be the saddest thing you\'ve ever seen.',icon:[24,30],require:'Box of maybe cookies', power:3,price: Math.pow(10,39)}); + Game.NewUpgradeCookie({name:'Flavor text cookie',desc:'What you\'re currently reading is what gives this cookie its inimitable flavor.',icon:[22,30],require:'Box of maybe cookies', power:4,price: Math.pow(10,41)}); + Game.NewUpgradeCookie({name:'High-definition cookie',desc:'Uncomfortably detailed, like those weird stories your aunt keeps telling at parties.',icon:[28,10],require:'Box of maybe cookies', power:5,price: Math.pow(10,43)}); + + order=10060; + Game.NewUpgradeCookie({name:'Toast',desc:'A crisp slice of bread, begging for some butter and jam.
Why do people keep proposing these at parties?',icon:[27,10],require:'Box of not cookies', power:4,price: Math.pow(10,34)}); + Game.NewUpgradeCookie({name:'Peanut butter & jelly',desc:'It\'s time.',icon:[29,9],require:'Box of not cookies', power:4,price: Math.pow(10,36)}); + Game.NewUpgradeCookie({name:'Wookies',desc:'These aren\'t the cookies you\'re looking for.',icon:[26,30],require:'Box of not cookies', power:4,price: Math.pow(10,38)}); + Game.NewUpgradeCookie({name:'Cheeseburger',desc:'Absolutely no relation to cookies whatsoever - Orteil just wanted an excuse to draw a cheeseburger.',icon:[28,30],require:'Box of not cookies', power:4,price: Math.pow(10,40)}); + Game.NewUpgradeCookie({name:'One lone chocolate chip',desc:'The start of something beautiful.',icon:[27,30],require:'Box of not cookies', power:1,price: Math.pow(10,42)}); + + + new Game.Upgrade('Genius accounting','Unlocks extra price information.
Each displayed cost now specifies how long it\'ll take you to afford it, and how much of your bank it represents.There\'s no accounting for taste, and yet here we are.',2000000,[11,10]);Game.last.pool='prestige';Game.last.parents=['Inspired checklist']; + + + new Game.Upgrade('Shimmering veil','Unlocks the shimmering veil, a switch that passively boosts your CpS by 50%.
You start with the veil turned on; however, it is very fragile, and clicking the big cookie or any golden cookie or reindeer will turn it off, requiring 24 hours of CpS to turn back on.Hands off!',999999999,[9,10]);Game.last.pool='prestige';Game.last.parents=['Distilled essence of redoubled luck']; + + order=40005; + var func=function(){ + var boost=50; + var resist=0; + if (Game.Has('Reinforced membrane')) {boost+=10;resist+=10;} + return (this.name=='Shimmering veil [on]'?'
Active.
':'')+'Boosts your cookie production by '+Beautify(boost)+'% when active.
The veil is very fragile and will break if you click the big cookie or any golden cookies or reindeer.

Once broken, turning the veil back on costs 24 hours of unbuffed CpS.'+(resist>0?('

Has a '+Beautify(resist)+'% chance to not break.'):''); + }; + new Game.Upgrade('Shimmering veil [off]','',1000000,[9,10]); + Game.last.pool='toggle';Game.last.toggleInto='Shimmering veil [on]'; + Game.last.priceFunc=function(){return Game.unbuffedCps*60*60*24;} + Game.last.descFunc=func; + new Game.Upgrade('Shimmering veil [on]','',0,[9,10]); + Game.last.pool='toggle';Game.last.toggleInto='Shimmering veil [off]'; + Game.last.descFunc=func; + + Game.loseShimmeringVeil=function(context) + { + if (!Game.Has('Shimmering veil')) return false; + if (!Game.Has('Shimmering veil [off]') && Game.Has('Shimmering veil [on]')) return false; + if (Game.Has('Reinforced membrane')) + { + if (context=='shimmer') Math.seedrandom(Game.seed+'/'+Game.goldenClicks); + else if (context=='click') Math.seedrandom(Game.seed+'/'+Game.cookieClicks); + if (Math.random()<0.1) + { + Game.Notify('The reinforced membrane protects the shimmering veil.','',[7,10]); + Game.Win('Thick-skinned'); + return false; + } + Math.seedrandom(); + } + var me=Game.Upgrades['Shimmering veil [on]']; + me.bought=1; + //Game.Upgrades[me.toggleInto].bought=false; + Game.Lock(me.toggleInto); + Game.Unlock(me.toggleInto); + Game.Notify('The shimmering veil disappears...','',[9,10]); + Game.upgradesToRebuild=1; + Game.recalculateGains=1; + PlaySound('snd/spellFail.mp3',0.75); + } + - order=10030; - Game.NewUpgradeCookie({name:'Lombardia cookies',desc:'These come from those farms with the really good memory.',icon:[23,13],require:'Box of brand biscuits',power: 3, price: 999999999999999999999*5}); - Game.NewUpgradeCookie({name:'Bastenaken cookies',desc:'French cookies made of delicious cinnamon and candy sugar. These do not contain Nuts!',icon:[24,13],require:'Box of brand biscuits',power: 3, price: 999999999999999999999*5}); + var getCookiePrice=function(level){return 999999999999999999999999999999999999999*Math.pow(10,(level-1)/2);}; order=10020; - Game.NewUpgradeCookie({name:'Pecan sandies',desc:'Stick a nut on a cookie and call it a day! Name your band after it! Whatever!',icon:[25,13],power: 4,price: 999999999999999999999999*5}); - Game.NewUpgradeCookie({name:'Moravian spice cookies',desc:'Popular for being the world\'s moravianest cookies.',icon:[26,13],power: 4,price: 9999999999999999999999999}); - Game.NewUpgradeCookie({name:'Anzac biscuits',desc:'Army biscuits from a bakery down under, containing no eggs but yes oats.',icon:[27,13],power: 4,price: 9999999999999999999999999*5}); - Game.NewUpgradeCookie({name:'Buttercakes',desc:'Glistening with cholesterol, these cookies moistly straddle the line between the legal definition of a cookie and just a straight-up stick of butter.',icon:[29,13],power: 4,price: 99999999999999999999999999}); - Game.NewUpgradeCookie({name:'Ice cream sandwiches',desc:'In an alternate universe, "ice cream sandwich" designates an ice cream cone filled with bacon, lettuce, and tomatoes. Maybe some sprinkles too.',icon:[28,13],power: 4,price: 99999999999999999999999999*5}); + Game.NewUpgradeCookie({name:'Whoopie pies',desc:'Two chocolate halves joined together by a cream filling. It\'s got no eyebrows, but you never noticed until now.',icon:[21,31],power: 5,price: getCookiePrice(1)}); + Game.NewUpgradeCookie({name:'Caramel wafer biscuits',desc:'Coated in delicious chocolate. As many layers as you\'ll get in a biscuit without involving onions.',icon:[22,31],power: 5,price: getCookiePrice(2)}); + Game.NewUpgradeCookie({name:'Chocolate chip mocha cookies',desc:'Mocha started out as an excuse to smuggle chocolate into coffee. And now, in a poignant display of diplomacy and cultural exchange, it\'s bringing coffee to chocolate cookies.',icon:[23,31],power: 5,price: getCookiePrice(3)}); + Game.NewUpgradeCookie({name:'Earl Grey cookies',desc:'Captain Picard\'s favorite.',icon:[24,31],power: 5,price: getCookiePrice(4)}); + Game.NewUpgradeCookie({name:'Corn syrup cookies',desc:'The corn syrup makes it extra chewy. Not the type of stuff you\'d think to put in a cookie, but bakers make do.',icon:[25,31],power: 5,price: getCookiePrice(5)}); + Game.NewUpgradeCookie({name:'Icebox cookies',desc:'Can be prepared in a variety of shapes with a variety of ingredients. Made by freezing dough before baking it, mirroring a time-proven medieval torture practice. Gotta keep them guessing.',icon:[26,31],power: 5,price: getCookiePrice(6)}); + Game.NewUpgradeCookie({name:'Graham crackers',desc:'Inspired in their design by the wish to live a life of austere temperance, free from pleasure or cheer; it\'s no wonder these are so tasty.',icon:[27,31],power: 5,price: getCookiePrice(7)}); + Game.NewUpgradeCookie({name:'Hardtack',desc:'Extremely hard and, if we\'re being honest, extremely tack.
If you\'re considering eating this as a fun snack, you probably have other things to worry about than this game, like getting scurvy or your crew fomenting mutiny.',icon:[28,31],power: 5,price: getCookiePrice(8)}); + Game.NewUpgradeCookie({name:'Cornflake cookies',desc:'They\'re grrrrrroovy! Careful not to let it sit in your milk too long, lest you accidentally end up with a bowl of cereal and get confused.',icon:[29,31],power: 5,price: getCookiePrice(9)}); + Game.NewUpgradeCookie({name:'Tofu cookies',desc:'There\'s really two ways to go with tofu cooking; either it asserts itself in plain sight or it camouflages itself in the other ingredients. This happens to be the latter, and as such, you can\'t really tell the difference between this and a regular cookie, save for that one pixel on the left.',icon:[30,31],power: 5,price: getCookiePrice(10)}); + Game.NewUpgradeCookie({name:'Gluten-free cookies',desc:'Made with browned butter and milk to closely match the archetypal chocolate chip cookie.
For celiacs, a chance to indulge in a delicious risk-free pastry. For others, a strangely threatening confection whose empty eyes will never know heaven nor hell.',icon:[30,30],power: 5,price: getCookiePrice(10)}); + Game.NewUpgradeCookie({name:'Russian bread cookies',desc:'Also known as alphabet cookies; while most bakers follow the recipe to the letter, it is said that some substitute the flour for spelt. But don\'t take my word for it.',icon:[30,29],power: 5,price: getCookiePrice(11)}); + Game.NewUpgradeCookie({name:'Lebkuchen',desc:'Diverse cookies from Germany, fragrant with honey and spices, often baked around Christmas.
Once worn by warriors of old for protection in battle.
+5 STR, +20% magic resistance.',icon:[30,28],power: 5,price: getCookiePrice(12)}); + Game.NewUpgradeCookie({name:'Aachener Printen',desc:'The honey once used to sweeten these gingerbread-like treats has since been swapped out for beet sugar, providing another sad example of regressive evolution.',icon:[30,27],power: 5,price: getCookiePrice(13)}); + Game.NewUpgradeCookie({name:'Canistrelli',desc:'A dry biscuit flavored with anise and wine, tough like the people of Corsica where it comes from.',icon:[30,26],power: 5,price: getCookiePrice(14)}); + Game.NewUpgradeCookie({name:'Nice biscuits',desc:'Made with coconut and perfect with tea. Traces its origins to a French city so nice they named it that.',icon:[30,25],power: 5,price: getCookiePrice(15)}); + Game.NewUpgradeCookie({name:'French pure butter cookies',desc:'You can\'t tell what\'s stronger coming off these - the smell of butter or condescension.',icon:[31,25],power: 5,price: getCookiePrice(16)}); + Game.NewUpgradeCookie({name:'Petit beurre',desc:'An unassuming biscuit whose name simply means "little butter". Famed and feared for its four ears and forty-eight teeth.
When it hears ya, it\'ll get ya...',icon:[31,26],power: 5,price: getCookiePrice(16)}); + Game.NewUpgradeCookie({name:'Nanaimo bars',desc:'A delicious no-bake pastry hailing from Canada. Probably beats eating straight-up snow with maple syrup poured on it, but what do I know.',icon:[31,27],power: 5,price: getCookiePrice(17)}); + Game.NewUpgradeCookie({name:'Berger cookies',desc:'Messily slathered with chocolate fudge, but one of the most popular bergers of Baltimore, along with the triple fried egg berger and the blue crab cheeseberger.',icon:[31,28],power: 5,price: getCookiePrice(18)}); + Game.NewUpgradeCookie({name:'Chinsuko',desc:'A little piece of Okinawa in cookie form. Part of a Japanese custom of selling sweets as souvenirs. But hey, pressed pennies are cool too.',icon:[31,29],power: 5,price: getCookiePrice(19)}); + Game.NewUpgradeCookie({name:'Panda koala biscuits',desc:'Assorted jungle animals with equally assorted fillings.
Comes in chocolate, strawberry, vanilla and green tea.
Eat them all before they go extinct!',icon:[31,13],power: 5,price: getCookiePrice(19)}); + Game.NewUpgradeCookie({name:'Putri salju',desc:'A beloved Indonesian pastry; its name means "snow princess", for the powdered sugar it\'s coated with. Had we added these to Cookie Clicker some years ago, this is where we\'d make a reference to that one Disney movie, but it\'s probably time to let it go.',icon:[31,30],power: 5,price: getCookiePrice(20)}); + Game.NewUpgradeCookie({name:'Milk cookies',desc:'Best eaten with a tall glass of chocolate.',icon:[31,31],power: 5,price: getCookiePrice(21)}); + + order=9999; + Game.NewUpgradeCookie({name:'Cookie crumbs',desc:'There used to be a cookie here. Now there isn\'t.
Good heavens, what did you DO?!',icon:[30,13],power:1,require:'Legacy',price:100}); + Game.NewUpgradeCookie({name:'Chocolate chip cookie',desc:'This is the cookie you\'ve been clicking this whole time. It looks a bit dented and nibbled on, but it\'s otherwise good as new.',icon:[10,0],power:10,require:'Legacy',price:1000000000000}); + + + new Game.Upgrade('Cosmic beginner\'s luck','Prior to purchasing the Heavenly chip secret upgrade in a run, random drops are 5 times more common.Oh! A penny!
Oh! A priceless heirloom!
Oh! Another penny!
',999999999*15,[8,10]);Game.last.pool='prestige';Game.last.parents=['Shimmering veil']; + new Game.Upgrade('Reinforced membrane','The shimmering veil is more resistant, and has a 10% chance not to break. It also gives +10% more CpS.A consistency between jellyfish and cling wrap.',999999999*15,[7,10]);Game.last.pool='prestige';Game.last.parents=['Shimmering veil']; - new Game.Upgrade('Stevia Caelestis','Sugar lumps ripen an hour sooner.A plant of supernatural sweetness grown by angels in heavenly gardens.',100000000,[25,15]);Game.last.pool='prestige';Game.last.parents=['Wrinkly cookies']; - new Game.Upgrade('Diabetica Daemonicus','Sugar lumps mature an hour sooner.A malevolent, if delicious herb that is said to grow on the cliffs of the darkest abyss of the underworld.',300000000,[26,15]);Game.last.pool='prestige';Game.last.parents=['Stevia Caelestis','Lucifer']; - new Game.Upgrade('Sucralosia Inutilis','Bifurcated sugar lumps appear 5% more often and are 5% more likely to drop 2 lumps.A rare berry of uninteresting flavor that is as elusive as its uses are limited; only sought-after by the most avid collectors with too much wealth on their hands.',1000000000,[27,15]);Game.last.pool='prestige';Game.last.parents=['Diabetica Daemonicus']; - //note : these showIf functions stop working beyond 10 quadrillion prestige level, due to loss in precision; the solution, of course, is to make sure 10 quadrillion is not an attainable prestige level - new Game.Upgrade('Lucky digit','+1% prestige level effect on CpS.
+1% golden cookie effect duration.
+1% golden cookie lifespan.This upgrade is a bit shy and only appears when your prestige level ends in 7.',777,[24,15]);Game.last.pool='prestige';Game.last.parents=['Heavenly luck'];Game.last.showIf=function(){return (Math.ceil(Game.prestige)%10==7);}; - new Game.Upgrade('Lucky number','+1% prestige level effect on CpS.
+1% golden cookie effect duration.
+1% golden cookie lifespan.This upgrade is a reclusive hermit and only appears when your prestige level ends in 777.',77777,[24,15]);Game.last.pool='prestige';Game.last.parents=['Lucky digit','Lasting fortune'];Game.last.showIf=function(){return (Math.ceil(Game.prestige)%1000==777);}; - new Game.Upgrade('Lucky payout','+1% prestige level effect on CpS.
+1% golden cookie effect duration.
+1% golden cookie lifespan.This upgrade took an oath of complete seclusion from the rest of the world and only appears when your prestige level ends in 777777.',77777777,[24,15]);Game.last.pool='prestige';Game.last.parents=['Lucky number','Decisive fate'];Game.last.showIf=function(){return (Math.ceil(Game.prestige)%1000000==777777);}; + order=255; + Game.GrandmaSynergy('Binary grandmas','A digital grandma to transfer more cookies.
(See also : boolean grandmas, string grandmas, and not-a-number grandmas, also known as "NaNs".)','Javascript console'); - order=50000; - new Game.Upgrade('Background selector','Lets you pick which wallpaper to display.',0,[29,5]); - Game.last.pool='toggle'; - Game.last.choicesFunction=function() - { - var choices=[]; - choices[0]={name:'Automatic',icon:[0,7]}; - choices[1]={name:'Blue',icon:[21,21]}; - choices[2]={name:'Red',icon:[22,21]}; - choices[3]={name:'White',icon:[23,21]}; - choices[4]={name:'Black',icon:[24,21]}; - choices[5]={name:'Gold',icon:[25,21]}; - choices[6]={name:'Grandmas',icon:[26,21]}; - choices[7]={name:'Displeased grandmas',icon:[27,21]}; - choices[8]={name:'Angered grandmas',icon:[28,21]}; - choices[9]={name:'Money',icon:[29,21]}; - choices[Game.bgType].selected=1; - return choices; - } - Game.last.choicesPick=function(id) - {Game.bgType=id;} + order=1400; + new Game.TieredUpgrade('The JavaScript console for dummies','Javascript consoles are twice as efficient.This should get you started. The first line reads: "To open the javascript console, press-"
...the rest of the book is soaked in chocolate milk. If only there was a way to look up this sort of information...
','Javascript console',1); + new Game.TieredUpgrade('64bit arrays','Javascript consoles are twice as efficient.A long-form variable type to pack your cookies much more efficiently.','Javascript console',2); + new Game.TieredUpgrade('Stack overflow','Javascript consoles are twice as efficient.This is really bad! You probably forgot to close a loop somewhere and now your programs are going crazy! The rest of your engineers seem really excited about it somehow. How could a software mishap like a stack overflow possibly ever help anyone?','Javascript console',3); + new Game.TieredUpgrade('Enterprise compiler','Javascript consoles are twice as efficient.This bespoke javascript compiler took your team years of development and billions in research, but it should let you execute (certain) functions (up to) 2% faster (in optimal circumstances).','Javascript console',4); + new Game.TieredUpgrade('Syntactic sugar','Javascript consoles are twice as efficient.Tastier code for tastier cookies.','Javascript console',5); + new Game.TieredUpgrade('A nice cup of coffee','Javascript consoles are twice as efficient.All this nerd stuff has you exhausted. You make yourself a nice cup of coffee, brewed with roasted beans from some far-away island. You may have been working a bit too hard though - the cup of coffee starts talking to you, insisting that it is NOT javascript.','Javascript console',6); + new Game.TieredUpgrade('Just-in-time baking','Javascript consoles are twice as efficient.A new method of preparing cookies; they bake themselves right in front of the customers before eating, leaving your kitchens mess-free.','Javascript console',7); + new Game.TieredUpgrade('cookies++','Javascript consoles are twice as efficient.Your very own cookie-themed programming language, elegantly named after its most interesting ability - increasing the "cookies" variable by 1.','Javascript console',8); + new Game.TieredUpgrade('Software updates','Javascript consoles are twice as efficient.This is grand news - someone\'s finally figured out the Wifi password, and your newfound internet connection seems to have triggered a whole lot of software updates! Your browsers, drivers and plugins all received a fresh coat of paint, and your javascript version has been updated to the latest ECMAScript specification. It\'s really too bad thousands had to die due to some deprecated function in your neurotoxin ventilation code, but I guess that\'s progress for you.','Javascript console',9); + new Game.TieredUpgrade('Game.Loop','Javascript consoles are twice as efficient.You\'re not quite sure what to make of this. What does it mean? What does it do? Who would leave something like that just laying around here? Try asking again in 1/30th of a second.','Javascript console',10); + new Game.TieredUpgrade('eval()','Javascript consoles are twice as efficient.It is said that this simple function holds the key to the universe, and that whosoever masters it may shape reality to their will.
Good thing you have no idea how it works. Makes for a neat plaque on your wall, though.
','Javascript console',11); - Game.BGsByChoice={ - 0:{pic:'bgBlue'}, - 1:{pic:'bgBlue'}, - 2:{pic:'bgRed'}, - 3:{pic:'bgWhite'}, - 4:{pic:'bgBlack'}, - 5:{pic:'bgGold'}, - 6:{pic:'grandmas1'}, - 7:{pic:'grandmas2'}, - 8:{pic:'grandmas3'}, - 9:{pic:'bgMoney'}, + order=5000; + Game.SynergyUpgrade('Script grannies','Armies of energy drink-fueled grandmas ready to hack into the cyberspace for renegade e-cookies.','Javascript console','Grandma','synergy1'); + Game.SynergyUpgrade('Tombola computing','','Javascript console','Chancemaker','synergy2'); + Game.last.descFunc=function(){ + Math.seedrandom(Game.seed+'-tombolacomputing'); + var str='(Your ticket reads '+Math.floor(Math.random()*100)+' '+Math.floor(Math.random()*100)+' '+Math.floor(Math.random()*100)+' '+Math.floor(Math.random()*100)+', entitling you to '+choose([Math.floor(Math.random()*5+2)+' lines of javascript','one free use of Math.random()','one qubit, whatever that is','one half-eaten cookie','a brand new vacuum cleaner','most of one room-temperature cup of orange soda','one really good sandwich','one handful of pocket lint','someone\'s mostly clean hairpiece','a trip to a fancy restaurant','the knowledge of those numbers','a furtive glance at the news ticker','another ticket, half-price','all-you-can-eat moldy bread','one lifetime supply of oxygen','the color '+choose['red','orange','yellow','green','blue','purple','black','white','gray','brown','pink','teal'],'increased intellect for a limited time','an ancient runesword','the throne of a far-away country','the position of Mafia capo. Good luck','one free time-travel week-end','something beautiful','the deed to some oil well','one hamburger made out of the animal, plant, or person of your choice','the last surviving '+choose['dodo bird','thylacine','unicorn','dinosaur','neanderthal'],'a deep feeling of accomplishment','a fleeting tinge of entertainment','a vague sense of unease','deep existential dread','one extra week added to your lifespan','breathe manually','blink right here and now','one meeting with any famous person, living or dead, in your next dream','one very nice dream','a wacky sound effect','45 seconds of moral flexibility','hundreds and thousands, also known as "sprinkles"','one circle, triangle, square or other simple geometric shape, of average dimensions','just this extra bit of randomness','the extra push you needed to turn your life around','a good fright','one secret superpower','a better luck next time','an irrational phobia of tombola tickets','one whole spider','an increased sense of self-worth and determination','inner peace','one double-XP week-end in the MMORPG of your choice','a little piece of the universe, represented by the trillions of atoms that make up this very ticket','food poisoning','the Moon! Well, conceptually','a new car, baby','a new catchphrase','an intrusive thought of your choice','- ...aw man, it just cuts off there','the director spot for the next big hit movie','really good-looking calves','one genuine pirate golden doubloon','"treasure and riches", or something','one boat, sunken','baby shoes, never worn','direct lineage to some King or Queen','innate knowledge of a dead language you\'ll never encounter','the melody of a song you don\'t know the words to','white noise','mild physical impairment','a new pair of lips','things, and such','one popular expression bearing your name','one typo','one get-out-of-jail-free card','the rest of your life... for now','one polite huff','a condescending stare','one cursed monkey paw','true love, probably','an interesting factoid about the animal, country, TV show or celebrity of your choice','a pop culture reference','minutes of fun','the etymology of the word "tombola" - it\'s Italian for "a tumble"','nothing. You lost, sorry'])+'.)'; + Math.seedrandom(); + return this.desc+'Like quantum computing, but more fun.
'+str+'
'; }; - order=255; - new Game.Upgrade('Lucky grandmas',Game.getGrandmaSynergyUpgradeDesc('Chancemaker')+'A fortunate grandma that always seems to find more cookies.',Game.Objects['Chancemaker'].basePrice*Game.Tiers[2].price,[10,9],function(){Game.Objects['Grandma'].redraw();}); + order=10020; + Game.NewUpgradeCookie({name:'Kruidnoten',desc:'A festive dutch favorite; tiny cinnamony bites sometimes coated in chocolate. The name translates roughly to "kruidnoten".',icon:[30,3],power: 5,price: getCookiePrice(22)}); + Game.NewUpgradeCookie({name:'Marie biscuits',desc:'Pleasantly round, smoothly buttery, subtly vanilla-flavored, ornately embossed, each ridge represents a person Marie killed in prison.',icon:[30,4],power: 5,price: getCookiePrice(23)}); + Game.NewUpgradeCookie({name:'Meringue cookies',desc:'Probably the most exciting thing you can make out of egg whites. Also called forgotten cookies, due to the recipe being once lost in a sealed mystical vault for 10,000 years.',icon:[31,4],power: 5,price: getCookiePrice(24)}); - order=1200; - new Game.TieredUpgrade('Your lucky cookie','Chancemakers are twice as efficient.This is the first cookie you\'ve ever baked. It holds a deep sentimental value and, after all this time, an interesting smell.','Chancemaker',1); - new Game.TieredUpgrade('"All Bets Are Off" magic coin','Chancemakers are twice as efficient.A coin that always lands on the other side when flipped. Not heads, not tails, not the edge. The other side.','Chancemaker',2); - new Game.TieredUpgrade('Winning lottery ticket','Chancemakers are twice as efficient.What lottery? THE lottery, that\'s what lottery! Only lottery that matters!','Chancemaker',3); - new Game.TieredUpgrade('Four-leaf clover field','Chancemakers are twice as efficient.No giant monsters here, just a whole lot of lucky grass.','Chancemaker',4); - new Game.TieredUpgrade('A recipe book about books','Chancemakers are twice as efficient.Tip the scales in your favor with 28 creative new ways to cook the books.','Chancemaker',5); - new Game.TieredUpgrade('Leprechaun village','Chancemakers are twice as efficient.You\'ve finally become accepted among the local leprechauns, who lend you their mythical luck as a sign of friendship (as well as some rather foul-tasting tea).','Chancemaker',6); - new Game.TieredUpgrade('Improbability drive','Chancemakers are twice as efficient.A strange engine that turns statistics on their head. Recommended by the Grandmother\'s Guide to the Bakery.','Chancemaker',7); - new Game.TieredUpgrade('Antisuperstistronics','Chancemakers are twice as efficient.An exciting new field of research that makes unlucky things lucky. No mirror unbroken, no ladder unwalked under!','Chancemaker',8); + order=10060; + Game.NewUpgradeCookie({name:'Pizza',desc:'What is a pizza if not a large, chewy cookie, frosted with a rather exuberant tomato & cheese icing? Not a cookie, that\'s what.',icon:[31,9],require:'Box of not cookies', power:5,price: Math.pow(10,44)}); - order=5000; - new Game.SynergyUpgrade('Gemmed talismans','Good-luck charms covered in ancient and excruciatingly rare crystals. A must have for job interviews!','Chancemaker','Mine','synergy1'); + order=10050; + Game.NewUpgradeCookie({name:'Crackers',desc:'These are the non-flavored kind with no salt added. Really just a judgement-free wheat square begging to have bits of ham and spreadable cheese piled onto it, its main contribution being "crunchy".',icon:[30,9],require:'Box of maybe cookies', power:4,price: Math.pow(10,45)}); - order=20000; - new Game.Upgrade('Kitten consultants','You gain more CpS the more milk you have.glad to be overpaid to work with you, sir',900000000000000000000000000000000,Game.GetIcon('Kitten',9));Game.last.kitten=1; + order=10030; + Game.NewUpgradeCookie({name:'Havabreaks',desc:'You can snap the sections neatly or just bite into the whole thing like some kind of lunatic. Some oversea countries manufacture these in hundreds of unique flavors, such as green tea, lobster bisque, and dark chocolate.',icon:[31,3],require:'Box of brand biscuits',power: 2, price: 999999999999999999999999999*5}); - order=99999; - var years=Math.floor((Date.now()-new Date(2013,7,8))/(1000*60*60*24*365)); - //only updates on page load - //may behave strangely on leap years - Game.NewUpgradeCookie({name:'Birthday cookie',desc:'-',icon:[22,13],power:years,price:99999999999999999999999999999});Game.last.baseDesc='Cookie production multiplier +1% for every year Cookie Clicker has existed (currently : +'+Beautify(years)+'%).Thank you for playing Cookie Clicker!
-Orteil
';Game.last.desc=BeautifyInText(Game.last.baseDesc); + order=20000; + new Game.Upgrade('Kitten executives','You gain more CpS the more milk you have.ready to execute whatever and whoever you\'d like, sir',900000000000000000000000000000000000000000000,Game.GetIcon('Kitten',13));Game.last.kitten=1;Game.MakeTiered(Game.last,13,18); - order=150;new Game.Upgrade('Armythril mouse','Clicking gains +1% of your CpS.This one takes about 53 people to push it around and another 48 to jump down on the button and trigger a click. You could say it\'s got some heft to it.',50000000000000000000000,[11,19]); + order=10020; + Game.NewUpgradeCookie({name:'Chai tea cookies',desc:'Not exactly Captain Picard\'s favorite, but I mean, these will do in a pinch.',icon:[23,32],power: 5,price: getCookiePrice(4)+5});Game.last.order=10020.5685; - order=200;new Game.TieredUpgrade('Reverse dementia','Grandmas are twice as efficient.Extremely unsettling, and somehow even worse than the regular kind.','Grandma',9); - order=300;new Game.TieredUpgrade('Humane pesticides','Farms are twice as efficient.Made by people, for people, from people and ready to unleash some righteous scorching pain on those pesky insects that so deserve it.','Farm',9); - order=400;new Game.TieredUpgrade('Mole people','Mines are twice as efficient.Engineered from real human beings within your very labs, these sturdy little folks have a knack for finding the tastiest underground minerals in conditions that more expensive machinery probably wouldn\'t survive.','Mine',9); - order=500;new Game.TieredUpgrade('Machine learning','Factories are twice as efficient.You figured you might get better productivity if you actually told your workers to learn how to work the machines. Sometimes, it\'s the little things...','Factory',9); - order=525;new Game.TieredUpgrade('Edible money','Banks are twice as efficient.It\'s really quite simple; you make all currency too delicious not to eat, solving world hunger and inflation in one fell swoop!','Bank',9); - order=550;new Game.TieredUpgrade('Sick rap prayers','Temples are twice as efficient.With their ill beat and radical rhymes, these way-hip religious tunes are sure to get all the youngins who thought they were 2 cool 4 church back on the pews and praying for more! Wicked!','Temple',9); - order=575;new Game.TieredUpgrade('Deluxe tailored wands','Wizard towers are twice as efficient.In this age of science, most skillful wand-makers are now long gone; but thankfully - not all those wanders are lost.','Wizard tower',9); - order=600;new Game.TieredUpgrade('Autopilot','Shipments are twice as efficient.Your ships are now fitted with completely robotic crews! It\'s crazy how much money you save when you don\'t have to compensate the families of those lost in space.','Shipment',9); - order=700;new Game.TieredUpgrade('The advent of chemistry','Alchemy labs are twice as efficient.You know what? That whole alchemy nonsense was a load of baseless rubbish. Dear god, what were you thinking?','Alchemy lab',9); - order=800;new Game.TieredUpgrade('The real world','Portals are twice as efficient.It turns out that our universe is actually the twisted dimension of another, saner plane of reality. Time to hop on over there and loot the place!','Portal',9); - order=900;new Game.TieredUpgrade('Second seconds','Time machines are twice as efficient.That\'s twice as many seconds in the same amount of time! What a deal! Also, what in god\'s name!','Time machine',9); - order=1000;new Game.TieredUpgrade('Quantum comb','Antimatter condensers are twice as efficient.Quantum entanglement is one of those things that are so annoying to explain that we might honestly be better off without it. This is finally possible thanks to the quantum comb!','Antimatter condenser',9); - order=1100;new Game.TieredUpgrade('Crystal mirrors','Prisms are twice as efficient.Designed to filter more light back into your prisms, reaching levels of brightness that reality itself had never planned for.','Prism',9); - order=1200;new Game.TieredUpgrade('Bunnypedes','Chancemakers are twice as efficient.You\'ve taken to breeding rabbits with hundreds of paws, which makes them intrinsically very lucky and thus a very handy (if very disturbing) pet.','Chancemaker',9); + Game.NewUpgradeCookie({name:'Yogurt cookies',desc:'Augmented by the wonders of dairy, these cookies are light and fluffy and just one more thing for the lactose-intolerant to avoid.
Truly for the cultured among us.',icon:[24,32],power: 5,price: getCookiePrice(25)}); + Game.NewUpgradeCookie({name:'Thumbprint cookies',desc:'Filled with jam and sometimes served in little paper cups. No longer admissible as biometric evidence in court. We\'re not having a repeat of that whole mess.',icon:[25,32],power: 5,price: getCookiePrice(26)}); + Game.NewUpgradeCookie({name:'Pizzelle',desc:'Thin, crisp waffle cookies baked in a bespoke iron following an ancient Italian recipe.
These cookies have been around for a long, long time.
These cookies have seen things.',icon:[26,32],power: 5,price: getCookiePrice(27)}); - order=20000; - new Game.Upgrade('Kitten assistants to the regional manager','You gain more CpS the more milk you have.nothing stresses meowt... except having to seek the approval of my inferiors, sir',900000000000000000000000000000000000,Game.GetIcon('Kitten',10));Game.last.kitten=1; + order=10030; + Game.NewUpgradeCookie({name:'Zilla wafers',desc:'Popular vanilla-flavored biscuits that somehow keep ending up in banana pudding.
Themed after a beloved radioactive prehistoric monster, for some reason.',icon:[22,32],require:'Box of brand biscuits',power: 2, price: 999999999999999999999999999999*5}); + Game.NewUpgradeCookie({name:'Dim Dams',desc:'Two biscuits joined by chocolate and coated in even more chocolate.
You wonder - which one is the dim, and which one is the dam?',icon:[31,10],require:'Box of brand biscuits',power: 2, price: 999999999999999999999999999999*5}); + + order=10060; + Game.NewUpgradeCookie({name:'Candy',desc:'There are two pillars to the world of sweets : pastries, of course - and candy.
You could make a whole new game just about these, but for now, please enjoy these assorted generic candies.',icon:[30,10],require:'Box of not cookies', power:5,price: Math.pow(10,46)}); + + + order=19000; + new Game.TieredUpgrade('Fortune #001','Cursors are 7% more efficient and 7% cheaper.Fingers are not the only thing you can count on.','Cursor','fortune'); + new Game.TieredUpgrade('Fortune #002','Grandmas are 7% more efficient and 7% cheaper.A wrinkle is a crack in a mundane facade.','Grandma','fortune'); + new Game.TieredUpgrade('Fortune #003','Farms are 7% more efficient and 7% cheaper.The seeds of tomorrow already lie within the seeds of today.','Farm','fortune'); + new Game.TieredUpgrade('Fortune #004','Mines are 7% more efficient and 7% cheaper.Riches from deep under elevate you all the same.','Mine','fortune'); + new Game.TieredUpgrade('Fortune #005','Factories are 7% more efficient and 7% cheaper.True worth is not in what you find, but in what you make.','Factory','fortune'); + new Game.TieredUpgrade('Fortune #006','Banks are 7% more efficient and 7% cheaper.The value of money means nothing to a pocket.','Bank','fortune'); + new Game.TieredUpgrade('Fortune #007','Temples are 7% more efficient and 7% cheaper.Not all guides deserve worship.','Temple','fortune'); + new Game.TieredUpgrade('Fortune #008','Wizard towers are 7% more efficient and 7% cheaper.Magic is about two things - showmanship, and rabbits.','Wizard tower','fortune'); + new Game.TieredUpgrade('Fortune #009','Shipments are 7% more efficient and 7% cheaper.Every mile travelled expands the mind by just as much.','Shipment','fortune'); + new Game.TieredUpgrade('Fortune #010','Alchemy labs are 7% more efficient and 7% cheaper.Don\'t get used to yourself. You\'re gonna have to change.','Alchemy lab','fortune'); + new Game.TieredUpgrade('Fortune #011','Portals are 7% more efficient and 7% cheaper.Every doorway is a gamble. Tread with care.','Portal','fortune'); + new Game.TieredUpgrade('Fortune #012','Time machines are 7% more efficient and 7% cheaper.Do your future self a favor; they\'ll thank you for it.','Time machine','fortune'); + new Game.TieredUpgrade('Fortune #013','Antimatter condensers are 7% more efficient and 7% cheaper.The world is made of what we put into it.','Antimatter condenser','fortune'); + new Game.TieredUpgrade('Fortune #014','Prisms are 7% more efficient and 7% cheaper.Staring at a dazzling light can blind you back to darkness.','Prism','fortune'); + new Game.TieredUpgrade('Fortune #015','Chancemakers are 7% more efficient and 7% cheaper.Don\'t leave to blind chance what you could accomplish with deaf skill.','Chancemaker','fortune'); + new Game.TieredUpgrade('Fortune #016','Fractal engines are 7% more efficient and 7% cheaper.It\'s good to see yourself in others. Remember to see yourself in yourself, too.','Fractal engine','fortune'); + new Game.TieredUpgrade('Fortune #017','Javascript consoles are 7% more efficient and 7% cheaper.If things aren\'t working out for you, rewrite the rules.','Javascript console','fortune'); + + + order=19100; + //note : price for these capped to base price OR 1 day of unbuffed CpS + new Game.Upgrade('Fortune #100','Upgrades and buildings cost -1%; you gain +1% CpS.True wealth is counted in gifts.', + Game.Tiers['fortune'].price*100000,[0,0]);Game.MakeTiered(Game.last,'fortune',10); + Game.last.priceFunc=function(me){return Math.min(me.basePrice,Game.unbuffedCps*60*60*24);} + new Game.Upgrade('Fortune #101','You gain +7% CpS.Some people dream of fortunes; others dream of cookies.',Game.Tiers['fortune'].price*100000000,[0,0]);Game.MakeTiered(Game.last,'fortune',10); + Game.last.priceFunc=function(me){return Math.min(me.basePrice,Game.unbuffedCps*60*60*24);} + new Game.Upgrade('Fortune #102','You gain +1% of your regular CpS while the game is closed (provided you have the Twin Gates of Transcendence heavenly upgrade).Help, I\'m trapped in a browser game!',Game.Tiers['fortune'].price*100000000000,[0,0]);Game.MakeTiered(Game.last,'fortune',10); + Game.last.priceFunc=function(me){return Math.min(me.basePrice,Game.unbuffedCps*60*60*24);} + new Game.Upgrade('Fortune #103','You gain more CpS the more milk you have.Don\'t believe the superstitions; all cats are good luck.',Game.Tiers['fortune'].price*100000000000000,[0,0]);Game.MakeTiered(Game.last,'fortune',18);Game.last.kitten=1; + Game.last.priceFunc=function(me){return Math.min(me.basePrice,Game.unbuffedCps*60*60*24);} + new Game.Upgrade('Fortune #104','Clicking gains +1% of your CpS.Remember to stay in touch.',Game.Tiers['fortune'].price*100000000000,[0,0]);Game.MakeTiered(Game.last,'fortune',11); + Game.last.priceFunc=function(me){return Math.min(me.basePrice,Game.unbuffedCps*60*60*24);} + + new Game.Upgrade('Fortune cookies','The news ticker may occasionally have fortunes, which may be clicked for something good.These don\'t taste all that great but that\'s not really the point, is it?',77777777777,[29,8]);Game.last.pool='prestige';Game.last.parents=['Distilled essence of redoubled luck']; - order=5000; - new Game.SynergyUpgrade('Charm quarks','They\'re after your lucky quarks!','Chancemaker','Antimatter condenser','synergy2'); //end of upgrades @@ -7954,6 +9758,54 @@ Game.Launch=function() 'halloween':{name:'Halloween',start:'Halloween has started!',over:'Halloween is over.',trigger:'Ghostly biscuit'} }; + Game.listTinyOwnedUpgrades=function(arr) + { + var str=''; + for (var i=0;i'; + } + } + return str; + } + + Game.santaDrops=['Increased merriness','Improved jolliness','A lump of coal','An itchy sweater','Reindeer baking grounds','Weighted sleighs','Ho ho ho-flavored frosting','Season savings','Toy workshop','Naughty list','Santa\'s bottomless bag','Santa\'s helpers','Santa\'s legacy','Santa\'s milk and cookies']; + + Game.GetHowManySantaDrops=function() + { + var num=0; + for (var i in Game.santaDrops) {if (Game.Has(Game.santaDrops[i])) num++;} + return num; + } + + Game.reindeerDrops=['Christmas tree biscuits','Snowflake biscuits','Snowman biscuits','Holly biscuits','Candy cane biscuits','Bell biscuits','Present biscuits']; + Game.GetHowManyReindeerDrops=function() + { + var num=0; + for (var i in Game.reindeerDrops) {if (Game.Has(Game.reindeerDrops[i])) num++;} + return num; + } + /*for (var i in Game.santaDrops) + { + Game.Upgrades[Game.santaDrops[i]].descFunc=function(){return '
You currently own '+Game.GetHowManySantaDrops()+'/'+Game.santaDrops.length+' of Santa\'s gifts.
'+this.desc;}; + }*/ + + Game.seasonDrops=Game.heartDrops.concat(Game.halloweenDrops).concat(Game.easterEggs).concat(Game.santaDrops).concat(Game.reindeerDrops); + + Game.saySeasonSwitchUses=function() + { + if (Game.seasonUses==0) return 'You haven\'t switched seasons this ascension yet.'; + return 'You\'ve switched seasons '+(Game.seasonUses==1?'once':Game.seasonUses==2?'twice':(Game.seasonUses+' times'))+' this ascension.'; + } + Game.Upgrades['Festive biscuit'].descFunc=function(){return '
'+Game.listTinyOwnedUpgrades(Game.santaDrops)+'

You\'ve purchased '+Game.GetHowManySantaDrops()+'/'+Game.santaDrops.length+' of Santa\'s gifts.
'+Game.listTinyOwnedUpgrades(Game.reindeerDrops)+'

You\'ve purchased '+Game.GetHowManyReindeerDrops()+'/'+Game.reindeerDrops.length+' reindeer cookies.
'+Game.saySeasonSwitchUses()+'
'+this.desc;}; + Game.Upgrades['Bunny biscuit'].descFunc=function(){return '
'+Game.listTinyOwnedUpgrades(Game.easterEggs)+'

You\'ve purchased '+Game.GetHowManyEggs()+'/'+Game.easterEggs.length+' eggs.
'+Game.saySeasonSwitchUses()+'
'+this.desc;}; + Game.Upgrades['Ghostly biscuit'].descFunc=function(){return '
'+Game.listTinyOwnedUpgrades(Game.halloweenDrops)+'

You\'ve purchased '+Game.GetHowManyHalloweenDrops()+'/'+Game.halloweenDrops.length+' halloween cookies.
'+Game.saySeasonSwitchUses()+'
'+this.desc;}; + Game.Upgrades['Lovesick biscuit'].descFunc=function(){return '
'+Game.listTinyOwnedUpgrades(Game.heartDrops)+'

You\'ve purchased '+Game.GetHowManyHeartDrops()+'/'+Game.heartDrops.length+' heart biscuits.
'+Game.saySeasonSwitchUses()+'
'+this.desc;}; + Game.Upgrades['Fool\'s biscuit'].descFunc=function(){return '
'+Game.saySeasonSwitchUses()+'
'+this.desc;}; + Game.computeSeasonPrices=function() { for (var i in Game.seasons) @@ -7967,7 +9819,9 @@ Game.Launch=function() else if (godLvl==2) m*=1.50; else if (godLvl==3) m*=1.25; } - return Game.seasonTriggerBasePrice*Math.pow(2,Game.seasonUses)*m; + //return Game.seasonTriggerBasePrice*Math.pow(2,Game.seasonUses)*m; + //return Game.cookiesPs*60*Math.pow(1.5,Game.seasonUses)*m; + return Game.seasonTriggerBasePrice+Game.unbuffedCps*60*Math.pow(1.5,Game.seasonUses)*m; } } } @@ -8004,7 +9858,28 @@ Game.Launch=function() else Game.Notify(str,'',this.icon,4); } - me.displayFuncWhenOwned=function(){return '
Time remaining :
'+(Game.Has('Eternal seasons')?'forever':Game.sayTime(Game.seasonT,-1))+'
';} + me.clickFunction=function(me){return function() + { + //undo season + if (me.bought && Game.season && me==Game.seasons[Game.season].triggerUpgrade) + { + me.lose(); + var str=Game.seasons[Game.season].over; + if (Game.prefs.popups) Game.Popup(str); + else Game.Notify(str,'',Game.seasons[Game.season].triggerUpgrade.icon); + if (Game.Has('Season switcher')) {Game.Unlock(Game.seasons[Game.season].trigger);Game.seasons[Game.season].triggerUpgrade.bought=0;} + + Game.upgradesToRebuild=1; + Game.recalculateGains=1; + Game.season=Game.baseSeason; + Game.seasonT=-1; + PlaySound('snd/tick.mp3'); + return false; + } + else return true; + };}(me); + + me.displayFuncWhenOwned=function(){return '
Time remaining :
'+(Game.Has('Eternal seasons')?'forever':Game.sayTime(Game.seasonT,-1))+'
(Click again to cancel season)
';} me.timerDisplay=function(upgrade){return function(){if (!Game.Upgrades[upgrade.name].bought || Game.Has('Eternal seasons')) return -1; else return 1-Game.seasonT/Game.getSeasonDuration();}}(me); } @@ -8040,14 +9915,22 @@ Game.Launch=function() } } + Game.goldenCookieUpgrades=['Get lucky','Lucky day','Serendipity','Heavenly luck','Lasting fortune','Decisive fate','Lucky digit','Lucky number','Lucky payout','Golden goose egg']; + Game.cookieUpgrades=[]; for (var i in Game.Upgrades) { var me=Game.Upgrades[i]; if ((me.pool=='cookie' || me.pseudoCookie)) Game.cookieUpgrades.push(me); + if (me.tier) Game.Tiers[me.tier].upgrades.push(me); } + for (var i in Game.UnlockAt){Game.Upgrades[Game.UnlockAt[i].name].unlockAt=Game.UnlockAt[i];} + for (var i in Game.Upgrades){if (Game.Upgrades[i].pool=='prestige') Game.Upgrades[i].order=Game.Upgrades[i].id;} - Game.UpgradePositions={141:[194,-30],181:[-555,-93],253:[-272,-231],254:[-99,-294],255:[-193,-279],264:[48,123],265:[133,154],266:[223,166],267:[305,137],268:[382,85],269:[-640,42],270:[-607,-246],271:[-728,-120],272:[-688,-201],273:[-711,-33],274:[270,-328],275:[317,-439],276:[333,-556],277:[334,-676],278:[333,-796],279:[328,-922],280:[303,-1040],281:[194,-230],282:[-265,212],283:[-321,297],284:[-322,406],285:[-243,501],286:[-403,501],287:[-314,606],288:[-312,-374],289:[-375,-502],290:[-206,-476],291:[453,-745],292:[-375,-651],293:[-399,-794],323:[-237,41],325:[192,-1127],326:[-328,-158],327:[-192,290],328:[-3,237],329:[92,376],353:[121,-326],354:[77,-436],355:[64,-548],356:[57,-673],357:[52,-793],358:[58,-924],359:[82,-1043],360:[-188,408],362:[158,289],363:[-30,-30],364:[-232,-730],365:[-77,349],368:[-82,-532],393:[196,-714],394:[197,-964],395:[-124,-139],396:[-264,-889],397:[-69,563],408:[-204,-1036],409:[-72,-1152],410:[-70,-1328],411:[-388,137],412:[-470,253],413:[-482,389],}; + /*var oldPrestigePrices={"Chimera":5764801,"Synergies Vol. I":2525,"Synergies Vol. II":252525,"Label printer":9999}; + for (var i in oldPrestigePrices){Game.Upgrades[i].basePrice=oldPrestigePrices[i];}*/ + + Game.UpgradePositions={141:[176,-66],181:[-555,-93],253:[-272,-231],254:[-99,-294],255:[-193,-279],264:[48,123],265:[133,154],266:[223,166],267:[305,137],268:[382,85],269:[-640,42],270:[-614,-268],271:[-728,-120],272:[-688,-205],273:[-711,-31],274:[270,-328],275:[317,-439],276:[333,-556],277:[334,-676],278:[333,-796],279:[328,-922],280:[303,-1040],281:[194,-230],282:[-265,212],283:[-321,297],284:[-322,406],285:[-243,501],286:[-403,501],287:[-314,606],288:[-312,-374],289:[-375,-502],290:[-206,-476],291:[453,-745],292:[-375,-651],293:[-399,-794],323:[-86,120],325:[192,-1127],326:[-328,-158],327:[-192,290],328:[-3,237],329:[92,376],353:[121,-326],354:[77,-436],355:[64,-548],356:[57,-673],357:[52,-793],358:[58,-924],359:[82,-1043],360:[-188,408],362:[158,289],363:[-30,-30],364:[-232,-730],365:[-77,349],368:[-82,-532],393:[196,-714],394:[197,-964],395:[-143,-140],396:[-264,-889],397:[-69,563],408:[-204,-1036],409:[-72,-1152],410:[-70,-1328],411:[-388,137],412:[-470,253],413:[-482,389],449:[-367,-1113],450:[-334,-1214],451:[-278,-1303],495:[-402,-966],496:[200,49],505:[-545,-570],520:[-279,-8],537:[-907,-131],539:[-508,-1270],540:[-629,-1291],541:[-594,-1186],542:[-548,-1374],561:[300,-17],562:[52,646],591:[154,744],592:[180,608],643:[-121,710],}; for (var i in Game.UpgradePositions) {Game.UpgradesById[i].posX=Game.UpgradePositions[i][0];Game.UpgradesById[i].posY=Game.UpgradePositions[i][1];} @@ -8098,7 +9981,7 @@ Game.Launch=function() Game.Achievements[what].won=1; if (Game.prefs.popups) Game.Popup('Achievement unlocked :
'+name); else Game.Notify('Achievement unlocked','
'+name+'
',Game.Achievements[what].icon); - if (Game.Achievements[what].pool!='shadow') Game.AchievementsOwned++; + if (Game.CountsAsAchievementOwned(Game.Achievements[what].pool)) Game.AchievementsOwned++; Game.recalculateGains=1; } } @@ -8112,11 +9995,28 @@ Game.Launch=function() if (Game.Achievements[what].won==1) { Game.Achievements[what].won=0; - if (Game.Achievements[what].pool!='shadow') Game.AchievementsOwned--; + if (Game.CountsAsAchievementOwned(Game.Achievements[what].pool)) Game.AchievementsOwned--; Game.recalculateGains=1; } } } + Game.Achievement.prototype.toggle=function()//cheating only + { + if (!this.won) + { + Game.Win(this.name); + } + else + { + Game.RemoveAchiev(this.name); + } + if (Game.onMenu=='stats') Game.UpdateMenu(); + } + + Game.CountsAsAchievementOwned=function(pool) + { + if (pool=='' || pool=='normal') return true; else return false; + } Game.HasAchiev=function(what) { @@ -8130,13 +10030,26 @@ Game.Launch=function() return achiev; } - Game.thresholdIcons=[0,1,2,3,4,5,6,7,8,9,10,11,18,19,20,21,22,23,24,25,26,27,28,29,21,22,23,24,25,26,27,28,29]; + Game.ProductionAchievement=function(name,building,tier,q,mult) + { + var building=Game.Objects[building]; + var icon=[building.iconColumn,22]; + var n=12+building.n+(mult||0); + if (tier==2) {icon[1]=23;n+=7;} + else if (tier==3) {icon[1]=24;n+=14;} + var pow=Math.pow(10,n); + var achiev=new Game.Achievement(name,'Make '+Beautify(pow)+' cookies just from '+building.plural+'.'+(q?''+q+'':''),icon); + building.productionAchievs.push({pow:pow,achiev:achiev}); + return achiev; + } + + Game.thresholdIcons=[0,1,2,3,4,5,6,7,8,9,10,11,18,19,20,21,22,23,24,25,26,27,28,29,21,22,23,24,25,26,27,28,29,21,22,23,24,25,26,27,28,29]; Game.BankAchievements=[]; Game.BankAchievement=function(name) { var threshold=Math.pow(10,Math.floor(Game.BankAchievements.length*1.5+2)); if (Game.BankAchievements.length==0) threshold=1; - var achiev=new Game.Achievement(name,'Bake '+Beautify(threshold)+' cookie'+(threshold==1?'':'s')+' in one ascension.',[Game.thresholdIcons[Game.BankAchievements.length],(Game.BankAchievements.length>23?2:5)]); + var achiev=new Game.Achievement(name,'Bake '+Beautify(threshold)+' cookie'+(threshold==1?'':'s')+' in one ascension.',[Game.thresholdIcons[Game.BankAchievements.length],(Game.BankAchievements.length>32?1:Game.BankAchievements.length>23?2:5)]); achiev.threshold=threshold; achiev.order=100+Game.BankAchievements.length*0.01; Game.BankAchievements.push(achiev); @@ -8145,9 +10058,9 @@ Game.Launch=function() Game.CpsAchievements=[]; Game.CpsAchievement=function(name) { - var threshold=Math.pow(10,Game.CpsAchievements.length); + var threshold=Math.pow(10,Math.floor(Game.CpsAchievements.length*1.2)); //if (Game.CpsAchievements.length==0) threshold=1; - var achiev=new Game.Achievement(name,'Bake '+Beautify(threshold)+' cookie'+(threshold==1?'':'s')+' per second.',[Game.thresholdIcons[Game.CpsAchievements.length],(Game.CpsAchievements.length>23?2:5)]); + var achiev=new Game.Achievement(name,'Bake '+Beautify(threshold)+' cookie'+(threshold==1?'':'s')+' per second.',[Game.thresholdIcons[Game.CpsAchievements.length],(Game.CpsAchievements.length>32?1:Game.CpsAchievements.length>23?2:5)]); achiev.threshold=threshold; achiev.order=200+Game.CpsAchievements.length*0.01; Game.CpsAchievements.push(achiev); @@ -8209,44 +10122,44 @@ Game.Launch=function() order=1100; new Game.Achievement('Just wrong','Sell a grandma.I thought you loved me.',[10,9]); - new Game.TieredAchievement('Grandma\'s cookies','Have 1 grandma.','Grandma',1); - new Game.TieredAchievement('Sloppy kisses','Have 50 grandmas.','Grandma',2); - new Game.TieredAchievement('Retirement home','Have 100 grandmas.','Grandma',3); + Game.TieredAchievement('Grandma\'s cookies','Have 1 grandma.','Grandma',1); + Game.TieredAchievement('Sloppy kisses','Have 50 grandmas.','Grandma',2); + Game.TieredAchievement('Retirement home','Have 100 grandmas.','Grandma',3); order=1200; - new Game.TieredAchievement('My first farm','Have 1 farm.','Farm',1); - new Game.TieredAchievement('Reap what you sow','Have 50 farms.','Farm',2); - new Game.TieredAchievement('Farm ill','Have 100 farms.','Farm',3); + Game.TieredAchievement('My first farm','Have 1 farm.','Farm',1); + Game.TieredAchievement('Reap what you sow','Have 50 farms.','Farm',2); + Game.TieredAchievement('Farm ill','Have 100 farms.','Farm',3); order=1400; - new Game.TieredAchievement('Production chain','Have 1 factory.','Factory',1); - new Game.TieredAchievement('Industrial revolution','Have 50 factories.','Factory',2); - new Game.TieredAchievement('Global warming','Have 100 factories.','Factory',3); + Game.TieredAchievement('Production chain','Have 1 factory.','Factory',1); + Game.TieredAchievement('Industrial revolution','Have 50 factories.','Factory',2); + Game.TieredAchievement('Global warming','Have 100 factories.','Factory',3); order=1300; - new Game.TieredAchievement('You know the drill','Have 1 mine.','Mine',1); - new Game.TieredAchievement('Excavation site','Have 50 mines.','Mine',2); - new Game.TieredAchievement('Hollow the planet','Have 100 mines.','Mine',3); + Game.TieredAchievement('You know the drill','Have 1 mine.','Mine',1); + Game.TieredAchievement('Excavation site','Have 50 mines.','Mine',2); + Game.TieredAchievement('Hollow the planet','Have 100 mines.','Mine',3); order=1500; - new Game.TieredAchievement('Expedition','Have 1 shipment.','Shipment',1); - new Game.TieredAchievement('Galactic highway','Have 50 shipments.','Shipment',2); - new Game.TieredAchievement('Far far away','Have 100 shipments.','Shipment',3); + Game.TieredAchievement('Expedition','Have 1 shipment.','Shipment',1); + Game.TieredAchievement('Galactic highway','Have 50 shipments.','Shipment',2); + Game.TieredAchievement('Far far away','Have 100 shipments.','Shipment',3); order=1600; - new Game.TieredAchievement('Transmutation','Have 1 alchemy lab.','Alchemy lab',1); - new Game.TieredAchievement('Transmogrification','Have 50 alchemy labs.','Alchemy lab',2); - new Game.TieredAchievement('Gold member','Have 100 alchemy labs.','Alchemy lab',3); + Game.TieredAchievement('Transmutation','Have 1 alchemy lab.','Alchemy lab',1); + Game.TieredAchievement('Transmogrification','Have 50 alchemy labs.','Alchemy lab',2); + Game.TieredAchievement('Gold member','Have 100 alchemy labs.','Alchemy lab',3); order=1700; - new Game.TieredAchievement('A whole new world','Have 1 portal.','Portal',1); - new Game.TieredAchievement('Now you\'re thinking','Have 50 portals.','Portal',2); - new Game.TieredAchievement('Dimensional shift','Have 100 portals.','Portal',3); + Game.TieredAchievement('A whole new world','Have 1 portal.','Portal',1); + Game.TieredAchievement('Now you\'re thinking','Have 50 portals.','Portal',2); + Game.TieredAchievement('Dimensional shift','Have 100 portals.','Portal',3); order=1800; - new Game.TieredAchievement('Time warp','Have 1 time machine.','Time machine',1); - new Game.TieredAchievement('Alternate timeline','Have 50 time machines.','Time machine',2); - new Game.TieredAchievement('Rewriting history','Have 100 time machines.','Time machine',3); + Game.TieredAchievement('Time warp','Have 1 time machine.','Time machine',1); + Game.TieredAchievement('Alternate timeline','Have 50 time machines.','Time machine',2); + Game.TieredAchievement('Rewriting history','Have 100 time machines.','Time machine',3); order=7000; @@ -8300,9 +10213,9 @@ Game.Launch=function() new Game.Achievement('Nihilism','Ascend with 1 quadrillion cookies baked.There are many things
that need to be erased
',[11,7]); order=1900; - new Game.TieredAchievement('Antibatter','Have 1 antimatter condenser.','Antimatter condenser',1); - new Game.TieredAchievement('Quirky quarks','Have 50 antimatter condensers.','Antimatter condenser',2); - new Game.TieredAchievement('It does matter!','Have 100 antimatter condensers.','Antimatter condenser',3); + Game.TieredAchievement('Antibatter','Have 1 antimatter condenser.','Antimatter condenser',1); + Game.TieredAchievement('Quirky quarks','Have 50 antimatter condensers.','Antimatter condenser',2); + Game.TieredAchievement('It does matter!','Have 100 antimatter condensers.','Antimatter condenser',3); order=6000; new Game.Achievement('Upgrader','Purchase 100 upgrades.',[9,2]); @@ -8329,8 +10242,8 @@ Game.Launch=function() new Game.Achievement('Clickasmic','Make 100,000,000,000 cookies from clicking.',[11,14]); order=1100; - new Game.TieredAchievement('Friend of the ancients','Have 150 grandmas.','Grandma',4); - new Game.TieredAchievement('Ruler of the ancients','Have 200 grandmas.','Grandma',5); + Game.TieredAchievement('Friend of the ancients','Have 150 grandmas.','Grandma',4); + Game.TieredAchievement('Ruler of the ancients','Have 200 grandmas.','Grandma',5); order=32000; new Game.Achievement('Wholesome','Unlock 100% of your heavenly chips power.',[15,7]); @@ -8344,38 +10257,38 @@ Game.Launch=function() new Game.Achievement('Moistburster','Burst 200 wrinklers.',[19,8]); order=22000; - new Game.Achievement('Spooky cookies','Unlock every Halloween-themed cookie.
Owning this achievement makes Halloween-themed cookies drop more frequently in future playthroughs.',[12,8]); + new Game.Achievement('Spooky cookies','Unlock every Halloween-themed cookie.
Owning this achievement makes Halloween-themed cookies drop more frequently in future playthroughs.',[12,8]); order=22100; new Game.Achievement('Coming to town','Reach Santa\'s 7th form.',[18,9]); new Game.Achievement('All hail Santa','Reach Santa\'s final form.',[19,10]); - new Game.Achievement('Let it snow','Unlock every Christmas-themed cookie.
Owning this achievement makes Christmas-themed cookies drop more frequently in future playthroughs.',[19,9]); + new Game.Achievement('Let it snow','Unlock every Christmas-themed cookie.
Owning this achievement makes Christmas-themed cookies drop more frequently in future playthroughs.',[19,9]); new Game.Achievement('Oh deer','Pop 1 reindeer.',[12,9]); new Game.Achievement('Sleigh of hand','Pop 50 reindeer.',[12,9]); new Game.Achievement('Reindeer sleigher','Pop 200 reindeer.',[12,9]); order=1200; - new Game.TieredAchievement('Perfected agriculture','Have 150 farms.','Farm',4); + Game.TieredAchievement('Perfected agriculture','Have 150 farms.','Farm',4); order=1400; - new Game.TieredAchievement('Ultimate automation','Have 150 factories.','Factory',4); + Game.TieredAchievement('Ultimate automation','Have 150 factories.','Factory',4); order=1300; - new Game.TieredAchievement('Can you dig it','Have 150 mines.','Mine',4); + Game.TieredAchievement('Can you dig it','Have 150 mines.','Mine',4); order=1500; - new Game.TieredAchievement('Type II civilization','Have 150 shipments.','Shipment',4); + Game.TieredAchievement('Type II civilization','Have 150 shipments.','Shipment',4); order=1600; - new Game.TieredAchievement('Gild wars','Have 150 alchemy labs.','Alchemy lab',4); + Game.TieredAchievement('Gild wars','Have 150 alchemy labs.','Alchemy lab',4); order=1700; - new Game.TieredAchievement('Brain-split','Have 150 portals.','Portal',4); + Game.TieredAchievement('Brain-split','Have 150 portals.','Portal',4); order=1800; - new Game.TieredAchievement('Time duke','Have 150 time machines.','Time machine',4); + Game.TieredAchievement('Time duke','Have 150 time machines.','Time machine',4); order=1900; - new Game.TieredAchievement('Molecular maestro','Have 150 antimatter condensers.','Antimatter condenser',4); + Game.TieredAchievement('Molecular maestro','Have 150 antimatter condensers.','Antimatter condenser',4); order=2000; - new Game.TieredAchievement('Lone photon','Have 1 prism.','Prism',1); - new Game.TieredAchievement('Dazzling glimmer','Have 50 prisms.','Prism',2); - new Game.TieredAchievement('Blinding flash','Have 100 prisms.','Prism',3); - new Game.TieredAchievement('Unending glow','Have 150 prisms.','Prism',4); + Game.TieredAchievement('Lone photon','Have 1 prism.','Prism',1); + Game.TieredAchievement('Dazzling glimmer','Have 50 prisms.','Prism',2); + Game.TieredAchievement('Blinding flash','Have 100 prisms.','Prism',3); + Game.TieredAchievement('Unending glow','Have 150 prisms.','Prism',4); order=5000; new Game.Achievement('Lord of Constructs','Own 2000 buildings.He saw the vast plains stretching ahead of him, and he said : let there be civilization.',[5,6]); @@ -8397,27 +10310,27 @@ Game.Launch=function() new Game.Achievement('You win a cookie','This is for baking 10 trillion cookies and making it on the local news.We\'re all so proud of you.',[10,0]); order=1070; - new Game.Achievement('Click delegator','Make 10,000,000,000,000,000,000 cookies just from cursors.',[0,22]); + Game.ProductionAchievement('Click delegator','Cursor',1,0,7); order=1120; - new Game.Achievement('Gushing grannies','Make 10,000,000,000,000,000,000 cookies just from grandmas.',[1,22]); + Game.ProductionAchievement('Gushing grannies','Grandma',1,0,6); order=1220; - new Game.Achievement('I hate manure','Make 10,000,000,000,000 cookies just from farms.',[2,22]); + Game.ProductionAchievement('I hate manure','Farm',1); order=1320; - new Game.Achievement('Never dig down','Make 100,000,000,000,000 cookies just from mines.',[3,22]); + Game.ProductionAchievement('Never dig down','Mine',1); order=1420; - new Game.Achievement('The incredible machine','Make 1,000,000,000,000,000 cookies just from factories.',[4,22]); + Game.ProductionAchievement('The incredible machine','Factory',1); order=1520; - new Game.Achievement('And beyond','Make 10,000,000,000,000,000,000 cookies just from shipments.',[5,22]); + Game.ProductionAchievement('And beyond','Shipment',1); order=1620; - new Game.Achievement('Magnum Opus','Make 100,000,000,000,000,000,000 cookies just from alchemy labs.',[6,22]); + Game.ProductionAchievement('Magnum Opus','Alchemy lab',1); order=1720; - new Game.Achievement('With strange eons','Make 1,000,000,000,000,000,000,000 cookies just from portals.',[7,22]); + Game.ProductionAchievement('With strange eons','Portal',1); order=1820; - new Game.Achievement('Spacetime jigamaroo','Make 10,000,000,000,000,000,000,000 cookies just from time machines.',[8,22]); + Game.ProductionAchievement('Spacetime jigamaroo','Time machine',1); order=1920; - new Game.Achievement('Supermassive','Make 100,000,000,000,000,000,000,000 cookies just from antimatter condensers.',[13,22]); + Game.ProductionAchievement('Supermassive','Antimatter condenser',1); order=2020; - new Game.Achievement('Praise the sun','Make 1,000,000,000,000,000,000,000,000 cookies just from prisms.',[14,22]); + Game.ProductionAchievement('Praise the sun','Prism',1); order=1000; @@ -8428,16 +10341,16 @@ Game.Launch=function() new Game.Achievement('Extreme polydactyly','Have 300 cursors.',[0,13]); new Game.Achievement('Dr. T','Have 400 cursors.',[0,14]); - order=1100;new Game.TieredAchievement('The old never bothered me anyway','Have 250 grandmas.','Grandma',6); - order=1200;new Game.TieredAchievement('Homegrown','Have 200 farms.','Farm',5); - order=1400;new Game.TieredAchievement('Technocracy','Have 200 factories.','Factory',5); - order=1300;new Game.TieredAchievement('The center of the Earth','Have 200 mines.','Mine',5); - order=1500;new Game.TieredAchievement('We come in peace','Have 200 shipments.','Shipment',5); - order=1600;new Game.TieredAchievement('The secrets of the universe','Have 200 alchemy labs.','Alchemy lab',5); - order=1700;new Game.TieredAchievement('Realm of the Mad God','Have 200 portals.','Portal',5); - order=1800;new Game.TieredAchievement('Forever and ever','Have 200 time machines.','Time machine',5); - order=1900;new Game.TieredAchievement('Walk the planck','Have 200 antimatter condensers.','Antimatter condenser',5); - order=2000;new Game.TieredAchievement('Rise and shine','Have 200 prisms.','Prism',5); + order=1100;Game.TieredAchievement('The old never bothered me anyway','Have 250 grandmas.','Grandma',6); + order=1200;Game.TieredAchievement('Homegrown','Have 200 farms.','Farm',5); + order=1400;Game.TieredAchievement('Technocracy','Have 200 factories.','Factory',5); + order=1300;Game.TieredAchievement('The center of the Earth','Have 200 mines.','Mine',5); + order=1500;Game.TieredAchievement('We come in peace','Have 200 shipments.','Shipment',5); + order=1600;Game.TieredAchievement('The secrets of the universe','Have 200 alchemy labs.','Alchemy lab',5); + order=1700;Game.TieredAchievement('Realm of the Mad God','Have 200 portals.','Portal',5); + order=1800;Game.TieredAchievement('Forever and ever','Have 200 time machines.','Time machine',5); + order=1900;Game.TieredAchievement('Walk the planck','Have 200 antimatter condensers.','Antimatter condenser',5); + order=2000;Game.TieredAchievement('Rise and shine','Have 200 prisms.','Prism',5); order=30200; new Game.Achievement('God complex','Name yourself Orteil.
Note : usurpers incur a -1% CpS penalty until they rename themselves something else.
But that\'s not you, is it?',[17,5]);Game.last.pool='shadow'; @@ -8454,67 +10367,68 @@ Game.Launch=function() new Game.Achievement('The hunt is on','Unlock 1 egg.',[1,12]); new Game.Achievement('Egging on','Unlock 7 eggs.',[4,12]); new Game.Achievement('Mass Easteria','Unlock 14 eggs.',[7,12]); - new Game.Achievement('Hide & seek champion','Unlock all the eggs.
Owning this achievement makes eggs drop more frequently in future playthroughs.',[13,12]); + new Game.Achievement('Hide & seek champion','Unlock all the eggs.
Owning this achievement makes eggs drop more frequently in future playthroughs.',[13,12]); order=11000; new Game.Achievement('What\'s in a name','Give your bakery a name.',[15,9]); order=1425; - new Game.TieredAchievement('Pretty penny','Have 1 bank.','Bank',1); - new Game.TieredAchievement('Fit the bill','Have 50 banks.','Bank',2); - new Game.TieredAchievement('A loan in the dark','Have 100 banks.','Bank',3); - new Game.TieredAchievement('Need for greed','Have 150 banks.','Bank',4); - new Game.TieredAchievement('It\'s the economy, stupid','Have 200 banks.','Bank',5); + Game.TieredAchievement('Pretty penny','Have 1 bank.','Bank',1); + Game.TieredAchievement('Fit the bill','Have 50 banks.','Bank',2); + Game.TieredAchievement('A loan in the dark','Have 100 banks.','Bank',3); + Game.TieredAchievement('Need for greed','Have 150 banks.','Bank',4); + Game.TieredAchievement('It\'s the economy, stupid','Have 200 banks.','Bank',5); order=1450; - new Game.TieredAchievement('Your time to shrine','Have 1 temple.','Temple',1); - new Game.TieredAchievement('Shady sect','Have 50 temples.','Temple',2); - new Game.TieredAchievement('New-age cult','Have 100 temples.','Temple',3); - new Game.TieredAchievement('Organized religion','Have 150 temples.','Temple',4); - new Game.TieredAchievement('Fanaticism','Have 200 temples.','Temple',5); + Game.TieredAchievement('Your time to shrine','Have 1 temple.','Temple',1); + Game.TieredAchievement('Shady sect','Have 50 temples.','Temple',2); + Game.TieredAchievement('New-age cult','Have 100 temples.','Temple',3); + Game.TieredAchievement('Organized religion','Have 150 temples.','Temple',4); + Game.TieredAchievement('Fanaticism','Have 200 temples.','Temple',5); order=1475; - new Game.TieredAchievement('Bewitched','Have 1 wizard tower.','Wizard tower',1); - new Game.TieredAchievement('The sorcerer\'s apprentice','Have 50 wizard towers.','Wizard tower',2); - new Game.TieredAchievement('Charms and enchantments','Have 100 wizard towers.','Wizard tower',3); - new Game.TieredAchievement('Curses and maledictions','Have 150 wizard towers.','Wizard tower',4); - new Game.TieredAchievement('Magic kingdom','Have 200 wizard towers.','Wizard tower',5); + Game.TieredAchievement('Bewitched','Have 1 wizard tower.','Wizard tower',1); + Game.TieredAchievement('The sorcerer\'s apprentice','Have 50 wizard towers.','Wizard tower',2); + Game.TieredAchievement('Charms and enchantments','Have 100 wizard towers.','Wizard tower',3); + Game.TieredAchievement('Curses and maledictions','Have 150 wizard towers.','Wizard tower',4); + Game.TieredAchievement('Magic kingdom','Have 200 wizard towers.','Wizard tower',5); order=1445; - new Game.Achievement('Vested interest','Make 10,000,000,000,000,000 cookies just from banks.',[15,22]); + Game.ProductionAchievement('Vested interest','Bank',1); order=1470; - new Game.Achievement('New world order','Make 100,000,000,000,000,000 cookies just from temples.',[16,22]); + Game.ProductionAchievement('New world order','Temple',1); order=1495; - new Game.Achievement('Hocus pocus','Make 1,000,000,000,000,000,000 cookies just from wizard towers.',[17,22]); + Game.ProductionAchievement('Hocus pocus','Wizard tower',1); + order=1070; - new Game.Achievement('Finger clickin\' good','Make 10,000,000,000,000,000,000,000 cookies just from cursors.',[0,23]); + Game.ProductionAchievement('Finger clickin\' good','Cursor',2,0,7); order=1120; - new Game.Achievement('Panic at the bingo','Make 10,000,000,000,000,000,000,000 cookies just from grandmas.',[1,23]); + Game.ProductionAchievement('Panic at the bingo','Grandma',2,0,6); order=1220; - new Game.Achievement('Rake in the dough','Make 10,000,000,000,000,000 cookies just from farms.',[2,23]); + Game.ProductionAchievement('Rake in the dough','Farm',2); order=1320; - new Game.Achievement('Quarry on','Make 100,000,000,000,000,000 cookies just from mines.',[3,23]); + Game.ProductionAchievement('Quarry on','Mine',2); order=1420; - new Game.Achievement('Yes I love technology','Make 1,000,000,000,000,000,000 cookies just from factories.',[4,23]); + Game.ProductionAchievement('Yes I love technology','Factory',2); order=1445; - new Game.Achievement('Paid in full','Make 10,000,000,000,000,000,000 cookies just from banks.',[15,23]); + Game.ProductionAchievement('Paid in full','Bank',2); order=1470; - new Game.Achievement('Church of Cookiology','Make 100,000,000,000,000,000,000 cookies just from temples.',[16,23]); + Game.ProductionAchievement('Church of Cookiology','Temple',2); order=1495; - new Game.Achievement('Too many rabbits, not enough hats','Make 1,000,000,000,000,000,000,000 cookies just from wizard towers.',[17,23]); + Game.ProductionAchievement('Too many rabbits, not enough hats','Wizard tower',2); order=1520; - new Game.Achievement('The most precious cargo','Make 10,000,000,000,000,000,000,000 cookies just from shipments.',[5,23]); + Game.ProductionAchievement('The most precious cargo','Shipment',2); order=1620; - new Game.Achievement('The Aureate','Make 100,000,000,000,000,000,000,000 cookies just from alchemy labs.',[6,23]); + Game.ProductionAchievement('The Aureate','Alchemy lab',2); order=1720; - new Game.Achievement('Ever more hideous','Make 1,000,000,000,000,000,000,000,000 cookies just from portals.',[7,23]); + Game.ProductionAchievement('Ever more hideous','Portal',2); order=1820; - new Game.Achievement('Be kind, rewind','Make 10,000,000,000,000,000,000,000,000 cookies just from time machines.',[8,23]); + Game.ProductionAchievement('Be kind, rewind','Time machine',2); order=1920; - new Game.Achievement('Infinitesimal','Make 100,000,000,000,000,000,000,000,000 cookies just from antimatter condensers.',[13,23]); + Game.ProductionAchievement('Infinitesimal','Antimatter condenser',2); order=2020; - new Game.Achievement('A still more glorious dawn','Make 1,000,000,000,000,000,000,000,000,000 cookies just from prisms.',[14,23]); + Game.ProductionAchievement('A still more glorious dawn','Prism',2); order=30000; new Game.Achievement('Rebirth','Ascend at least once.',[21,6]); @@ -8530,21 +10444,21 @@ Game.Launch=function() order=1100; - new Game.TieredAchievement('The agemaster','Have 300 grandmas.','Grandma',7); - new Game.TieredAchievement('To oldly go','Have 350 grandmas.','Grandma',8); - - order=1200;new Game.TieredAchievement('Gardener extraordinaire','Have 250 farms.','Farm',6); - order=1300;new Game.TieredAchievement('Tectonic ambassador','Have 250 mines.','Mine',6); - order=1400;new Game.TieredAchievement('Rise of the machines','Have 250 factories.','Factory',6); - order=1425;new Game.TieredAchievement('Acquire currency','Have 250 banks.','Bank',6); - order=1450;new Game.TieredAchievement('Zealotry','Have 250 temples.','Temple',6); - order=1475;new Game.TieredAchievement('The wizarding world','Have 250 wizard towers.','Wizard tower',6); - order=1500;new Game.TieredAchievement('Parsec-masher','Have 250 shipments.','Shipment',6); - order=1600;new Game.TieredAchievement('The work of a lifetime','Have 250 alchemy labs.','Alchemy lab',6); - order=1700;new Game.TieredAchievement('A place lost in time','Have 250 portals.','Portal',6); - order=1800;new Game.TieredAchievement('Heat death','Have 250 time machines.','Time machine',6); - order=1900;new Game.TieredAchievement('Microcosm','Have 250 antimatter condensers.','Antimatter condenser',6); - order=2000;new Game.TieredAchievement('Bright future','Have 250 prisms.','Prism',6); + Game.TieredAchievement('The agemaster','Have 300 grandmas.','Grandma',7); + Game.TieredAchievement('To oldly go','Have 350 grandmas.','Grandma',8); + + order=1200;Game.TieredAchievement('Gardener extraordinaire','Have 250 farms.','Farm',6); + order=1300;Game.TieredAchievement('Tectonic ambassador','Have 250 mines.','Mine',6); + order=1400;Game.TieredAchievement('Rise of the machines','Have 250 factories.','Factory',6); + order=1425;Game.TieredAchievement('Acquire currency','Have 250 banks.','Bank',6); + order=1450;Game.TieredAchievement('Zealotry','Have 250 temples.','Temple',6); + order=1475;Game.TieredAchievement('The wizarding world','Have 250 wizard towers.','Wizard tower',6); + order=1500;Game.TieredAchievement('Parsec-masher','Have 250 shipments.','Shipment',6); + order=1600;Game.TieredAchievement('The work of a lifetime','Have 250 alchemy labs.','Alchemy lab',6); + order=1700;Game.TieredAchievement('A place lost in time','Have 250 portals.','Portal',6); + order=1800;Game.TieredAchievement('Heat death','Have 250 time machines.','Time machine',6); + order=1900;Game.TieredAchievement('Microcosm','Have 250 antimatter condensers.','Antimatter condenser',6); + order=2000;Game.TieredAchievement('Bright future','Have 250 prisms.','Prism',6); order=25000; new Game.Achievement('Here be dragon','Complete your dragon\'s training.',[21,12]); @@ -8560,7 +10474,7 @@ Game.Launch=function() Game.CpsAchievement('A world filled with cookies'); - Game.CpsAchievement('When this baby hits '+Beautify(100000000000*60*60)+' cookies per hour'); + Game.CpsAchievement('When this baby hits '+Beautify(10000000000000*60*60)+' cookies per hour'); Game.CpsAchievement('Fast and delicious'); Game.CpsAchievement('Cookiehertz : a really, really tasty hertz');Game.last.baseDesc+='Tastier than a hertz donut, anyway.';Game.last.desc=BeautifyInText(Game.last.baseDesc); Game.CpsAchievement('Woops, you solved world hunger'); @@ -8587,23 +10501,24 @@ Game.Launch=function() order=6000; new Game.Achievement('Polymath','Own 300 upgrades and 3000 buildings.Excellence doesn\'t happen overnight - it usually takes a good couple days.',[29,7]); + order=6005; new Game.Achievement('The elder scrolls','Own a combined 777 grandmas and cursors.Let me guess. Someone stole your cookie.',[10,9]); order=30050; new Game.Achievement('To crumbs, you say?','Ascend with 1 decillion cookies baked.Very well then.',[29,6]); - order=1200;new Game.TieredAchievement('Seedy business','Have 300 farms.','Farm',7); - order=1300;new Game.TieredAchievement('Freak fracking','Have 300 mines.','Mine',7); - order=1400;new Game.TieredAchievement('Modern times','Have 300 factories.','Factory',7); - order=1425;new Game.TieredAchievement('The nerve of war','Have 300 banks.','Bank',7); - order=1450;new Game.TieredAchievement('Wololo','Have 300 temples.','Temple',7); - order=1475;new Game.TieredAchievement('And now for my next trick, I\'ll need a volunteer from the audience','Have 300 wizard towers.','Wizard tower',7); - order=1500;new Game.TieredAchievement('It\'s not delivery','Have 300 shipments.','Shipment',7); - order=1600;new Game.TieredAchievement('Gold, Jerry! Gold!','Have 300 alchemy labs.','Alchemy lab',7); - order=1700;new Game.TieredAchievement('Forbidden zone','Have 300 portals.','Portal',7); - order=1800;new Game.TieredAchievement('cookie clicker forever and forever a hundred years cookie clicker, all day long forever, forever a hundred times, over and over cookie clicker adventures dot com','Have 300 time machines.','Time machine',7); - order=1900;new Game.TieredAchievement('Scientists baffled everywhere','Have 300 antimatter condensers.','Antimatter condenser',7); - order=2000;new Game.TieredAchievement('Harmony of the spheres','Have 300 prisms.','Prism',7); + order=1200;Game.TieredAchievement('Seedy business','Have 300 farms.','Farm',7); + order=1300;Game.TieredAchievement('Freak fracking','Have 300 mines.','Mine',7); + order=1400;Game.TieredAchievement('Modern times','Have 300 factories.','Factory',7); + order=1425;Game.TieredAchievement('The nerve of war','Have 300 banks.','Bank',7); + order=1450;Game.TieredAchievement('Wololo','Have 300 temples.','Temple',7); + order=1475;Game.TieredAchievement('And now for my next trick, I\'ll need a volunteer from the audience','Have 300 wizard towers.','Wizard tower',7); + order=1500;Game.TieredAchievement('It\'s not delivery','Have 300 shipments.','Shipment',7); + order=1600;Game.TieredAchievement('Gold, Jerry! Gold!','Have 300 alchemy labs.','Alchemy lab',7); + order=1700;Game.TieredAchievement('Forbidden zone','Have 300 portals.','Portal',7); + order=1800;Game.TieredAchievement('cookie clicker forever and forever a hundred years cookie clicker, all day long forever, forever a hundred times, over and over cookie clicker adventures dot com','Have 300 time machines.','Time machine',7); + order=1900;Game.TieredAchievement('Scientists baffled everywhere','Have 300 antimatter condensers.','Antimatter condenser',7); + order=2000;Game.TieredAchievement('Harmony of the spheres','Have 300 prisms.','Prism',7); order=35000; new Game.Achievement('Last Chance to See','Burst the near-extinct shiny wrinkler.You monster!',[24,12]);Game.last.pool='shadow'; @@ -8636,47 +10551,49 @@ Game.Launch=function() Game.BankAchievement('The dreams in which I\'m baking are the best I\'ve ever had'); Game.BankAchievement('Set for life'); - order=1200;new Game.TieredAchievement('You and the beanstalk','Have 350 farms.','Farm',8); - order=1300;new Game.TieredAchievement('Romancing the stone','Have 350 mines.','Mine',8); - order=1400;new Game.TieredAchievement('Ex machina','Have 350 factories.','Factory',8); - order=1425;new Game.TieredAchievement('And I need it now','Have 350 banks.','Bank',8); - order=1450;new Game.TieredAchievement('Pray on the weak','Have 350 temples.','Temple',8); - order=1475;new Game.TieredAchievement('It\'s a kind of magic','Have 350 wizard towers.','Wizard tower',8); - order=1500;new Game.TieredAchievement('Make it so','Have 350 shipments.','Shipment',8); - order=1600;new Game.TieredAchievement('All that glitters is gold','Have 350 alchemy labs.','Alchemy lab',8); - order=1700;new Game.TieredAchievement('H̸̷͓̳̳̯̟͕̟͍͍̣͡ḛ̢̦̰̺̮̝͖͖̘̪͉͘͡ ̠̦͕̤̪̝̥̰̠̫̖̣͙̬͘ͅC̨̦̺̩̲̥͉̭͚̜̻̝̣̼͙̮̯̪o̴̡͇̘͎̞̲͇̦̲͞͡m̸̩̺̝̣̹̱͚̬̥̫̳̼̞̘̯͘ͅẹ͇̺̜́̕͢s̶̙̟̱̥̮̯̰̦͓͇͖͖̝͘͘͞','Have 350 portals.','Portal',8); - order=1800;new Game.TieredAchievement('Way back then','Have 350 time machines.','Time machine',8); - order=1900;new Game.TieredAchievement('Exotic matter','Have 350 antimatter condensers.','Antimatter condenser',8); - order=2000;new Game.TieredAchievement('At the end of the tunnel','Have 350 prisms.','Prism',8); + order=1200;Game.TieredAchievement('You and the beanstalk','Have 350 farms.','Farm',8); + order=1300;Game.TieredAchievement('Romancing the stone','Have 350 mines.','Mine',8); + order=1400;Game.TieredAchievement('Ex machina','Have 350 factories.','Factory',8); + order=1425;Game.TieredAchievement('And I need it now','Have 350 banks.','Bank',8); + order=1450;Game.TieredAchievement('Pray on the weak','Have 350 temples.','Temple',8); + order=1475;Game.TieredAchievement('It\'s a kind of magic','Have 350 wizard towers.','Wizard tower',8); + order=1500;Game.TieredAchievement('Make it so','Have 350 shipments.','Shipment',8); + order=1600;Game.TieredAchievement('All that glitters is gold','Have 350 alchemy labs.','Alchemy lab',8); + order=1700;Game.TieredAchievement('H̸̷͓̳̳̯̟͕̟͍͍̣͡ḛ̢̦̰̺̮̝͖͖̘̪͉͘͡ ̠̦͕̤̪̝̥̰̠̫̖̣͙̬͘ͅC̨̦̺̩̲̥͉̭͚̜̻̝̣̼͙̮̯̪o̴̡͇̘͎̞̲͇̦̲͞͡m̸̩̺̝̣̹̱͚̬̥̫̳̼̞̘̯͘ͅẹ͇̺̜́̕͢s̶̙̟̱̥̮̯̰̦͓͇͖͖̝͘͘͞','Have 350 portals.','Portal',8); + order=1800;Game.TieredAchievement('Way back then','Have 350 time machines.','Time machine',8); + order=1900;Game.TieredAchievement('Exotic matter','Have 350 antimatter condensers.','Antimatter condenser',8); + order=2000;Game.TieredAchievement('At the end of the tunnel','Have 350 prisms.','Prism',8); + + order=1070; - new Game.Achievement('Click (starring Adam Sandler)','Make 10,000,000,000,000,000,000,000,000 cookies just from cursors.',[0,24]); + Game.ProductionAchievement('Click (starring Adam Sandler)','Cursor',3,0,7); order=1120; - new Game.Achievement('Frantiquities','Make 10,000,000,000,000,000,000,000,000 cookies just from grandmas.',[1,24]); + Game.ProductionAchievement('Frantiquities','Grandma',3,0,6); order=1220; - new Game.Achievement('Overgrowth','Make 10,000,000,000,000,000,000 cookies just from farms.',[2,24]); + Game.ProductionAchievement('Overgrowth','Farm',3); order=1320; - new Game.Achievement('Sedimentalism','Make 100,000,000,000,000,000,000 cookies just from mines.',[3,24]); + Game.ProductionAchievement('Sedimentalism','Mine',3); order=1420; - new Game.Achievement('Labor of love','Make 1,000,000,000,000,000,000,000 cookies just from factories.',[4,24]); + Game.ProductionAchievement('Labor of love','Factory',3); order=1445; - new Game.Achievement('Reverse funnel system','Make 10,000,000,000,000,000,000,000 cookies just from banks.',[15,24]); + Game.ProductionAchievement('Reverse funnel system','Bank',3); order=1470; - new Game.Achievement('Thus spoke you','Make 100,000,000,000,000,000,000,000 cookies just from temples.',[16,24]); + Game.ProductionAchievement('Thus spoke you','Temple',3); order=1495; - new Game.Achievement('Manafest destiny','Make 1,000,000,000,000,000,000,000,000 cookies just from wizard towers.',[17,24]); + Game.ProductionAchievement('Manafest destiny','Wizard tower',3); order=1520; - new Game.Achievement('Neither snow nor rain nor heat nor gloom of night','Make 10,000,000,000,000,000,000,000,000 cookies just from shipments.',[5,24]); + Game.ProductionAchievement('Neither snow nor rain nor heat nor gloom of night','Shipment',3); order=1620; - new Game.Achievement('I\'ve got the Midas touch','Make 100,000,000,000,000,000,000,000,000 cookies just from alchemy labs.',[6,24]); + Game.ProductionAchievement('I\'ve got the Midas touch','Alchemy lab',3); order=1720; - new Game.Achievement('Which eternal lie','Make 1,000,000,000,000,000,000,000,000,000 cookies just from portals.',[7,24]); + Game.ProductionAchievement('Which eternal lie','Portal',3); order=1820; - new Game.Achievement('Déjà vu','Make 10,000,000,000,000,000,000,000,000,000 cookies just from time machines.',[8,24]); + Game.ProductionAchievement('Déjà vu','Time machine',3); order=1920; - new Game.Achievement('Powers of Ten','Make 100,000,000,000,000,000,000,000,000,000 cookies just from antimatter condensers.',[13,24]); + Game.ProductionAchievement('Powers of Ten','Antimatter condenser',3); order=2020; - new Game.Achievement('Now the dark days are gone','Make 1,000,000,000,000,000,000,000,000,000,000 cookies just from prisms.',[14,24]); + Game.ProductionAchievement('Now the dark days are gone','Prism',3); order=1070; new Game.Achievement('Freaky jazz hands','Reach level 10 cursors.',[0,26]);Game.Objects['Cursor'].levelAchiev10=Game.last; @@ -8717,24 +10634,198 @@ Game.Launch=function() new Game.Achievement('Four-leaf cookie','Have 4 golden cookies simultaneously.Fairly rare, considering cookies don\'t even have leaves.',[27,6]);Game.last.pool='shadow'; order=2100; - new Game.TieredAchievement('Lucked out','Have 1 chancemaker.','Chancemaker',1); - new Game.TieredAchievement('What are the odds','Have 50 chancemakers.','Chancemaker',2); - new Game.TieredAchievement('Grandma needs a new pair of shoes','Have 100 chancemakers.','Chancemaker',3); - new Game.TieredAchievement('Million to one shot, doc','Have 150 chancemakers.','Chancemaker',4); - new Game.TieredAchievement('As luck would have it','Have 200 chancemakers.','Chancemaker',5); - new Game.TieredAchievement('Ever in your favor','Have 250 chancemakers.','Chancemaker',6); - new Game.TieredAchievement('Be a lady','Have 300 chancemakers.','Chancemaker',7); - new Game.TieredAchievement('Dicey business','Have 350 chancemakers.','Chancemaker',8); + Game.TieredAchievement('Lucked out','Have 1 chancemaker.','Chancemaker',1); + Game.TieredAchievement('What are the odds','Have 50 chancemakers.','Chancemaker',2); + Game.TieredAchievement('Grandma needs a new pair of shoes','Have 100 chancemakers.','Chancemaker',3); + Game.TieredAchievement('Million to one shot, doc','Have 150 chancemakers.','Chancemaker',4); + Game.TieredAchievement('As luck would have it','Have 200 chancemakers.','Chancemaker',5); + Game.TieredAchievement('Ever in your favor','Have 250 chancemakers.','Chancemaker',6); + Game.TieredAchievement('Be a lady','Have 300 chancemakers.','Chancemaker',7); + Game.TieredAchievement('Dicey business','Have 350 chancemakers.','Chancemaker',8); order=2120; - new Game.Achievement('Fingers crossed','Make 10,000,000,000,000,000,000,000,000 cookies just from chancemakers.',[19,22]); - new Game.Achievement('Just a statistic','Make 10,000,000,000,000,000,000,000,000,000 cookies just from chancemakers.',[19,23]); - new Game.Achievement('Murphy\'s wild guess','Make 10,000,000,000,000,000,000,000,000,000,000 cookies just from chancemakers.',[19,24]); + Game.ProductionAchievement('Fingers crossed','Chancemaker',1); + Game.ProductionAchievement('Just a statistic','Chancemaker',2); + Game.ProductionAchievement('Murphy\'s wild guess','Chancemaker',3); new Game.Achievement('Let\'s leaf it at that','Reach level 10 chancemakers.',[19,26]);Game.Objects['Chancemaker'].levelAchiev10=Game.last; order=1000; - new Game.Achievement('The ultimate clickdown','Make 1,000,000,000,000,000,000,000 cookies from clicking.(of ultimate destiny.)',[11,19]); + new Game.Achievement('The ultimate clickdown','Make 1,000,000,000,000,000,000,000 cookies from clicking.(of ultimate destiny.)',[11,19]); + + + order=1100; + Game.TieredAchievement('Aged well','Have 400 grandmas.','Grandma',9); + Game.TieredAchievement('101st birthday','Have 450 grandmas.','Grandma',10); + Game.TieredAchievement('Defense of the ancients','Have 500 grandmas.','Grandma',11); + order=1200;Game.TieredAchievement('Harvest moon','Have 400 farms.','Farm',9); + order=1300;Game.TieredAchievement('Mine?','Have 400 mines.','Mine',9); + order=1400;Game.TieredAchievement('In full gear','Have 400 factories.','Factory',9); + order=1425;Game.TieredAchievement('Treacle tart economics','Have 400 banks.','Bank',9); + order=1450;Game.TieredAchievement('Holy cookies, grandma!','Have 400 temples.','Temple',9); + order=1475;Game.TieredAchievement('The Prestige','Have 400 wizard towers.(Unrelated to the Cookie Clicker feature of the same name.)','Wizard tower',9); + order=1500;Game.TieredAchievement('That\'s just peanuts to space','Have 400 shipments.','Shipment',9); + order=1600;Game.TieredAchievement('Worth its weight in lead','Have 400 alchemy labs.','Alchemy lab',9); + order=1700;Game.TieredAchievement('What happens in the vortex stays in the vortex','Have 400 portals.','Portal',9); + order=1800;Game.TieredAchievement('Invited to yesterday\'s party','Have 400 time machines.','Time machine',9); + order=1900;Game.TieredAchievement('Downsizing','Have 400 antimatter condensers.','Antimatter condenser',9);//the trailer got me really hyped up but i've read some pretty bad reviews. is it watchable ? is it worth seeing ? i don't mind matt damon + order=2000;Game.TieredAchievement('My eyes','Have 400 prisms.','Prism',9); + order=2100;Game.TieredAchievement('Maybe a chance in hell, actually','Have 400 chancemakers.','Chancemaker',9); + + order=1200;Game.TieredAchievement('Make like a tree','Have 450 farms.','Farm',10); + order=1300;Game.TieredAchievement('Cave story','Have 450 mines.','Mine',10); + order=1400;Game.TieredAchievement('In-cog-neato','Have 450 factories.','Factory',10); + order=1425;Game.TieredAchievement('Save your breath because that\'s all you\'ve got left','Have 450 banks.','Bank',10); + order=1450;Game.TieredAchievement('Vengeful and almighty','Have 450 temples.','Temple',10); + order=1475;Game.TieredAchievement('Spell it out for you','Have 450 wizard towers.','Wizard tower',10); + order=1500;Game.TieredAchievement('Space space space space space','Have 450 shipments.It\'s too far away...','Shipment',10); + order=1600;Game.TieredAchievement('Don\'t get used to yourself, you\'re gonna have to change','Have 450 alchemy labs.','Alchemy lab',10); + order=1700;Game.TieredAchievement('Objects in the mirror dimension are closer than they appear','Have 450 portals.','Portal',10); + order=1800;Game.TieredAchievement('Groundhog day','Have 450 time machines.','Time machine',10); + order=1900;Game.TieredAchievement('A matter of perspective','Have 450 antimatter condensers.','Antimatter condenser',10); + order=2000;Game.TieredAchievement('Optical illusion','Have 450 prisms.','Prism',10); + order=2100;Game.TieredAchievement('Jackpot','Have 450 chancemakers.','Chancemaker',10); + + order=36000; + new Game.Achievement('So much to do so much to see','Manage a cookie legacy for at least a year.Thank you so much for playing Cookie Clicker!',[23,11]);Game.last.pool='shadow'; + + + + Game.CpsAchievement('Running with scissors'); + Game.CpsAchievement('Rarefied air'); + Game.CpsAchievement('Push it to the limit'); + Game.CpsAchievement('Green cookies sleep furiously'); + + Game.BankAchievement('Panic! at Nabisco'); + Game.BankAchievement('Bursting at the seams'); + Game.BankAchievement('Just about full'); + Game.BankAchievement('Hungry for more'); + + order=1000; + new Game.Achievement('All the other kids with the pumped up clicks','Make 100,000,000,000,000,000,000,000 cookies from clicking.',[11,28]); + new Game.Achievement('One...more...click...','Make 10,000,000,000,000,000,000,000,000 cookies from clicking.',[11,30]); + + order=61515; + new Game.Achievement('Botany enthusiast','Harvest 100 mature garden plants.',[26,20]); + new Game.Achievement('Green, aching thumb','Harvest 1000 mature garden plants.',[27,20]); + new Game.Achievement('In the garden of Eden (baby)','Fill every tile of the biggest garden plot with plants.Isn\'t tending to those precious little plants just so rock and/or roll?',[28,20]); + + new Game.Achievement('Keeper of the conservatory','Unlock every garden seed.',[25,20]); + new Game.Achievement('Seedless to nay','Convert a complete seed log into sugar lumps by sacrificing your garden to the sugar hornets.
Owning this achievement makes seeds 5% cheaper, plants mature 5% sooner, and plant upgrades drop 5% more.',[29,20]); + + order=30050; + new Game.Achievement('You get nothing','Ascend with 1 undecillion cookies baked.Good day sir!',[29,6]); + new Game.Achievement('Humble rebeginnings','Ascend with 1 duodecillion cookies baked.Started from the bottom, now we\'re here.',[29,6]); + new Game.Achievement('The end of the world','Ascend with 1 tredecillion cookies baked.(as we know it)',[21,25]); + new Game.Achievement('Oh, you\'re back','Ascend with 1 quattuordecillion cookies baked.Missed us?',[21,25]); + new Game.Achievement('Lazarus','Ascend with 1 quindecillion cookies baked.All rise.',[21,25]); + + Game.CpsAchievement('Leisurely pace'); + Game.CpsAchievement('Hypersonic'); + + Game.BankAchievement('Feed me, Orteil'); + Game.BankAchievement('And then what?'); + + order=7002; + new Game.Achievement('Tricentennial and a half','Have at least 350 of everything.(it\'s free real estate)',[21,26]); + new Game.Achievement('Quadricentennial','Have at least 400 of everything.You\'ve had to do horrible things to get this far.
Horrible... horrible things.
',[22,26]); + new Game.Achievement('Quadricentennial and a half','Have at least 450 of everything.At this point, you might just be compensating for something.',[23,26]); + + new Game.Achievement('Quincentennial','Have at least 500 of everything.Some people would say you\'re halfway there.
We do not care for those people and their reckless sense of unchecked optimism.
',[29,25]); + + + order=21100; + new Game.Achievement('Maillard reaction','Harvest a caramelized sugar lump.',[29,27]); + + order=30250; + new Game.Achievement('When the cookies ascend just right','Ascend with exactly 1,000,000,000,000 cookies.',[25,7]);Game.last.pool='shadow';//this achievement is shadow because it is only achievable through blind luck or reading external guides; this may change in the future + + + order=1050; + new Game.Achievement('With her finger and her thumb','Have 600 cursors.',[0,16]); + + order=1100;Game.TieredAchievement('But wait \'til you get older','Have 550 grandmas.','Grandma',12); + order=1200;Game.TieredAchievement('Sharpest tool in the shed','Have 500 farms.','Farm',11); + order=1300;Game.TieredAchievement('Hey now, you\'re a rock','Have 500 mines.','Mine',11); + order=1400;Game.TieredAchievement('Break the mold','Have 500 factories.','Factory',11); + order=1425;Game.TieredAchievement('Get the show on, get paid','Have 500 banks.','Bank',11); + order=1450;Game.TieredAchievement('My world\'s on fire, how about yours','Have 500 temples.','Temple',11); + order=1475;Game.TieredAchievement('The meteor men beg to differ','Have 500 wizard towers.','Wizard tower',11); + order=1500;Game.TieredAchievement('Only shooting stars','Have 500 shipments.','Shipment',11); + order=1600;Game.TieredAchievement('We could all use a little change','Have 500 alchemy labs.','Alchemy lab',11);//"all that glitters is gold" was already an achievement + order=1700;Game.TieredAchievement('Your brain gets smart but your head gets dumb','Have 500 portals.','Portal',11); + order=1800;Game.TieredAchievement('The years start coming','Have 500 time machines.','Time machine',11); + order=1900;Game.TieredAchievement('What a concept','Have 500 antimatter condensers.','Antimatter condenser',11); + order=2000;Game.TieredAchievement('You\'ll never shine if you don\'t glow','Have 500 prisms.','Prism',11); + order=2100;Game.TieredAchievement('You\'ll never know if you don\'t go','Have 500 chancemakers.','Chancemaker',11); + + order=2200; + Game.TieredAchievement('Self-contained','Have 1 fractal engine.','Fractal engine',1); + Game.TieredAchievement('Threw you for a loop','Have 50 fractal engines.','Fractal engine',2); + Game.TieredAchievement('The sum of its parts','Have 100 fractal engines.','Fractal engine',3); + Game.TieredAchievement('Bears repeating','Have 150 fractal engines.Where did these come from?','Fractal engine',4); + Game.TieredAchievement('More of the same','Have 200 fractal engines.','Fractal engine',5); + Game.TieredAchievement('Last recurse','Have 250 fractal engines.','Fractal engine',6); + Game.TieredAchievement('Out of one, many','Have 300 fractal engines.','Fractal engine',7); + Game.TieredAchievement('An example of recursion','Have 350 fractal engines.','Fractal engine',8); + Game.TieredAchievement('For more information on this achievement, please refer to its title','Have 400 fractal engines.','Fractal engine',9); + Game.TieredAchievement('I\'m so meta, even this achievement','Have 450 fractal engines.','Fractal engine',10); + Game.TieredAchievement('Never get bored','Have 500 fractal engines.','Fractal engine',11); + + order=2220; + Game.ProductionAchievement('The needs of the many','Fractal engine',1); + Game.ProductionAchievement('Eating its own','Fractal engine',2); + Game.ProductionAchievement('We must go deeper','Fractal engine',3); + + new Game.Achievement('Sierpinski rhomboids','Reach level 10 fractal engines.',[20,26]);Game.Objects['Fractal engine'].levelAchiev10=Game.last; + + Game.CpsAchievement('Gotta go fast'); + Game.BankAchievement('I think it\'s safe to say you\'ve got it made'); + + order=6000; + new Game.Achievement('Renaissance baker','Own 400 upgrades and 4000 buildings.If you have seen further, it is by standing on the shoulders of giants - a mysterious species of towering humanoids until now thought long-extinct.',[10,10]); + + order=1150; + new Game.Achievement('Veteran','Own at least 14 grandma types.14\'s a crowd!',[10,9]); + + order=10000; + new Game.Achievement('Thick-skinned','Have your reinforced membrane protect the shimmering veil.',[7,10]); + + + order=2300; + Game.TieredAchievement('F12','Have 1 javascript console.','Javascript console',1); + Game.TieredAchievement('Variable success','Have 50 javascript consoles.','Javascript console',2); + Game.TieredAchievement('No comments','Have 100 javascript consoles.','Javascript console',3); + Game.TieredAchievement('Up to code','Have 150 javascript consoles.','Javascript console',4); + Game.TieredAchievement('Works on my machine','Have 200 javascript consoles.','Javascript console',5); + Game.TieredAchievement('Technical debt','Have 250 javascript consoles.','Javascript console',6); + Game.TieredAchievement('Mind your language','Have 300 javascript consoles.','Javascript console',7); + Game.TieredAchievement('Inconsolable','Have 350 javascript consoles.','Javascript console',8); + Game.TieredAchievement('Closure','Have 400 javascript consoles.','Javascript console',9); + Game.TieredAchievement('Dude what if we\'re all living in a simulation like what if we\'re all just code on a computer somewhere','Have 450 javascript consoles.','Javascript console',10); + Game.TieredAchievement('Taking the back streets','Have 500 javascript consoles.','Javascript console',11); + + order=2320; + Game.ProductionAchievement('Inherited prototype','Javascript console',1); + Game.ProductionAchievement('A model of document object','Javascript console',2); + Game.ProductionAchievement('First-class citizen','Javascript console',3); + + new Game.Achievement('Alexandria','Reach level 10 javascript consoles.',[32,26]);Game.Objects['Javascript console'].levelAchiev10=Game.last; + + Game.CpsAchievement('Bake him away, toys'); + Game.CpsAchievement('You\'re #1 so why try harder'); + Game.CpsAchievement('Haven\'t even begun to peak'); + Game.BankAchievement('A sometimes food'); + Game.BankAchievement('Not enough of a good thing'); + Game.BankAchievement('Horn of plenty'); + + order=30050; + new Game.Achievement('Smurf account','Ascend with 1 sexdecillion cookies baked.It\'s like you just appeared out of the blue!',[21,32]); + new Game.Achievement('If at first you don\'t succeed','Ascend with 1 septendecillion cookies baked.If at first you don\'t succeed, try, try, try again.
But isn\'t that the definition of insanity?
',[21,32]); + + order=33000; + new Game.Achievement('O Fortuna','Own every fortune upgrade.
Owning this achievement makes fortunes appear twice as often; unlocked fortune upgrades also have a 40% chance to carry over after ascending.',[29,8]); + //end of achievements /*===================================================================================== @@ -8779,7 +10870,7 @@ Game.Launch=function() //create dom Game.buffsL.innerHTML=Game.buffsL.innerHTML+'

'+buff.name+'

'+buff.desc+'
' - ,'left',true):'')+' style="opacity:1;float:none;display:block;background-position:'+(-buff.icon[0]*48)+'px '+(-buff.icon[1]*48)+'px;">'; + ,'left',true):'')+' style="opacity:1;float:none;display:block;'+(buff.icon[2]?'background-image:url('+buff.icon[2]+');':'')+'background-position:'+(-buff.icon[0]*48)+'px '+(-buff.icon[1]*48)+'px;">'; buff.l=l('buff'+buff.id); @@ -9080,6 +11171,18 @@ Game.Launch=function() max:true }; }); + new Game.buffType('sugar frenzy',function(time,pow) + { + return { + name:'Sugar frenzy', + desc:'Cookie production x'+pow+' for '+Game.sayTime(time*Game.fps,-1)+'!', + icon:[29,14], + time:time*Game.fps, + add:true, + multCpS:pow, + aura:0 + }; + }); //end of buffs @@ -9167,7 +11270,7 @@ Game.Launch=function() { for (var i in Game.wrinklers) { - Game.wrinklers[i]={id:parseInt(i),close:0,sucked:0,phase:0,x:0,y:0,r:0,hurt:0,hp:Game.wrinklerHP,type:0}; + Game.wrinklers[i]={id:parseInt(i),close:0,sucked:0,phase:0,x:0,y:0,r:0,hurt:0,hp:Game.wrinklerHP,selected:0,type:0}; } } Game.CollectWrinklers=function() @@ -9248,6 +11351,7 @@ Game.Launch=function() if (me.phase==0 && Game.elderWrath>0 && n0) { - Game.LeftBackground.globalAlpha=me.close; - Game.LeftBackground.save(); - Game.LeftBackground.translate(me.x,me.y); - Game.LeftBackground.rotate(-(me.r)*Math.PI/180); + ctx.globalAlpha=me.close; + ctx.save(); + ctx.translate(me.x,me.y); + ctx.rotate(-(me.r)*Math.PI/180); //var s=Math.min(1,me.sucked/(Game.cookiesPs*60))*0.75+0.25;//scale wrinklers as they eat - //Game.LeftBackground.scale(Math.pow(s,1.5)*1.25,s); - //Game.LeftBackground.fillRect(-50,-10,100,200); - if (me.type==1) Game.LeftBackground.drawImage(Pic('shinyWrinkler.png'),-50,-10); - else if (Game.season=='christmas') Game.LeftBackground.drawImage(Pic('winterWrinkler.png'),-50,-10); - else Game.LeftBackground.drawImage(Pic('wrinkler.png'),-50,-10); - //Game.LeftBackground.fillText(me.id+' : '+me.sucked,0,0); + //ctx.scale(Math.pow(s,1.5)*1.25,s); + //ctx.fillRect(-50,-10,100,200); + if (me.type==1) ctx.drawImage(Pic('shinyWrinkler.png'),-50,-10); + else if (Game.season=='christmas') ctx.drawImage(Pic('winterWrinkler.png'),-50,-10); + else ctx.drawImage(Pic('wrinkler.png'),-50,-10); + //ctx.fillText(me.id+' : '+me.sucked,0,0); if (me.type==1 && Math.random()<0.3 && Game.prefs.particles)//sparkle { - Game.LeftBackground.globalAlpha=Math.random()*0.65+0.1; + ctx.globalAlpha=Math.random()*0.65+0.1; var s=Math.random()*30+5; - Game.LeftBackground.globalCompositeOperation='lighter'; - Game.LeftBackground.drawImage(Pic('glint.jpg'),-s/2+Math.random()*50-25,-s/2+Math.random()*200,s,s); + ctx.globalCompositeOperation='lighter'; + ctx.drawImage(Pic('glint.jpg'),-s/2+Math.random()*50-25,-s/2+Math.random()*200,s,s); } - Game.LeftBackground.restore(); + ctx.restore(); if (me.phase==2 && Math.random()<0.03 && Game.prefs.particles) { Game.particleAdd(me.x,me.y,Math.random()*4-2,Math.random()*-2-2,Math.random()*0.5+0.5,1,2); } - } + + if (me.selected) selected=me; + } + } + if (selected && Game.Has('Eye of the wrinkler')) + { + var x=Game.cookieOriginX; + var y=Game.cookieOriginY; + ctx.font='14px Merriweather'; + ctx.textAlign='center'; + var width=Math.max(ctx.measureText('Swallowed :').width,ctx.measureText(Beautify(selected.sucked)).width); + ctx.fillStyle='#000'; + ctx.strokeStyle='#000'; + ctx.lineWidth=8; + ctx.globalAlpha=0.5; + ctx.beginPath(); + ctx.moveTo(x,y); + ctx.lineTo(Math.floor(selected.x),Math.floor(selected.y)); + ctx.stroke(); + ctx.fillRect(x-width/2-8-14,y-23,width+16+28,38); + ctx.globalAlpha=1; + ctx.fillStyle='#fff'; + ctx.fillText('Swallowed :',x+14,y-8); + ctx.fillText(Beautify(selected.sucked),x+14,y+8); + ctx.drawImage(Pic('icons.png'),27*48,26*48,48,48,x-width/2-8-22,y-4-24,48,48); } } Game.SaveWrinklers=function() @@ -9555,10 +11684,10 @@ Game.Launch=function() } Game.santaLevels=['Festive test tube','Festive ornament','Festive wreath','Festive tree','Festive present','Festive elf fetus','Elf toddler','Elfling','Young elf','Bulky elf','Nick','Santa Claus','Elder Santa','True Santa','Final Claus']; - Game.santaDrops=['Increased merriness','Improved jolliness','A lump of coal','An itchy sweater','Reindeer baking grounds','Weighted sleighs','Ho ho ho-flavored frosting','Season savings','Toy workshop','Naughty list','Santa\'s bottomless bag','Santa\'s helpers','Santa\'s legacy','Santa\'s milk and cookies']; for (var i in Game.santaDrops)//scale christmas upgrade prices with santa level {Game.Upgrades[Game.santaDrops[i]].priceFunc=function(){return Math.pow(3,Game.santaLevel)*2525;}} + Game.UpgradeSanta=function() { var moni=Math.pow(Game.santaLevel+1,Game.santaLevel+1); @@ -9628,7 +11757,7 @@ Game.Launch=function() cost:function(){return Game.Objects['Farm'].amount>=100;}, buy:function(){Game.Objects['Farm'].sacrifice(100);}, costStr:function(){return '100 farms';}}, - {name:'Krumblor, cookie dragon',action:'Train Earth Shatterer
Aura : buildings sell back for 85% instead of 50%',pic:5, + {name:'Krumblor, cookie dragon',action:'Train Earth Shatterer
Aura : buildings sell back for 50% instead of 25%',pic:5, cost:function(){return Game.Objects['Mine'].amount>=100;}, buy:function(){Game.Objects['Mine'].sacrifice(100);}, costStr:function(){return '100 mines';}}, @@ -9672,19 +11801,27 @@ Game.Launch=function() cost:function(){return Game.Objects['Prism'].amount>=100;}, buy:function(){Game.Objects['Prism'].sacrifice(100);}, costStr:function(){return '100 prisms';}}, - {name:'Krumblor, cookie dragon',action:'Train Dragon\'s Fortune
Aura : +111% CpS per golden cookie on-screen',pic:5, + {name:'Krumblor, cookie dragon',action:'Train Dragon\'s Fortune
Aura : +123% CpS per golden cookie on-screen',pic:5, cost:function(){return Game.Objects['Chancemaker'].amount>=100;}, buy:function(){Game.Objects['Chancemaker'].sacrifice(100);}, costStr:function(){return '100 chancemakers';}}, + {name:'Krumblor, cookie dragon',action:'Train Dragon\'s Curve
Aura : sugar lumps grow 5% faster, 50% weirder',pic:5, + cost:function(){return Game.Objects['Fractal engine'].amount>=100;}, + buy:function(){Game.Objects['Fractal engine'].sacrifice(100);}, + costStr:function(){return '100 fractal engines';}}, + {name:'Krumblor, cookie dragon',action:'Train Reality Bending
Aura : 10% of every other aura, combined',pic:5, + cost:function(){return Game.Objects['Javascript console'].amount>=100;}, + buy:function(){Game.Objects['Javascript console'].sacrifice(100);}, + costStr:function(){return '100 javascript consoles';}}, {name:'Krumblor, cookie dragon',action:'Bake dragon cookie
Delicious!',pic:6, cost:function(){var fail=0;for (var i in Game.Objects){if (Game.Objects[i].amount<50) fail=1;}return (fail==0);}, buy:function(){for (var i in Game.Objects){Game.Objects[i].sacrifice(50);}Game.Unlock('Dragon cookie');}, costStr:function(){return '50 of every building';}}, - {name:'Krumblor, cookie dragon',action:'Train secondary aura
Lets you use two dragon auras simultaneously',pic:6, + {name:'Krumblor, cookie dragon',action:'Train secondary aura
Lets you use two dragon auras simultaneously',pic:7, cost:function(){var fail=0;for (var i in Game.Objects){if (Game.Objects[i].amount<200) fail=1;}return (fail==0);}, buy:function(){for (var i in Game.Objects){Game.Objects[i].sacrifice(200);}}, costStr:function(){return '200 of every building';}}, - {name:'Krumblor, cookie dragon',action:'Your dragon is fully trained.',pic:7} + {name:'Krumblor, cookie dragon',action:'Your dragon is fully trained.',pic:8} ]; Game.dragonAuras={ @@ -9693,7 +11830,7 @@ Game.Launch=function() 2:{name:'Dragon Cursor',pic:[0,25],desc:'Clicking is 5% more effective.'}, 3:{name:'Elder Battalion',pic:[1,25],desc:'Grandmas gain +1% CpS for every non-grandma building.'}, 4:{name:'Reaper of Fields',pic:[2,25],desc:'Golden cookies may trigger a Dragon Harvest.'}, - 5:{name:'Earth Shatterer',pic:[3,25],desc:'Buildings sell back for 85% instead of 50%.'}, + 5:{name:'Earth Shatterer',pic:[3,25],desc:'Buildings sell back for 50% instead of 25%.'}, 6:{name:'Master of the Armory',pic:[4,25],desc:'All upgrades are 2% cheaper.'}, 7:{name:'Fierce Hoarder',pic:[15,25],desc:'All buildings are 2% cheaper.'}, 8:{name:'Dragon God',pic:[16,25],desc:'Prestige CpS bonus +5%.'}, @@ -9704,13 +11841,22 @@ Game.Launch=function() 13:{name:'Epoch Manipulator',pic:[8,25],desc:'Golden cookies last 5% longer.'}, 14:{name:'Mind Over Matter',pic:[13,25],desc:'Random drops are 25% more common.'}, 15:{name:'Radiant Appetite',pic:[14,25],desc:'All cookie production multiplied by 2.'}, - 16:{name:'Dragon\'s Fortune',pic:[19,25],desc:'+111% CpS per golden cookie on-screen, multiplicative.'}, + 16:{name:'Dragon\'s Fortune',pic:[19,25],desc:'+123% CpS per golden cookie on-screen, multiplicative.'}, + 17:{name:'Dragon\'s Curve',pic:[20,25],desc:'+5% sugar lump growth and sugar lumps are twice as likely to be unusual.'}, + 18:{name:'Reality Bending',pic:[32,25],desc:'One tenth of every other dragon aura, combined.'}, }; Game.hasAura=function(what) { if (Game.dragonAuras[Game.dragonAura].name==what || Game.dragonAuras[Game.dragonAura2].name==what) return true; else return false; } + Game.auraMult=function(what) + { + var n=0; + if (Game.dragonAuras[Game.dragonAura].name==what || Game.dragonAuras[Game.dragonAura2].name==what) n=1; + if (Game.dragonAuras[Game.dragonAura].name=='Reality Bending' || Game.dragonAuras[Game.dragonAura2].name=='Reality Bending') n+=0.1; + return n; + } Game.SelectDragonAura=function(slot,update) { @@ -9726,7 +11872,7 @@ Game.Launch=function() if (Game.dragonLevel>=parseInt(i)+4) { var icon=Game.dragonAuras[i].pic; - if (i==0 || i!=otherAura) str+='
'; } } @@ -9781,8 +11927,8 @@ Game.Launch=function() var pic=''; var frame=0; if (Game.specialTab=='santa') {pic='santa.png';frame=Game.santaLevel;} - else if (Game.specialTab=='dragon') {pic='dragon.png';frame=Game.dragonLevels[Game.dragonLevel].pic;} - else {pic='dragon.png';frame=4;} + else if (Game.specialTab=='dragon') {pic='dragon.png?v='+Game.version;frame=Game.dragonLevels[Game.dragonLevel].pic;} + else {pic='dragon.png?v='+Game.version;frame=4;} var str='
'; str+='
x
'; @@ -9811,7 +11957,7 @@ Game.Launch=function() if (Game.dragonLevel>=5) { var icon=Game.dragonAuras[Game.dragonAura].pic; - str+='

'+Game.dragonAuras[Game.dragonAura].name+'

'+ '
'+ Game.dragonAuras[Game.dragonAura].desc+ @@ -9819,10 +11965,10 @@ Game.Launch=function() ,'top')+ '>
'; } - if (Game.dragonLevel>=22) + if (Game.dragonLevel>=24)//2nd aura slot; increased with last building (javascript consoles) { var icon=Game.dragonAuras[Game.dragonAura2].pic; - str+='

'+Game.dragonAuras[Game.dragonAura2].name+'

'+ '
'+ Game.dragonAuras[Game.dragonAura2].desc+ @@ -9883,8 +12029,8 @@ Game.Launch=function() if (selected) {s=1;x=48;} if (Game.specialTabs[i]=='santa') {pic='santa.png';frame=Game.santaLevel;} - else if (Game.specialTabs[i]=='dragon') {pic='dragon.png';frame=Game.dragonLevels[Game.dragonLevel].pic;} - else {pic='dragon.png';frame=4;} + else if (Game.specialTabs[i]=='dragon') {pic='dragon.png?v='+Game.version;frame=Game.dragonLevels[Game.dragonLevel].pic;} + else {pic='dragon.png?v='+Game.version;frame=4;} if (hovered || selected) { @@ -9912,17 +12058,24 @@ Game.Launch=function() =======================================================================================*/ Game.Milks=[ - {name:'Rank I - Plain milk',pic:'milkPlain'}, - {name:'Rank II - Chocolate milk',pic:'milkChocolate'}, - {name:'Rank III - Raspberry milk',pic:'milkRaspberry'}, - {name:'Rank IV - Orange milk',pic:'milkOrange'}, - {name:'Rank V - Caramel milk',pic:'milkCaramel'}, - {name:'Rank VI - Banana milk',pic:'milkBanana'}, - {name:'Rank VII - Lime milk',pic:'milkLime'}, - {name:'Rank VIII - Blueberry milk',pic:'milkBlueberry'}, - {name:'Rank IX - Strawberry milk',pic:'milkStrawberry'}, - {name:'Rank X - Vanilla milk',pic:'milkVanilla'}, - {name:'Rank XI - Honey milk',pic:'milkHoney'}, + {name:'Rank I - Plain milk',pic:'milkPlain',icon:[1,8]}, + {name:'Rank II - Chocolate milk',pic:'milkChocolate',icon:[2,8]}, + {name:'Rank III - Raspberry milk',pic:'milkRaspberry',icon:[3,8]}, + {name:'Rank IV - Orange milk',pic:'milkOrange',icon:[4,8]}, + {name:'Rank V - Caramel milk',pic:'milkCaramel',icon:[5,8]}, + {name:'Rank VI - Banana milk',pic:'milkBanana',icon:[6,8]}, + {name:'Rank VII - Lime milk',pic:'milkLime',icon:[7,8]}, + {name:'Rank VIII - Blueberry milk',pic:'milkBlueberry',icon:[8,8]}, + {name:'Rank IX - Strawberry milk',pic:'milkStrawberry',icon:[9,8]}, + {name:'Rank X - Vanilla milk',pic:'milkVanilla',icon:[10,8]}, + {name:'Rank XI - Honey milk',pic:'milkHoney',icon:[21,23]}, + {name:'Rank XII - Coffee milk',pic:'milkCoffee',icon:[22,23]}, + {name:'Rank XIII - Tea with a spot of milk',pic:'milkTea',icon:[23,23]}, + {name:'Rank XIV - Coconut milk',pic:'milkCoconut',icon:[24,23]}, + {name:'Rank XV - Cherry milk',pic:'milkCherry',icon:[25,23]}, + {name:'Rank XVI - Spiced milk',pic:'milkSpiced',icon:[26,23]}, + {name:'Rank XVII - Maple milk',pic:'milkMaple',icon:[28,23]}, + {name:'Rank XVIII - Mint milk',pic:'milkMint',icon:[29,23]}, ]; Game.Milk=Game.Milks[0]; @@ -9932,6 +12085,7 @@ Game.Launch=function() Game.cookieOriginY=0; Game.DrawBackground=function() { + Timer.clean(); //background if (!Game.Background)//init some stuff @@ -9957,6 +12111,7 @@ Game.Launch=function() }); } + var ctx=Game.LeftBackground; if (Game.OnAscend) { @@ -10108,24 +12263,24 @@ Game.Launch=function() Timer.track('window background'); //clear - Game.LeftBackground.clearRect(0,0,Game.LeftBackground.canvas.width,Game.LeftBackground.canvas.height); - /*if (Game.AscendTimer=1) opacity=1-((Math.min(Game.elderWrathD,1.5)-1)/0.5); - Game.LeftBackground.globalAlpha=opacity; + ctx.globalAlpha=opacity; var y=(Math.floor(Game.T*2)%512); - Game.LeftBackground.fillPattern(Pic(pic),0,0,Game.LeftBackground.canvas.width,Game.LeftBackground.canvas.height+512,512,512,0,y); - Game.LeftBackground.globalAlpha=1; + ctx.fillPattern(Pic(pic),0,0,ctx.canvas.width,ctx.canvas.height+512,512,512,0,y); + ctx.globalAlpha=1; } //snow if (Game.season=='christmas') { var y=(Math.floor(Game.T*2.5)%512); - Game.LeftBackground.globalAlpha=0.75; - Game.LeftBackground.globalCompositeOperation='lighter'; - Game.LeftBackground.fillPattern(Pic('snow2.jpg'),0,0,Game.LeftBackground.canvas.width,Game.LeftBackground.canvas.height+512,512,512,0,y); - Game.LeftBackground.globalCompositeOperation='source-over'; - Game.LeftBackground.globalAlpha=1; + ctx.globalAlpha=0.75; + ctx.globalCompositeOperation='lighter'; + ctx.fillPattern(Pic('snow2.jpg'),0,0,ctx.canvas.width,ctx.canvas.height+512,512,512,0,y); + ctx.globalCompositeOperation='source-over'; + ctx.globalAlpha=1; } //hearts if (Game.season=='valentines') { var y=(Math.floor(Game.T*2.5)%512); - Game.LeftBackground.globalAlpha=1; - Game.LeftBackground.fillPattern(Pic('heartStorm.png'),0,0,Game.LeftBackground.canvas.width,Game.LeftBackground.canvas.height+512,512,512,0,y); - Game.LeftBackground.globalAlpha=1; + ctx.globalAlpha=1; + ctx.fillPattern(Pic('heartStorm.png'),0,0,ctx.canvas.width,ctx.canvas.height+512,512,512,0,y); + ctx.globalAlpha=1; } Timer.track('left background'); Game.particlesDraw(0); - Game.LeftBackground.globalAlpha=1; + ctx.globalAlpha=1; Timer.track('particles'); //big cookie shine @@ -10180,29 +12335,29 @@ Game.Launch=function() var y=Game.cookieOriginY; var r=Math.floor((Game.T*0.5)%360); - Game.LeftBackground.save(); - Game.LeftBackground.translate(x,y); - Game.LeftBackground.rotate((r/360)*Math.PI*2); + ctx.save(); + ctx.translate(x,y); + ctx.rotate((r/360)*Math.PI*2); var alphaMult=1; if (Game.bgType==2 || Game.bgType==4) alphaMult=0.5; var pic='shine.png'; if (goodBuff) {pic='shineGold.png';alphaMult=1;} else if (badBuff) {pic='shineRed.png';alphaMult=1;} - if (goodBuff && Game.prefs.fancy) Game.LeftBackground.globalCompositeOperation='lighter'; - Game.LeftBackground.globalAlpha=0.5*alphaMult; - Game.LeftBackground.drawImage(Pic(pic),-s/2,-s/2,s,s); - Game.LeftBackground.rotate((-r*2/360)*Math.PI*2); - Game.LeftBackground.globalAlpha=0.25*alphaMult; - Game.LeftBackground.drawImage(Pic(pic),-s/2,-s/2,s,s); - Game.LeftBackground.restore(); + if (goodBuff && Game.prefs.fancy) ctx.globalCompositeOperation='lighter'; + ctx.globalAlpha=0.5*alphaMult; + ctx.drawImage(Pic(pic),-s/2,-s/2,s,s); + ctx.rotate((-r*2/360)*Math.PI*2); + ctx.globalAlpha=0.25*alphaMult; + ctx.drawImage(Pic(pic),-s/2,-s/2,s,s); + ctx.restore(); Timer.track('shine'); if (Game.ReincarnateTimer>0) { - Game.LeftBackground.globalAlpha=1-Game.ReincarnateTimer/Game.ReincarnateDuration; - Game.LeftBackground.fillStyle='#000'; - Game.LeftBackground.fillRect(0,0,Game.LeftBackground.canvas.width,Game.LeftBackground.canvas.height); - Game.LeftBackground.globalAlpha=1; + ctx.globalAlpha=1-Game.ReincarnateTimer/Game.ReincarnateDuration; + ctx.fillStyle='#000'; + ctx.fillRect(0,0,ctx.canvas.width,ctx.canvas.height); + ctx.globalAlpha=1; } if (showDragon) @@ -10211,13 +12366,13 @@ Game.Launch=function() var s=300*2*(1+Math.sin(Game.T*0.013)*0.1); var x=Game.cookieOriginX-s/2; var y=Game.cookieOriginY-s/(1.4+0.2*Math.sin(Game.T*0.01)); - Game.LeftBackground.drawImage(Pic('dragonBG.png'),x,y,s,s); + ctx.drawImage(Pic('dragonBG.png'),x,y,s,s); } //big cookie if (false)//don't do that { - Game.LeftBackground.globalAlpha=1; + ctx.globalAlpha=1; var amount=Math.floor(Game.cookies).toString(); var digits=amount.length; var space=0; @@ -10234,42 +12389,42 @@ Game.Launch=function() var spin=Game.T*(0.005+i*0.001)+i+(ii/num)*Math.PI*2; x+=Math.sin(spin)*space; y+=Math.cos(spin)*space; - Game.LeftBackground.drawImage(Pic('perfectCookie.png'),x-s/2,y-s/2,s,s); + ctx.drawImage(Pic('perfectCookie.png'),x-s/2,y-s/2,s,s); } space+=s/2; } } else { - Game.LeftBackground.globalAlpha=1; + ctx.globalAlpha=1; var s=256*Game.BigCookieSize; var x=Game.cookieOriginX; var y=Game.cookieOriginY; - Game.LeftBackground.save(); - Game.LeftBackground.translate(x,y); + ctx.save(); + ctx.translate(x,y); if (Game.season=='easter') { var nestW=304*0.98*Game.BigCookieSize; var nestH=161*0.98*Game.BigCookieSize; - Game.LeftBackground.drawImage(Pic('nest.png'),-nestW/2,-nestH/2+130,nestW,nestH); + ctx.drawImage(Pic('nest.png'),-nestW/2,-nestH/2+130,nestW,nestH); } - //Game.LeftBackground.rotate(((Game.startDate%360)/360)*Math.PI*2); - Game.LeftBackground.drawImage(Pic('perfectCookie.png'),-s/2,-s/2,s,s); + //ctx.rotate(((Game.startDate%360)/360)*Math.PI*2); + ctx.drawImage(Pic('perfectCookie.png'),-s/2,-s/2,s,s); if (goodBuff && Game.prefs.particles)//sparkle { - Game.LeftBackground.globalCompositeOperation='lighter'; + ctx.globalCompositeOperation='lighter'; for (var i=0;i<1;i++) { - Game.LeftBackground.globalAlpha=Math.random()*0.65+0.1; + ctx.globalAlpha=Math.random()*0.65+0.1; var size=Math.random()*30+5; var a=Math.random()*Math.PI*2; var d=s*0.9*Math.random()/2; - Game.LeftBackground.drawImage(Pic('glint.jpg'),-size/2+Math.sin(a)*d,-size/2+Math.cos(a)*d,size,size); + ctx.drawImage(Pic('glint.jpg'),-size/2+Math.sin(a)*d,-size/2+Math.cos(a)*d,size,size); } } - Game.LeftBackground.restore(); + ctx.restore(); Timer.track('big cookie'); } } @@ -10279,8 +12434,8 @@ Game.Launch=function() var s=512; var x=Game.cookieOriginX-s/2; var y=Game.cookieOriginY-s/2; - Game.LeftBackground.globalAlpha=0.5; - Game.LeftBackground.drawImage(Pic('shine.png'),x,y,s,s); + ctx.globalAlpha=0.5; + ctx.drawImage(Pic('shine.png'),x,y,s,s); if (showDragon) { @@ -10288,54 +12443,58 @@ Game.Launch=function() var s=300*2*(1+Math.sin(Game.T*0.013)*0.1); var x=Game.cookieOriginX-s/2; var y=Game.cookieOriginY-s/(1.4+0.2*Math.sin(Game.T*0.01)); - Game.LeftBackground.drawImage(Pic('dragonBG.png'),x,y,s,s); + ctx.drawImage(Pic('dragonBG.png'),x,y,s,s); } //big cookie - Game.LeftBackground.globalAlpha=1; + ctx.globalAlpha=1; var s=256*Game.BigCookieSize; var x=Game.cookieOriginX-s/2; var y=Game.cookieOriginY-s/2; - Game.LeftBackground.drawImage(Pic('perfectCookie.png'),x,y,s,s); + ctx.drawImage(Pic('perfectCookie.png'),x,y,s,s); } //cursors if (Game.prefs.cursors) { - if (showDragon) Game.LeftBackground.globalAlpha=0.25; + ctx.save(); + ctx.translate(Game.cookieOriginX,Game.cookieOriginY); + var pic=Pic('cursor.png'); + var fancy=Game.prefs.fancy; + + if (showDragon) ctx.globalAlpha=0.25; var amount=Game.Objects['Cursor'].amount; - var spe=-1; + //var spe=-1; for (var i=0;i0.997) w=1.5; else if (w>0.994) w=0.5; else w=0; w*=-4; - if (Game.prefs.fancy) w+=Math.sin((n+Game.T*0.01)*Math.PI/2)*4; - if (Game.prefs.fancy) r=(-(a)*360-Game.T*0.1); + if (fancy) w+=Math.sin((n+Game.T*0.01)*Math.PI/2)*4; var x=0; var y=(140/* *Game.BigCookieSize*/+n*16+w)-16; - - Game.LeftBackground.save(); - Game.LeftBackground.translate(Game.cookieOriginX,Game.cookieOriginY); - Game.LeftBackground.rotate((r/360)*Math.PI*2); - Game.LeftBackground.drawImage(Pic('cursor.png'),32*(i==spe),0,32,32,x,y,32,32); - Game.LeftBackground.restore(); + var rot=7.2;//(1/50)*360 + if (i==0 && fancy) rot-=Game.T*0.1; + if (i%50==0) rot+=7.2/2; + ctx.rotate((rot/360)*Math.PI*2); + ctx.drawImage(pic,0,0,32,32,x,y,32,32); + //ctx.drawImage(pic,32*(i==spe),0,32,32,x,y,32,32); /*if (i==spe) { y+=16; x=Game.cookieOriginX+Math.sin(-((r-5)/360)*Math.PI*2)*y; y=Game.cookieOriginY+Math.cos(-((r-5)/360)*Math.PI*2)*y; - if (Game.CanClick && Game.LeftBackground && Math.abs(Game.mouseX-x)<16 && Math.abs(Game.mouseY-y)<16) Game.mousePointer=1; + if (Game.CanClick && ctx && Math.abs(Game.mouseX-x)<16 && Math.abs(Game.mouseY-y)<16) Game.mousePointer=1; }*/ } + ctx.restore(); Timer.track('cursors'); } } @@ -10350,7 +12509,7 @@ Game.Launch=function() if (Game.AscendTimer0) { - Game.LeftBackground.save(); - Game.LeftBackground.globalAlpha=1-Math.pow(t,0.5); - Game.LeftBackground.translate(x,y); - Game.LeftBackground.globalCompositeOperation='lighter'; - Game.LeftBackground.rotate(Game.T*0.007); + ctx.save(); + ctx.globalAlpha=1-Math.pow(t,0.5); + ctx.translate(x,y); + ctx.globalCompositeOperation='lighter'; + ctx.rotate(Game.T*0.007); s=0.5+Math.pow(tBase,0.6)*1; var s2=(600)*s; - Game.LeftBackground.drawImage(Pic('heavenRing1.jpg'),-s2/2,-s2/2,s2,s2); - Game.LeftBackground.rotate(-Game.T*0.002); + ctx.drawImage(Pic('heavenRing1.jpg'),-s2/2,-s2/2,s2,s2); + ctx.rotate(-Game.T*0.002); s=0.5+Math.pow(1-tBase,0.4)*1; s2=(600)*s; - Game.LeftBackground.drawImage(Pic('heavenRing2.jpg'),-s2/2,-s2/2,s2,s2); - Game.LeftBackground.restore(); + ctx.drawImage(Pic('heavenRing2.jpg'),-s2/2,-s2/2,s2,s2); + ctx.restore(); } s=256;//*Game.BigCookieSize; - Game.LeftBackground.save(); - Game.LeftBackground.translate(x,y); - Game.LeftBackground.rotate((t*(-0.1))*Math.PI*2); + ctx.save(); + ctx.translate(x,y); + ctx.rotate((t*(-0.1))*Math.PI*2); var chunks={0:7,1:6,2:3,3:2,4:8,5:1,6:9,7:5,8:0,9:4}; s*=t/2+1; - /*Game.LeftBackground.globalAlpha=(1-t)*0.33; + /*ctx.globalAlpha=(1-t)*0.33; for (var i=0;i<10;i++) { var d=(t-0.2)*(80+((i+2)%3)*40); - Game.LeftBackground.drawImage(Pic('brokenCookie.png'),256*(chunks[i]),0,256,256,-s/2+Math.sin(-(((chunks[i]+4)%10)/10)*Math.PI*2)*d,-s/2+Math.cos(-(((chunks[i]+4)%10)/10)*Math.PI*2)*d,s,s); + ctx.drawImage(Pic('brokenCookie.png'),256*(chunks[i]),0,256,256,-s/2+Math.sin(-(((chunks[i]+4)%10)/10)*Math.PI*2)*d,-s/2+Math.cos(-(((chunks[i]+4)%10)/10)*Math.PI*2)*d,s,s); } - Game.LeftBackground.globalAlpha=(1-t)*0.66; + ctx.globalAlpha=(1-t)*0.66; for (var i=0;i<10;i++) { var d=(t-0.1)*(80+((i+2)%3)*40); - Game.LeftBackground.drawImage(Pic('brokenCookie.png'),256*(chunks[i]),0,256,256,-s/2+Math.sin(-(((chunks[i]+4)%10)/10)*Math.PI*2)*d,-s/2+Math.cos(-(((chunks[i]+4)%10)/10)*Math.PI*2)*d,s,s); + ctx.drawImage(Pic('brokenCookie.png'),256*(chunks[i]),0,256,256,-s/2+Math.sin(-(((chunks[i]+4)%10)/10)*Math.PI*2)*d,-s/2+Math.cos(-(((chunks[i]+4)%10)/10)*Math.PI*2)*d,s,s); }*/ - Game.LeftBackground.globalAlpha=1-t; + ctx.globalAlpha=1-t; for (var i=0;i<10;i++) { var d=(t)*(80+((i+2)%3)*40); var x2=(Math.random()*2-1)*5*shake; var y2=(Math.random()*2-1)*5*shake; - Game.LeftBackground.drawImage(Pic('brokenCookie.png'),256*(chunks[i]),0,256,256,-s/2+Math.sin(-(((chunks[i]+4)%10)/10)*Math.PI*2)*d+x2,-s/2+Math.cos(-(((chunks[i]+4)%10)/10)*Math.PI*2)*d+y2,s,s); + ctx.drawImage(Pic('brokenCookie.png'),256*(chunks[i]),0,256,256,-s/2+Math.sin(-(((chunks[i]+4)%10)/10)*Math.PI*2)*d+x2,-s/2+Math.cos(-(((chunks[i]+4)%10)/10)*Math.PI*2)*d+y2,s,s); } var brokenHalo=1-Math.min(t/(1/3),1/3)*3; if (Game.AscendTimer0) { - Game.LeftBackground.globalAlpha=1-tBase/0.1; - Game.LeftBackground.fillStyle='#fff'; - Game.LeftBackground.fillRect(0,0,Game.LeftBackground.canvas.width,Game.LeftBackground.canvas.height); - Game.LeftBackground.globalAlpha=1; + ctx.globalAlpha=1-tBase/0.1; + ctx.fillStyle='#fff'; + ctx.fillRect(0,0,ctx.canvas.width,ctx.canvas.height); + ctx.globalAlpha=1; } if (tBase>0.8) { - Game.LeftBackground.globalAlpha=(tBase-0.8)/0.2; - Game.LeftBackground.fillStyle='#000'; - Game.LeftBackground.fillRect(0,0,Game.LeftBackground.canvas.width,Game.LeftBackground.canvas.height); - Game.LeftBackground.globalAlpha=1; + ctx.globalAlpha=(tBase-0.8)/0.2; + ctx.fillStyle='#000'; + ctx.fillRect(0,0,ctx.canvas.width,ctx.canvas.height); + ctx.globalAlpha=1; } } //milk and milk accessories if (Game.prefs.milk) { - var width=Game.LeftBackground.canvas.width; - var height=Game.LeftBackground.canvas.height; + var width=ctx.canvas.width; + var height=ctx.canvas.height; var x=Math.floor((Game.T*2-(Game.milkH-Game.milkHd)*2000+480*2)%480);//Math.floor((Game.T*2+Math.sin(Game.T*0.1)*2+Math.sin(Game.T*0.03)*2-(Game.milkH-Game.milkHd)*2000+480*2)%480); - var y=(Game.milkHd)*height;//(((Game.milkHd)*Game.LeftBackground.canvas.height)*(1+0.05*(Math.sin(Game.T*0.017)/2+0.5))); + var y=(Game.milkHd)*height;//(((Game.milkHd)*ctx.canvas.height)*(1+0.05*(Math.sin(Game.T*0.017)/2+0.5))); var a=1; if (Game.AscendTimer>0) { @@ -10513,18 +12672,18 @@ Game.Launch=function() new Game.Toy(Math.random()*width,Math.random()*height*0.3); } } - Game.LeftBackground.globalAlpha=0.5; + ctx.globalAlpha=0.5; for (var i in Game.toys) { var me=Game.toys[i]; - Game.LeftBackground.save(); - Game.LeftBackground.translate(me.x,me.y); - Game.LeftBackground.rotate(me.r); - if (Game.toysType==1) Game.LeftBackground.drawImage(Pic('smallCookies.png'),(me.id%8)*64,0,64,64,-me.s/2,-me.s/2,me.s,me.s); - else Game.LeftBackground.drawImage(Pic('icons.png'),me.icon[0]*48,me.icon[1]*48,48,48,-me.s/2,-me.s/2,me.s,me.s); - Game.LeftBackground.restore(); + ctx.save(); + ctx.translate(me.x,me.y); + ctx.rotate(me.r); + if (Game.toysType==1) ctx.drawImage(Pic('smallCookies.png'),(me.id%8)*64,0,64,64,-me.s/2,-me.s/2,me.s,me.s); + else ctx.drawImage(Pic('icons.png'),me.icon[0]*48,me.icon[1]*48,48,48,-me.s/2,-me.s/2,me.s,me.s); + ctx.restore(); } - Game.LeftBackground.globalAlpha=1; + ctx.globalAlpha=1; for (var i in Game.toys) { var me=Game.toys[i]; @@ -10597,30 +12756,30 @@ Game.Launch=function() else me.l.style.transform='translate('+(me.x-me.s/2)+'px,'+(me.y-me.s/2)+'px)'; me.l.style.width=me.s+'px'; me.l.style.height=me.s+'px'; - Game.LeftBackground.save(); - Game.LeftBackground.translate(me.x,me.y); - Game.LeftBackground.rotate(me.r); - if (Game.toysType==1) Game.LeftBackground.drawImage(Pic('smallCookies.png'),(me.id%8)*64,0,64,64,-me.s/2,-me.s/2,me.s,me.s); - else Game.LeftBackground.drawImage(Pic('icons.png'),me.icon[0]*48,me.icon[1]*48,48,48,-me.s/2,-me.s/2,me.s,me.s); - Game.LeftBackground.restore(); + ctx.save(); + ctx.translate(me.x,me.y); + ctx.rotate(me.r); + if (Game.toysType==1) ctx.drawImage(Pic('smallCookies.png'),(me.id%8)*64,0,64,64,-me.s/2,-me.s/2,me.s,me.s); + else ctx.drawImage(Pic('icons.png'),me.icon[0]*48,me.icon[1]*48,48,48,-me.s/2,-me.s/2,me.s,me.s); + ctx.restore(); } } var pic=Game.Milk.pic; if (Game.milkType!=0 && Game.ascensionMode!=1) pic=Game.MilksByChoice[Game.milkType].pic; - Game.LeftBackground.globalAlpha=0.9*a; - Game.LeftBackground.fillPattern(Pic(pic+'.png'),0,height-y,width+480,1,480,480,x,0); + ctx.globalAlpha=0.9*a; + ctx.fillPattern(Pic(pic+'.png'),0,height-y,width+480,1,480,480,x,0); - Game.LeftBackground.fillStyle='#000'; - Game.LeftBackground.fillRect(0,height-y+480,width,Math.max(0,(y-480))); - Game.LeftBackground.globalAlpha=1; + ctx.fillStyle='#000'; + ctx.fillRect(0,height-y+480,width,Math.max(0,(y-480))); + ctx.globalAlpha=1; Timer.track('milk'); } if (Game.AscendTimer>0) { - Game.LeftBackground.drawImage(Pic('shadedBordersSoft.png'),0,0,Game.LeftBackground.canvas.width,Game.LeftBackground.canvas.height); + ctx.drawImage(Pic('shadedBordersSoft.png'),0,0,ctx.canvas.width,ctx.canvas.height); } if (Game.AscendTimer==0) @@ -10631,13 +12790,13 @@ Game.Launch=function() Game.particlesDraw(2);Timer.track('text particles'); //shiny border during frenzies etc - Game.LeftBackground.globalAlpha=1; + ctx.globalAlpha=1; var borders='shadedBordersSoft.png'; if (goodBuff) borders='shadedBordersGold.png'; else if (badBuff) borders='shadedBordersRed.png'; - if (goodBuff && Game.prefs.fancy) Game.LeftBackground.globalCompositeOperation='lighter'; - Game.LeftBackground.drawImage(Pic(borders),0,0,Game.LeftBackground.canvas.width,Game.LeftBackground.canvas.height); - if (goodBuff && Game.prefs.fancy) Game.LeftBackground.globalCompositeOperation='source-over'; + if (goodBuff && Game.prefs.fancy) ctx.globalCompositeOperation='lighter'; + ctx.drawImage(Pic(borders),0,0,ctx.canvas.width,ctx.canvas.height); + if (goodBuff && Game.prefs.fancy) ctx.globalCompositeOperation='source-over'; } } }; @@ -10653,16 +12812,9 @@ Game.Launch=function() Game.RuinTheFun=function(silent) { Game.popups=0; - var leftout=['Magic shenanigans','Occult obstruction']; - for (var i in Game.Upgrades) - { - if (Game.Upgrades[i].pool=='toggle' || leftout.indexOf(Game.Upgrades[i].name)!=-1) {} - else Game.Upgrades[i].earn(); - } - for (var i in Game.Achievements) - { - if (Game.Achievements[i].pool!='dungeon') Game.Win(Game.Achievements[i].name); - } + Game.SetAllUpgrades(1); + Game.SetAllAchievs(1); + Game.popups=0; Game.Earn(999999999999999999999999999999); Game.MaxSpecials(); Game.nextResearch=0; @@ -10670,17 +12822,23 @@ Game.Launch=function() Game.upgradesToRebuild=1; Game.recalculateGains=1; Game.popups=1; + for (var i in Game.Objects) + { + var me=Game.Objects[i]; + if (me.minigame && me.minigame.onRuinTheFun) me.minigame.onRuinTheFun(); + } if (!silent) { if (Game.prefs.popups) Game.Popup('Thou doth ruineth the fun!'); else Game.Notify('Thou doth ruineth the fun!','You\'re free. Free at last.',[11,5]); } + return 'You feel a bitter taste in your mouth...'; } Game.SetAllUpgrades=function(on) { Game.popups=0; - var leftout=['Magic shenanigans','Occult obstruction']; + var leftout=['Magic shenanigans','Occult obstruction','Glucose-charged air']; for (var i in Game.Upgrades) { if (on && (Game.Upgrades[i].pool=='toggle' || leftout.indexOf(Game.Upgrades[i].name)!=-1)) {} @@ -10696,7 +12854,7 @@ Game.Launch=function() Game.popups=0; for (var i in Game.Achievements) { - if (on) Game.Win(Game.Achievements[i].name); + if (on && Game.Achievements[i].pool!='dungeon') Game.Win(Game.Achievements[i].name); else if (!on) Game.RemoveAchiev(Game.Achievements[i].name); } Game.recalculateGains=1; @@ -10760,8 +12918,11 @@ Game.Launch=function() str+='All achievs
'; str+='Reset specials'; str+='Max specials
'; + str+='Reset refills'; str+=''+(Game.DebuggingPrestige?'Exit Ascend Edit':'Ascend Edit')+''; str+='Debug upgrades CpS'; + str+='Re-seed'; + str+='Max heralds'; str+='
'; for (var i=0;i=7) Game.Unlock('Kitten experts'); if (Game.milkProgress>=8) Game.Unlock('Kitten consultants'); if (Game.milkProgress>=9) Game.Unlock('Kitten assistants to the regional manager'); + if (Game.milkProgress>=10) Game.Unlock('Kitten marketeers'); + if (Game.milkProgress>=11) Game.Unlock('Kitten analysts'); + if (Game.milkProgress>=12) Game.Unlock('Kitten executives'); Game.milkH=Math.min(1,Game.milkProgress)*0.35; Game.milkHd+=(Game.milkH-Game.milkHd)*0.02; @@ -11003,6 +13188,7 @@ Game.Launch=function() var timePlayed=new Date(); timePlayed.setTime(Date.now()-Game.startDate); + if (!Game.fullDate || (Date.now()-Game.fullDate)>=365*24*60*60*1000) Game.Win('So much to do so much to see'); if (Game.cookiesEarned>=1000000 && (Game.ascensionMode==1 || Game.resets==0))//challenge run or hasn't ascended yet { @@ -11028,6 +13214,8 @@ Game.Launch=function() } if (Game.Has('Golden switch')) Game.Unlock('Golden switch [off]'); + if (Game.Has('Shimmering veil') && !Game.Has('Shimmering veil [off]') && !Game.Has('Shimmering veil [on]')) {Game.Unlock('Shimmering veil [on]');Game.Upgrades['Shimmering veil [off]'].earn();} + if (Game.Has('Sugar craving')) Game.Unlock('Sugar frenzy'); if (Game.Has('Classic dairy selection')) Game.Unlock('Milk selector'); if (Game.Has('Basic wallpaper assortment')) Game.Unlock('Background selector'); if (Game.Has('Golden cookie alert sound')) Game.Unlock('Golden cookie sound selector'); @@ -11046,6 +13234,17 @@ Game.Launch=function() if (eggs>=Game.easterEggs.length) Game.Win('Hide & seek champion'); } + if (Game.Has('Fortune cookies')) + { + var list=Game.Tiers['fortune'].upgrades; + var fortunes=0; + for (var i in list) + { + if (Game.Has(list[i].name)) fortunes++; + } + if (fortunes>=list.length) Game.Win('O Fortuna'); + } + if (Game.prestige>0 && Game.ascensionMode!=1) { Game.Unlock('Heavenly chip secret'); @@ -11081,6 +13280,10 @@ Game.Launch=function() if (minAmount>=200) {Game.Win('Bicentennial');Game.Unlock('White chocolate butter biscuit');} if (minAmount>=250) {Game.Win('Bicentennial and a half');Game.Unlock('Ruby chocolate butter biscuit');} if (minAmount>=300) {Game.Win('Tricentennial');Game.Unlock('Lavender chocolate butter biscuit');} + if (minAmount>=350) {Game.Win('Tricentennial and a half');Game.Unlock('Synthetic chocolate green honey butter biscuit');} + if (minAmount>=400) {Game.Win('Quadricentennial');Game.Unlock('Royal raspberry chocolate butter biscuit');} + if (minAmount>=450) {Game.Win('Quadricentennial and a half');Game.Unlock('Ultra-concentrated high-energy chocolate butter biscuit');} + if (minAmount>=500) {Game.Win('Quincentennial');Game.Unlock('Pure pitch-black chocolate butter biscuit');} if (Game.handmadeCookies>=1000) {Game.Win('Clicktastic');Game.Unlock('Plastic mouse');} if (Game.handmadeCookies>=100000) {Game.Win('Clickathlon');Game.Unlock('Iron mouse');} @@ -11092,6 +13295,8 @@ Game.Launch=function() if (Game.handmadeCookies>=100000000000000000) {Game.Win('Clickastrophe');Game.Unlock('Fantasteel mouse');} if (Game.handmadeCookies>=10000000000000000000) {Game.Win('Clickataclysm');Game.Unlock('Nevercrack mouse');} if (Game.handmadeCookies>=1000000000000000000000) {Game.Win('The ultimate clickdown');Game.Unlock('Armythril mouse');} + if (Game.handmadeCookies>=100000000000000000000000) {Game.Win('All the other kids with the pumped up clicks');Game.Unlock('Technobsidian mouse');} + if (Game.handmadeCookies>=10000000000000000000000000) {Game.Win('One...more...click...');Game.Unlock('Plasmarble mouse');} if (Game.cookiesEarned=100) Game.Win('Upgrader'); if (Game.UpgradesOwned>=200) Game.Win('Lord of Progress'); if (buildingsOwned>=3000 && Game.UpgradesOwned>=300) Game.Win('Polymath'); + if (buildingsOwned>=4000 && Game.UpgradesOwned>=400) Game.Win('Renaissance baker'); if (Game.cookiesEarned>=10000000000000 && !Game.HasAchiev('You win a cookie')) {Game.Win('You win a cookie');Game.Earn(1);} if (Game.shimmerTypes['golden'].n>=4) Game.Win('Four-leaf cookie'); var grandmas=0; - if (Game.Has('Farmer grandmas')) grandmas++; - if (Game.Has('Worker grandmas')) grandmas++; - if (Game.Has('Miner grandmas')) grandmas++; - if (Game.Has('Cosmic grandmas')) grandmas++; - if (Game.Has('Transmuted grandmas')) grandmas++; - if (Game.Has('Altered grandmas')) grandmas++; - if (Game.Has('Grandmas\' grandmas')) grandmas++; - if (Game.Has('Antigrandmas')) grandmas++; - if (Game.Has('Rainbow grandmas')) grandmas++; - if (Game.Has('Banker grandmas')) grandmas++; - if (Game.Has('Priestess grandmas')) grandmas++; - if (Game.Has('Witch grandmas')) grandmas++; - if (Game.Has('Lucky grandmas')) grandmas++; + for (var i in Game.GrandmaSynergies) + { + if (Game.Has(Game.GrandmaSynergies[i])) grandmas++; + } if (!Game.HasAchiev('Elder') && grandmas>=7) Game.Win('Elder'); + if (!Game.HasAchiev('Veteran') && grandmas>=14) Game.Win('Veteran'); if (Game.Objects['Grandma'].amount>=6 && !Game.Has('Bingo center/Research facility') && Game.HasAchiev('Elder')) Game.Unlock('Bingo center/Research facility'); if (Game.pledges>0) Game.Win('Elder nap'); if (Game.pledges>=5) Game.Win('Elder slumber'); if (Game.pledges>=10) Game.Unlock('Sacrificial rolling pins'); if (Game.Objects['Cursor'].amount+Game.Objects['Grandma'].amount>=777) Game.Win('The elder scrolls'); - var base=10000000000000; - if (Game.Objects['Cursor'].totalCookies>=base*1000000) Game.Win('Click delegator'); - if (Game.Objects['Grandma'].totalCookies>=base*1000000) Game.Win('Gushing grannies'); - if (Game.Objects['Farm'].totalCookies>=base) Game.Win('I hate manure'); - if (Game.Objects['Mine'].totalCookies>=base* 10) Game.Win('Never dig down'); - if (Game.Objects['Factory'].totalCookies>=base* 100) Game.Win('The incredible machine'); - if (Game.Objects['Bank'].totalCookies>=base* 1000) Game.Win('Vested interest'); - if (Game.Objects['Temple'].totalCookies>=base* 10000) Game.Win('New world order'); - if (Game.Objects['Wizard tower'].totalCookies>=base* 100000) Game.Win('Hocus pocus'); - if (Game.Objects['Shipment'].totalCookies>=base* 1000000) Game.Win('And beyond'); - if (Game.Objects['Alchemy lab'].totalCookies>=base* 10000000) Game.Win('Magnum Opus'); - if (Game.Objects['Portal'].totalCookies>=base* 100000000) Game.Win('With strange eons'); - if (Game.Objects['Time machine'].totalCookies>=base* 1000000000) Game.Win('Spacetime jigamaroo'); - if (Game.Objects['Antimatter condenser'].totalCookies>=base*10000000000) Game.Win('Supermassive'); - if (Game.Objects['Prism'].totalCookies>=base* 100000000000) Game.Win('Praise the sun'); - if (Game.Objects['Chancemaker'].totalCookies>=base* 1000000000000) Game.Win('Fingers crossed'); - - var base=10000000000000000; - if (Game.Objects['Cursor'].totalCookies>=base*1000000) Game.Win('Finger clickin\' good'); - if (Game.Objects['Grandma'].totalCookies>=base*1000000) Game.Win('Panic at the bingo'); - if (Game.Objects['Farm'].totalCookies>=base) Game.Win('Rake in the dough'); - if (Game.Objects['Mine'].totalCookies>=base* 10) Game.Win('Quarry on'); - if (Game.Objects['Factory'].totalCookies>=base* 100) Game.Win('Yes I love technology'); - if (Game.Objects['Bank'].totalCookies>=base* 1000) Game.Win('Paid in full'); - if (Game.Objects['Temple'].totalCookies>=base* 10000) Game.Win('Church of Cookiology'); - if (Game.Objects['Wizard tower'].totalCookies>=base* 100000) Game.Win('Too many rabbits, not enough hats'); - if (Game.Objects['Shipment'].totalCookies>=base* 1000000) Game.Win('The most precious cargo'); - if (Game.Objects['Alchemy lab'].totalCookies>=base* 10000000) Game.Win('The Aureate'); - if (Game.Objects['Portal'].totalCookies>=base* 100000000) Game.Win('Ever more hideous'); - if (Game.Objects['Time machine'].totalCookies>=base* 1000000000) Game.Win('Be kind, rewind'); - if (Game.Objects['Antimatter condenser'].totalCookies>=base*10000000000) Game.Win('Infinitesimal'); - if (Game.Objects['Prism'].totalCookies>=base* 100000000000) Game.Win('A still more glorious dawn'); - if (Game.Objects['Chancemaker'].totalCookies>=base* 1000000000000) Game.Win('Just a statistic'); - - var base=10000000000000000000; - if (Game.Objects['Cursor'].totalCookies>=base*1000000) Game.Win('Click (starring Adam Sandler)'); - if (Game.Objects['Grandma'].totalCookies>=base*1000000) Game.Win('Frantiquities'); - if (Game.Objects['Farm'].totalCookies>=base) Game.Win('Overgrowth'); - if (Game.Objects['Mine'].totalCookies>=base* 10) Game.Win('Sedimentalism'); - if (Game.Objects['Factory'].totalCookies>=base* 100) Game.Win('Labor of love'); - if (Game.Objects['Bank'].totalCookies>=base* 1000) Game.Win('Reverse funnel system'); - if (Game.Objects['Temple'].totalCookies>=base* 10000) Game.Win('Thus spoke you'); - if (Game.Objects['Wizard tower'].totalCookies>=base* 100000) Game.Win('Manafest destiny'); - if (Game.Objects['Shipment'].totalCookies>=base* 1000000) Game.Win('Neither snow nor rain nor heat nor gloom of night'); - if (Game.Objects['Alchemy lab'].totalCookies>=base* 10000000) Game.Win('I\'ve got the Midas touch'); - if (Game.Objects['Portal'].totalCookies>=base* 100000000) Game.Win('Which eternal lie'); - if (Game.Objects['Time machine'].totalCookies>=base* 1000000000) Game.Win('Déjà vu'); - if (Game.Objects['Antimatter condenser'].totalCookies>=base*10000000000) Game.Win('Powers of Ten'); - if (Game.Objects['Prism'].totalCookies>=base* 100000000000) Game.Win('Now the dark days are gone'); - if (Game.Objects['Chancemaker'].totalCookies>=base* 1000000000000) Game.Win('Murphy\'s wild guess'); + for (var i in Game.Objects) + { + var it=Game.Objects[i]; + for (var ii in it.productionAchievs) + { + if (it.totalCookies>=it.productionAchievs[ii].pow) Game.Win(it.productionAchievs[ii].achiev.name); + } + } if (!Game.HasAchiev('Cookie-dunker') && Game.LeftBackground && Game.milkProgress>0.1 && (Game.LeftBackground.canvas.height*0.4+256/2-16)>((1-Game.milkHd)*Game.LeftBackground.canvas.height)) Game.Win('Cookie-dunker'); //&& l('bigCookie').getBoundingClientRect().bottom>l('milk').getBoundingClientRect().top+16 && Game.milkProgress>0.1) Game.Win('Cookie-dunker'); @@ -11283,7 +13439,7 @@ Game.Launch=function() Game.NotesLogic(); if (Game.mouseMoved || Game.Scroll || Game.tooltip.dynamic) Game.tooltip.update(); - if (Game.T%(Game.fps*5)==0 && !Game.mouseDown) Game.UpdateMenu(); + if (Game.T%(Game.fps*5)==0 && !Game.mouseDown && (Game.onMenu=='stats' || Game.onMenu=='prefs')) Game.UpdateMenu(); if (Game.T%(Game.fps*1)==0) Game.UpdatePrompt(); if (Game.AscendTimer>0) Game.UpdateAscendIntro(); if (Game.ReincarnateTimer>0) Game.UpdateReincarnateIntro(); @@ -11303,8 +13459,20 @@ Game.Launch=function() Game.mouseMoved=0; Game.CanClick=1; - if (Game.T%(Game.fps*60)==0 && Game.T>Game.fps*10 && Game.prefs.autosave && !Game.OnAscend) Game.WriteSave(); - if (Game.T%(Game.fps*60*30)==0 && Game.T>Game.fps*10 && Game.prefs.autoupdate) Game.CheckUpdates(); + if ((Game.toSave || (Game.T%(Game.fps*60)==0 && Game.T>Game.fps*10 && Game.prefs.autosave)) && !Game.OnAscend) + { + //check if we can save : no minigames are loading + var canSave=true; + for (var i in Game.Objects) + { + var me=Game.Objects[i]; + if (me.minigameLoading){canSave=false;break;} + } + if (canSave) Game.WriteSave(); + } + + //every 30 minutes : get server data (ie. update notification, patreon data) + if (Game.T%(Game.fps*60*30)==0 && Game.T>Game.fps*10/* && Game.prefs.autoupdate*/) {Game.CheckUpdates();Game.GrabData();} Game.T++; } @@ -11349,7 +13517,7 @@ Game.Launch=function() for (var i in Game.Objects) { var me=Game.Objects[i]; - if (me.onMinigame && me.minigame.draw) me.minigame.draw(); + if (me.onMinigame && me.minigame.draw && !me.muted) me.minigame.draw(); } Timer.track('draw minigames'); @@ -11379,7 +13547,7 @@ Game.Launch=function() if (!me.bought) { var price=me.getPrice(); - var canBuy=(Game.cookies>=price); + var canBuy=me.canBuy();//(Game.cookies>=price); var enabled=(l('upgrade'+i).className.indexOf('enabled')>-1); if ((canBuy && !enabled) || (!canBuy && enabled)) Game.upgradesToRebuild=1; if (price=1000*60*5) + { + if (Game.accumulatedDelay>1000*60*30) Game.delayTimeouts+=3;//more than 30 minutes delay ? computer probably asleep and not making cookies anyway + else if (Game.accumulatedDelay>1000*5) Game.delayTimeouts++;//add to timeout counter when we skip 10 seconds worth of frames (and the player has been inactive for at least 5 minutes) + if (Game.delayTimeouts>=3) Game.Timeout();//trigger timeout when the timeout counter is 3+ + } + Game.accumulatedDelay=Math.min(Game.accumulatedDelay,1000*5);//don't compensate over 5 seconds; if you do, something's probably very wrong - Game.time=Date.now(); + Game.time=time; while (Game.accumulatedDelay>0) { Game.Logic(); @@ -11455,22 +13632,38 @@ Game.Launch=function() Timer.say('END LOGIC'); if (!Game.prefs.altDraw) { + var hasFocus=document.hasFocus(); Timer.say('DRAW'); - if (hasFocus || Game.prefs.focus || Game.loopT%10==0) Game.Draw(); + if (hasFocus || Game.prefs.focus || Game.loopT%10==0) requestAnimationFrame(Game.Draw); //if (document.hasFocus() || Game.loopT%5==0) Game.Draw(); Timer.say('END DRAW'); } + else requestAnimationFrame(Game.Draw); //if (!hasFocus) Game.tooltip.hide(); if (Game.sesame) { - l('fpsCounter').innerHTML=Game.getFps()+' fps'; + //fps counter and graph + Game.previousFps=Game.currentFps; + Game.currentFps=Game.getFps(); + var ctx=Game.fpsGraphCtx; + ctx.drawImage(Game.fpsGraph,-1,0); + ctx.fillStyle='rgb('+Math.round((1-Game.currentFps/Game.fps)*128)+',0,0)'; + ctx.fillRect(128-1,0,1,64); + ctx.strokeStyle='#fff'; + ctx.beginPath(); + ctx.moveTo(128-1,(1-Game.previousFps/Game.fps)*64); + ctx.lineTo(128,(1-Game.currentFps/Game.fps)*64); + ctx.stroke(); + + l('fpsCounter').innerHTML=Game.currentFps+' fps'; var str=''; for (var i in Timer.labels) {str+=Timer.labels[i];} if (Game.debugTimersOn) l('debugLog').style.display='block'; else l('debugLog').style.display='none'; l('debugLog').innerHTML=str; + } Timer.reset(); @@ -11495,6 +13688,13 @@ window.onload=function() if (top!=self) Game.ErrorFrame(); else { + console.log('[=== '+choose([ + 'Oh, hello!', + 'hey, how\'s it hangin', + 'About to cheat in some cookies or just checking for bugs?', + 'Remember : cheated cookies taste awful!', + 'Hey, Orteil here. Cheated cookies taste awful... or do they?', + ])+' ===]'); Game.Load(); //try {Game.Load();} //catch(err) {console.log('ERROR : '+err.message);} diff --git a/minigameGarden.js b/minigameGarden.js new file mode 100644 index 0000000..6f377c6 --- /dev/null +++ b/minigameGarden.js @@ -0,0 +1,2018 @@ +var M={}; +M.parent=Game.Objects['Farm']; +M.parent.minigame=M; +M.launch=function() +{ + var M=this; + M.name=M.parent.minigameName; + M.init=function(div) + { + //populate div with html and initialize values + + /* + plants age from 0 to 100 + at one point in its lifespan, the plant becomes mature + plants have 4 life stages once planted : bud, sprout, bloom, mature + a plant may age faster by having a higher .ageTick + if a plant has .ageTickR, a random number between 0 and that amount is added to .ageTick + a plant may mature faster by having a lower .mature + a plant's effects depend on how mature it is + a plant can only reproduce when mature + */ + M.plants={ + 'bakerWheat':{ + name:'Baker\'s wheat', + icon:0, + cost:1, + costM:30, + ageTick:7, + ageTickR:2, + mature:35, + children:['bakerWheat','thumbcorn','cronerice','bakeberry','clover','goldenClover','chocoroot','tidygrass'], + effsStr:'
• +1% CpS
', + q:'A plentiful crop whose hardy grain is used to make flour for pastries.', + onHarvest:function(x,y,age) + { + if (age>=this.mature) M.dropUpgrade('Wheat slims',0.001); + }, + }, + 'thumbcorn':{ + name:'Thumbcorn', + icon:1, + cost:5, + costM:100, + ageTick:6, + ageTickR:2, + mature:20, + children:['bakerWheat','thumbcorn','cronerice','gildmillet','glovemorel'], + effsStr:'
• +2% cookies per click
', + q:'A strangely-shaped variant of corn. The amount of strands that can sprout from one seed is usually in the single digits.', + }, + 'cronerice':{ + name:'Cronerice', + icon:2, + cost:15, + costM:250, + ageTick:0.4, + ageTickR:0.7, + mature:55, + children:['thumbcorn','gildmillet','elderwort','wardlichen'], + effsStr:'
• +3% grandma CpS
', + q:'Not only does this wrinkly bulb look nothing like rice, it\'s not even related to it either; its closest extant relative is the weeping willow.', + }, + 'gildmillet':{ + name:'Gildmillet', + icon:3, + cost:15, + costM:1500, + ageTick:2, + ageTickR:1.5, + mature:40, + children:['clover','goldenClover','shimmerlily'], + effsStr:'
• +1% golden cookie gains
• +0.1% golden cookie effect duration
', + q:'An ancient staple crop, famed for its golden sheen. Was once used to bake birthday cakes for kings and queens of old.', + }, + 'clover':{ + name:'Ordinary clover', + icon:4, + cost:25, + costM:77777, + ageTick:1, + ageTickR:1.5, + mature:35, + children:['goldenClover','greenRot','shimmerlily'], + effsStr:'
• +1% golden cookie frequency
', + q:'Trifolium repens, a fairly mundane variety of clover with a tendency to produce four leaves. Such instances are considered lucky by some.', + }, + 'goldenClover':{ + name:'Golden clover', + icon:5, + cost:125, + costM:777777777777, + ageTick:4, + ageTickR:12, + mature:50, + children:[], + effsStr:'
• +3% golden cookie frequency
', + q:'A variant of the ordinary clover that traded its chlorophyll for pure organic gold. Tragically short-lived, this herb is an evolutionary dead-end - but at least it looks pretty.', + }, + 'shimmerlily':{ + name:'Shimmerlily', + icon:6, + cost:60, + costM:777777, + ageTick:5, + ageTickR:6, + mature:70, + children:['elderwort','whiskerbloom','chimerose','cheapcap'], + effsStr:'
• +1% golden cookie gains
• +1% golden cookie frequency
• +1% random drops
', + q:'These little flowers are easiest to find at dawn, as the sunlight refracting in dew drops draws attention to their pure-white petals.', + }, + 'elderwort':{ + name:'Elderwort', + icon:7, + cost:60*3, + costM:100000000, + ageTick:0.3, + ageTickR:0.5, + mature:90, + immortal:1, + noContam:true, + detailsStr:'Immortal', + children:['everdaisy','ichorpuff','shriekbulb'], + effsStr:'
• +1% wrath cookie gains
• +1% wrath cookie frequency
• +1% grandma CpS
• immortal
• surrounding plants (3x3) age 3% faster
', + q:'A very old, long-forgotten subspecies of edelweiss that emits a strange, heady scent. There is some anecdotal evidence that these do not undergo molecular aging.', + onHarvest:function(x,y,age) + { + if (age>=this.mature) M.dropUpgrade('Elderwort biscuits',0.01); + }, + }, + 'bakeberry':{ + name:'Bakeberry', + icon:8, + cost:45, + costM:100000000, + ageTick:1, + ageTickR:1, + mature:50, + children:['queenbeet'], + effsStr:'
• +1% CpS
• harvest when mature for +30 minutes of CpS (max. 3% of bank)
', + q:'A favorite among cooks, this large berry has a crunchy brown exterior and a creamy red center. Excellent in pies or chicken stews.', + onHarvest:function(x,y,age) + { + if (age>=this.mature) + { + var moni=Math.min(Game.cookies*0.03,Game.cookiesPs*60*30); + if (moni!=0) + { + Game.Earn(moni); + Game.Popup('(Bakeberry)
+'+Beautify(moni)+' cookies!',Game.mouseX,Game.mouseY); + } + M.dropUpgrade('Bakeberry cookies',0.015); + } + }, + }, + 'chocoroot':{ + name:'Chocoroot', + icon:9, + cost:15, + costM:100000, + ageTick:4, + ageTickR:0, + mature:25, + detailsStr:'Predictable growth', + children:['whiteChocoroot','drowsyfern','queenbeet'], + effsStr:'
• +1% CpS
• harvest when mature for +3 minutes of CpS (max. 3% of bank)
• predictable growth
', + q:'A tangly bramble coated in a sticky, sweet substance. Unknown genetic ancestry. Children often pick these from fields as-is as a snack.', + onHarvest:function(x,y,age) + { + if (age>=this.mature) + { + var moni=Math.min(Game.cookies*0.03,Game.cookiesPs*60*3); + if (moni!=0) + { + Game.Earn(moni); + Game.Popup('(Chocoroot)
+'+Beautify(moni)+' cookies!',Game.mouseX,Game.mouseY); + } + } + }, + }, + 'whiteChocoroot':{ + name:'White chocoroot', + icon:10, + cost:15, + costM:100000, + ageTick:4, + ageTickR:0, + mature:25, + detailsStr:'Predictable growth', + children:['whiskerbloom','tidygrass'], + effsStr:'
• +1% golden cookie gains
• harvest when mature for +3 minutes of CpS (max. 3% of bank)
• predictable growth
', + q:'A pale, even sweeter variant of the chocoroot. Often impedes travelers with its twisty branches.', + onHarvest:function(x,y,age) + { + if (age>=this.mature) + { + var moni=Math.min(Game.cookies*0.03,Game.cookiesPs*60*3); + if (moni!=0) + { + Game.Earn(moni); + Game.Popup('(White chocoroot)
+'+Beautify(moni)+' cookies!',Game.mouseX,Game.mouseY); + } + } + }, + }, + + 'whiteMildew':{ + name:'White mildew', + fungus:true, + icon:26, + cost:20, + costM:9999, + ageTick:8, + ageTickR:12, + mature:70, + detailsStr:'Spreads easily', + children:['brownMold','whiteChocoroot','wardlichen','greenRot'], + effsStr:'
• +1% CpS
• may spread as brown mold
', + q:'A common rot that infests shady plots of earth. Grows in little creamy capsules. Smells sweet, but sadly wilts quickly.', + }, + 'brownMold':{ + name:'Brown mold', + fungus:true, + icon:27, + cost:20, + costM:9999, + ageTick:8, + ageTickR:12, + mature:70, + detailsStr:'Spreads easily', + children:['whiteMildew','chocoroot','keenmoss','wrinklegill'], + effsStr:'
• -1% CpS
• may spread as white mildew
', + q:'A common rot that infests shady plots of earth. Grows in odd reddish clumps. Smells bitter, but thankfully wilts quickly.', + }, + + 'meddleweed':{ + name:'Meddleweed', + weed:true, + icon:29, + cost:1, + costM:10, + ageTick:10, + ageTickR:6, + mature:50, + contam:0.05, + detailsStr:'Grows in empty tiles, spreads easily', + children:['meddleweed','brownMold','crumbspore'], + effsStr:'
• useless
• may overtake nearby plants
• may sometimes drop spores when uprooted
', + q:'The sign of a neglected farmland, this annoying weed spawns from unused dirt and may sometimes spread to other plants, killing them in the process.', + onKill:function(x,y,age) + { + if (Math.random()<0.2*(age/100)) M.plot[y][x]=[M.plants[choose(['brownMold','crumbspore'])].id+1,0]; + }, + }, + + 'whiskerbloom':{ + name:'Whiskerbloom', + icon:11, + cost:20, + costM:1000000, + ageTick:2, + ageTickR:2, + mature:60, + children:['chimerose','nursetulip'], + effsStr:'
• +0.2% effects from milk
', + q:'Squeezing the translucent pods makes them excrete a milky liquid, while producing a faint squeak akin to a cat\'s meow.', + }, + 'chimerose':{ + name:'Chimerose', + icon:12, + cost:15, + costM:242424, + ageTick:1, + ageTickR:1.5, + mature:30, + children:['chimerose'], + effsStr:'
• +1% reindeer gains
• +1% reindeer frequency
', + q:'Originating in the greener flanks of polar mountains, this beautiful flower with golden accents is fragrant enough to make any room feel a little bit more festive.', + }, + 'nursetulip':{ + name:'Nursetulip', + icon:13, + cost:40, + costM:1000000000, + ageTick:0.5, + ageTickR:2, + mature:60, + children:[], + effsStr:'
• surrounding plants (3x3) are 20% more efficient
• -2% CpS
', + q:'This flower grows an intricate root network that distributes nutrients throughout the surrounding soil. The reason for this seemingly altruistic behavior is still unknown.', + }, + 'drowsyfern':{ + name:'Drowsyfern', + icon:14, + cost:90, + costM:100000, + ageTick:0.05, + ageTickR:0.1, + mature:30, + children:[], + effsStr:'
• +3% CpS
• -5% cookies per click
• -10% golden cookie frequency
', + q:'Traditionally used to brew a tea that guarantees a good night of sleep.', + onHarvest:function(x,y,age) + { + if (age>=this.mature) M.dropUpgrade('Fern tea',0.01); + }, + }, + 'wardlichen':{ + name:'Wardlichen', + icon:15, + cost:10, + costM:10000, + ageTick:5, + ageTickR:4, + mature:65, + children:['wardlichen'], + effsStr:'
• 2% less wrath cookies
• wrinklers spawn 15% slower
', + q:'The metallic stench that emanates from this organism has been known to keep insects and slugs away.', + }, + 'keenmoss':{ + name:'Keenmoss', + icon:16, + cost:50, + costM:1000000, + ageTick:4, + ageTickR:5, + mature:65, + children:['drowsyfern','wardlichen','keenmoss'], + effsStr:'
• +3% random drops
', + q:'Fuzzy to the touch and of a vibrant green. In plant symbolism, keenmoss is associated with good luck for finding lost objects.', + }, + 'queenbeet':{ + name:'Queenbeet', + icon:17, + cost:60*1.5, + costM:1000000000, + ageTick:1, + ageTickR:0.4, + mature:80, + noContam:true, + children:['duketater','queenbeetLump','shriekbulb'], + effsStr:'
• +0.3% golden cookie effect duration
• -2% CpS
• harvest when mature for +1 hour of CpS (max. 4% of bank)
', + q:'A delicious taproot used to prepare high-grade white sugar. Entire countries once went to war over these.', + onHarvest:function(x,y,age) + { + if (age>=this.mature) + { + var moni=Math.min(Game.cookies*0.04,Game.cookiesPs*60*60); + if (moni!=0) + { + Game.Earn(moni); + Game.Popup('(Queenbeet)
+'+Beautify(moni)+' cookies!',Game.mouseX,Game.mouseY); + } + } + }, + }, + 'queenbeetLump':{ + name:'Juicy queenbeet', + icon:18, + plantable:false, + cost:60*2, + costM:1000000000000, + ageTick:0.04, + ageTickR:0.08, + mature:85, + noContam:true, + children:[], + effsStr:'
• -10% CpS
• surrounding plants (3x3) are 20% less efficient
• harvest when mature for a sugar lump
', + q:'A delicious taproot used to prepare high-grade white sugar. Entire countries once went to war over these.
It looks like this one has grown especially sweeter and juicier from growing in close proximity to other queenbeets.', + onHarvest:function(x,y,age) + { + if (age>=this.mature) + { + Game.gainLumps(1); + popup='(Juicy queenbeet)
Sweet!
Found 1 sugar lump!
'; + } + }, + }, + 'duketater':{ + name:'Duketater', + icon:19, + cost:60*8, + costM:1000000000000, + ageTick:0.4, + ageTickR:0.1, + mature:95, + noContam:true, + children:['shriekbulb'], + effsStr:'
• harvest when mature for +2 hours of CpS (max. 8% of bank)
', + q:'A rare, rich-tasting tuber fit for a whole meal, as long as its strict harvesting schedule is respected. Its starch has fascinating baking properties.', + onHarvest:function(x,y,age) + { + if (age>=this.mature) + { + var moni=Math.min(Game.cookies*0.08,Game.cookiesPs*60*60*2); + if (moni!=0) + { + Game.Earn(moni); + Game.Popup('(Duketater)
+'+Beautify(moni)+' cookies!',Game.mouseX,Game.mouseY); + } + M.dropUpgrade('Duketater cookies',0.005); + } + }, + }, + 'crumbspore':{ + name:'Crumbspore', + fungus:true, + icon:20, + cost:10, + costM:999, + ageTick:3, + ageTickR:3, + mature:65, + contam:0.03, + noContam:true, + detailsStr:'Spreads easily', + children:['crumbspore','glovemorel','cheapcap','doughshroom','wrinklegill','ichorpuff'], + effsStr:'
• explodes into up to 1 minute of CpS at the end of its lifecycle (max. 1% of bank)
• may overtake nearby plants
', + q:'An archaic mold that spreads its spores to the surrounding dirt through simple pod explosion.', + onDie:function(x,y) + { + var moni=Math.min(Game.cookies*0.01,Game.cookiesPs*60)*Math.random(); + if (moni!=0) + { + Game.Earn(moni); + Game.Popup('(Crumbspore)
+'+Beautify(moni)+' cookies!',Game.mouseX,Game.mouseY); + } + }, + }, + 'doughshroom':{ + name:'Doughshroom', + fungus:true, + icon:24, + cost:100, + costM:100000000, + ageTick:1, + ageTickR:2, + mature:85, + contam:0.03, + noContam:true, + detailsStr:'Spreads easily', + children:['crumbspore','doughshroom','foolBolete','shriekbulb'], + effsStr:'
• explodes into up to 5 minutes of CpS at the end of its lifecycle (max. 3% of bank)
• may overtake nearby plants
', + q:'Jammed full of warm spores; some forest walkers often describe the smell as similar to passing by a bakery.', + onDie:function(x,y) + { + var moni=Math.min(Game.cookies*0.03,Game.cookiesPs*60*5)*Math.random(); + if (moni!=0) + { + Game.Earn(moni); + Game.Popup('(Doughshroom)
+'+Beautify(moni)+' cookies!',Game.mouseX,Game.mouseY); + } + }, + }, + 'glovemorel':{ + name:'Glovemorel', + fungus:true, + icon:21, + cost:30, + costM:10000, + ageTick:3, + ageTickR:18, + mature:80, + children:[], + effsStr:'
• +4% cookies per click
• +1% cursor CpS
• -1% CpS
', + q:'Touching its waxy skin reveals that the interior is hollow and uncomfortably squishy.', + }, + 'cheapcap':{ + name:'Cheapcap', + fungus:true, + icon:22, + cost:40, + costM:100000, + ageTick:6, + ageTickR:16, + mature:40, + children:[], + effsStr:'
• buildings and upgrades are 0.2% cheaper
• cannot handle cold climates; 15% chance to die when frozen
', + q:'Small, tough, and good in omelettes. Some historians propose that the heads of dried cheapcaps were once used as currency in some bronze age societies.', + }, + 'foolBolete':{ + name:'Fool\'s bolete', + fungus:true, + icon:23, + cost:15, + costM:10000, + ageTick:5, + ageTickR:25, + mature:50, + children:[], + effsStr:'
• +2% golden cookie frequency
• -5% golden cookie gains
• -2% golden cookie duration
• -2% golden cookie effect duration
', + q:'Named for its ability to fool mushroom pickers. The fool\'s bolete is not actually poisonous, it\'s just extremely bland.', + }, + 'wrinklegill':{ + name:'Wrinklegill', + fungus:true, + icon:25, + cost:20, + costM:1000000, + ageTick:1, + ageTickR:3, + mature:65, + children:['elderwort','shriekbulb'], + effsStr:'
• wrinklers spawn 2% faster
• wrinklers eat 1% more
', + q:'This mushroom\'s odor resembles that of a well-done steak, and is said to whet the appetite - making one\'s stomach start gurgling within seconds.', + }, + 'greenRot':{ + name:'Green rot', + fungus:true, + icon:28, + cost:60, + costM:1000000, + ageTick:12, + ageTickR:13, + mature:65, + children:['keenmoss','foolBolete'], + effsStr:'
• +0.5% golden cookie duration
• +1% golden cookie frequency
• +1% random drops
', + q:'This short-lived mold is also known as "emerald pebbles", and is considered by some as a pseudo-gem that symbolizes good fortune.', + onHarvest:function(x,y,age) + { + if (age>=this.mature) M.dropUpgrade('Green yeast digestives',0.005); + }, + }, + 'shriekbulb':{ + name:'Shriekbulb', + icon:30, + cost:60, + costM:4444444444444, + ageTick:3, + ageTickR:1, + mature:60, + noContam:true, + detailsStr:'The unfortunate result of some plant combinations', + children:['shriekbulb'], + effsStr:'
• -2% CpS
• surrounding plants (3x3) are 5% less efficient
', + q:'A nasty vegetable with a dreadful quirk : its flesh resonates with a high-pitched howl whenever it is hit at the right angle by sunlight, moonlight, or even a slight breeze.', + }, + 'tidygrass':{ + name:'Tidygrass', + icon:31, + cost:90, + costM:100000000000000, + ageTick:0.5, + ageTickR:0, + mature:40, + children:['everdaisy'], + effsStr:'
• surrounding tiles (5x5) develop no weeds or fungus
', + q:'The molecules this grass emits are a natural weedkiller. Its stems grow following a predictable pattern, making it an interesting -if expensive- choice for a lawn grass.', + }, + 'everdaisy':{ + name:'Everdaisy', + icon:32, + cost:180, + costM:100000000000000000000, + ageTick:0.3, + ageTickR:0, + mature:75, + noContam:true, + immortal:1, + detailsStr:'Immortal', + children:[], + effsStr:'
• surrounding tiles (3x3) develop no weeds or fungus
• immortal
', + q:'While promoted by some as a superfood owing to its association with longevity and intriguing geometry, this elusive flower is actually mildly toxic.', + }, + 'ichorpuff':{ + name:'Ichorpuff', + fungus:true, + icon:33, + cost:120, + costM:987654321, + ageTick:1, + ageTickR:1.5, + mature:35, + children:[], + effsStr:'
• surrounding plants (3x3) age half as fast
• surrounding plants (3x3) are half as efficient
', + q:'This puffball mushroom contains sugary spores, but it never seems to mature to bursting on its own. Surrounding plants under its influence have a very slow metabolism, reducing their effects but lengthening their lifespan.', + onHarvest:function(x,y,age) + { + if (age>=this.mature) M.dropUpgrade('Ichor syrup',0.005); + }, + }, + }; + M.plantsById=[];var n=0; + for (var i in M.plants) + { + M.plants[i].unlocked=0; + M.plants[i].id=n; + M.plants[i].key=i; + M.plants[i].matureBase=M.plants[i].mature; + M.plantsById[n]=M.plants[i]; + if (typeof M.plants[i].plantable==='undefined') {M.plants[i].plantable=true;} + n++; + } + M.plantsN=M.plantsById.length; + M.plantsUnlockedN=0; + M.getUnlockedN=function() + { + M.plantsUnlockedN=0; + for (var i in M.plants){if (M.plants[i].unlocked) M.plantsUnlockedN++;} + if (M.plantsUnlockedN>=M.plantsN) + { + Game.Win('Keeper of the conservatory'); + l('gardenTool-3').classList.remove('locked'); + } + else l('gardenTool-3').classList.add('locked'); + + return M.plantsUnlockedN; + } + + M.dropUpgrade=function(upgrade,rate) + { + if (!Game.Has(upgrade) && Math.random()<=rate*Game.dropRateMult()*(Game.HasAchiev('Seedless to nay')?1.05:1)) + { + Game.Unlock(upgrade); + } + } + + M.computeMatures=function() + { + var mult=1; + if (Game.HasAchiev('Seedless to nay')) mult=0.95; + for (var i in M.plants) + { + M.plants[i].mature=M.plants[i].matureBase*mult; + } + } + + M.plantContam={}; + for (var i in M.plants) + { + if (M.plants[i].contam) M.plantContam[M.plants[i].key]=M.plants[i].contam; + } + + M.getMuts=function(neighs,neighsM) + { + //get possible mutations given a list of neighbors + //note : neighs stands for neighbors, not horsey noises + var muts=[]; + + if (neighsM['bakerWheat']>=2) muts.push(['bakerWheat',0.2],['thumbcorn',0.05],['bakeberry',0.001]); + if (neighsM['bakerWheat']>=1 && neighsM['thumbcorn']>=1) muts.push(['cronerice',0.01]); + if (neighsM['thumbcorn']>=2) muts.push(['thumbcorn',0.1],['bakerWheat',0.05]); + if (neighsM['cronerice']>=1 && neighsM['thumbcorn']>=1) muts.push(['gildmillet',0.03]); + if (neighsM['cronerice']>=2) muts.push(['thumbcorn',0.02]); + if (neighsM['bakerWheat']>=1 && neighsM['gildmillet']>=1) muts.push(['clover',0.03],['goldenClover',0.0007]); + if (neighsM['clover']>=1 && neighsM['gildmillet']>=1) muts.push(['shimmerlily',0.02]); + if (neighsM['clover']>=2 && neighs['clover']<5) muts.push(['clover',0.007],['goldenClover',0.0001]); + if (neighsM['clover']>=4) muts.push(['goldenClover',0.0007]); + if (neighsM['shimmerlily']>=1 && neighsM['cronerice']>=1) muts.push(['elderwort',0.01]); + if (neighsM['wrinklegill']>=1 && neighsM['cronerice']>=1) muts.push(['elderwort',0.002]); + if (neighsM['bakerWheat']>=1 && neighs['brownMold']>=1) muts.push(['chocoroot',0.1]); + if (neighsM['chocoroot']>=1 && neighs['whiteMildew']>=1) muts.push(['whiteChocoroot',0.1]); + if (neighsM['whiteMildew']>=1 && neighs['brownMold']<=1) muts.push(['brownMold',0.5]); + if (neighsM['brownMold']>=1 && neighs['whiteMildew']<=1) muts.push(['whiteMildew',0.5]); + if (neighsM['meddleweed']>=1 && neighs['meddleweed']<=3) muts.push(['meddleweed',0.15]); + + if (neighsM['shimmerlily']>=1 && neighsM['whiteChocoroot']>=1) muts.push(['whiskerbloom',0.01]); + if (neighsM['shimmerlily']>=1 && neighsM['whiskerbloom']>=1) muts.push(['chimerose',0.05]); + if (neighsM['chimerose']>=2) muts.push(['chimerose',0.005]); + if (neighsM['whiskerbloom']>=2) muts.push(['nursetulip',0.05]); + if (neighsM['chocoroot']>=1 && neighsM['keenmoss']>=1) muts.push(['drowsyfern',0.005]); + if ((neighsM['cronerice']>=1 && neighsM['keenmoss']>=1) || (neighsM['cronerice']>=1 && neighsM['whiteMildew']>=1)) muts.push(['wardlichen',0.005]); + if (neighsM['wardlichen']>=1 && neighs['wardlichen']<2) muts.push(['wardlichen',0.05]); + if (neighsM['greenRot']>=1 && neighsM['brownMold']>=1) muts.push(['keenmoss',0.1]); + if (neighsM['keenmoss']>=1 && neighs['keenmoss']<2) muts.push(['keenmoss',0.05]); + if (neighsM['chocoroot']>=1 && neighsM['bakeberry']>=1) muts.push(['queenbeet',0.01]); + if (neighsM['queenbeet']>=8) muts.push(['queenbeetLump',0.001]); + if (neighsM['queenbeet']>=2) muts.push(['duketater',0.001]); + + if (neighsM['crumbspore']>=1 && neighs['crumbspore']<=1) muts.push(['crumbspore',0.07]); + if (neighsM['crumbspore']>=1 && neighsM['thumbcorn']>=1) muts.push(['glovemorel',0.02]); + if (neighsM['crumbspore']>=1 && neighsM['shimmerlily']>=1) muts.push(['cheapcap',0.04]); + if (neighsM['doughshroom']>=1 && neighsM['greenRot']>=1) muts.push(['foolBolete',0.04]); + if (neighsM['crumbspore']>=2) muts.push(['doughshroom',0.005]); + if (neighsM['doughshroom']>=1 && neighs['doughshroom']<=1) muts.push(['doughshroom',0.07]); + if (neighsM['doughshroom']>=2) muts.push(['crumbspore',0.005]); + if (neighsM['crumbspore']>=1 && neighsM['brownMold']>=1) muts.push(['wrinklegill',0.06]); + if (neighsM['whiteMildew']>=1 && neighsM['clover']>=1) muts.push(['greenRot',0.05]); + + if (neighsM['wrinklegill']>=1 && neighsM['elderwort']>=1) muts.push(['shriekbulb',0.001]); + if (neighsM['elderwort']>=5) muts.push(['shriekbulb',0.001]); + if (neighs['duketater']>=3) muts.push(['shriekbulb',0.005]); + if (neighs['doughshroom']>=4) muts.push(['shriekbulb',0.002]); + if (neighsM['queenbeet']>=5) muts.push(['shriekbulb',0.001]); + if (neighs['shriekbulb']>=1 && neighs['shriekbulb']<2) muts.push(['shriekbulb',0.005]); + + if (neighsM['bakerWheat']>=1 && neighsM['whiteChocoroot']>=1) muts.push(['tidygrass',0.002]); + if (neighsM['tidygrass']>=3 && neighsM['elderwort']>=3) muts.push(['everdaisy',0.002]); + if (neighsM['elderwort']>=1 && neighsM['crumbspore']>=1) muts.push(['ichorpuff',0.002]); + + return muts; + } + + M.computeBoostPlot=function() + { + //some plants apply effects to surrounding tiles + //this function computes those effects by creating a grid in which those effects stack + for (var y=0;y<6;y++) + { + for (var x=0;x<6;x++) + { + //age mult, power mult, weed mult + M.plotBoost[y][x]=[1,1,1]; + } + } + + var effectOn=function(X,Y,s,mult) + { + for (var y=Math.max(0,Y-s);y0) + { + var me=M.plantsById[tile[0]-1]; + var name=me.key; + var stage=0; + if (tile[1]>=me.mature) stage=4; + else if (tile[1]>=me.mature*0.666) stage=3; + else if (tile[1]>=me.mature*0.333) stage=2; + else stage=1; + + var soilMult=M.soilsById[M.soil].effMult; + var mult=soilMult; + + if (stage==1) mult*=0.1; + else if (stage==2) mult*=0.25; + else if (stage==3) mult*=0.5; + else mult*=1; + + //age mult, power mult, weed mult + /*if (name=='elderwort') effectOn(x,y,1,[1+0.03*mult,1,1]); + else if (name=='queenbeetLump') effectOn(x,y,1,[1,1-0.2*mult,1]); + else if (name=='nursetulip') effectOn(x,y,1,[1,1+0.2*mult,1]); + else if (name=='shriekbulb') effectOn(x,y,1,[1,1-0.05*mult,1]); + else if (name=='tidygrass') effectOn(x,y,2,[1,1,0]); + else if (name=='everdaisy') effectOn(x,y,1,[1,1,0]); + else if (name=='ichorpuff') effectOn(x,y,1,[1-0.5*mult,1-0.5*mult,1]);*/ + + var ageMult=1; + var powerMult=1; + var weedMult=1; + var range=0; + + if (name=='elderwort') {ageMult=1.03;range=1;} + else if (name=='queenbeetLump') {powerMult=0.8;range=1;} + else if (name=='nursetulip') {powerMult=1.2;range=1;} + else if (name=='shriekbulb') {powerMult=0.95;range=1;} + else if (name=='tidygrass') {weedMult=0;range=2;} + else if (name=='everdaisy') {weedMult=0;range=1;} + else if (name=='ichorpuff') {ageMult=0.5;powerMult=0.5;range=1;} + + //by god i hope these are right + if (ageMult>=1) ageMult=(ageMult-1)*mult+1; else if (mult>=1) ageMult=1/((1/ageMult)*mult); else ageMult=1-(1-ageMult)*mult; + if (powerMult>=1) powerMult=(powerMult-1)*mult+1; else if (mult>=1) powerMult=1/((1/powerMult)*mult); else powerMult=1-(1-powerMult)*mult; + + if (range>0) effectOn(x,y,range,[ageMult,powerMult,weedMult]); + } + } + } + } + + M.computeEffs=function() + { + M.toCompute=false; + var effs={ + cps:1, + click:1, + cursorCps:1, + grandmaCps:1, + goldenCookieGain:1, + goldenCookieFreq:1, + goldenCookieDur:1, + goldenCookieEffDur:1, + wrathCookieGain:1, + wrathCookieFreq:1, + wrathCookieDur:1, + wrathCookieEffDur:1, + reindeerGain:1, + reindeerFreq:1, + reindeerDur:1, + itemDrops:1, + milk:1, + wrinklerSpawn:1, + wrinklerEat:1, + upgradeCost:1, + buildingCost:1, + }; + + if (!M.freeze) + { + var soilMult=M.soilsById[M.soil].effMult; + + for (var y=0;y<6;y++) + { + for (var x=0;x<6;x++) + { + var tile=M.plot[y][x]; + if (tile[0]>0) + { + var me=M.plantsById[tile[0]-1]; + var name=me.key; + var stage=0; + if (tile[1]>=me.mature) stage=4; + else if (tile[1]>=me.mature*0.666) stage=3; + else if (tile[1]>=me.mature*0.333) stage=2; + else stage=1; + + var mult=soilMult; + + if (stage==1) mult*=0.1; + else if (stage==2) mult*=0.25; + else if (stage==3) mult*=0.5; + else mult*=1; + + mult*=M.plotBoost[y][x][1]; + + if (name=='bakerWheat') effs.cps+=0.01*mult; + else if (name=='thumbcorn') effs.click+=0.02*mult; + else if (name=='cronerice') effs.grandmaCps+=0.03*mult; + else if (name=='gildmillet') {effs.goldenCookieGain+=0.01*mult;effs.goldenCookieEffDur+=0.001*mult;} + else if (name=='clover') effs.goldenCookieFreq+=0.01*mult; + else if (name=='goldenClover') effs.goldenCookieFreq+=0.03*mult; + else if (name=='shimmerlily') {effs.goldenCookieGain+=0.01*mult;effs.goldenCookieFreq+=0.01*mult;effs.itemDrops+=0.01*mult;} + else if (name=='elderwort') {effs.wrathCookieGain+=0.01*mult;effs.wrathCookieFreq+=0.01*mult;effs.grandmaCps+=0.01*mult;} + else if (name=='bakeberry') effs.cps+=0.01*mult; + else if (name=='chocoroot') effs.cps+=0.01*mult; + else if (name=='whiteChocoroot') effs.goldenCookieGain+=0.01*mult; + + else if (name=='whiteMildew') effs.cps+=0.01*mult; + else if (name=='brownMold') effs.cps*=1-0.01*mult; + + else if (name=='meddleweed') {} + + else if (name=='whiskerbloom') effs.milk+=0.002*mult; + else if (name=='chimerose') {effs.reindeerGain+=0.01*mult;effs.reindeerFreq+=0.01*mult;} + + else if (name=='nursetulip') {effs.cps*=1-0.02*mult;} + else if (name=='drowsyfern') {effs.cps+=0.03*mult;effs.click*=1-0.05*mult;effs.goldenCookieFreq*=1-0.1*mult;} + else if (name=='wardlichen') {effs.wrinklerSpawn*=1-0.15*mult;effs.wrathCookieFreq*=1-0.02*mult;} + else if (name=='keenmoss') {effs.itemDrops+=0.03*mult;} + else if (name=='queenbeet') {effs.goldenCookieEffDur+=0.003*mult;effs.cps*=1-0.02*mult;} + else if (name=='queenbeetLump') {effs.cps*=1-0.1*mult;} + else if (name=='glovemorel') {effs.click+=0.04*mult;effs.cursorCps+=0.01*mult;effs.cps*=1-0.01*mult;} + else if (name=='cheapcap') {effs.upgradeCost*=1-0.002*mult;effs.buildingCost*=1-0.002*mult;} + else if (name=='foolBolete') {effs.goldenCookieFreq+=0.02*mult;effs.goldenCookieGain*=1-0.05*mult;effs.goldenCookieDur*=1-0.02*mult;effs.goldenCookieEffDur*=1-0.02*mult;} + else if (name=='wrinklegill') {effs.wrinklerSpawn+=0.02*mult;effs.wrinklerEat+=0.01*mult;} + else if (name=='greenRot') {effs.goldenCookieDur+=0.005*mult;effs.goldenCookieFreq+=0.01*mult;effs.itemDrops+=0.01*mult;} + else if (name=='shriekbulb') {effs.cps*=1-0.02*mult;} + } + } + } + } + M.effs=effs; + Game.recalculateGains=1; + } + + + M.soils={ + 'dirt':{ + name:'Dirt', + icon:0, + tick:5, + effMult:1, + weedMult:1, + req:0, + effsStr:'
• tick every 5 minutes
', + q:'Simple, regular old dirt that you\'d find in nature.', + }, + 'fertilizer':{ + name:'Fertilizer', + icon:1, + tick:3, + effMult:0.75, + weedMult:1.2, + req:50, + effsStr:'
• tick every 3 minutes
• passive plant effects -25%
• weeds appear 20% more
', + q:'Soil with a healthy helping of fresh manure. Plants grow faster but are less efficient.', + }, + 'clay':{ + name:'Clay', + icon:2, + tick:15, + effMult:1.25, + weedMult:1, + req:100, + effsStr:'
• tick every 15 minutes
• passive plant effects +25%
', + q:'Rich soil with very good water retention. Plants grow slower but are more efficient.', + }, + 'pebbles':{ + name:'Pebbles', + icon:3, + tick:5, + effMult:0.25, + weedMult:0.1, + req:200, + effsStr:'
• tick every 5 minutes
• passive plant effects -75%
35% chance of collecting seeds automatically when plants expire
• weeds appear 10 times less
', + q:'Dry soil made of small rocks tightly packed together. Not very conducive to plant health, but whatever falls off your crops will be easy to retrieve.
Useful if you\'re one of those farmers who just want to find new seeds without having to tend their garden too much.', + }, + 'woodchips':{ + name:'Wood chips', + icon:4, + tick:5, + effMult:0.25, + weedMult:0.1, + req:300, + effsStr:'
• tick every 5 minutes
• passive plant effects -75%
• plants spread and mutate 3 times more
• weeds appear 10 times less
', + q:'Soil made of bits and pieces of bark and sawdust. Helpful for young sprouts to develop, not so much for mature plants.', + }, + }; + M.soilsById=[];var n=0;for (var i in M.soils){M.soils[i].id=n;M.soils[i].key=i;M.soilsById[n]=M.soils[i];n++;} + + + M.tools={ + 'info':{ + name:'Garden information', + icon:3, + desc:'-', + descFunc:function() + { + var str=''; + if (M.freeze) str='Your garden is frozen, providing no effects.'; + else + { + var effs={ + cps:{n:'CpS'}, + click:{n:'cookies/click'}, + cursorCps:{n:'cursor CpS'}, + grandmaCps:{n:'grandma CpS'}, + goldenCookieGain:{n:'golden cookie gains'}, + goldenCookieFreq:{n:'golden cookie frequency'}, + goldenCookieDur:{n:'golden cookie duration'}, + goldenCookieEffDur:{n:'golden cookie effect duration'}, + wrathCookieGain:{n:'wrath cookie gains'}, + wrathCookieFreq:{n:'wrath cookie frequency'}, + wrathCookieDur:{n:'wrath cookie duration'}, + wrathCookieEffDur:{n:'wrath cookie effect duration'}, + reindeerGain:{n:'reindeer gains'}, + reindeerFreq:{n:'reindeer cookie frequency'}, + reindeerDur:{n:'reindeer cookie duration'}, + itemDrops:{n:'random drops'}, + milk:{n:'milk effects'}, + wrinklerSpawn:{n:'wrinkler spawn rate'}, + wrinklerEat:{n:'wrinkler appetite'}, + upgradeCost:{n:'upgrade costs',rev:true}, + buildingCost:{n:'building costs',rev:true}, + }; + + var effStr=''; + for (var i in M.effs) + { + if (M.effs[i]!=1 && effs[i]) + { + var amount=(M.effs[i]-1)*100; + effStr+='
• '+effs[i].n+' : '+(amount>0?'+':'-')+Beautify(Math.abs(M.effs[i]-1)*100,2)+'%
'; + } + } + if (effStr=='') effStr='
None.
'; + str+='
Combined effects of all your plants :
'+effStr; + } + str+='
'; + str+='• You can cross-breed plants by planting them close to each other; new plants will grow in the empty tiles next to them.
• Unlock new seeds by harvesting mature plants.
• When you ascend, your garden plants are reset, but you keep all the seeds you\'ve unlocked.
• Your garden has no effect and does not grow while the game is closed.
'; + return str; + }, + func:function(){}, + }, + 'harvestAll':{ + name:'Harvest all', + icon:0, + descFunc:function(){return 'Instantly harvest all plants in your garden.
'+((Game.keys[16] && Game.keys[17])?'You are holding shift+ctrl. Only mature, mortal plants will be harvested.':'Shift+ctrl+click to harvest only mature, mortal plants.');}, + func:function(){ + PlaySound('snd/toneTick.mp3'); + /*if (M.freeze){return false;}*/ + if (Game.keys[16] && Game.keys[17]) M.harvestAll(0,1,1);//ctrl & shift, harvest only mature non-immortal plants + else M.harvestAll(); + }, + }, + 'freeze':{ + name:'Freeze', + icon:1, + descFunc:function() + { + return 'Cryogenically preserve your garden.
Plants no longer grow, spread or die; they provide no benefits.
Soil cannot be changed.
Using this will effectively pause your garden.
';//'+((M.nextFreeze>Date.now())?'You will be able to freeze your garden again in '+Game.sayTime((M.nextFreeze-Date.now())/1000*30+30,-1)+'.':'After unfreezing your garden, you must wait 10 minutes to freeze it again.')+' + }, + func:function(){ + //if (!M.freeze && M.nextFreeze>Date.now()) return false; + PlaySound('snd/toneTick.mp3'); + M.freeze=(M.freeze?0:1); + if (M.freeze) + { + M.computeEffs(); + PlaySound('snd/freezeGarden.mp3'); + this.classList.add('on'); + l('gardenContent').classList.add('gardenFrozen'); + + + for (var y=0;y<6;y++) + { + for (var x=0;x<6;x++) + { + var tile=M.plot[y][x]; + if (tile[0]>0) + { + var me=M.plantsById[tile[0]-1]; + var age=tile[1]; + if (me.key=='cheapcap' && Math.random()<0.15) + { + M.plot[y][x]=[0,0]; + if (me.onKill) me.onKill(x,y,age); + M.toRebuild=true; + } + } + } + } + } + else + { + //M.nextFreeze=Date.now()+(Game.Has('Turbo-charged soil')?1:(1000*60*10)); + M.computeEffs(); + this.classList.remove('on'); + l('gardenContent').classList.remove('gardenFrozen'); + } + }, + isOn:function(){if (M.freeze){l('gardenContent').classList.add('gardenFrozen');}else{l('gardenContent').classList.remove('gardenFrozen');}return M.freeze;}, + }, + 'convert':{ + name:'Sacrifice garden', + icon:2, + desc:'A swarm of sugar hornets comes down on your garden, destroying every plant as well as every seed you\'ve unlocked - leaving only a Baker\'s wheat seed.
In exchange, they will grant you 10 sugar lumps.
This action is only available with a complete seed log.', + func:function(){PlaySound('snd/toneTick.mp3');M.askConvert();}, + isDisplayed:function(){if (M.plantsUnlockedN>=M.plantsN) return true; else return false;}, + }, + }; + M.toolsById=[];var n=0;for (var i in M.tools){M.tools[i].id=n;M.tools[i].key=i;M.toolsById[n]=M.tools[i];n++;} + + + M.plot=[]; + for (var y=0;y<6;y++) + { + M.plot[y]=[]; + for (var x=0;x<6;x++) + { + M.plot[y][x]=[0,0]; + } + } + M.plotBoost=[]; + for (var y=0;y<6;y++) + { + M.plotBoost[y]=[]; + for (var x=0;x<6;x++) + { + //age mult, power mult, weed mult + M.plotBoost[y][x]=[1,1,1]; + } + } + + M.tileSize=40; + + M.seedSelected=-1; + + M.soil=0; + M.nextSoil=0;//timestamp for when soil will be ready to change again + + M.stepT=1;//in seconds + M.nextStep=0;//timestamp for next step tick + + M.harvests=0; + M.harvestsTotal=0; + + M.loopsMult=1; + + M.toRebuild=false; + M.toCompute=false; + + M.freeze=0; + M.nextFreeze=0;//timestamp for when we can freeze again; unused, but still stored + + M.getCost=function(me) + { + if (Game.Has('Turbo-charged soil')) return 0; + return Math.max(me.costM,Game.cookiesPs*me.cost*60)*(Game.HasAchiev('Seedless to nay')?0.95:1); + } + + M.getPlantDesc=function(me) + { + var children=''; + if (me.children.length>0) + { + children+='
'; + for (var i in me.children) + { + if (!M.plants[me.children[i]]) console.log('No plant named '+me.children[i]); + else + { + var it=M.plants[me.children[i]]; + if (it.unlocked) children+='
'; + else children+='
'; + } + } + children+='
'; + } + + return '
'+ + (!me.immortal?('
Average lifespan : '+Game.sayTime(((100/(me.ageTick+me.ageTickR/2))*M.stepT)*30,-1)+' ('+Beautify(Math.ceil((100/((me.ageTick+me.ageTickR/2)))*(1)))+' ticks)
'):'')+ + '
Average maturation : '+Game.sayTime(((100/((me.ageTick+me.ageTickR/2)))*(me.mature/100)*M.stepT)*30,-1)+' ('+Beautify(Math.ceil((100/((me.ageTick+me.ageTickR/2)))*(me.mature/100)))+' ticks)
'+ + (me.weed?'
Is a weed
':'')+ + (me.fungus?'
Is a fungus
':'')+ + (me.detailsStr?('
Details : '+me.detailsStr+'
'):'')+ + (children!=''?('
Possible mutations : '+children+'
'):'')+ + '
'+ + '
Effects :
'+ + '
'+me.effsStr+'
'+ + (me.q?(''+me.q+''):'')+ + '
'; + } + M.canPlant=function(me) + { + if (Game.cookies>=M.getCost(me)) return true; else return false; + } + + M.cursor=1; + M.hideCursor=function() + { + M.cursor=0; + } + M.showCursor=function() + { + M.cursor=1; + } + + M.soilTooltip=function(id) + { + return function(){ + var me=M.soilsById[id]; + var str='
'+ + (M.parent.amountSoil unlocked at '+me.req+' farms.
' + ):('
'+ + '
'+me.name+'
'+((M.soil==me.id)?'Your field is currently using this soil.':(M.nextSoil>Date.now())?'You will be able to change your soil again in '+Game.sayTime((M.nextSoil-Date.now())/1000*30+30,-1)+'.':'Click to use this type of soil for your whole field.')+'
'+ + '
'+ + '
'+ + '
Effects :
'+ + '
'+me.effsStr+'
'+ + (me.q?(''+me.q+''):'')+ + '
'))+ + '
'; + return str; + }; + } + M.seedTooltip=function(id) + { + return function(){ + var me=M.plantsById[id]; + var str='
'+ + '
'+ + '
'+ + '
'+ + (me.plantable?('
Planting cost :
'+Beautify(Math.round(shortenNumber(M.getCost(me))))+'
'+Game.sayTime(me.cost*60*30,-1)+' of CpS,
minimum '+Beautify(me.costM)+' cookies
'):'')+ + '
'+me.name+' seed
'+(me.plantable?'Click to select this seed for planting.':'This seed cannot be planted.')+'
Shift+ctrl+click to harvest all mature plants of this type.
'+ + '
'+ + M.getPlantDesc(me)+ + '
'; + return str; + }; + } + M.toolTooltip=function(id) + { + return function(){ + var me=M.toolsById[id]; + var icon=[me.icon,35]; + var str='
'+ + '
'+ + '
'+me.name+'
'+ + '
'+ + '
'+ + (me.descFunc?me.descFunc():me.desc)+ + '
'+ + '
'; + return str; + }; + } + M.tileTooltip=function(x,y) + { + return function(){ + if (Game.keys[16]) return ''; + var tile=M.plot[y][x]; + if (tile[0]==0) + { + var me=(M.seedSelected>=0)?M.plantsById[M.seedSelected]:0; + var str='
'+ + '
Empty tile
'+'
'+ + 'This tile of soil is empty.
Pick a seed and plant something!'+ + (me?'
Click to plant '+me.name+' for '+Beautify(Math.round(M.getCost(me)))+'.
(Shift-click to plant multiple.)
(Holding the shift key pressed will also hide tooltips.)':'')+ + (M.plotBoost[y][x]!=[1,1,1]?(''+ + (M.plotBoost[y][x][0]!=1?'
Aging multiplier : '+Beautify(M.plotBoost[y][x][0]*100)+'%':'')+ + (M.plotBoost[y][x][1]!=1?'
Effect multiplier : '+Beautify(M.plotBoost[y][x][1]*100)+'%':'')+ + (M.plotBoost[y][x][2]!=1?'
Weeds/fungus repellent : '+Beautify(100-M.plotBoost[y][x][2]*100)+'%':'')+ + '
' + ):'')+ + '
'+ + '
'; + return str; + } + else + { + var me=M.plantsById[tile[0]-1]; + var stage=0; + if (tile[1]>=me.mature) stage=4; + else if (tile[1]>=me.mature*0.666) stage=3; + else if (tile[1]>=me.mature*0.333) stage=2; + else stage=1; + var icon=[stage,me.icon]; + var str='
'+ + '
'+ + '
'+me.name+'
This plant is growing here.
'+ + '
'+ + '
'+ + '
'+ + '
'+ + '
'+ + '
'+ + '
'+ + '
'+ + '

'+ + 'Stage : '+['bud','sprout','bloom','mature'][stage-1]+'
'+ + ''+(stage==1?'Plant effects : 10%':stage==2?'Plant effects : 25%':stage==3?'Plant effects : 50%':'Plant effects : 100%; may reproduce, will drop seed when harvested')+''+ + '
'+( + stage<4?( + 'Mature in about '+Game.sayTime(((100/(M.plotBoost[y][x][0]*(me.ageTick+me.ageTickR/2)))*((me.mature-tile[1])/100)*M.stepT)*30,-1)+' ('+Beautify(Math.ceil((100/(M.plotBoost[y][x][0]*(me.ageTick+me.ageTickR/2)))*((me.mature-tile[1])/100)))+' tick'+(Math.ceil((100/(M.plotBoost[y][x][0]*(me.ageTick+me.ageTickR/2)))*((me.mature-tile[1])/100))==1?'':'s')+')' + ):( + !me.immortal?( + 'Decays in about '+Game.sayTime(((100/(M.plotBoost[y][x][0]*(me.ageTick+me.ageTickR/2)))*((100-tile[1])/100)*M.stepT)*30,-1)+' ('+Beautify(Math.ceil((100/(M.plotBoost[y][x][0]*(me.ageTick+me.ageTickR/2)))*((100-tile[1])/100)))+' tick'+(Math.ceil((100/(M.plotBoost[y][x][0]*(me.ageTick+me.ageTickR/2)))*((100-tile[1])/100))==1?'':'s')+')' + ): + 'Does not decay' + ) + )+''+ + //'
'+M.plotBoost[y][x]+'
'+ + (M.plotBoost[y][x]!=[1,1,1]?(''+ + (M.plotBoost[y][x][0]!=1?'
Aging multiplier : '+Beautify(M.plotBoost[y][x][0]*100)+'%':'')+ + (M.plotBoost[y][x][1]!=1?'
Effect multiplier : '+Beautify(M.plotBoost[y][x][1]*100)+'%':'')+ + (M.plotBoost[y][x][2]!=1?'
Weeds/fungus repellent : '+Beautify(100-M.plotBoost[y][x][2]*100)+'%':'')+ + '
' + ):'')+ + '
'+ + '
'+ + //'
Click to harvest'+(M.seedSelected>=0?', planting '+M.plantsById[M.seedSelected].name+'
for '+Beautify(Math.round(M.getCost(M.plantsById[M.seedSelected])))+' in its place':'')+'.
'+ + '
Click to '+(stage==4?'harvest':'unearth')+'.
'+ + '
'+ + M.getPlantDesc(me)+ + '
'; + return str; + } + }; + } + + M.refillTooltip=function(){ + return '
Click to refill your soil timer and trigger 1 plant growth tick with x3 spread and mutation rate for 1 sugar lump.'+ + (Game.canRefillLump()?'
(can be done once every '+Game.sayTime(Game.getLumpRefillMax(),-1)+')':('
(usable again in '+Game.sayTime(Game.getLumpRefillRemaining()+Game.fps,-1)+')'))+ + '
'; + }; + + M.buildPanel=function() + { + if (!l('gardenSeeds')) return false; + var str=''; + for (var i in M.plants) + { + var me=M.plants[i]; + var icon=[0,me.icon]; + str+='
'; + str+='
'; + str+='
'; + } + l('gardenSeeds').innerHTML=str; + + for (var i in M.plants) + { + var me=M.plants[i]; + me.l=l('gardenSeed-'+me.id); + AddEvent(me.l,'click',function(me){return function() + { + if (/* !M.freeze && */Game.keys[16] && Game.keys[17])//shift & ctrl + { + //harvest all mature of type + M.harvestAll(me,1); + return false; + } + if (!me.plantable && !Game.sesame) return false; + if (M.seedSelected==me.id){M.seedSelected=-1;} + else {M.seedSelected=me.id;PlaySound('snd/toneTick.mp3');} + for (var i in M.plants) + { + var it=M.plants[i]; + if (it.id==M.seedSelected){it.l.classList.add('on');} + else {it.l.classList.remove('on');} + } + }}(me)); + AddEvent(me.l,'mouseover',M.hideCursor); + AddEvent(me.l,'mouseout',M.showCursor); + if (me.unlocked) me.l.classList.remove('locked'); + } + + var str=''; + for (var i in M.tools) + { + var me=M.tools[i]; + var icon=[me.icon,35]; + str+='
'; + str+='
'; + str+='
'; + } + l('gardenTools').innerHTML=str; + + for (var i in M.tools) + { + var me=M.tools[i]; + AddEvent(l('gardenTool-'+me.id),'click',me.func); + AddEvent(l('gardenTool-'+me.id),'mouseover',M.hideCursor); + AddEvent(l('gardenTool-'+me.id),'mouseout',M.showCursor); + } + + var str=''; + for (var i in M.soils) + { + var me=M.soils[i]; + var icon=[me.icon,34]; + str+='
'; + str+='
'; + str+='
'; + } + l('gardenSoils').innerHTML=str; + + for (var i in M.soils) + { + var me=M.soils[i]; + AddEvent(l('gardenSoil-'+me.id),'click',function(me){return function(){ + if (M.freeze || M.soil==me.id || M.nextSoil>Date.now() || M.parent.amount