A library for creating a custom Minecraft launcher
Project description
minecraft-launcher-lib
A Python library for creating a custom minecraft launcher. This library containts functions to install and execute minecraft and interacting with mojang accounts.
import minecraft_launcher_lib
import subprocess
#Get latest version
latest_version = minecraft_launcher_lib.utils.get_latest_version()["release"]
#Get Minecraft directory
minecraft_directory = minecraft_launcher_lib.utils.get_minecraft_directory()
#Make sure, the latest version of Minecraft is installed
minecraft_launcher_lib.install.install_minecraft_version(latest_version,minecraft_directory)
#Login
login_data = minecraft_launcher_lib.account.login_user("JohnDoe","secret")
#Get Minecraft command
options = {
"username": login_data["selectedProfile"]["name"],
"uuid": login_data["selectedProfile"]["id"],
"token": login_data["accessToken"]
}
minecraft_command = minecraft_launcher_lib.command.get_minecraft_command(latest_version,minecraft_directory,options)
#Start Minecraft
subprocess.call(minecraft_command)
Features:
- Easy installing
- Get command to run minecraft
- Login to mojang account
- Forge supported
- Old versions like alpha or beta supported
- Documention aviable
- OpenSource
Thanks to tomsik68 who documented how a minecraft launcher works
Note:
This library is still beta. It might not work with all versions of minecraft yet.
Project details
Release history Release notifications | RSS feed
Download files
Download the file for your platform. If you're not sure which to choose, learn more about installing packages.
Source Distribution
Built Distribution
Close
Hashes for minecraft-launcher-lib-0.5.tar.gz
Algorithm | Hash digest | |
---|---|---|
SHA256 | f44a80fd1e08eeb46b6c795a26dbe83d01218d7c8674007b5446c4818105a242 |
|
MD5 | 787114bfd646e9a71a5ffb2cdead97c6 |
|
BLAKE2b-256 | acc0f860bedde2790906856b397560ee48906ac8ae58d801854df4686b44f3cb |
Close
Hashes for minecraft_launcher_lib-0.5-py3-none-any.whl
Algorithm | Hash digest | |
---|---|---|
SHA256 | fd20c43fa68b49aa488ed3b916ce527381dd55348cfc9cd96c79a13ed7099a1e |
|
MD5 | 81c4e2f0645eae05ad8b65893e7d84a6 |
|
BLAKE2b-256 | c086d7f50f571c568c9145b687cb8f5a31714b410edbf8aed36762cf60e696ae |