This commit is contained in:
Turtle committed 2025-12-31 14:17:50 +01:00
1 parent 76258c2291
commit b4aa7bb628
4 files changed
+61 -42

No files matched your search

+5 -2
View File
@@ -263,13 +263,16 @@ async function init() {
async function getXpPoints(elm, xp, name, pos) {
elm.remove();
playLevelSound();
const course = await couchDB.get("course:" + name);
const data = course.result_history[pos];
data["got_xp"] = true;
await levelUpXP(couchDB, userData, xp);
if (await levelUpXP(couchDB, userData, xp)) {
playLevelSound();
} else {
playXPSound();
}
await couchDB.set("course:" + name, course);
}