This commit is contained in:
choelzl 2022-02-09 04:48:58 +01:00
parent 8359300d8e
commit d34b30abf7
Signed by: sora
GPG Key ID: A362EA0491E2EEA0

View File

@ -138,8 +138,8 @@
};
$.bind('command', function(event) {
const sender = "" + event.getSender().toLowerCase(),
console.log(event)
const sender = event.getSender().toLowerCase(),
command = event.getCommand(),
args = event.getArgs(),
action = args[0];
@ -164,6 +164,7 @@
}else if(action.equalsIgnoreCase('refresh')){
var newseed = GameHelper.fetchSeed(args[1]);
}else if(action.equalsIgnoreCase('gg')){
console.log("GOT: GG")
sendData('guesses',JSON.stringify(guesses));
}
}
@ -173,12 +174,12 @@
$.registerChatCommand('./custom/custom/chatguessr.js', 'cg',7);
$.registerChatCommand('./custom/custom/chatguessr.js', 'g',7);
$.registerChatCommand('./custom/custom/chatguessr.js', 'cga',7);
$.registerChatSubcommand('cga', 'open', 1);
$.registerChatSubcommand('cga', 'close', 1);
$.registerChatSubcommand('cga', 'start', 1);
$.registerChatSubcommand('cga', 'end', 1);
$.registerChatSubcommand('cga', 'refresh', 1);
$.registerChatSubcommand('cga', 'gg', 1);
$.registerChatSubcommand('cga', 'open', 2);
$.registerChatSubcommand('cga', 'close', 2);
$.registerChatSubcommand('cga', 'start', 2);
$.registerChatSubcommand('cga', 'end', 2);
$.registerChatSubcommand('cga', 'refresh', 2);
$.registerChatSubcommand('cga', 'gg', 2);
});
})();