summaryrefslogtreecommitdiff
diff options
context:
space:
mode:
authorJesusaves <cpntb1@ymail.com>2021-05-09 11:50:30 -0300
committerJesusaves <cpntb1@ymail.com>2021-05-09 11:50:30 -0300
commit347015485d484f739575fcc2e64872d485305ba4 (patch)
tree85eb0c28bcfacb3b17762892a64d699a891c5f3f
parent8aee552a861faa9ae938e97523f6bfea97bac23d (diff)
downloadrenpy-347015485d484f739575fcc2e64872d485305ba4.tar.gz
renpy-347015485d484f739575fcc2e64872d485305ba4.tar.bz2
renpy-347015485d484f739575fcc2e64872d485305ba4.tar.xz
renpy-347015485d484f739575fcc2e64872d485305ba4.zip
Behave differently when error code 406 is received
-rw-r--r--game/update.rpy8
1 files changed, 7 insertions, 1 deletions
diff --git a/game/update.rpy b/game/update.rpy
index 609e63d..9bcadf1 100644
--- a/game/update.rpy
+++ b/game/update.rpy
@@ -181,6 +181,12 @@ init python:
## Request the Vault for the ticket validation
r = requests.post(VAULT_HOST+"/steam_auth", json=auth, timeout=15.0)
+ ## Ticket error, we die here.
+ if (r.status_code == 406):
+ status_update("{color=#f00}{b}STEAM AUTHENTICATION ERROR.\nSteam refused authentication. Try restarting the app.{/b}{/color}")
+ responsive=False
+ return
+
## Intercept rate-limiting (429) and retry once
if (r.status_code == 429 or r.status_code == 500):
status_update("Rate limited! Trying again 15s...", 85)
@@ -192,7 +198,7 @@ init python:
status_update("Rate limited! Trying again...", 85)
r = requests.post(VAULT_HOST+"/steam_auth", json=auth, timeout=15.0)
- ## If unsucessful, give up on Steam Auth
+ ## If still unsucessful, give up on Steam Auth
if (r.status_code != 200):
raise Exception("Vault returned code %d" % r.status_code)