mirror of
https://github.com/Ratstail91/SANCTUM.git
synced 2025-11-29 10:34:26 +11:00
Mori is half complete
This commit is contained in:
@@ -20,6 +20,7 @@ exports.ConnectToServer = function(username, address, port, pass) { //NOTE: this
|
||||
io.on("connect", () => io.emit("authentication", {SERVER_PASS_KEY: pass, username: username}) );
|
||||
io.on("authenticated", () => console.log("Authenticated with server: " + `${address}:${port}`));
|
||||
io.on("disconnect", () => console.log("disconnected from server: " + `${address}:${port}`));
|
||||
io.on("error", (err) => { throw err; } );
|
||||
|
||||
initialized = true;
|
||||
}
|
||||
|
||||
@@ -9,6 +9,7 @@ exports = module.exports = {};
|
||||
//typingDelay (optional) - delay in milliseconds for the message, while typing is shown
|
||||
exports.SendPublicMessage = function(client, user, channel, message, typingDelay = 0) {
|
||||
//Handle optional second argument (so much for default arugments in node)
|
||||
//WARNING: this may be funky as fuck due to typingDelay; if so, delete this
|
||||
if (message === undefined) {
|
||||
message = channel;
|
||||
channel = user;
|
||||
|
||||
Reference in New Issue
Block a user