mirror of
https://github.com/sudoxnym/habitica.git
synced 2026-07-19 02:04:10 +00:00
remove log
This commit is contained in:
parent
21652c2670
commit
8b2af1ef56
1 changed files with 0 additions and 3 deletions
|
|
@ -55,15 +55,12 @@ schema.methods.incrementPerkCounterAndReward = async function incrementPerkCount
|
|||
// if perkMonthCount wasn't used before, initialize it.
|
||||
if (this.perkMonthCount == undefined && adding == 1) {
|
||||
this.perkMonthCount = (this.consecutive.count-1) % SUBSCRIPTION_BASIC_BLOCK_LENGTH;
|
||||
console.log(`initializing perk count with ${this.perkMonthCount}`);
|
||||
} else {
|
||||
this.perkMonthCount += adding;
|
||||
}
|
||||
console.log(this.perkMonthCount);
|
||||
|
||||
const perks = Math.floor(this.perkMonthCount / 3);
|
||||
if (perks > 0) {
|
||||
console.log(`giving benefits for ${perks} from ${this.perkMonthCount}, ${adding}`);
|
||||
this.consecutive.gemCapExtra += 5 * perks; // 5 extra Gems every 3 months
|
||||
// cap it at 50 (hard 25 limit + extra 25)
|
||||
if (this.consecutive.gemCapExtra > 25) this.consecutive.gemCapExtra = 25;
|
||||
|
|
|
|||
Loading…
Reference in a new issue