This repository has been archived on 2020-03-22. You can view files and clone it, but cannot push or open issues/pull-requests.
ThatMinecraftLauncher/main.py

45 lines
1.5 KiB
Python
Raw Normal View History

#!/usr/bin/python2
#proposed launcher startup sequence
#
# - look at command line arguments
# possible arguments:
# --ui:gui, --ui:cli-interactive, --ui:args-only, --ui:auto (default: auto)
# --update:if-available, --update:force, --update:noupdate (default: if-available)
# --launch, -l (default: not present)
2019-10-12 07:34:00 +02:00
# --silent, --quiet, -s, -q (default: only present in interactive cli mode)
#
# - decide whether to launch the GUI or not (either by command line argument
# or by determining if running from terminal)
#
# - if updating: install update and restart if in GUI mode or interactive CLI mode,
# update and exit in args-only mode
#
# - launch GUI or launch interactive CLI or follow instructions from the
# command line:
# If --ui:args-only is present, the default actions are update:if-available
# and exit without launching. If -l is present, the GUI or
# interactive CLI are only shown while updating and Minecraft will launch
# automatically.
#
# - load configuration
#
# - handle user actions (only in GUI or interactive mode, skipped with -l)
# - update and store configuration
# - GUI interaction
# - wait for launch or close actions
#
# - launch the game or exit
2019-10-22 14:20:32 +02:00
# import standard libraries
import sys
# adjust path
sys.path.append("./lib/launcher/python")
# import libraries from changed path
import yggdrasil
# temporary test stuff
2019-10-22 14:20:32 +02:00
a,b = yggdrasil.authenticateUser(raw_input("Username: "), raw_input("Password: "))
if a:
print b["accessToken"]