Skip to main content

Provides info on the EarthMC Minecraft server.

Project description

EarthMC Package

Provides info on the EarthMC Minecraft server.

Installation

$ pip install EarthMC

Import and instantiate classes

from EarthMC import towns, nations, players

towns = towns()
nations = nations()
players = players()

Methods

Player Related

Get all online players

onlinePlayers = players.allOnline()

print(onlinePlayers)

# => [{"x": 0, "y": 64, "z": 0, "isUnderground": true, "nickname": "PlayerNickname", "name": "PlayerName"}, ...]

Get an online player

op = players.getOnlinePlayer("PlayerName")

print(op)

# => {"x": 0, "y": 64, "z": 0, "isUnderground": true, "nickname": "PlayerNickname", "name": "PlayerName"}

Town Related

Get all towns

allTowns = towns.all()

print(allTowns)

# => [{ area: 975, x: -352, z: -9904, name: 'TownName', nation: 'NationName', mayor: 'MayorName', residents: ['Resident', 'OtherResident', ...], pvp: false, mobs: false, public: false, explosion: false, fire: false, capital: true }, ...]

Get a town by name

town = towns.get("TownName")

print(town)

# => { area: 975, x: -352, z: -9904, name: 'TownName', nation: 'NationName', mayor: 'MayorName', residents: ['Resident', 'OtherResident', ...], pvp: false, mobs: false, public: false, explosion: false, fire: false, capital: true }

Nation Related

Get all nations

allNations = nations.all()

print(allNations)

# => [{ name: 'NationName', residents: ['Resident', 'OtherResident', ...], towns: ['Town', 'OtherTown', ...], king: 'KingName', capitalName: 'CapitalName', capitalX: -352, capitalZ: -9904, area: 7289 }, ...]

Get a nation by name

nation = nations.get("NationName")

print(nation)

# => { name: 'NationName', residents: ['Resident', 'OtherResident', ...], towns: ['Town', 'OtherTown', ...], king: 'KingName', capitalName: 'CapitalName', capitalX: -352, capitalZ: -9904, area: 7289 }

Project details


Download files

Download the file for your platform. If you're not sure which to choose, learn more about installing packages.

Source Distribution

EarthMC-1.0.6.tar.gz (2.7 kB view details)

Uploaded Source

Built Distribution

If you're not sure about the file name format, learn more about wheel file names.

EarthMC-1.0.6-py2-none-any.whl (3.4 kB view details)

Uploaded Python 2

File details

Details for the file EarthMC-1.0.6.tar.gz.

File metadata

  • Download URL: EarthMC-1.0.6.tar.gz
  • Upload date:
  • Size: 2.7 kB
  • Tags: Source
  • Uploaded using Trusted Publishing? No
  • Uploaded via: twine/1.15.0 pkginfo/1.5.0.1 requests/2.24.0 setuptools/41.2.0 requests-toolbelt/0.9.1 tqdm/4.48.2 CPython/2.7.17

File hashes

Hashes for EarthMC-1.0.6.tar.gz
Algorithm Hash digest
SHA256 1e1ad0b5adaaf7d134f527dbff8f38c916a79e5aee155157c85eba2777f16940
MD5 66856e7f2b0813e4283210b697899a2d
BLAKE2b-256 a6deb2f6c41a4954b04fddc9e28158a7cbb91950eef1946741d1aa345d5bbb8b

See more details on using hashes here.

File details

Details for the file EarthMC-1.0.6-py2-none-any.whl.

File metadata

  • Download URL: EarthMC-1.0.6-py2-none-any.whl
  • Upload date:
  • Size: 3.4 kB
  • Tags: Python 2
  • Uploaded using Trusted Publishing? No
  • Uploaded via: twine/1.15.0 pkginfo/1.5.0.1 requests/2.24.0 setuptools/41.2.0 requests-toolbelt/0.9.1 tqdm/4.48.2 CPython/2.7.17

File hashes

Hashes for EarthMC-1.0.6-py2-none-any.whl
Algorithm Hash digest
SHA256 810fba9a662912c1fed18516d7fd96e6c3352fc698ac4b98c9b78459960d76b1
MD5 8da51da62b652cff390a35f7a45c9703
BLAKE2b-256 af326f800218a4aa21c8e0c39aa56729a036d4471f2a34ce5909d8db7a4d891b

See more details on using hashes here.

Supported by

AWS Cloud computing and Security Sponsor Datadog Monitoring Depot Continuous Integration Fastly CDN Google Download Analytics Pingdom Monitoring Sentry Error logging StatusPage Status page