Huge command system overhaul

This commit is contained in:
Vortrex
2020-12-13 14:44:14 -06:00
parent f97775760b
commit 2ef292d799
19 changed files with 145 additions and 1587 deletions

View File

@@ -10,25 +10,12 @@
function initChatScript() {
console.log("[Asshat.Chat]: Initializing chat script ...");
addChatCommandHandlers();
console.log("[Asshat.Chat]: Chat script initialized successfully!");
return true;
}
// ---------------------------------------------------------------------------
function addChatCommandHandlers() {
console.log("[Asshat.Chat]: Adding chat command handlers ...");
let chatCommands = serverCommands.chat;
for(let i in chatCommands) {
addCommandHandler(chatCommands[i].command, chatCommands[i].handlerFunction);
}
console.log("[Asshat.Chat]: Chat command handlers added successfully!");
return true;
}
// ---------------------------------------------------------------------------
function meActionCommand(command, params, client) {
if(doesCommandRequireLogin(command)) {
if(!isClientLoggedIn(client)) {