minestat

Crystal port of ldilley's MineStat

minestat

A port of minestat

Installation

Add this to your application's shard.yml:

dependencies:
  minestat:
    github: unn4m3d/minestat

Usage

Use this like ruby version, but use MineStat::Data instead of MineStat. Remember to add .not_nil! if necessary

require "minestat"

ms = MineStat::Data.new "minecraft.dilley.me", 25565u32
puts "Minecraft server status of #{ms.address} on port #{ms.port}:"
if ms.online
  puts "Server is online running version #{ms.version.not_nil!} with #{ms.current_players.not_nil!} out of #{ms.max_players.not_nil!} players."
  puts "Message of the day: #{ms.motd.not_nil!}"
else
  puts "Server is offline!"
end

Development

TODO: Write development instructions here

Contributing

  1. Fork it ( https://github.com/unn4m3d/minestat/fork )
  2. Create your feature branch (git checkout -b my-new-feature)
  3. Commit your changes (git commit -am 'Add some feature')
  4. Push to the branch (git push origin my-new-feature)
  5. Create a new Pull Request

Contributors

Repository

minestat

Owner
Statistic
  • 0
  • 0
  • 0
  • 1
  • 1
  • almost 7 years ago
  • January 12, 2018
License

MIT License

Links
Synced at

Sun, 22 Dec 2024 03:44:54 GMT

Languages