Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Update pixel update to current standards #602

Merged
merged 69 commits into from
Jun 29, 2024
Merged
Show file tree
Hide file tree
Changes from all commits
Commits
Show all changes
69 commits
Select commit Hold shift + click to select a range
9994f68
?
KhafraDev May 3, 2024
f323df6
?
KhafraDev May 3, 2024
81dcea4
?
KhafraDev May 3, 2024
37ae074
Exalt Subtab Move Baseline
Mixelz May 4, 2024
cfeb786
TL Files Fix
Mixelz May 4, 2024
b1947e4
Hide Nav/Mouse Hover (Minor)
Mixelz May 4, 2024
04a160b
Screaming Variables
Mixelz May 7, 2024
2a1d636
Reward Description Overhaul
Mixelz May 7, 2024
e784f7c
don't use form for login
KhafraDev May 8, 2024
0a98e71
TL Files Insert
Mixelz May 9, 2024
77ff48a
Merge branch 'Pseudo-Corp:master' into exalt-challenge-subtab
Mixelz May 9, 2024
87eb8ac
Kill the Camels
Mixelz May 9, 2024
dbd6214
Merge branch 'exalt-challenge-subtab' of https://github.com/Mixelz/Sy…
Mixelz May 9, 2024
c1ec9df
Rename perkOneHundredThirtyOne.png to perkoneHundredThirtyOne.png (#595)
pinterior May 20, 2024
583eaa8
Merge branch 'Pseudo-Corp:master' into exalt-challenge-subtab
Mixelz May 21, 2024
9635fcc
Standardized code that doesn't do anything
Mixelz May 22, 2024
da40f1b
Removed Debug Code
Mixelz May 23, 2024
bdcdcf3
Merge pull request #594 from Mixelz/exalt-challenge-subtab
Pseudonian May 29, 2024
b7921f3
Fixed ambrosia unlock (#597)
httpsnet Jun 2, 2024
079f852
fix spyware browser
KhafraDev Jun 3, 2024
4dafb2a
ah shit, here we go again
KhafraDev Jun 10, 2024
2ca5c11
use zod
KhafraDev Jun 10, 2024
041b696
use more zod
KhafraDev Jun 10, 2024
dcb62e0
fixup
KhafraDev Jun 10, 2024
01d162c
fixup
KhafraDev Jun 10, 2024
245604a
fixup
KhafraDev Jun 10, 2024
2eba268
load v2.0.0 saves
KhafraDev Jun 11, 2024
7aabf01
load v2.0.0 saves
KhafraDev Jun 11, 2024
62f11d7
load every save in the bank
KhafraDev Jun 11, 2024
47facbe
use zod for loading
KhafraDev Jun 12, 2024
6ada011
fixup
KhafraDev Jun 12, 2024
8ba1280
fix dumbass caches
KhafraDev Jun 12, 2024
5fde43d
fix NaN
KhafraDev Jun 12, 2024
cf7a656
use zod to export save
KhafraDev Jun 12, 2024
50a1df3
fix hotkeys
KhafraDev Jun 12, 2024
9c01750
fix sing tab
KhafraDev Jun 12, 2024
4de5a44
fixup
KhafraDev Jun 12, 2024
b06e994
fixup
KhafraDev Jun 12, 2024
4f6b55b
fixup
KhafraDev Jun 12, 2024
0b6bd5e
arrayExtend, fixed NaN bug with cubeUpgrade
Pseudonian Jun 13, 2024
8e73357
don't reset wow* values
KhafraDev Jun 13, 2024
f3ee0f6
fixup! hepteractCrafts
KhafraDev Jun 13, 2024
ebe647a
Removed functionality of all StatCaches
Pseudonian Jun 13, 2024
80f332a
Merge branch 'player-object-2' of https://github.com/Pseudo-Corp/Syne…
Pseudonian Jun 13, 2024
f16bf9f
Why was this message here?
Pseudonian Jun 13, 2024
e3e6b6f
fixup! ambrosia
KhafraDev Jun 13, 2024
577ab17
Fixed Some Statistic Issues + Added Obtainium Stats (Test Branch Vers…
Arvingo Jun 18, 2024
9f41b83
fixup! delete savefile
KhafraDev Jun 18, 2024
6f5c79a
fixup! use zod for sing
KhafraDev Jun 18, 2024
34d3b0b
Merge pull request #599 from Pseudo-Corp/player-object-2
Pseudonian Jun 19, 2024
f9d9931
Shadow nerf against ambrosia accelerator
Pseudonian Jun 19, 2024
5b2e46a
Fix and buff Dilated Luck Perk
Pseudonian Jun 19, 2024
80a8533
fixup! hover ambrosia highlights
KhafraDev Jun 21, 2024
2781ae9
fixes
KhafraDev Jun 21, 2024
8eaff97
simplify zod & fix types
KhafraDev Jun 23, 2024
e4c4a64
fixup! hepteractCrafts optional properties
KhafraDev Jun 24, 2024
ea5eadb
Update some free daily stuff
Pseudonian Jun 25, 2024
ca39460
Merge branch 'master' of https://github.com/Pseudo-Corp/SynergismOffi…
Pseudonian Jun 25, 2024
7afd274
Update some free daily stuff
Pseudonian Jun 25, 2024
444557b
Make free levels worth something lol
Pseudonian Jun 25, 2024
5d19039
prepare for patreon login
KhafraDev Jun 26, 2024
d362a40
fixup
KhafraDev Jun 26, 2024
1e0f9a5
fixup
KhafraDev Jun 26, 2024
6e6cc61
Nerf octeracts
Pseudonian Jun 27, 2024
78d956c
Merge branch 'master' of https://github.com/Pseudo-Corp/SynergismOffi…
Pseudonian Jun 27, 2024
b9dd981
Oops! No Octeracts
Pseudonian Jun 27, 2024
a3f9d63
Patreon login (#601)
KhafraDev Jun 27, 2024
37da888
fixup! real logout
KhafraDev Jun 27, 2024
af9f0c9
fixup!
KhafraDev Jun 27, 2024
File filter

Filter by extension

Filter by extension


Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
Binary file added Pictures/patreon-logo.png
Loading
Sorry, something went wrong. Reload?
Sorry, we cannot display this file.
Sorry, this file is invalid so it cannot be displayed.
1 change: 1 addition & 0 deletions Sample_Saves/Synergism2.5 - (1) c10 completed.txt

Large diffs are not rendered by default.

1 change: 1 addition & 0 deletions Sample_Saves/Synergism2.5 - (10) Omega completed.txt

Large diffs are not rendered by default.

Large diffs are not rendered by default.

1 change: 1 addition & 0 deletions Sample_Saves/Synergism2.5 - (2) c11 completed.txt

Large diffs are not rendered by default.

1 change: 1 addition & 0 deletions Sample_Saves/Synergism2.5 - (3)c14 completed.txt

Large diffs are not rendered by default.

1 change: 1 addition & 0 deletions Sample_Saves/Synergism2.5 - (4) w5x10 completed.txt

Large diffs are not rendered by default.

1 change: 1 addition & 0 deletions Sample_Saves/Synergism2.5 - (5) Alpha completed.txt

Large diffs are not rendered by default.

1 change: 1 addition & 0 deletions Sample_Saves/Synergism2.5 - (6) p2x1 completed.txt

Large diffs are not rendered by default.

1 change: 1 addition & 0 deletions Sample_Saves/Synergism2.5 - (7) p3x1 completed.txt

Large diffs are not rendered by default.

1 change: 1 addition & 0 deletions Sample_Saves/Synergism2.5 - (8) Beta completed.txt

Large diffs are not rendered by default.

1 change: 1 addition & 0 deletions Sample_Saves/Synergism2.5 - (9) 1e15 c15 expo.txt

Large diffs are not rendered by default.

93 changes: 79 additions & 14 deletions Synergism.css
Original file line number Diff line number Diff line change
Expand Up @@ -1558,6 +1558,26 @@ p#transcendhotkeys {
padding: 0;
}

#challengesTabsToggle {
display: flex;
justify-content: center;
flex-flow: wrap;
margin-top: 15px;
margin-bottom: 10px;
gap: 10px 15px;
}

#challengesTabsToggle > button {
min-width: 100px;
text-align: center;
}

.singularityChallenges {
display: flex;
justify-content: center;
column-gap: 4px;
}

#challengesWrapper {
display: flex;
flex-direction: column;
Expand All @@ -1567,14 +1587,23 @@ p#transcendhotkeys {
#challengeIntroduction {
text-align: center;
font-size: 1.2em;
margin: 20px 0 0;
margin-top: 10px;
margin-bottom: 10px;
}

#ExaltIntroduction {
text-align: center;
font-size: 1.2em;
margin-top: 10px;
margin-bottom: 10px;
}

#challengesAutoToggles {
display: flex;
justify-content: center;
flex-flow: wrap;
gap: 10px 15px;
margin-bottom: 10px;
}

#challengesAutoToggles > button {
Expand Down Expand Up @@ -1635,10 +1664,11 @@ p#transcendhotkeys {
}

#challengeDetails {
display: flex;
display: grid;
grid-template-columns: repeat(2, auto);
justify-content: center;
max-width: 1200px;
align-self: center;
margin-top: 10px;
}

#challengeTimers {
Expand Down Expand Up @@ -3545,12 +3575,6 @@ header #obtainiumDisplay { color: pink; }
border: 2px solid blue;
}

.singularityChallenges {
display: flex;
justify-content: center;
column-gap: 4px;
}

.rainbowBorder {
width: 64px;
height: 64px;
Expand All @@ -3570,6 +3594,11 @@ header #obtainiumDisplay { color: pink; }
border-radius: 3px;
}

.rainbowBorder:hover {
cursor: pointer;
background-color: var(--hover-color);
}

.rainbowBorder::before {
position: absolute;
width: 150%; /* 96px */
Expand Down Expand Up @@ -3667,13 +3696,49 @@ img#singularityPerksIcon {
}

#singularityChallengeDetails {
width: 50%;
margin-left: 25%;
display: block;
}

#singularityChallengesMultiline {
#singularityChallengesInfo {
white-space: pre-line;
margin: 15px 0 0;
margin-top: 10px;
margin-bottom: 5px;
text-align: center;
}

#singularityChallengeAllRewards {
display: grid;
grid-template-rows: repeat(2, auto);
grid-template-columns: repeat(2, 375px);
justify-content: center;
grid-gap: 10px;
}

#singularityChallengeScalingHeader {
font-weight: bold;
font-size: 1.2em;
text-align: center;
margin: 0;
}

#singularityChallengeUniqueHeader {
font-weight: bold;
font-size: 1.2em;
text-align: center;
margin: 0;
}

#singularityChallengesScalingRewards {
display: block;
white-space: pre-line;
margin: 0;
text-align: center;
}

#singularityChallengesUniqueRewards {
display: block;
white-space: pre-line;
margin: 0;
}

.newPerk {
Expand Down Expand Up @@ -3801,7 +3866,7 @@ img#singularityPerksIcon {
padding-top: 10px;
}

#accountSubTab > div.scrollbarX > img#discord-logo {
#accountSubTab > div.scrollbarX > img {
/* A 1.3 width x height ratio */
width: 96px;
height: 72px;
Expand Down
291 changes: 182 additions & 109 deletions index.html

Large diffs are not rendered by default.

5 changes: 4 additions & 1 deletion package.json
Original file line number Diff line number Diff line change
Expand Up @@ -10,11 +10,14 @@
"eventemitter3": "^4.0.7",
"i18next": "^22.4.9",
"localforage": "^1.10.0",
"lodash.clonedeepwith": "^4.5.0",
"lz-string": "^1.4.4",
"worker-timers": "^7.0.53"
"worker-timers": "^7.0.53",
"zod": "^3.23.8"
},
"devDependencies": {
"@biomejs/biome": "^1.4.1",
"@types/lodash.clonedeepwith": "^4.5.9",
"@types/lz-string": "^1.3.34",
"deep-object-diff": "^1.1.9",
"dprint": "^0.45.0",
Expand Down
41 changes: 26 additions & 15 deletions src/BlueberryUpgrades.ts
Original file line number Diff line number Diff line change
@@ -1,12 +1,14 @@
import i18next from 'i18next'
import { DOMCacheGetOrSet } from './Cache/DOM'
import { calculateAmbrosiaGenerationSpeed, calculateAmbrosiaLuck } from './Calculate'
import { DynamicUpgrade } from './DynamicUpgrade'
import type { IUpgradeData } from './DynamicUpgrade'
import { exportData, saveFilename } from './ImportExport'
import { format, player } from './Synergism'
import type { Player } from './types/Synergism'
import { Alert, Confirm, Prompt } from './UpdateHTML'
import { visualUpdateAmbrosia } from './UpdateVisuals'
import { Globals as G } from './Variables'

export type blueberryUpgradeNames =
| 'ambrosiaTutorial'
Expand Down Expand Up @@ -121,7 +123,7 @@ export class BlueberryUpgrade extends DynamicUpgrade {
break
} else {
if (this.level === 0) {
const availableBlueberries = player.caches.blueberryInventory.totalVal - player.spentBlueberries
const availableBlueberries = G.ambrosiaCurrStats.ambrosiaBlueberries - player.spentBlueberries
if (availableBlueberries < this.blueberryCost) {
return Alert(i18next.t('ambrosia.notEnoughBlueberries'))
} else {
Expand Down Expand Up @@ -283,7 +285,7 @@ export class BlueberryUpgrade extends DynamicUpgrade {
}

public get rewardDesc (): string {
const effectiveLevel = (player.singularityChallenges.noAmbrosiaUpgrades.enabled) ? 0: this.level
const effectiveLevel = (player.singularityChallenges.noAmbrosiaUpgrades.enabled) ? 0 : this.level
if ('desc' in this.rewards(0)) {
return String(this.rewards(effectiveLevel).desc)
} else {
Expand All @@ -292,7 +294,7 @@ export class BlueberryUpgrade extends DynamicUpgrade {
}

public get bonus () {
const effectiveLevel = (player.singularityChallenges.noAmbrosiaUpgrades.enabled) ? 0: this.level
const effectiveLevel = (player.singularityChallenges.noAmbrosiaUpgrades.enabled) ? 0 : this.level
return this.rewards(effectiveLevel)
}
}
Expand Down Expand Up @@ -389,8 +391,9 @@ export const blueberryUpgradeData: Record<
ambrosiaTutorial: 10
},
cacheUpdates: [
() => player.caches.ambrosiaLuck.updateVal('BlueberryUpgrade1'),
() => player.caches.ambrosiaLuck.updateVal('BlueberryUpgrade2')
() => {
G.ambrosiaCurrStats.ambrosiaLuck = calculateAmbrosiaLuck().value
}
]
},
ambrosiaQuarkCube1: {
Expand Down Expand Up @@ -428,7 +431,7 @@ export const blueberryUpgradeData: Record<
},
rewards: (n: number) => {
const baseVal = 0.0002 * n
const val = 1 + baseVal * player.caches.ambrosiaLuck.usedTotal
const val = 1 + baseVal * G.ambrosiaCurrStats.ambrosiaLuck
return {
cubes: val,
desc: String(
Expand Down Expand Up @@ -485,9 +488,9 @@ export const blueberryUpgradeData: Record<
rewards: (n: number) => {
const baseVal = 0.0001 * n
const effectiveLuck = Math.min(
player.caches.ambrosiaLuck.usedTotal,
G.ambrosiaCurrStats.ambrosiaLuck,
Math.pow(1000, 0.5)
* Math.pow(player.caches.ambrosiaLuck.usedTotal, 0.5)
* Math.pow(G.ambrosiaCurrStats.ambrosiaLuck, 0.5)
)
const val = 1 + baseVal * effectiveLuck
return {
Expand Down Expand Up @@ -535,7 +538,9 @@ export const blueberryUpgradeData: Record<
ambrosiaCubes1: 20
},
cacheUpdates: [
() => player.caches.ambrosiaLuck.updateVal('BlueberryCubeLuck1')
() => {
G.ambrosiaCurrStats.ambrosiaLuck = calculateAmbrosiaLuck().value
}
]
},
ambrosiaQuarkLuck1: {
Expand Down Expand Up @@ -563,7 +568,9 @@ export const blueberryUpgradeData: Record<
ambrosiaQuarks1: 20
},
cacheUpdates: [
() => player.caches.ambrosiaLuck.updateVal('BlueberryQuarkLuck1')
() => {
G.ambrosiaCurrStats.ambrosiaLuck = calculateAmbrosiaLuck().value
}
]
},
ambrosiaQuarks2: {
Expand Down Expand Up @@ -645,7 +652,9 @@ export const blueberryUpgradeData: Record<
ambrosiaLuck1: 40
},
cacheUpdates: [
() => player.caches.ambrosiaLuck.updateVal('BlueberryUpgrade2')
() => {
G.ambrosiaCurrStats.ambrosiaLuck = calculateAmbrosiaLuck().value
}
]
},
ambrosiaPatreon: {
Expand All @@ -667,7 +676,9 @@ export const blueberryUpgradeData: Record<
}
},
cacheUpdates: [
() => player.caches.ambrosiaGeneration.updateVal('BlueberryPatreon')
() => {
G.ambrosiaCurrStats.ambrosiaGenerationSpeed = calculateAmbrosiaGenerationSpeed().value
}
]
},
ambrosiaObtainium1: {
Expand All @@ -678,7 +689,7 @@ export const blueberryUpgradeData: Record<
return baseCost * Math.pow(25, level)
},
rewards: (n: number) => {
const luck = player.caches.ambrosiaLuck.usedTotal
const luck = G.ambrosiaCurrStats.ambrosiaLuck
return {
luckMult: n,
obtainiumMult: n * luck,
Expand All @@ -698,7 +709,7 @@ export const blueberryUpgradeData: Record<
return baseCost * Math.pow(25, level)
},
rewards: (n: number) => {
const luck = player.caches.ambrosiaLuck.usedTotal
const luck = G.ambrosiaCurrStats.ambrosiaLuck
return {
luckMult: n,
offeringMult: n * luck,
Expand Down Expand Up @@ -757,7 +768,7 @@ export const validateBlueberryTree = (modules: BlueberryOpt) => {
}

const ambrosiaBudget = player.lifetimeAmbrosia
const blueberryBudget = player.caches.blueberryInventory.totalVal
const blueberryBudget = G.ambrosiaCurrStats.ambrosiaBlueberries

let spentAmbrosia = 0
let spentBlueberries = 0
Expand Down
Loading
Loading