ServerManager
The ServerManager is a tool which helps you keeping track of servers / your current server.
Properties
parseServer(server: string) : { region: number, index: number }
: This method is used to parse a server from a string. The input should be a string containing the index of the server and the region.
const server = serverManager.parseServer("12:2:0");
extractRegionAndIndex() : { region: number | null, index: number | null }
: This method is used to extract the current region and index of the server.
const { region, index } = serverManager.extractRegionAndIndex();
// region = 12 (for example)
// index = 2 (for example)
initialize() : void
: This method will initialize the server manager. It will automatically be called when you create a new MooMoo instance. Sometimes it doesnt work, so calling it at the beginning your of script can fix some bugs.