save data export and import

This commit is contained in:
2023-06-26 19:44:32 +02:00
parent a2b8b40464
commit d6e897c289
5 changed files with 151 additions and 12 deletions
-6
View File
@@ -51,7 +51,6 @@ import {version} from "../package.json"
:adventurerForHire="adventurerForHire"
:news="news"
@finalizeQuest="finalizeQuest($event)"
@wipeSave="resetSave()"
@recruitActionTaken="recruitAction($event)"
/>
</template>
@@ -262,11 +261,6 @@ export default defineComponent({
}
}
},
resetSave() {
if (!confirm("You are about to wipe your save file. Are you sure?")) return;
window.localStorage.removeItem("savedGame");
window.location.reload();
},
async updateNews() {
const result = await fetch("https://raw.githubusercontent.com/YouHaveTrouble/GuildMaster/master/news.txt").catch(() => {
return null;