summaryrefslogtreecommitdiff
diff options
context:
space:
mode:
authorJesusaves <cpntb1@ymail.com>2021-05-08 00:55:59 -0300
committerJesusaves <cpntb1@ymail.com>2021-05-08 00:55:59 -0300
commit7805a9651eea35f8b18beb46942fc4b030f906d9 (patch)
tree503833df53413ba652b455e71e45c1d7207da16a
parentdcd375a3f945a6ec6d021fa346dd5dae41680cb3 (diff)
downloadrenpy-7805a9651eea35f8b18beb46942fc4b030f906d9.tar.gz
renpy-7805a9651eea35f8b18beb46942fc4b030f906d9.tar.bz2
renpy-7805a9651eea35f8b18beb46942fc4b030f906d9.tar.xz
renpy-7805a9651eea35f8b18beb46942fc4b030f906d9.zip
Fix some remaining bugs
-rw-r--r--game/update.rpy10
1 files changed, 5 insertions, 5 deletions
diff --git a/game/update.rpy b/game/update.rpy
index 0463a2e..4313dd2 100644
--- a/game/update.rpy
+++ b/game/update.rpy
@@ -166,10 +166,10 @@ init python:
status_update("Attempting Steam authentication...", 81)
accId = steam.get_account_id()
stdout("Steam login active, user %d" % accId)
+
+ # Retrieve new ticket ("token"), send it in Base64 to the API
steam.cancel_ticket()
token = steam.get_session_ticket()
- # The token is a bytearray but we want a string, so we convert it
- print(base64.b64encode(token))
auth = {"accId": accId, "token": base64.b64encode(token)}
time.sleep(1.0)
status_update("Waiting for Vault reply...", 85)
@@ -181,9 +181,9 @@ init python:
raise Exception("Vault returned code %d" % r.status_code)
# Receive the Vault Token
- stdout("Steam result: [%d] %s" % str(r.status_code, r.text))
- auth2 = json.loads(r.text)
- vaultId = auth2["accId"]
+ stdout("Steam result: (%d) %s" % (r.status_code, r.text))
+ auth2 = r.json()
+ vaultId = auth2["vaultId"]
vaultToken = auth2["token"]
# If everything went well, inform Steam support is ON