1
0
mirror of https://dev.s-ul.net/Galexion/MaiMaiDXNet.git synced 2025-02-17 16:58:32 +01:00

not a hotfix, just a usability update

This commit is contained in:
Galexion 2023-08-02 01:15:04 -04:00
parent cc3dacadeb
commit 282a54a6b4
3 changed files with 50 additions and 22 deletions

View File

@ -258,16 +258,19 @@ async function userPlayLogFormatter(div, loadMoreButton) {
let SGimgarray = ["D", "C", "B", "BB", "BBB", "A", "AA", "AAA", "S", "Sp", "SS", "SSp", "SSS", "SSSp"] let SGimgarray = ["D", "C", "B", "BB", "BBB", "A", "AA", "AAA", "S", "Sp", "SS", "SSp", "SSS", "SSSp"]
const scoreGradeDiv = document.createElement('div'); const scoreGradeDiv = document.createElement('div');
scoreGradeDiv.classList.add('score-grade'); scoreGradeDiv.classList.add('score-grade');
if (rankImgCheck = false) {
let scoreGrade = document.createElement('h4'); let scoreGrade = document.createElement('h4');
scoreGrade.textContent = `${scoreGrades[score.score_rank || score.scoreRank]}`; scoreGrade.textContent = `${scoreGrades[score.score_rank || score.scoreRank]}`;
scoreGradeDiv.append(scoreGrade);
} else {
let SGimg = document.createElement('img'); let SGimg = document.createElement('img');
SGimg.addEventListener("error", function () { SGimg.addEventListener("error", function () {
this.src = "assets/icon/UI_Icon_000000.png"; this.src = "assets/icon/UI_Icon_000000.png";
}); });
SGimg.classList.add('sg-image'); SGimg.classList.add('sg-image');
SGimg.src = "assets/uicon/UI_TTR_Rank_" + scoreGrades[score.score_rank||score.scoreRank] + '.png'; SGimg.src = "assets/uicon/UI_TTR_Rank_" + SGimgarray[score.score_rank || score.scoreRank] + '.png';
scoreGradeDiv.append(SGimg); scoreGradeDiv.append(SGimg);
//scoreGradeDiv.append(scoreGrade); }
tasGrid.append(scoreGradeDiv); tasGrid.append(scoreGradeDiv);
//DX Score & Fast Late Reading //DX Score & Fast Late Reading
@ -609,3 +612,18 @@ async function imageList() {
} }
} }
async function rankImgCheck() {
const url = "/assets/uicon/UI_TTR_Rank_AA.png";
try {
const response = await fetch(url, {
method: "GET",
headers: {
"Content-Type": "application/json",
},
});
return true
} catch (error) {
return false
}
}

View File

@ -25,6 +25,7 @@ in the public folder, the assets should look like this
\_ | - icon \_ | - icon
| - jacket | - jacket
| - metadata | - metadata
| - uicon
``` ```
Then, create the `/public/image/` folder. this will be where the images will be stored. Then, create the `/public/image/` folder. this will be where the images will be stored.
@ -32,7 +33,9 @@ Then, create the `/public/image/` folder. this will be where the images will be
You'll also need the Game metadata, extracted using [SegaParser](https://dev.s-ul.net/Galexion/segaparser), You'll also need the Game metadata, extracted using [SegaParser](https://dev.s-ul.net/Galexion/segaparser),
to get the game metadata. this is ***Nessasary*** for the interface to function. to get the game metadata. this is ***Nessasary*** for the interface to function.
Tip: you'll need to extract both Common (FC, FS, and Rank) and streamed assets.
you'll also need to go and create your own Grayscale version of FC and FS. SnS.
## Aqua ## Aqua

View File

@ -23,11 +23,18 @@
<div id="loginContent"> <div id="loginContent">
<details> <details>
<summary> <summary>
<h4>Issue Log:</h4> <h4>Issue & Update Log:</h4>
</summary> </summary>
<h5> <h5>
Hello and welcome to the beta of the new score layout, apart of a bigger redo of the front end.
<br><br>
Changes: <br>
- literally the whole score layout<br>
- score grade will now switch between Text & Image depending on if you had imported them into your assets folder.
<br><br>
issues:<br>
- Site Is Not Complete<br> - Site Is Not Complete<br>
- Artemis does not Support Memorial Photos, though that is coming.<br> - Details dropdown does nothing. that is currently intended, as i haven't coded it in yet.<br>
UI Jackets Have Now been fixed, please redl segapaser and rerun music.js.</h5> UI Jackets Have Now been fixed, please redl segapaser and rerun music.js.</h5>
</details> </details>
</div> </div>