Skip to content

Commit

Permalink
Add more info when no patches were found
Browse files Browse the repository at this point in the history
  • Loading branch information
ComputerElite committed Mar 9, 2024
1 parent 8319b7f commit 3779780
Show file tree
Hide file tree
Showing 3 changed files with 39 additions and 13 deletions.
Original file line number Diff line number Diff line change
Expand Up @@ -99,7 +99,15 @@ <h1>Downgrade</h1>
</div>
<div class="content hidden" id="patcheserror">
<h1>No patches available</h1>
<p>I could not find any downgrade patches for your current Beat Saber version. Make sure you got the latest version of Beat Saber installed.</p>
<p>
I could not find any downgrade patches for your current Beat Saber version. This either means that you are not on the latest Beat Saber version or that we didn't have time yet to create a patch for downgrading from the newest version.
</p>
<p>
<b>You'll have to wait until we have created a patch for your version which may take a while.</b>
</p>
<p>
Alternatively <b>switch to the <code>legacy1.29.0_unity_ver2019.4.28f1</code> branch of Beat Saber in the Oculus app</b>.
</p>
</div>
<div class="content hidden" id="downgradeLoginDiff">
<p>
Expand Down
27 changes: 16 additions & 11 deletions QuestAppVersionSwitcher/Assets/html/index.html
Original file line number Diff line number Diff line change
Expand Up @@ -285,18 +285,23 @@ <h1>QAVS can currently not manage mods for Quest 3!</h1>
<iframe id="downgradeframe" src=""></iframe>
</div>
<div class="contentItem hidden" style="position: relative" id="downgradeDiff">
<h3>Compatible downgrades for <div class="inline packageName"></div></h3>
<div id="currentVersionDowngrade" class="inline"></div>
<br>
<table id="compatibleDowngrades">
</table>
<br>
<br>
<h3>Downgrades available if you install other versions</h3>
These versions can only be downgraded to once you install the version shown at the left before.
<table id="availableDowngrades">
<div id="noDowngradeShit">

</div>
<div id="allDowngradeShit">
<h3>Compatible downgrades for <div class="inline packageName"></div></h3>
<div id="currentVersionDowngrade" class="inline"></div>
<br>
<table id="compatibleDowngrades">
</table>
<br>
<br>
<h3>Downgrades available if you install other versions</h3>
These versions can only be downgraded to once you install the version shown at the left before.
<table id="availableDowngrades">

</table>
</table>
</div>
</div>
<div class="contentItem hidden" id="download">
<h2>Game Downloads</h2>
Expand Down
15 changes: 14 additions & 1 deletion QuestAppVersionSwitcher/Assets/html/script.js
Original file line number Diff line number Diff line change
Expand Up @@ -66,7 +66,20 @@ function DownloadDowngrade(package, sourceSha, targetSha, targetVersion) {
function UpdateDowngrades() {
document.getElementById("compatibleDowngrades").innerHTML = `Loading downgrades${squareLoader}`
fetch(`https://raw.githubusercontent.com/ComputerElite/APKDowngrader/main/versions.json`).then(res => res.json().then(res => {

// Check if current app even has any downgrades
if(!res.versions.find(x => x.appid == config.currentApp)) {
document.getElementById("allDowngradeShit").style.display = "none"
document.getElementById("noDowngradeShit").style.display = "block"
document.getElementById("noDowngradeShit").innerHTML = `There are no patches available for <code>${config.currentApp}</code>. This means you can sadly not downgrade currently.
<br>
<br>If you ask yourself why it worked before or works in a video you're watching, here's the reason:4
<br>Meta changed how downloads work and I haven't figured out a way how to download any version of any app yet. If we find a way to do that, I'll add it back. But for now you can only downgrade specific games to specific versions which is all manual work on our side to get working.
<br>I'm sorry for the inconvenience.`
return
}
document.getElementById("allDowngradeShit").style.display = "block"
document.getElementById("noDowngradeShit").style.display = "none"
config.currentApp
document.getElementById("compatibleDowngrades").innerHTML = `Checking compatibility. This may take 2 minutes${squareLoader}`
fetch(`/api/currentsha256`).then(s => s.json().then(s => {
var sha = s.msg
Expand Down

0 comments on commit 3779780

Please sign in to comment.