Merge pull request #3188 from IvarK/Lars-did-some-stuff

miscellaneous ui & qol improvements (basically: glyph dragging in cel7 is possible now)
This commit is contained in:
L4R5W 2022-11-15 15:56:17 +01:00 committed by GitHub
commit afee015d37
No known key found for this signature in database
GPG Key ID: 4AEE18F83AFDEB23
21 changed files with 74 additions and 47 deletions

View File

@ -138,7 +138,7 @@ export const Pelle = {
get uselessPerks() {
return [10, 12, 13, 14, 15, 16, 17, 30, 40, 41, 42, 43, 44, 45, 46, 51, 53,
60, 61, 62, 80, 81, 82, 83, 100, 105, 106, 201, 202, 203, 204];
60, 61, 62, 80, 81, 82, 83, 100, 104, 105, 106, 201, 202, 203, 204];
},
get specialGlyphEffect() {

View File

@ -232,13 +232,10 @@ export const Glyphs = {
return this.active[activeIndex];
},
equip(glyph, targetSlot) {
const pelleMaxGlyphs = 1;
const glyphsEquipped = Glyphs.active.filter(Boolean).length;
if (
Pelle.isDoomed &&
(
Pelle.isDisabled("glyphs") ||
glyphsEquipped >= pelleMaxGlyphs ||
["effarig", "reality", "cursed"].includes(glyph.type)
)
) return;

View File

@ -61,7 +61,7 @@ class NormalChallengeState extends GameMechanicState {
}
get isDisabled() {
return this.config.isDisabledInDoomed && Pelle.isDoomed;
return Pelle.isDoomed;
}
get lockedAt() {

View File

@ -1813,8 +1813,8 @@ GameDatabase.celestials.navigation = {
complete: () => {
if (Pelle.isUnlocked) return 1;
const imCost = Math.clampMax(emphasizeEnd(Math.log10(Currency.imaginaryMachines.value) / Math.log10(1.6e15)), 1);
let laitelaProgress = Laitela.isRunning ? Currency.eternityPoints.value.log10() / 4000 : 0;
if (Laitela.difficultyTier !== 8) laitelaProgress = 0;
let laitelaProgress = Laitela.isRunning ? Math.min(Currency.eternityPoints.value.log10() / 4000, 0.99) : 0;
if (Laitela.difficultyTier !== 8 || Glyphs.activeList.length > 1) laitelaProgress = 0;
else if (ImaginaryUpgrade(25).isAvailableForPurchase) laitelaProgress = 1;
return (imCost + laitelaProgress) / 2;
},
@ -1835,7 +1835,7 @@ GameDatabase.celestials.navigation = {
];
}
let laitelaString = `${format(Currency.eternityPoints.value)} / ${format("1e4000")} EP`;
if (!Laitela.isRunning || Laitela.difficultyTier !== 8) {
if (!Laitela.isRunning || Laitela.difficultyTier !== 8 || Glyphs.activeList.length > 1) {
laitelaString = "Lai'tela's Reality is still intact";
} else if (ImaginaryUpgrade(25).isAvailableForPurchase) {
laitelaString = "Lai'tela's Reality has been destroyed";
@ -1888,8 +1888,8 @@ GameDatabase.celestials.navigation = {
Achievements.prePelleRows.length];
const alchemy = [AlchemyResources.all.countWhere(r => r.capped), AlchemyResources.all.length];
return [
`Complete ${formatInt(achievements[0])} / ${formatInt(achievements[1])} rows of achievements`,
`Fill ${formatInt(alchemy[0])} / ${formatInt(alchemy[1])} alchemy resources`,
`Complete ${formatInt(achievements[0])} / ${formatInt(achievements[1])} rows of Achievements`,
`Fill ${formatInt(alchemy[0])} / ${formatInt(alchemy[1])} Alchemy Resources`,
];
},
angle: 290,

View File

@ -19,7 +19,6 @@ GameDatabase.challenges.normal = [
name: "1st Antimatter Dimension Autobuyer",
reward: "Upgradeable 1st Antimatter Dimension Autobuyer",
lockedAt: DC.D0,
isDisabledInDoomed: true,
},
{
id: 2,
@ -31,7 +30,6 @@ GameDatabase.challenges.normal = [
name: "2nd Antimatter Dimension Autobuyer",
reward: "Upgradeable 2nd Antimatter Dimension Autobuyer",
lockedAt: DC.D0,
isDisabledInDoomed: true,
},
{
id: 3,
@ -43,7 +41,6 @@ GameDatabase.challenges.normal = [
name: "3rd Antimatter Dimension",
reward: "Upgradeable 3rd Antimatter Dimension Autobuyer",
lockedAt: DC.D0,
isDisabledInDoomed: true,
},
{
id: 4,
@ -54,7 +51,6 @@ GameDatabase.challenges.normal = [
name: "4th Antimatter Dimension Autobuyer",
reward: "Upgradeable 4th Antimatter Dimension Autobuyer",
lockedAt: DC.D0,
isDisabledInDoomed: true,
},
{
id: 5,
@ -65,7 +61,6 @@ GameDatabase.challenges.normal = [
name: "5th Antimatter Dimension Autobuyer",
reward: "Upgradeable 5th Antimatter Dimension Autobuyer",
lockedAt: DC.D0,
isDisabledInDoomed: true,
},
{
id: 6,
@ -76,7 +71,6 @@ GameDatabase.challenges.normal = [
name: "6th Antimatter Dimension Autobuyer",
reward: "Upgradeable 6th Antimatter Dimension Autobuyer",
lockedAt: DC.D0,
isDisabledInDoomed: true,
},
{
id: 7,
@ -88,7 +82,6 @@ GameDatabase.challenges.normal = [
name: "7th Antimatter Dimension Autobuyer",
reward: "Upgradeable 7th Antimatter Dimension Autobuyer",
lockedAt: DC.D0,
isDisabledInDoomed: true,
},
{
id: 8,
@ -99,7 +92,6 @@ GameDatabase.challenges.normal = [
name: "8th Antimatter Dimension Autobuyer",
reward: "Upgradeable 8th Antimatter Dimension Autobuyer",
lockedAt: DC.D0,
isDisabledInDoomed: true,
},
{
id: 9,
@ -110,7 +102,6 @@ GameDatabase.challenges.normal = [
name: "Tickspeed Autobuyer",
reward: "Upgradeable Tickspeed Autobuyer",
lockedAt: DC.D0,
isDisabledInDoomed: true,
},
{
id: 10,
@ -121,7 +112,6 @@ GameDatabase.challenges.normal = [
name: "Automated Dimension Boosts",
reward: "Dimension Boosts Autobuyer",
lockedAt: DC.D16,
isDisabledInDoomed: true,
},
{
id: 11,
@ -132,7 +122,6 @@ GameDatabase.challenges.normal = [
name: "Automated Antimatter Galaxies",
reward: "Antimatter Galaxies Autobuyer",
lockedAt: DC.D16,
isDisabledInDoomed: true,
},
{
id: 12,

View File

@ -296,8 +296,8 @@ GameDatabase.reality.imaginaryUpgrades = [
at least ${formatInt(4)} empty Glyph slots`,
hasFailed: () => !Laitela.isRunning || Laitela.maxAllowedDimension !== 0 || Glyphs.activeList.length > 1,
checkRequirement: () => Laitela.isRunning && Laitela.maxAllowedDimension === 0 &&
Glyphs.activeList.length <= 1,
checkEvent: GAME_EVENT.REALITY_RESET_BEFORE,
Glyphs.activeList.length <= 1 && TimeStudy.reality.isBought,
checkEvent: GAME_EVENT.GAME_TICK_AFTER,
description: "Unlock Pelle, Celestial of Antimatter",
},
];

View File

@ -723,11 +723,31 @@ function laitelaRealityTick(realDiff) {
}
if (Laitela.realityReward > oldInfo.realityReward) {
completionText += `<br><br>Dark Matter Multiplier: ${formatX(oldInfo.realityReward, 2, 2)}
${formatX(Laitela.realityReward, 2, 2)}
<br>Best Completion Time: ${TimeSpan.fromSeconds(oldInfo.fastestCompletion).toStringShort()}
(${formatInt(8 - oldInfo.difficultyTier)})
${TimeSpan.fromSeconds(laitelaInfo.fastestCompletion).toStringShort()}
(${formatInt(8 - laitelaInfo.difficultyTier)})`;
${formatX(Laitela.realityReward, 2, 2)}`;
if (oldInfo.fastestCompletion === 3600 || oldInfo.fastestCompletion === 300 && oldInfo.difficultyTier > 0) {
if (Time.thisRealityRealTime.totalSeconds < 30) {
// First attempt - destabilising
completionText += `<br>Best Completion Time: None ➜ Destabilized
<br>Highest Active Dimension: ${formatInt(8 - oldInfo.difficultyTier)}
${formatInt(8 - laitelaInfo.difficultyTier)}`;
} else {
// First attempt - not destabilising
completionText += `<br>Best Completion Time: None ➜
${TimeSpan.fromSeconds(laitelaInfo.fastestCompletion).toStringShort()}
<br>Highest Active Dimension: ${formatInt(8 - laitelaInfo.difficultyTier)}`;
}
} else if (Time.thisRealityRealTime.totalSeconds < 30) {
// Second+ attempt - destabilising
completionText += `<br>Best Completion Time: ${TimeSpan.fromSeconds(oldInfo.fastestCompletion).toStringShort()}
Destablized
<br>Highest Active Dimension: ${formatInt(8 - oldInfo.difficultyTier)}
${formatInt(8 - laitelaInfo.difficultyTier)}`;
} else {
// Second+ attempt - not destabilising
completionText += `<br>Best Completion Time: ${TimeSpan.fromSeconds(oldInfo.fastestCompletion).toStringShort()}
${TimeSpan.fromSeconds(laitelaInfo.fastestCompletion).toStringShort()}
<br>Highest Active Dimension: ${formatInt(8 - oldInfo.difficultyTier)}`;
}
player.records.bestReality.laitelaSet = Glyphs.copyForRecords(Glyphs.active.filter(g => g !== null));
} else {
completionText += ` You need to destabilize in faster than

View File

@ -4746,6 +4746,7 @@ properly on certain themes. */
.o-eternity-upgrade--useless {
color: black;
background-color: var(--color-pelle--base);
filter: grayscale(50%);
border-color: black;
}
@ -5208,6 +5209,7 @@ properly on certain themes. */
.o-dilation-upgrade--useless {
color: black;
background-color: var(--color-pelle--base);
filter: grayscale(50%);
}
.o-dilation-upgrade--unavailable {

View File

@ -47,6 +47,7 @@
border: 0.1rem solid;
border-radius: var(--var-border-radius, 0.4rem);
transition-duration: 0.2s;
text-decoration: line-through;
}
.c-pelle-useless-available {

View File

@ -55,6 +55,7 @@ export default {
"o-infinity-upgrade-btn--available": !this.isUseless && !this.isBought && this.canBeBought,
"o-infinity-upgrade-btn--unavailable": !this.isUseless && !this.isBought && !this.canBeBought,
"o-infinity-upgrade-btn--useless": this.isUseless,
"o-pelle-disabled": this.isUseless,
"o-infinity-upgrade-btn--chargeable": !this.isCharged && this.chargePossible &&
(this.showingCharged || this.shiftDown),
"o-infinity-upgrade-btn--charged": this.isCharged,

View File

@ -20,13 +20,18 @@ export default {
return {
target: 0,
idx: 0,
isDoomed: false,
};
},
computed: {
resetTerm() { return this.isDoomed ? "Armageddon" : "Reality"; },
},
methods: {
update() {
this.target = this.targetSlot;
this.idx = this.inventoryIndex;
this.glyph = Glyphs.findByInventoryIndex(this.idx);
this.isDoomed = Pelle.isDoomed;
},
handleYesClick() {
Glyphs.swapIntoActive(this.glyph, this.targetSlot);
@ -43,6 +48,6 @@ export default {
<template #header>
You are about to replace a Glyph
</template>
Replacing a Glyph will restart this Reality.
Replacing a Glyph will restart this {{ resetTerm }}.
</ModalWrapperChoice>
</template>

View File

@ -14,7 +14,7 @@ export default {
<template>
<ModalWrapper class="c-shop-modal">
<template #header>
Support The Developer -coins
Support The Developer - coins
</template>
<div class="l-modal-store-content">
<img src="images/std_coin.png">

View File

@ -53,6 +53,7 @@ export default {
Glyphs.harshAutoClean();
for (const type of BASIC_GLYPH_TYPES) Glyphs.addToInventory(GlyphGenerator.doomedGlyph(type));
Glyphs.refreshActive();
player.options.confirmations.glyphReplace = true;
player.celestials.pelle.doomed = true;
Pelle.armageddon(false);
respecTimeStudies(true);
@ -96,7 +97,8 @@ export default {
>
Dooming your Reality will reset everything except Challenge records, Celestial progress and anything under
the General and Reality header on the Statistics tab. You will not gain any rewards from your progress
in your current Reality. Dooming your Reality will also disable certain game mechanics.
in your current Reality. Dooming your Reality will also purge most of your unprotected Glyphs and disable
certain game mechanics.
<br>
<br>
Are you sure you want to do this?

View File

@ -20,6 +20,7 @@ export default {
},
data() {
return {
laitelaFastest: 3600,
teresaBestAM: new Decimal(),
teresaRunMult: 0,
effarigDone: false,
@ -75,8 +76,8 @@ export default {
this.effarigDone = effarigStage === EFFARIG_STAGES.COMPLETED;
this.effarigLayer = [null, "Infinity", "Eternity", "Reality"][effarigStage];
this.enslavedDone = Enslaved.isCompleted;
const laitelaFastest = player.celestials.laitela.fastestCompletion;
this.laitelaTime = TimeSpan.fromSeconds(laitelaFastest).toStringShort();
this.laitelaFastest = player.celestials.laitela.fastestCompletion;
this.laitelaTime = TimeSpan.fromSeconds(this.laitelaFastest).toStringShort();
},
handleYesClick() {
beginProcessReality(getRealityProps(true));

View File

@ -36,6 +36,7 @@ export default {
canChangeStoreRealTime: false,
canDischarge: false,
canAutoRelease: false,
hasNoCharge: true,
}),
computed: {
storedRealEfficiencyDesc() {
@ -95,7 +96,7 @@ export default {
return {
"o-enslaved-mechanic-button": true,
"o-enslaved-mechanic-button--clickable": !this.isDoomed,
"l-fixed-setting": !this.canDischarge,
"l-fixed-setting": !this.canDischarge || this.hasNoCharge,
"o-pelle-disabled": this.isDoomed
};
},
@ -139,6 +140,7 @@ export default {
this.canChangeStoreRealTime = Enslaved.canModifyRealTimeStorage;
this.canDischarge = Enslaved.canRelease(false);
this.canAutoRelease = Enslaved.canRelease(true);
this.hasNoCharge = player.celestials.enslaved.stored === 0;
},
toggleStoreBlackHole() {
Enslaved.toggleStoreBlackHole();
@ -304,7 +306,7 @@ export default {
<button
:class="[mechanicButtonClass,
{'o-enslaved-mechanic-button--storing-time': autoStoreReal && offlineEnabled,
'l-fixed-setting': !canChangeStoreRealTime},
'l-fixed-setting': !canChangeStoreRealTime || !offlineEnabled},
doomedDisabledClass]"
@click="toggleAutoStoreReal"
>

View File

@ -14,11 +14,13 @@ export default {
realityReward: 1,
singularitiesUnlocked: false,
bestSet: [],
tierNotCompleted: true,
};
},
computed: {
completionTime() {
return TimeSpan.fromSeconds(this.realityTime).toStringShort();
if (this.tierNotCompleted) return "Not completed at this tier";
return `Fastest Completion: ${TimeSpan.fromSeconds(this.realityTime).toStringShort()}`;
},
runEffects() {
return GameDatabase.celestials.descriptions[5].effects().split("\n");
@ -36,6 +38,7 @@ export default {
this.isRunning = Laitela.isRunning;
this.singularitiesUnlocked = Currency.singularities.gt(0);
this.bestSet = Glyphs.copyForRecords(player.records.bestReality.laitelaSet);
this.tierNotCompleted = this.realityTime === 3600 || (this.realityTime === 300 && this.maxDimTier < 8);
},
startRun() {
if (this.isDoomed) return;
@ -74,7 +77,7 @@ export default {
</b>
<span v-if="maxDimTier > 0">
<br><br>
Fastest Completion: {{ completionTime }}
{{ completionTime }}
<br><br>
<span v-if="maxDimTier <= 7">
Highest active dimension: {{ formatInt(maxDimTier) }}

View File

@ -28,6 +28,7 @@ export default {
currentCondenseTime: 0,
autoCondenseDelay: 0,
lastCheckedMilestones: 0,
autoSingActive: false,
}),
computed: {
// The bar is a mask that inverts colors for any element with a lower z-index (including text).
@ -68,7 +69,7 @@ export default {
},
progressDisplay() {
const condenseCount = this.remainingSingularities / this.singularitiesPerCondense;
let thisSingularityTime, extraTime;
let thisSingularityTime, extraTime, timeText;
switch (this.milestoneMode) {
case SINGULARITY_MILESTONE_RESOURCE.SINGULARITIES:
return `In ${quantify("Singularity", this.remainingSingularities, 2)}`;
@ -81,7 +82,8 @@ export default {
case SINGULARITY_MILESTONE_RESOURCE.AUTO_TIME:
thisSingularityTime = Math.clampMin(0, this.currentCondenseTime + this.autoCondenseDelay);
extraTime = Math.ceil(condenseCount - 1) * (this.baseCondenseTime + this.autoCondenseDelay);
return `In ${TimeSpan.fromSeconds(thisSingularityTime + extraTime).toStringShort()} (auto)`;
timeText = `In ${TimeSpan.fromSeconds(thisSingularityTime + extraTime).toStringShort()}`;
return this.autoSingActive ? timeText : `Auto-Singularity is OFF`;
default:
throw new Error("Unrecognized Singularity Milestone mode");
}
@ -90,6 +92,7 @@ export default {
},
methods: {
update() {
this.autoSingActive = player.auto.singularity.isActive;
this.isMaxed = this.milestone.isMaxed;
this.progressToNext = this.milestone.progressToNext;
this.remainingSingularities = this.milestone.remainingSingularities;

View File

@ -54,6 +54,7 @@ export default {
return this.formatRate(this.singularitiesGained / totalTime);
},
autoSingularityRate() {
if (this.hasAutoSingularity && !this.isAutoEnabled) return "Auto-Singularity is OFF";
const totalTime = this.baseTimeToSingularity + this.extraTimeAfterSingularity;
return this.formatRate(this.singularitiesGained / totalTime);
},

View File

@ -93,13 +93,13 @@ export default {
v-else
class="pelle-unlock-requirements"
>
You must have {{ formatInt(totalRows) }} rows of achievements
and all of your Glyph Alchemy resources capped to unlock Pelle.
You must have {{ formatInt(totalRows) }} rows of Achievements
and all of your Glyph Alchemy Resources capped to unlock Pelle, Celestial of Antimatter.
<br>
<br>
{{ formatInt(completedRows) }} / {{ formatInt(totalRows) }} Achievement rows
{{ formatInt(completedRows) }} / {{ formatInt(totalRows) }} Achievement rows completed
<br>
{{ formatInt(cappedResources) }} / {{ formatInt(totalAlchemyResources) }} Capped resources
{{ formatInt(cappedResources) }} / {{ formatInt(totalAlchemyResources) }} capped Alchemy Resources
</div>
</div>
</template>
@ -148,7 +148,7 @@ export default {
.pelle-unlock-requirements {
width: 50rem;
padding: 0.5rem;
font-size: 3rem;
font-size: 2.4rem;
color: var(--color-pelle--base);
background: black;
border: var(--var-border-width, 0.2rem) solid var(--color-pelle--base);

View File

@ -29,7 +29,8 @@ export default {
return {
"o-eternity-upgrade": true,
"o-eternity-upgrade--useless": !this.isAffordable,
"o-pelle-disabled-pointer": true
"o-pelle-disabled-pointer": true,
"o-pelle-disabled": true,
};
}
return {

View File

@ -70,8 +70,7 @@ export default {
<DescriptionDisplay :config="descriptionDisplayConfig" />
</template>
<template #bottom>
<span v-if="isDisabled">There is no reward for completing this challenge</span>
<span v-else>Reward: {{ challenge.config.reward }}</span>
<span :class="{ 'o-pelle-disabled': isDisabled }">Reward: {{ challenge.config.reward }}</span>
</template>
</ChallengeBox>
</template>