Skip to content

Instantly share code, notes, and snippets.

@compbrain
Created December 8, 2011 06:23
Show Gist options
  • Save compbrain/1446276 to your computer and use it in GitHub Desktop.
Save compbrain/1446276 to your computer and use it in GitHub Desktop.
minecraft_status example
import minecraft_status
status = minecraft_status.GetMCStatus('my_server_hostname')
if status[0]:
print 'Server is online'
print 'MOTD is: %s' % status[1]
print 'Currently %s/%s players online' % (status[2], status[3])
else:
print 'Server is offline'
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment