Skip to content

Commit

Permalink
1.0.0
Browse files Browse the repository at this point in the history
  • Loading branch information
insraq committed Sep 11, 2024
1 parent 6b6204b commit 4eeca30
Show file tree
Hide file tree
Showing 3 changed files with 17 additions and 12 deletions.
7 changes: 7 additions & 0 deletions assets/Script/CoreGame/Changelog.ts
Original file line number Diff line number Diff line change
@@ -1,5 +1,12 @@
export const CHANGELOG = [
{
version: "1.0.0",
content: [
"Bugfix: Do not transfer trading right when cancel a save transfer",
"Bugfix: Downgrade Research Lab gives less cash than it should",
"Update translations",
],
}, {
version: "0.20.9",
content: [
"Update Norwegian, Czech, Portuguese (Brazil) and Chinese translation (@FishPond)",
Expand Down
20 changes: 9 additions & 11 deletions assets/Script/General/NativeSdk.ts
Original file line number Diff line number Diff line change
Expand Up @@ -175,18 +175,16 @@ export class DefaultNativeSdk {
}
allowPortrait(allow: boolean): void {}
async saveFile(suggestedName: string, content: string): Promise<void> {
try {
const handle = await window.showSaveFilePicker({
suggestedName,
});
const stream = await handle.createWritable();
await stream.write(content);
await stream.close();
} catch (error) {
if(error instanceof AbortError)
throw error;
downloadFile(content, suggestedName);
if (typeof window.showSaveFilePicker === "undefined") {
downloadFile(suggestedName, content);
return;
}
const handle = await window.showSaveFilePicker({
suggestedName,
});
const stream = await handle.createWritable();
await stream.write(content);
await stream.close();
}
async readFile(): Promise<string> {
if (!window.showOpenFilePicker) {
Expand Down
2 changes: 1 addition & 1 deletion assets/Script/UI/UIHelper.ts
Original file line number Diff line number Diff line change
Expand Up @@ -380,8 +380,8 @@ export function uiBuildingBasicInfo(entity: Entity) {
onclick: () => {
G.audio.playClick();
if (entity.level > 1) {
entity.level--;
refundCash(downgradeRefund());
entity.level--;
}
},
},
Expand Down

0 comments on commit 4eeca30

Please sign in to comment.