Skip to content

Commit

Permalink
Fix custom patching for vers >4.x
Browse files Browse the repository at this point in the history
  • Loading branch information
NotThorny committed Aug 28, 2024
1 parent c72aaa9 commit 25a359b
Show file tree
Hide file tree
Showing 8 changed files with 8 additions and 7 deletions.
2 changes: 1 addition & 1 deletion package.json
Original file line number Diff line number Diff line change
@@ -1,6 +1,6 @@
{
"name": "cultivation",
"version": "1.4.4",
"version": "1.4.6",
"private": true,
"dependencies": {
"@tauri-apps/api": "^1.0.0-rc.5",
Expand Down
2 changes: 1 addition & 1 deletion src-tauri/Cargo.lock

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

2 changes: 1 addition & 1 deletion src-tauri/Cargo.toml
Original file line number Diff line number Diff line change
@@ -1,6 +1,6 @@
[package]
name = "cultivation"
version = "1.4.4"
version = "1.4.6"
description = "A custom launcher for anime game."
authors = ["KingRainbow44", "SpikeHD"]
license = ""
Expand Down
2 changes: 1 addition & 1 deletion src-tauri/tauri.conf.json
Original file line number Diff line number Diff line change
Expand Up @@ -7,7 +7,7 @@
},
"package": {
"productName": "Cultivation",
"version": "1.4.4"
"version": "1.4.6"
},
"tauri": {
"allowlist": {
Expand Down
1 change: 1 addition & 0 deletions src/ui/App.tsx
Original file line number Diff line number Diff line change
Expand Up @@ -87,6 +87,7 @@ class App extends React.Component<Readonly<unknown>, IState> {
// @ts-expect-error - TS doesn't like our custom event
page: e.detail,
})
this.forceUpdate
})
}

Expand Down
2 changes: 1 addition & 1 deletion src/ui/components/ServerLaunchSection.tsx
Original file line number Diff line number Diff line change
Expand Up @@ -176,7 +176,7 @@ export default class ServerLaunchSection extends React.Component<IProps, IState>

const versionString = gameVersion?.major.toString() + gameVersion?.minor.toString()

if (gameVersion?.major == 4 && gameVersion?.minor > 5) {
if ((gameVersion?.major == 4 && gameVersion?.minor > 5) || gameVersion?.major > 4) {
newerGame = true

const path = (await invoke('install_location')) as string
Expand Down
2 changes: 1 addition & 1 deletion src/ui/components/menu/Options.tsx
Original file line number Diff line number Diff line change
Expand Up @@ -186,7 +186,7 @@ export default class Options extends React.Component<IProps, IState> {
}

// If setting any other game, automatically set to redirect more
if (!value.toLowerCase().includes('genshin' || 'yuanshen')) {
if (!value.toLowerCase().includes('genshin') || !value.toLowerCase().includes('yuanshen')) {
if (!this.state.redirect_more) {
this.toggleOption('redirect_more')
}
Expand Down
2 changes: 1 addition & 1 deletion src/ui/components/news/NewsSection.tsx
Original file line number Diff line number Diff line change
Expand Up @@ -143,7 +143,7 @@ export default class NewsSection extends React.Component<IProps, IState> {
<tr>
<td>
Work in progress area! These numbers may be outdated, so please do not use them as reference. Latest
version: Grasscutter 1.7.4 - Cultivation 1.4.4
version: Grasscutter 1.7.4 - Cultivation 1.4.6
</td>
</tr>
)
Expand Down

0 comments on commit 25a359b

Please sign in to comment.