Add rcon from https://github.com/aidanlok/mc_rcon/tree/master but without flutter requirement

This commit is contained in:
zontreck 2024-05-24 14:40:28 -07:00
parent 1133992078
commit 5af94f3988
3 changed files with 411 additions and 0 deletions

View file

@ -0,0 +1,12 @@
import 'dart:io';
import 'dart:math';
/// The socket that is used to communicate with the RCON server.
/// Generated when createSocket() is run.
Socket? rconSck;
/// The randomly generated request ID that is sent with every
/// message to the RCON server. Used to ensure that the commands
/// sent to and received from the server are ours, and not another
/// user's.
int requestID = Random().nextInt(2147483647);