Complete overhaul of code structure and relevant files (#639)
This commit is contained in:
17
src/Cache/Stats/Reindeer.js
Normal file
17
src/Cache/Stats/Reindeer.js
Normal file
@@ -0,0 +1,17 @@
|
||||
/* eslint-disable no-unused-vars */
|
||||
import { CacheSeaSpec } from '../VariablesAndData';
|
||||
|
||||
/**
|
||||
* This functions caches the reward of popping a reindeer
|
||||
* It is called by CM.Main.Loop() and CM.Cache.InitCache()
|
||||
* @global {number} CM.Cache.SeaSpec The reward for popping a reindeer
|
||||
*/
|
||||
export default function CacheSeasonSpec() {
|
||||
if (Game.season === 'christmas') {
|
||||
let val = Game.cookiesPs * 60;
|
||||
if (Game.hasBuff('Elder frenzy')) val *= 0.5;
|
||||
if (Game.hasBuff('Frenzy')) val *= 0.75;
|
||||
CacheSeaSpec = Math.max(25, val);
|
||||
if (Game.Has('Ho ho ho-flavored frosting')) CacheSeaSpec *= 2;
|
||||
}
|
||||
}
|
||||
Reference in New Issue
Block a user