Skip to content

Commit

Permalink
Merge pull request #68 from Tendsty/develop
Browse files Browse the repository at this point in the history
bugfix patch 1.5.1
  • Loading branch information
Tendsty authored Sep 28, 2024
2 parents 6d476ae + 4935595 commit 2091713
Show file tree
Hide file tree
Showing 25 changed files with 179 additions and 47 deletions.
4 changes: 2 additions & 2 deletions package-lock.json

Some generated files are not rendered by default. Learn more about how customized files appear on GitHub.

2 changes: 1 addition & 1 deletion package.json
Original file line number Diff line number Diff line change
@@ -1,6 +1,6 @@
{
"name": "gooboo",
"version": "1.5.0",
"version": "1.5.1",
"description": "An idle game",
"author": "Tendsty",
"main": "main.js",
Expand Down
2 changes: 1 addition & 1 deletion public/version.txt
Original file line number Diff line number Diff line change
@@ -1 +1 @@
1.5.0
1.5.1
10 changes: 6 additions & 4 deletions src/components/partial/farm/Inventory.vue
Original file line number Diff line number Diff line change
Expand Up @@ -20,10 +20,12 @@
</template>
</div>
</template>
<v-select v-else class="w-100" outlined hide-details clearable item-value="name" v-model="selectedPlaceable" :items="placeableList" @change="selectPlaceable">
<template v-slot:selection="{ item }"><placeable-select-display :item="item" is-simple></placeable-select-display></template>
<template v-slot:item="{ item }"><placeable-select-display :item="item"></placeable-select-display></template>
</v-select>
<div v-else class="ma-1">
<v-select class="w-100" outlined hide-details clearable item-value="name" v-model="selectedPlaceable" :items="placeableList" @change="selectPlaceable">
<template v-slot:selection="{ item }"><placeable-select-display :item="item" is-simple></placeable-select-display></template>
<template v-slot:item="{ item }"><placeable-select-display :item="item"></placeable-select-display></template>
</v-select>
</div>
<div v-if="unlock.farmFertilizer.see && selectedCropName" class="d-flex flex-wrap justify-center ma-1">
<consumable v-for="(item, key) in fertilizers" class="ma-1" :key="'fertilizer-' + key" :name="`farm_${key}`" :is-selected="selectedFertilizerName === key" @click="selectFertilizer(key)">
<fertilizer-card :name="key"></fertilizer-card>
Expand Down
17 changes: 9 additions & 8 deletions src/components/partial/gallery/Color.vue
Original file line number Diff line number Diff line change
Expand Up @@ -82,11 +82,13 @@
<v-btn color="primary" :disabled="!canAfford || disabled" @click="convertOne">{{ $vuetify.lang.t('$vuetify.gooboo.convert') }}</v-btn>
</div>
</template>
<div class="d-flex align-center mt-0">
<div class="d-flex justify-center align-center mt-0">
<price-tag class="ma-1" v-for="(amount, currency) in conversionPrice" :key="currency" :currency="currency" :amount="amount"></price-tag>
<v-icon class="ma-1">mdi-transfer-right</v-icon>
<price-tag class="ma-1" :currency="`gallery_${name}`" :amount="conversionMult" add></price-tag>
<price-tag class="ma-1" :currency="`gallery_${name}`" :amount="conversionGain" add></price-tag>
</div>
<alert-text type="info">{{ $vuetify.lang.t('$vuetify.gallery.allConverterInfo') }}</alert-text>
<alert-text v-if="canAfford && converterOverload > 1" type="info">{{ $vuetify.lang.t('$vuetify.gallery.converterOverload', $formatNum(converterOverload, true)) }}</alert-text>
</gb-tooltip>
<v-icon v-if="showTransferArrow" class="color-generate-arrow">mdi-transfer-up</v-icon>
</template>
Expand Down Expand Up @@ -150,12 +152,11 @@ export default {
canAfford() {
return this.$store.getters['currency/canAfford'](this.conversionPrice);
},
conversionMult() {
const colorPrice = this.$store.getters['gallery/conversionColorPrice'](this.name);
return Math.max(1, Math.min(
this.$store.state.currency.gallery_converter.value / this.conversionPrice.gallery_converter,
this.$store.state.currency[colorPrice.name].value / colorPrice.amount
)) * this.$store.getters['mult/get'](`gallery${ this.statBaseName }Conversion`);
converterOverload() {
return this.$store.getters['gallery/converterOverload'](this.name);
},
conversionGain() {
return this.canAfford ? this.$store.getters['gallery/conversionGain'](this.name) : this.$store.getters['mult/get'](`gallery${ capitalize(this.name) }Conversion`);
},
isPremium() {
if (this.name === 'beauty') {
Expand Down
2 changes: 1 addition & 1 deletion src/components/partial/horde/ActiveTooltip.vue
Original file line number Diff line number Diff line change
Expand Up @@ -39,7 +39,7 @@
<span class="indigo--text" :class="`text--${ themeModifier }`" v-if="effect.int !== undefined">+{{ $formatNum(effect.int * healingMult * 100, true) }}% <v-icon size="12" :color="`indigo ${ themeModifier }`">mdi-lightbulb-on</v-icon></span>
<span>)</span>
</div>
<div v-if="critEffect > 0" class="ml-2 mt-n1">(can crit at {{ $formatNum(critEffect * 100) }}% efficiency)</div>
<div v-if="critEffect > 0" class="ml-2 mt-n1">({{ $vuetify.lang.t(`$vuetify.horde.active.canCrit`, $formatNum(critEffect * 100)) }})</div>
</div>
</template>

Expand Down
2 changes: 2 additions & 0 deletions src/components/partial/horde/Item.vue
Original file line number Diff line number Diff line change
Expand Up @@ -243,6 +243,8 @@ export default {
elem.effect.forEach((buff, bindex) => {
buffs.push({type: buff.type, name: buff.name, before: buff.value, after: after[key].effect[bindex].value, isBuff: true});
});
} else if (elem.type === 'hordeActive' && elem.canCrit !== undefined) {
buffs.push({type: 'hordeActiveCrit', name: elem.name, before: elem.canCrit, after: after[key].canCrit, isBuff: false});
}
return {type: elem.type, name: elem.name, before: elem.value, after: after[key].value, isBuff: false};
});
Expand Down
2 changes: 1 addition & 1 deletion src/components/partial/render/MultStat.vue
Original file line number Diff line number Diff line change
Expand Up @@ -45,7 +45,7 @@ export default {
return this.$store.state.mult.items[this.mult];
},
display() {
if (this.type === 'hordeActive') {
if (this.type === 'hordeActive' || this.type === 'hordeActiveCrit') {
return ['revive', 'divisionShield'].includes(this.mult) ? 'number' : (['stun', 'silence'].includes(this.mult) ? 'time' : 'percent');
} else if (this.type === 'hordeCooldown' || this.type === 'hordeBuff') {
return 'time';
Expand Down
3 changes: 3 additions & 0 deletions src/components/partial/upgrade/DisplayRow.vue
Original file line number Diff line number Diff line change
Expand Up @@ -136,6 +136,9 @@ export default {
case 'hordeActive':
cacheValue = this.$vuetify.lang.t(`$vuetify.horde.active.${this.name}.0`) + ' ' + this.$vuetify.lang.t(`$vuetify.horde.active.${this.name}.1`);
break;
case 'hordeActiveCrit':
cacheValue = this.$vuetify.lang.t(`$vuetify.horde.active.canCritDiff`);
break;
case 'hordeBuff':
cacheValue = this.$vuetify.lang.t(`$vuetify.horde.active.buff.duration`);
break;
Expand Down
2 changes: 1 addition & 1 deletion src/components/render/Currency.vue
Original file line number Diff line number Diff line change
@@ -1,6 +1,6 @@
<style scoped>
.render-currency-small {
width: 220px;
width: 210px;
font-size: 16px;
}
.render-currency-large {
Expand Down
2 changes: 2 additions & 0 deletions src/js/modules/meta.js
Original file line number Diff line number Diff line change
Expand Up @@ -20,6 +20,7 @@ import v1_3_6 from "./patchnote/v1_3_6";
import v1_4_1 from "./patchnote/v1_4_1";
import v1_5_0 from "./patchnote/v1_5_0";
import v1_4_2 from "./patchnote/v1_4_2";
import v1_5_1 from "./patchnote/v1_5_1";

export default {
name: 'meta',
Expand Down Expand Up @@ -55,6 +56,7 @@ export default {
store.commit('system/initTheme', {name: key, ...elem});
}
for (const [key, elem] of Object.entries({
'1.5.1': v1_5_1,
'1.5.0': v1_5_0,
'1.4.2': v1_4_2,
'1.4.1': v1_4_1,
Expand Down
24 changes: 24 additions & 0 deletions src/js/modules/migration/v1_5_1.js
Original file line number Diff line number Diff line change
@@ -0,0 +1,24 @@
export default function(save) {
// Use new school subject format
if (save.school) {
for (const [key, elem] of Object.entries(save.school)) {
save.school[key] = [elem.grade, elem.currentGrade, elem.progress];
}
}

// Use new smeltery format
if (save.mining && save.mining.smeltery) {
for (const [key, elem] of Object.entries(save.mining.smeltery)) {
save.mining.smeltery[key] = [elem.progress, elem.stored, elem.total];
}
}

// Use new offering format
if (save.village && save.village.offering) {
for (const [key, elem] of Object.entries(save.village.offering)) {
save.village.offering[key] = [elem.offeringBought, elem.upgradeBought];
}
}

return save;
}
8 changes: 4 additions & 4 deletions src/js/modules/mining.js
Original file line number Diff line number Diff line change
Expand Up @@ -489,7 +489,7 @@ export default {
let smelteryData = {};
for (const [key, elem] of Object.entries(store.state.mining.smeltery)) {
if (elem.total > 0) {
smelteryData[key] = {progress: elem.progress, stored: elem.stored, total: elem.total};
smelteryData[key] = [elem.progress, elem.stored, elem.total];
}
}
if (Object.keys(smelteryData).length > 0) {
Expand Down Expand Up @@ -524,9 +524,9 @@ export default {
if (data.smeltery !== undefined) {
for (const [key, elem] of Object.entries(data.smeltery)) {
if (store.state.mining.smeltery[key] !== undefined) {
store.commit('mining/updateSmelteryKey', {name: key, key: 'progress', value: elem.progress});
store.commit('mining/updateSmelteryKey', {name: key, key: 'stored', value: elem.stored});
store.commit('mining/updateSmelteryKey', {name: key, key: 'total', value: elem.total});
store.commit('mining/updateSmelteryKey', {name: key, key: 'progress', value: elem[0]});
store.commit('mining/updateSmelteryKey', {name: key, key: 'stored', value: elem[1]});
store.commit('mining/updateSmelteryKey', {name: key, key: 'total', value: elem[2]});
}
}
}
Expand Down
50 changes: 50 additions & 0 deletions src/js/modules/patchnote/v1_5_1.js
Original file line number Diff line number Diff line change
@@ -0,0 +1,50 @@
export default {
day: '2024-09-28',
content: {
card: [
{
type: 'bugfix',
text: '392'
},
],
horde: [
{
unlock: 'hordeItems',
type: 'bugfix',
text: '388'
},
],
farm: [
{
type: 'bugfix',
text: '389'
},
],
gallery: [
{
unlock: 'galleryConversion',
type: 'balance',
text: '390',
balance: 'nerf',
before: '4x',
after: '16x'
},
{
unlock: 'galleryConversion',
type: 'new',
text: '391'
},
{
unlock: 'galleryConversion',
type: 'clarity',
text: '394'
},
],
horde_1: [
{
type: 'bugfix',
text: '393'
},
],
}
}
8 changes: 4 additions & 4 deletions src/js/modules/school.js
Original file line number Diff line number Diff line change
Expand Up @@ -43,17 +43,17 @@ export default {
let obj = {};
for (const [key, elem] of Object.entries(store.state.school)) {
if (elem.grade > 0 || elem.progress > 0) {
obj[key] = {grade: elem.grade, currentGrade: elem.currentGrade, progress: elem.progress};
obj[key] = [elem.grade, elem.currentGrade, elem.progress];
}
}
return obj;
},
loadGame(data) {
for (const [key, elem] of Object.entries(data)) {
if (store.state.school[key] !== undefined) {
store.commit('school/updateKey', {name: key, key: 'grade', value: elem.grade});
store.commit('school/updateKey', {name: key, key: 'currentGrade', value: elem.currentGrade});
store.commit('school/updateKey', {name: key, key: 'progress', value: elem.progress});
store.commit('school/updateKey', {name: key, key: 'grade', value: elem[0]});
store.commit('school/updateKey', {name: key, key: 'currentGrade', value: elem[1]});
store.commit('school/updateKey', {name: key, key: 'progress', value: elem[2]});
}
}
}
Expand Down
6 changes: 3 additions & 3 deletions src/js/modules/village.js
Original file line number Diff line number Diff line change
Expand Up @@ -391,7 +391,7 @@ export default {
obj.offering = {};
for (const [key, elem] of Object.entries(store.state.village.offering)) {
if (elem.offeringBought > 0 || elem.upgradeBought > 0) {
obj.offering[key] = {offeringBought: elem.offeringBought, upgradeBought: elem.upgradeBought};
obj.offering[key] = [elem.offeringBought, elem.upgradeBought];
}
}
}
Expand Down Expand Up @@ -445,8 +445,8 @@ export default {
if (data.offering !== undefined) {
for (const [key, elem] of Object.entries(data.offering)) {
if (store.state.village.offering[key] !== undefined) {
store.commit('village/updateOfferingKey', {name: key, key: 'offeringBought', value: elem.offeringBought});
store.commit('village/updateOfferingKey', {name: key, key: 'upgradeBought', value: elem.upgradeBought});
store.commit('village/updateOfferingKey', {name: key, key: 'offeringBought', value: elem[0]});
store.commit('village/updateOfferingKey', {name: key, key: 'upgradeBought', value: elem[1]});
}
}
}
Expand Down
2 changes: 2 additions & 0 deletions src/js/savefile.js
Original file line number Diff line number Diff line change
Expand Up @@ -25,8 +25,10 @@ import v1_4_0 from "./modules/migration/v1_4_0";
import v1_4_1 from "./modules/migration/v1_4_1";
import { simpleHash } from "./utils/random";
import v1_5_0 from "./modules/migration/v1_5_0";
import v1_5_1 from "./modules/migration/v1_5_1";

const migrations = {
'1.5.1': v1_5_1,
'1.5.0': v1_5_0,
'1.4.1': v1_4_1,
'1.4.0': v1_4_0,
Expand Down
4 changes: 4 additions & 0 deletions src/lang/de.js
Original file line number Diff line number Diff line change
Expand Up @@ -1872,6 +1872,8 @@ export default {
duration: 'Schubdauer',
suffix: '(Schub)',
},
canCrit: 'kann mit {0}% Effizienz kritisch treffen',
canCritDiff: 'Aktive kritische Effizienz',
reviveAll: 'Stelle alle Wiederbelebungen her',
removeStun: 'Entferne Betäubungen',
},
Expand Down Expand Up @@ -2236,6 +2238,8 @@ export default {
openPackage: 'Öffnen',
colorGainReduced: 'Zusätzliches Einkommen wird nach 100 Farbe auf die Quadratwurzel reduziert',
drumCompounding: 'Um diese Farbtrommel finden zu können, musst du auch alle Farbtrommeln der vorherigen Farben im selben Paket finden. Dies reduziert die effektive Chance, diese Farbtrommel zu finden',
allConverterInfo: 'Das Umwandeln einer Farbe verbraucht immer alle Konverter',
converterOverload: 'Du hast deutlich mehr Konverter als Farbe für diese Umwandlung, weshalb diese Umwandlung x{0} Farbe gibt',
idea: {
tier: 'Stufe-{0}-Idee',
unlock: 'Idee freischalten',
Expand Down
9 changes: 9 additions & 0 deletions src/lang/de/patchnote.js
Original file line number Diff line number Diff line change
Expand Up @@ -468,6 +468,15 @@ export default {
385: 'Es kann nun eine Zutat als Lieblingszutat markiert werden',
386: 'Säcke tauchen nun bei hohen Magiemengen auf',
387: 'Sämtliche Ausrüstung in der Horde wurde abgelegt, vergiss\' nicht sie neu anzulegen!',

// v1.5.1
388: 'Ausrüstung mit steigender kritischer Effizienz zeigen das nun beim Verbessern an',
389: 'Ein Fehler wurde behoben, wo bei manchen Browsern alle Währungen in einer Spalte dargestellt wurden',
390: 'Konverter pro Farbstufe gebraucht',
391: 'Du erhältst nun mehr Farbe beim Umwandeln, wenn du deutlich mehr Konverter als nötige Farbe hast',
392: 'Kartenkraft wird nun korrekt beim Prestige zurückgesetzt',
393: 'Der Courage-Multiplikator einzelner Klassen wird nun korrekt beim Prestige zurückgesetzt',
394: 'Der Tooltip bei der Umwandlung zeigt nun an, dass alle Konverter verbraucht werden',
},
v: {
1: {
Expand Down
4 changes: 4 additions & 0 deletions src/lang/en.js
Original file line number Diff line number Diff line change
Expand Up @@ -1872,6 +1872,8 @@ export default {
duration: 'Buff duration',
suffix: '(buff)',
},
canCrit: 'can crit at {0}% efficiency',
canCritDiff: 'Active crit efficiency',
reviveAll: 'Refill all revives',
removeStun: 'Remove stuns',
},
Expand Down Expand Up @@ -2236,6 +2238,8 @@ export default {
openPackage: 'Open',
colorGainReduced: 'Additional gains are reduced to square root after 100 color',
drumCompounding: 'To be able to find this drum, you must also find all drums of previous colors in the same package. This reduces the effective chance of finding this drum',
allConverterInfo: 'Converting a color always consumes all converters',
converterOverload: 'You have way more converters than color for this conversion, resulting in x{0} conversion gain',
idea: {
tier: 'Tier {0} idea',
unlock: 'Unlock idea',
Expand Down
9 changes: 9 additions & 0 deletions src/lang/en/patchnote.js
Original file line number Diff line number Diff line change
Expand Up @@ -468,6 +468,15 @@ export default {
385: 'Added the option to mark an ingredient as favourite',
386: 'Sacks now appear for high magic amounts',
387: 'Unequipped all horde equipment, don\'t forget to equip it again!',

// v1.5.1
388: 'Fixed item actives with increasing crit efficiency not showing this on upgrade',
389: 'Fixed currencies showing all in one column in some browsers',
390: 'Converters needed per color tier',
391: 'You now get more color per conversion if you have way more converters than color needed',
392: 'Fixed card power not properly resetting on prestige',
393: 'Fixed the class courage gain multiplier not properly resetting on prestige',
394: 'The conversion tooltip now states that all converters will be used',
},
v: {
1: {
Expand Down
5 changes: 4 additions & 1 deletion src/store/card.js
Original file line number Diff line number Diff line change
Expand Up @@ -242,9 +242,12 @@ export default {
activateCards({ state, commit, dispatch }, feature) {
state.feature[feature].cardEquipped.forEach(card => {
state.card[card].reward.forEach(eff => {
dispatch('system/resetEffect', {type: eff.type, name: eff.name, multKey: `card_${card}`}, {root: true});
dispatch('system/resetEffect', {type: eff.type, name: eff.name, multKey: `card_${ card }`}, {root: true});
});
});
state.feature[feature].powerReward.forEach(elem => {
dispatch('system/resetEffect', {type: elem.type, name: elem.name, multKey: `cardPower_${ feature }`}, {root: true});
});

commit('updateKey', {type: 'feature', name: feature, key: 'cardEquipped', value: [...state.feature[feature].cardSelected]});
commit('updateKey', {type: 'feature', name: feature, key: 'cardSelected', value: []});
Expand Down
Loading

0 comments on commit 2091713

Please sign in to comment.