Skip to content

Commit 8f3a31d

Browse files
committed
Refactor scanner options and GUI, add MC version output
Removed default IP range and port constants from scanner.cpp and updated argument parsing to require explicit --start-ip and --end-ip. Simplified and improved whitespace trimming in file loading. Refactored GUI to remove port input, enforce randomized targets, and improve input validation. In mcstatus_probe.py, added Minecraft server version to output.
1 parent c262f7c commit 8f3a31d

3 files changed

Lines changed: 139 additions & 199 deletions

File tree

6.24 KB
Binary file not shown.

mcstatus_probe.py

Lines changed: 3 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -79,12 +79,15 @@ def log(msg: str) -> None:
7979
latency_ms = getattr(status, "latency", None)
8080
players_online = getattr(status.players, "online", None)
8181
players_max = getattr(status.players, "max", None)
82+
version = getattr(getattr(status, "version", None), "name", None)
8283

8384
parts = [f"{args.ip}:{args.port}"]
8485
if players_online is not None and players_max is not None:
8586
parts.append(f"players {players_online}/{players_max}")
8687
if latency_ms is not None:
8788
parts.append(f"latency {latency_ms:.1f} ms")
89+
if version:
90+
parts.append(f"version {version}")
8891
if motd:
8992
parts.append(f"motd \"{motd}\"")
9093

0 commit comments

Comments
 (0)