Skip to main content

(Deprecated) Module to control Minehut servers via Python

Reason this release was yanked:

Broken

Project description

This module is deprecated as of the Minehut API being shut down.

Welcome to the Minefob documentation.

Here you will learn how to use Minefob.

Initialization

m = Minefob("foorbar@example.domain", "password", "my_server")

Initializing a new Minefob class instance requires 3 arguments:

  • Email associated with Minehut account
  • Password of the aforementioned account
  • and the server name

will return RunTimeError if server name is misspelled.

Post Commands

Say

m.say("Hey there")

Will print the desired message to the chat. Appears like this [Server] Hey there

Title

m.title("Big text", subwords="little text", fadeIn=0, hold=20, fadeOut=0)

Will summon a title. The big text title is the first argument and the subtitle as the second argument. Subtitle is not required. I have a feeling the fadeIn, hold, and fadeOut are self-explanatory, however you must know that the time is in Minecraft ticks (20 ticks = 1 sec.)

Kick

m.kick("@a", "because i wanted to")

Will kick the selected player(s). Use the second argument to provide a reason, if wanted.

Command

m.command("/give @r minecraft:diamonds 64")

Will run the desired command.

Save

m.save()

Saves server.

Awaken

m.awaken()

Wakes server from hibernation.

Slumber

m.slumber(17)

Will kick players, save server, and put it into hibernation AFTER a countdown. Length of countdown is determined by the only argument passed into this function. Leave at 0 to skip countdown and shut down instantly.

Properties

Players

>>> m.players
3

Returns the number of active players on the server.

Online

>>> m.online
False

Returns whether the server is online or not.

Status

>>> m.status
'SERVER-DOWNLOADING'

Returns the current status of the server, basically a more detailed version of m.online

Started

>>> m.started
[09, 34, 55]

Returns the time the server was started as a list in this format: [HH:MM:SS]

Stopped

>>> m.stopped
[10, 16, 37]

Returns the time the server was stopped as a list in this format: [HH:MM:SS]

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

minefob-1.0.2.1.tar.gz (3.0 kB view details)

Uploaded Source

Built Distribution

minefob-1.0.2.1-py3-none-any.whl (3.6 kB view details)

Uploaded Python 3

File details

Details for the file minefob-1.0.2.1.tar.gz.

File metadata

  • Download URL: minefob-1.0.2.1.tar.gz
  • Upload date:
  • Size: 3.0 kB
  • Tags: Source
  • Uploaded using Trusted Publishing? No
  • Uploaded via: twine/5.1.1 CPython/3.12.4

File hashes

Hashes for minefob-1.0.2.1.tar.gz
Algorithm Hash digest
SHA256 654af810da10bb2a1bd54d9c5ee39030c3097a94c48bbde3b72d1d092b1da651
MD5 6127b5fdb358f155eaa1668be97ac01d
BLAKE2b-256 dcb5dd22acf6ed9dfa4ca80966791ad4a8030508d552292df1ad92e43b601763

See more details on using hashes here.

File details

Details for the file minefob-1.0.2.1-py3-none-any.whl.

File metadata

  • Download URL: minefob-1.0.2.1-py3-none-any.whl
  • Upload date:
  • Size: 3.6 kB
  • Tags: Python 3
  • Uploaded using Trusted Publishing? No
  • Uploaded via: twine/5.1.1 CPython/3.12.4

File hashes

Hashes for minefob-1.0.2.1-py3-none-any.whl
Algorithm Hash digest
SHA256 5bcece70c99320095acec002d54db46ef43e6cb1bbed5e3873e0ca94b493b7cd
MD5 b962746f27e6cc3f3d2dfdc72c710eba
BLAKE2b-256 835eb24d9ba7bbfd9b358ea58a071b12e10b2ae73e3db2d39dfc408e6fe22e98

See more details on using hashes here.

Supported by

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