summaryrefslogtreecommitdiff
diff options
context:
space:
mode:
authorJesusaves <cpntb1@ymail.com>2022-11-03 09:15:16 -0300
committerJesusaves <cpntb1@ymail.com>2022-11-03 09:15:16 -0300
commit2c2e3ed3f595be69adcf5b3f7a71ecd2a4e0d2bf (patch)
treec6dccc5831153fa5fc38dd2b6c5c86f49f6b229f
parent51ba06d1391f6b8cc93f7badf5cc8e511298e4c8 (diff)
downloadrenpy-2c2e3ed3f595be69adcf5b3f7a71ecd2a4e0d2bf.tar.gz
renpy-2c2e3ed3f595be69adcf5b3f7a71ecd2a4e0d2bf.tar.bz2
renpy-2c2e3ed3f595be69adcf5b3f7a71ecd2a4e0d2bf.tar.xz
renpy-2c2e3ed3f595be69adcf5b3f7a71ecd2a4e0d2bf.zip
Fetch ManaVerse directly from upstream
-rw-r--r--game/3rdparty/manaverse.rpy14
1 files changed, 13 insertions, 1 deletions
diff --git a/game/3rdparty/manaverse.rpy b/game/3rdparty/manaverse.rpy
index 9c25389..2909fb4 100644
--- a/game/3rdparty/manaverse.rpy
+++ b/game/3rdparty/manaverse.rpy
@@ -6,12 +6,24 @@
# Warning: Third Party game clients
#################################################################################
+####### Constants
+define manaverseWin64 = "https://manaplus.germantmw.de/manaplus/nightly/windows/manaverse.zip"
+define manaverseLinux = "https://manaplus.germantmw.de/manaplus/nightly/linux/ManaPlus-x86_64.AppImage"
+
+####### Main Code
init 1 python:
#############################################################################
def download_manaverse(fname):
installdir=get_path("manaplus")
status_update("Downloading %s on RAM..." % fname, 62)
- r=requests.get(persistent.host+"/%s" % fname, timeout=60.0)
+ ## TODO: use `stream=True`
+ if renpy.linux:
+ r=requests.get(manaverseLinux, timeout=60.0)
+ elif renpy.windows:
+ r=requests.get(manaverseWin64, timeout=60.0)
+ else:
+ r=requests.get(persistent.host+"/%s" % fname, timeout=60.0)
+
if (r.status_code != 200):
status_update("Failure retrieving M+: ERROR %d" % r.status_code)
return False