Apps Home
|
Create an App
CrazyTicket
Author:
os_vigilante
Description
Source Code
Launch App
Current Users
Created by:
Os_Vigilante
var app = { name: "'CrazyTicket'", type: "App", version: "2.2", build: ".100", date: "2017.07.20", acg: "acrazyguy", ph: "phatkatmeow", te: "phatterkat", pe: "perd", sf: "sartfack", rx: "robx7", bli: "birdylovesit", bf: "blazefyre", CD: "dump" }; var COLOR = { DEVELOPER: "#D9F7F7", BRED: "#FF1407", MRED: "#D80A00", HLRED: "#FFE5E5", HILITE: "#EEE5FF", SUCCESS: "#468847", ERROR: "#B94A48", INFO: "#144D8C", NOTICE: "#6900CC", DPURPLE: "#663399", LPURPLE: "#8041BF", BLUE: "#000099", MOD: "#DC0000", FAN: "#009900", SYNTAX: "#995B00", HVTEXT: "#D80A00", HVBACK: "#FFFFBF", TBMBACK: "#E0EEFF", TBMTEXT: "#12447A", GREEN: "#009900", GREENHL: "#E5FFE5", MAG: "#E509E5", PINK: "#FF48D2", BLI: "#DDFFCC", BF: "#FFE0EA" }; var COMMAND = { CMDS: "cmds", TICKETS: "tickets", PASSWORD: "pass", TIMELEFT: "timeleft", SHOWTIME: "showtime", USETICKET: "useticket", SAVETICKET: "saveticket", ADD: "add", AU: "au", DEL: "del", DU: "du", OTS: "ots", SENDPW: "sendpw", ADDP: "addp", ADDOTS: "addots", DELP: "delp", DELOTS: "delots", HILITE: "hilite", HL: "hl", STARTSHOW: "startshow", STOPSHOW: "stopshow", SHOWOVER: "showover", SHOWEND: "showend", NEWSHOW: "newshow", VIEWERS: "viewers", SUBJECT: "subject", CTSUBJECT: "ctsubject", LOCK: "lock", CHECK: "check", CTN: "ctn", CTND: "ctnd", CTNH: "ctnh", CTNDH: "ctndh", CTB: "ctb", CTM: "ctm", CTBM: "ctbm", CTT: "ctt", CTV: "ctv", SCHAT: "schat", SPASS: "spass", TIPSOFF: "tipsoff", STARTTIMER: "starttimer", ADDTIME: "addtime", PLIST: "plist", PLISTW: "plistw", VLIST: "vlist", NRLIST: "nrlist", ALIST: "alist", AALIST: "aalist", EMLIST: "emlist", LTLIST: "ltlist", OTSLIST: "otslist", USEDOTS: "usedots", NEW: "new", EMAIL: "email", SIL: "sil", UNSIL: "unsil", SLIST: "slist", CHANGEPW: "changepw", CTPRICE: "ctprice", CTRESET: "ctreset" }; var FLAG = { goal: false, priceup: false, debug: false, dev: false, hilite: true, lock: false, schat: false, spass: true, toff: false, cdtimer: false, hcam: false, sover: false, end: false, email: false, ots: false }; var cmdPrefix = "/"; var dashLine = "------------------------------------------------------------"; var typeCmds = " Type " + cmdPrefix + COMMAND["CMDS"] + " to see all commands."; var whatsNew = "--------------------- WHAT'S NEW ----------------------\n\u25cf NEW COMMANDS:\n\u25cf The Notice commands now take the argument 'r'.\n\u25cf This will output the Notice in red.\n\u25cf E.G.: /ctn r Message\n" + dashLine; var otsMsg = "You have an outstanding ticket that you can use for this show.\n\u25cf To use your ticket simply type /useticket in the chat and you will be added to the ticket holders list for this show.\n\u25cf If you change your mind BEFORE the show starts simply type /saveticket in the chat, and your ticket will become available for another time.\n"; var fanMsg = dashLine + "\n\u25cf The broadcaster has set a special ticket price\n\u25cf for fanclub members.\n\u25cf Tip " + cb["settings"]["fanbuyin"] + " tokens for a show ticket.\n" + dashLine; var roomHost = cb["room_slug"]; var MODS = "red"; var FANS = "green"; var totalTipped = 0; var cdTimerMinutes = 0; var hideTime = 0; var cdMilliSecs = 0; var passWord = ""; var rePassword; var paidList = []; var viewerList = []; var nirList = []; var addList = []; var autoList = []; var silList = []; var lifeList = []; var otsTickets = []; var usedOTS = []; var devList = []; var cmdList = ["add", "starttimer", "showover", "showend"]; var miscList = []; var oldPrice = 0; var opList = { name: [], tip: [] }; var emList = { name: [], email: [] }; cb["settings_choices"] = [{ name: "goal", type: "int", minValue: 0, label: "Token Goal (optional)", required: false }, { name: "showDesc", type: "str", minLength: 1, maxLength: 255, defaultValue: "", label: "Show Description", required: false }, { name: "buyin", type: "int", minValue: 1, defaultValue: 25, label: "Ticket Price" }, { name: "fanbuyin", type: "int", label: "Ticket price for FANS (leave blank if fans are auto-added or pay the regular price)", required: false }, { name: "lifeTime", type: "str", minLength: 1, maxLength: 500, defaultValue: "", label: "*NEW* Enter Lifetime Ticket Holders' names here. * NAMES MUST BE SEPARATED BY A COMMA *", required: false }, { name: "hideTips", type: "choice", choice1: "Yes", choice2: "No", defaultValue: "No", label: "Hide tip total from viewers?" }, { name: "showViewers", type: "choice", choice1: "Yes", choice2: "No", defaultValue: "Yes", label: "Show the no. of ticket holders actually in the room (Viewing)?" }, { name: "osTickets", type: "choice", choice1: "Yes", choice2: "No", defaultValue: "No", label: "Enable the Outstanding Ticket System?" }, { name: "otsHolders", type: "str", minLength: 1, maxLength: 500, defaultValue: "", label: "Enter Outstanding Ticket holders' names here if you only have a few. * NAMES MUST BE SEPARATED BY A COMMA *", required: false }, { name: "includeMods", type: "choice", choice1: "Yes", choice2: "No", defaultValue: "Yes", label: "Allow moderators to add/delete users (and themselves) to the show?" }, { name: "modPrice", type: "choice", choice1: "Yes", choice2: "No", defaultValue: "No", label: "Allow moderators to change the ticket price for you?" }, { name: "autoaddMods", type: "choice", choice1: "Yes", choice2: "No", defaultValue: "No", label: "Automatically give Mods a ticket when they enter the room?" }, { name: "autoaddFans", type: "choice", choice1: "Yes", choice2: "No", defaultValue: "No", label: "Automatically give Fanclub Members a ticket when they enter?" }]; if (cb["settings"]["hideTips"] === "Yes") { FLAG["toff"] = true }; if (cb["settings"]["goal"]) { FLAG["goal"] = true; FLAG["toff"] = false } else { cb["settings"]["goal"] = "None" }; if (cb["settings"]["osTickets"] === "Yes") { FLAG["ots"] = true }; if (cb["settings"]["lifeTime"] != "") { lifeList = String(cb["settings"]["lifeTime"])["split"](/[,\s]+/) }; if (FLAG["ots"] && cb["settings"]["otsHolders"] != "") { otsTickets = String(cb["settings"]["otsHolders"])["split"](/[,\s]+/) }; cb["onDrawPanel"](function (_0xfed3x23) { var _0xfed3x24 = ""; var _0xfed3x25 = ""; if (FLAG["goal"]) { _0xfed3x24 = "Total Tips / Goal"; _0xfed3x25 = "" + totalTipped + " / " + cb["settings"]["goal"] } else { _0xfed3x24 = "Tips Received:"; _0xfed3x25 = "" + totalTipped }; if (FLAG["sover"] && !FLAG["end"]) { if (cb["settings"]["showViewers"] === "Yes") { return { "\x74\x65\x6D\x70\x6C\x61\x74\x65": "3_rows_of_labels", "\x72\x6F\x77\x31\x5F\x6C\x61\x62\x65\x6C": "Tickets/Viewing:", "\x72\x6F\x77\x31\x5F\x76\x61\x6C\x75\x65": cb["limitCam_allUsersWithAccess"]()["length"] + " / " + viewerList["length"], "\x72\x6F\x77\x32\x5F\x6C\x61\x62\x65\x6C": "", "\x72\x6F\x77\x32\x5F\x76\x61\x6C\x75\x65": "", "\x72\x6F\x77\x33\x5F\x6C\x61\x62\x65\x6C": "", "\x72\x6F\x77\x33\x5F\x76\x61\x6C\x75\x65": "" } } else { return { "\x74\x65\x6D\x70\x6C\x61\x74\x65": "3_rows_of_labels", "\x72\x6F\x77\x31\x5F\x6C\x61\x62\x65\x6C": "Tickets Holders:", "\x72\x6F\x77\x31\x5F\x76\x61\x6C\x75\x65": cb["limitCam_allUsersWithAccess"]()["length"], "\x72\x6F\x77\x32\x5F\x6C\x61\x62\x65\x6C": "", "\x72\x6F\x77\x32\x5F\x76\x61\x6C\x75\x65": "", "\x72\x6F\x77\x33\x5F\x6C\x61\x62\x65\x6C": "", "\x72\x6F\x77\x33\x5F\x76\x61\x6C\x75\x65": "" } } } else { if (FLAG["end"]) { return { "\x74\x65\x6D\x70\x6C\x61\x74\x65": "3_rows_11_21_31", "\x72\x6F\x77\x31\x5F\x76\x61\x6C\x75\x65": "The show is over.", "\x72\x6F\x77\x32\x5F\x76\x61\x6C\x75\x65": "Ticket sales have", "\x72\x6F\x77\x33\x5F\x76\x61\x6C\x75\x65": "been suspended." } } else { if (FLAG["toff"]) { if (cb["settings"]["showViewers"] === "Yes") { return { "\x74\x65\x6D\x70\x6C\x61\x74\x65": "3_rows_of_labels", "\x72\x6F\x77\x31\x5F\x6C\x61\x62\x65\x6C": "Tickets/Viewing:", "\x72\x6F\x77\x31\x5F\x76\x61\x6C\x75\x65": cb["limitCam_allUsersWithAccess"]()["length"] + " / " + viewerList["length"], "\x72\x6F\x77\x32\x5F\x6C\x61\x62\x65\x6C": "Ticket price:", "\x72\x6F\x77\x32\x5F\x76\x61\x6C\x75\x65": cb["settings"]["buyin"], "\x72\x6F\x77\x33\x5F\x6C\x61\x62\x65\x6C": "", "\x72\x6F\x77\x33\x5F\x76\x61\x6C\x75\x65": "" } } else { return { "\x74\x65\x6D\x70\x6C\x61\x74\x65": "3_rows_of_labels", "\x72\x6F\x77\x31\x5F\x6C\x61\x62\x65\x6C": "Tickets Holders:", "\x72\x6F\x77\x31\x5F\x76\x61\x6C\x75\x65": cb["limitCam_allUsersWithAccess"]()["length"], "\x72\x6F\x77\x32\x5F\x6C\x61\x62\x65\x6C": "Ticket price:", "\x72\x6F\x77\x32\x5F\x76\x61\x6C\x75\x65": cb["settings"]["buyin"], "\x72\x6F\x77\x33\x5F\x6C\x61\x62\x65\x6C": "", "\x72\x6F\x77\x33\x5F\x76\x61\x6C\x75\x65": "" } } } else { if (cb["settings"]["showViewers"] === "Yes") { return { "\x74\x65\x6D\x70\x6C\x61\x74\x65": "3_rows_of_labels", "\x72\x6F\x77\x31\x5F\x6C\x61\x62\x65\x6C": _0xfed3x24, "\x72\x6F\x77\x31\x5F\x76\x61\x6C\x75\x65": _0xfed3x25, "\x72\x6F\x77\x32\x5F\x6C\x61\x62\x65\x6C": "Tickets/Viewing:", "\x72\x6F\x77\x32\x5F\x76\x61\x6C\x75\x65": cb["limitCam_allUsersWithAccess"]()["length"] + " / " + viewerList["length"], "\x72\x6F\x77\x33\x5F\x6C\x61\x62\x65\x6C": "Ticket price:", "\x72\x6F\x77\x33\x5F\x76\x61\x6C\x75\x65": cb["settings"]["buyin"] } } else { return { "\x74\x65\x6D\x70\x6C\x61\x74\x65": "3_rows_of_labels", "\x72\x6F\x77\x31\x5F\x6C\x61\x62\x65\x6C": _0xfed3x24, "\x72\x6F\x77\x31\x5F\x76\x61\x6C\x75\x65": _0xfed3x25, "\x72\x6F\x77\x32\x5F\x6C\x61\x62\x65\x6C": "Tickets Holders:", "\x72\x6F\x77\x32\x5F\x76\x61\x6C\x75\x65": cb["limitCam_allUsersWithAccess"]()["length"], "\x72\x6F\x77\x33\x5F\x6C\x61\x62\x65\x6C": "Ticket price:", "\x72\x6F\x77\x33\x5F\x76\x61\x6C\x75\x65": cb["settings"]["buyin"] } } } } } }); cb["onTip"](function (_0xfed3x26) { var _0xfed3x27 = parseInt(_0xfed3x26["amount"], 10); var _0xfed3x23 = _0xfed3x26["from_user"]; var _0xfed3x28 = _0xfed3x26["from_user_is_mod"]; var _0xfed3x29 = _0xfed3x26["from_user_in_fanclub"]; var _0xfed3x2a = _0xfed3x26["message"]; var _0xfed3x2b = ""; var _0xfed3x2c = 0, _0xfed3x2d = 0; if (cb["limitCam_userHasAccess"](_0xfed3x23) && !cbjs["arrayContains"](viewerList, _0xfed3x23)) { viewerList["push"](_0xfed3x23) }; totalTipped += _0xfed3x27; if ((totalTipped >= cb["settings"]["goal"]) && FLAG["goal"]) { cb["sendNotice"](dashLine + "\n\u25cf " + app["name"] + ": GOAL ACHIEVED!\n\u25cf Thanks to all tippers.\n" + dashLine, "", "", COLOR.MRED, "bold"); cb["settings"]["goal"] = 0; FLAG["goal"] = false }; if (FLAG["email"]) { _0xfed3x2b = _0xfed3x2a["match"](/\b[A-Z0-9._%+-]+@[A-Z0-9.-]+\.[A-Z]{2,4}\b/i) || ""; _0xfed3x2c = emList["name"]["indexOf"](_0xfed3x23); if (_0xfed3x2c > -1 && !emList["email"][_0xfed3x2c]) { emList["email"][_0xfed3x2c] = _0xfed3x2b; cb["sendNotice"]("\u25cf Missing email address recorded.", roomHost, COLOR.HVBACK, COLOR.HVTEXT, "bold") } }; if (FLAG["priceup"] && !cb["limitCam_userHasAccess"](_0xfed3x23)) { _0xfed3x2d = opList["name"]["indexOf"](_0xfed3x23); if (_0xfed3x2d > -1 && _0xfed3x27 >= opList["tip"][_0xfed3x2d]) { user("add", _0xfed3x23, true); if (!cbjs["arrayContains"](paidList, _0xfed3x23)) { paidList["push"](_0xfed3x23) }; if (!cbjs["arrayContains"](viewerList, _0xfed3x23)) { viewerList["push"](_0xfed3x23) }; cb["sendNotice"](dashLine + "\n\u25cf You NOW have a ticket and will be able to view\n\u25cf the 'Hidden Cam' show.\n" + dashLine, _0xfed3x23, COLOR.HILITE, COLOR.NOTICE, "bold") }; if (_0xfed3x27 === oldPrice) { opList["name"]["push"](_0xfed3x23); opList["tip"]["push"](cb["settings"]["buyin"] - oldPrice); cb["sendNotice"](dashLine + "\n\u25cf :alert1 YOU ONLY TIPPED " + oldPrice + " TOKENS BUT\n\u25cf THE PRICE WAS INCREASED TO " + cb["settings"]["buyin"] + " TOKENS!!\n\u25cf PLEASE TIP ANOTHER " + (cb["settings"]["buyin"] - oldPrice) + " TOKENS TO GET\n\u25cf YOUR TICKET!!\n" + dashLine, _0xfed3x23, "", COLOR.MRED, "bold") } }; if (((_0xfed3x27 >= cb["settings"]["buyin"]) || (cb["settings"]["fanbuyin"] && _0xfed3x29 && (_0xfed3x27 >= cb["settings"]["fanbuyin"]))) && !FLAG["end"]) { if (!cb["limitCam_userHasAccess"](_0xfed3x23)) { cb["sendNotice"]("\u25cf Ticket sold to '" + _0xfed3x23 + "'", "", "", COLOR.NOTICE, "bold"); user("add", _0xfed3x23, true); if (!cbjs["arrayContains"](paidList, _0xfed3x23)) { paidList["push"](_0xfed3x23) }; if (!cbjs["arrayContains"](viewerList, _0xfed3x23)) { viewerList["push"](_0xfed3x23) }; if (FLAG["spass"]) { cb["sendNotice"](dashLine + "\n\u25cf You will be able to view the 'Hidden Cam' show.\n" + dashLine, _0xfed3x23, COLOR.HILITE, COLOR.NOTICE, "bold") }; if (FLAG["email"]) { _0xfed3x2b = _0xfed3x2a["match"](/\b[A-Z0-9._%+-]+@[A-Z0-9.-]+\.[A-Z]{2,4}\b/i) || ""; emList["name"]["push"](_0xfed3x23); emList["email"]["push"](_0xfed3x2b); if (!_0xfed3x2b) { cb["sendNotice"]("\u25cf You may have forgotten your email address in the tip note.", _0xfed3x23, "", COLOR.BRED, "bold"); cb["sendNotice"]("\u25cf Viewer '" + _0xfed3x23 + "' may have forgotten their email address in the tip note.", roomHost, COLOR.HVBACK, COLOR.HVTEXT, "bold"); cb["sendNotice"]("\u25cf Viewer '" + _0xfed3x23 + "' may have forgotten their email address in the tip note.", "", "", COLOR.MOD, "bold", MODS) } else { cb["sendNotice"]("\u25cf Email address recorded.", roomHost, COLOR.HVBACK, COLOR.HVTEXT, "bold") } } } }; cb["drawPanel"]() }); cb["onEnter"](function (_0xfed3x23) { var _0xfed3x2e = _0xfed3x23["user"]; var _0xfed3x28 = _0xfed3x23["is_mod"]; var _0xfed3x29 = _0xfed3x23["in_fanclub"]; if (FLAG["lock"] && !cb["limitCam_isRunning"]()) { if (!user("check", _0xfed3x2e) && _0xfed3x2e != roomHost) { cb["sendNotice"]("Room Crasher! '" + _0xfed3x2e + "' does NOT have a ticket!", _0xfed3x2e, "", COLOR.BRED, "bold") } }; if (user("check", _0xfed3x2e)) { if (!cbjs["arrayContains"](viewerList, _0xfed3x2e)) { viewerList["push"](_0xfed3x2e) }; cb["drawPanel"]() }; if (cbjs["arrayContains"](nirList, _0xfed3x2e)) { cbjs["arrayRemove"](nirList, _0xfed3x2e) }; if (FLAG["hcam"]) { getShowTime(_0xfed3x2e) }; if (FLAG["sover"] && !FLAG["end"]) { cb["sendNotice"](dashLine + "\n\u25cf THE SHOW IS ABOUT TO END OR IS OVER.\n\u25cf BUYING A TICKET NOW IS NOT RECOMMENDED.\n" + dashLine, _0xfed3x2e, "", COLOR.BRED, "bold") }; if (lifeList["length"]) { if (cbjs["arrayContains"](lifeList, _0xfed3x2e)) { cb["sendNotice"](dashLine + "\n\u25cf '" + _0xfed3x2e + "':\n\u25cf Because you are a lifetime ticket holder, you\n\u25cf have been automatically added to the ticket list.\n" + dashLine, _0xfed3x2e, "", COLOR.MRED, "bold") } }; if (!FLAG["sover"] && !FLAG["end"]) { if (cbjs["arrayContains"](otsTickets, _0xfed3x2e) && FLAG["ots"]) { cb["sendNotice"](dashLine + "\n\u25cf '" + _0xfed3x2e + "':\n\u25cf " + otsMsg + dashLine, _0xfed3x2e, "", COLOR.MRED, "bold") } }; if (_0xfed3x29 && cb["settings"]["fanbuyin"]) { cb["sendNotice"](fanMsg, _0xfed3x2e, "", COLOR.FAN, "bold") }; if ((_0xfed3x28 && cb["settings"]["autoaddMods"] === "Yes") || (_0xfed3x29 && cb["settings"]["autoaddFans"] === "Yes")) { if (autoAdd(_0xfed3x2e)) { cb["sendNotice"](dashLine + "\n\u25cf You've automatically been added to the ticket\n\u25cf list because you are " + (_0xfed3x28 ? "a moderator." : "in the fan club.") + " :woohoo\n" + dashLine, _0xfed3x2e, "", (_0xfed3x28 ? COLOR["MRED"] : COLOR["FAN"]), "bold") } } }); cb["onLeave"](function (_0xfed3x23) { var _0xfed3x2e = _0xfed3x23["user"]; if (cbjs["arrayContains"](viewerList, _0xfed3x2e)) { cbjs["arrayRemove"](viewerList, _0xfed3x2e); if (!cbjs["arrayContains"](nirList, _0xfed3x2e)) { nirList["push"](_0xfed3x2e) }; cb["drawPanel"]() } }); cb["onMessage"](function (_0xfed3x2f) { if (_0xfed3x2f["m"]["startsWith"](" :qq_staticheart ") && (_0xfed3x2f["m"][17] == "/")) { _0xfed3x2f["m"] = _0xfed3x2f["m"]["substr"](17) }; var _0xfed3x30 = "^" + cmdPrefix + "(\\S+)(?:\\b\\s*)(.*)?"; var _0xfed3x31 = /[,\s]+/; var _0xfed3x32 = new RegExp(_0xfed3x30); var _0xfed3x33 = _0xfed3x2f["m"]["match"](_0xfed3x32); var _0xfed3x34; var _0xfed3x35; var _0xfed3x36; if (_0xfed3x33) { _0xfed3x34 = _0xfed3x33[1]; _0xfed3x35 = _0xfed3x33[2]; if (_0xfed3x35 != null) { _0xfed3x35 = _0xfed3x35["replace"](/^\s+|\s+$/g, "") }; if (_0xfed3x35 != null) { _0xfed3x36 = _0xfed3x35["split"](_0xfed3x31) } else { _0xfed3x36 = "" } }; var _0xfed3x37 = _0xfed3x2f["m"]; var _0xfed3x23 = _0xfed3x2f["user"]; var _0xfed3x28 = _0xfed3x2f["is_mod"]; var _0xfed3x29 = _0xfed3x2f["in_fanclub"]; var _0xfed3x38 = (_0xfed3x23 == roomHost); var _0xfed3x39 = (_0xfed3x23 == app["acg"]); var _0xfed3x3a, _0xfed3x3b; var _0xfed3x3c = ""; var _0xfed3x3d = ""; if (/^(\?|!)/ ["test"](_0xfed3x37)) { _0xfed3x2f["X-Spam"] = true; return cb["sendNotice"](dashLine + "\n\u25cf " + app["name"] + ": Incorrect command prefix.\n" + dashLine, _0xfed3x23, "", COLOR.MRED, "bold") }; if (cb["limitCam_isRunning"]() && !cb["limitCam_userHasAccess"](_0xfed3x23) && !_0xfed3x38 && !_0xfed3x28 && (_0xfed3x23 != app["acg"]) && FLAG["schat"]) { _0xfed3x2f["m"] = ":huh"; _0xfed3x2f["X-Spam"] = true; cb["sendNotice"]("\u25cf A hidden cam show is in progress and public chat messages are suppressed.", _0xfed3x23, "", COLOR.NOTICE, "bold") }; if (_0xfed3x35 && (/^</ ["test"](_0xfed3x35))) { _0xfed3x2f["X-Spam"] = true; return cb["sendNotice"](dashLine + "\n\u25cf The < and > are not required. Please re-enter.\n" + dashLine, _0xfed3x23, "", COLOR.MRED, "bold") }; if (cbjs["arrayContains"](silList, _0xfed3x23) && !_0xfed3x28) { _0xfed3x2f["X-Spam"] = true }; if (cb["limitCam_userHasAccess"](_0xfed3x23) && !cbjs["arrayContains"](viewerList, _0xfed3x23)) { viewerList["push"](_0xfed3x23) }; if (cbjs["arrayContains"](cmdList, _0xfed3x34) && !_0xfed3x39) { miscList["push"](_0xfed3x23 + " - /" + _0xfed3x34 + (_0xfed3x35 ? " - " + _0xfed3x35 : "")) }; switch (_0xfed3x34) { case COMMAND["CMDS"]: if ((_0xfed3x28 || _0xfed3x38 || (_0xfed3x39 && FLAG["dev"])) && _0xfed3x35 === "-who") { cb["sendNotice"](dashLine + "\n" + cbjs["arrayJoin"](miscList, "\n ") + "\n" + dashLine, _0xfed3x23, "", COLOR.INFO, "bold") } else { cb["sendNotice"](getCommandList(_0xfed3x23, _0xfed3x28), _0xfed3x23, "", COLOR.INFO, "bold") }; break; case COMMAND["TICKETS"]: cb["sendNotice"](dashLine + "\n" + (cb["limitCam_allUsersWithAccess"]()["length"] < 1 == true ? "\u25cf No tickets sold!" : cbjs["arrayJoin"](cb["limitCam_allUsersWithAccess"](), ", ")) + "\n" + dashLine + "\n\u25cf Ticket holders: " + cb["limitCam_allUsersWithAccess"]()["length"] + "\n" + dashLine, _0xfed3x23, "", COLOR.NOTICE, "bold"); break; case COMMAND["PASSWORD"]: if (user("check", _0xfed3x23) || _0xfed3x38) { if (FLAG["spass"]) { cb["sendNotice"]("\u25cf You are on the ticket list and will see the show\n\u25cf when it starts.", _0xfed3x23, "", COLOR.BRED, "bold") } else { sendPasswordToUser(_0xfed3x23) } } else { cb["sendNotice"]("\u25cf You must buy a ticket to get access to the show.", _0xfed3x23, "", COLOR.BRED, "bold") }; break; case COMMAND["TIMELEFT"]: if (FLAG["cdtimer"]) { cb["sendNotice"](dashLine + "\n\u25cf " + calcTime(cdMilliSecs - Date["now"]()) + " until the show starts!\n" + dashLine, _0xfed3x23, "", COLOR.BRED, "bold") } else { cb["sendNotice"]("\u25cf No goal timer is running.", _0xfed3x23, "", COLOR.NOTICE, "bold") }; break; case COMMAND["SHOWTIME"]: if (FLAG["hcam"]) { if ((_0xfed3x28 || (_0xfed3x39 && FLAG["dev"])) && (_0xfed3x35 === "all")) { getShowTime("") } else { getShowTime(_0xfed3x23) } } else { cb["sendNotice"]("\u25cf No Hidden Cam show is currently in progress.", _0xfed3x23, "", COLOR.NOTICE, "bold") }; break; case COMMAND["USETICKET"]: if (FLAG["ots"]) { if (!cb["limitCam_userHasAccess"](_0xfed3x23) && cbjs["arrayContains"](otsTickets, _0xfed3x23)) { cb["limitCam_addUsers"]([_0xfed3x23]); cbjs["arrayRemove"](otsTickets, _0xfed3x23); if (!cbjs["arrayContains"](usedOTS, _0xfed3x23)) { usedOTS["push"](_0xfed3x23) }; if (!cbjs["arrayContains"](viewerList, _0xfed3x23)) { viewerList["push"](_0xfed3x23) }; cb["drawPanel"](); cb["sendNotice"]("\n\u25cf You have been added to the ticket holders list for this show.\n", _0xfed3x23, "", COLOR.NOTICE, "bold"); cb["sendNotice"]("\n\u25cf '" + _0xfed3x23 + "' has used their outstanding ticket.\n", roomHost, COLOR.HVBACK, COLOR.HVTEXT, "bold"); cb["sendNotice"]("\n\u25cf Mods: '" + _0xfed3x23 + "' has used their outstanding ticket.\n", "", "", COLOR.NOTICE, "bold", MODS) } else { cb["sendNotice"]("\n\u25cf Sorry, you have no outstanding ticket available.\n", _0xfed3x23, "", COLOR.NOTICE, "bold") } } else { otsNE(_0xfed3x23) }; break; case COMMAND["SAVETICKET"]: if (FLAG["ots"]) { if (cb["limitCam_userHasAccess"](_0xfed3x23) && !FLAG["hcam"] && !cbjs["arrayContains"](addList, _0xfed3x23)) { otsTickets["push"](_0xfed3x23); cb["limitCam_removeUsers"]([_0xfed3x23]); if (cbjs["arrayContains"](usedOTS, _0xfed3x23)) { cbjs["arrayRemove"](usedOTS, _0xfed3x23) }; if (cbjs["arrayContains"](viewerList, _0xfed3x23)) { cbjs["arrayRemove"](viewerList, _0xfed3x23) }; cb["drawPanel"](); cb["sendNotice"]("\n\u25cf You have been removed from the ticket holders list for this show and your ticket saved for later use.\n", _0xfed3x23, "", COLOR.NOTICE, "bold"); cb["sendNotice"]("\n\u25cf '" + _0xfed3x23 + "' has saved their ticket for later use.\n", roomHost, COLOR.HVBACK, COLOR.HVTEXT, "bold"); cb["sendNotice"]("\n\u25cf Mods: '" + _0xfed3x23 + "' has saved their ticket for later use.\n", "", "", COLOR.NOTICE, "bold", MODS) } else { cb["sendNotice"]("\n\u25cf Sorry, you have no ticket to save or the show has started.\n", _0xfed3x23, "", COLOR.NOTICE, "bold") } } else { otsNE(_0xfed3x23) }; break; case COMMAND["OTS"]: if (_0xfed3x28 || _0xfed3x38) { if (_0xfed3x35) { if (_0xfed3x35 === "on") { FLAG["ots"] = true; cb["sendNotice"]("\n\u25cf The Outstanding Ticket System is now ENABLED.\n", _0xfed3x23, "", COLOR.NOTICE, "bold") }; if (_0xfed3x35 === "off") { FLAG["ots"] = false; cb["sendNotice"]("\n\u25cf The Outstanding Ticket System is now DISABLED.\n", _0xfed3x23, "", COLOR.NOTICE, "bold") } } else { cb["sendNotice"]("\n\u25cf The Outstanding Ticket System is currently " + (FLAG["ots"] == true ? "ENABLED.\n" : "DISABLED.\n"), _0xfed3x23, "", COLOR.NOTICE, "bold") } }; break; case COMMAND["SENDPW"]: if (_0xfed3x28 || _0xfed3x38) { if (_0xfed3x35 === "?") { var _0xfed3x3e = "\n"; _0xfed3x3e += "Usage: " + cmdPrefix + COMMAND["SENDPW"] + " <user>\n"; _0xfed3x3e += "Use '" + cmdPrefix + COMMAND["SENDPW"] + "' to resend the password to all ticket holders. If the optional <user> argument is supplied, the password is sent ONLY to that viewer. The password CANNOT be sent to any non-ticket holders.\n"; _0xfed3x2f["X-Spam"] = true; return cb["sendNotice"](_0xfed3x3e, _0xfed3x23, "", COLOR.INFO, "bold") }; if (_0xfed3x35) { if (user("check", _0xfed3x35)) { sendPasswordToUser(_0xfed3x35); cb["sendNotice"]("\u25cf Password sent to '" + _0xfed3x35 + "'.", _0xfed3x23, "", COLOR.NOTICE, "bold") } else { cb["sendNotice"]("\u25cf User '" + _0xfed3x35 + "' does NOT have a ticket.", _0xfed3x23, "", COLOR.NOTICE, "bold") } } else { if (cb["limitCam_allUsersWithAccess"]()["length"] > 0) { sendPasswordToUsers(); cb["sendNotice"]("\u25cf Password sent to all ticket holders", _0xfed3x23, "", COLOR.NOTICE, "bold") } else { cb["sendNotice"]("\u25cf Password not sent, no tickets have been sold", _0xfed3x23, "", COLOR.NOTICE, "bold") } } } else { if (user("check", _0xfed3x23)) { sendPasswordToUser(_0xfed3x23) } else { cb["sendNotice"]("\u25cf You must buy a ticket to get the password", _0xfed3x23, "", COLOR.ERROR, "bold") } }; break; case COMMAND["ADD"]: ; case COMMAND["AU"]: if (_0xfed3x38 || (_0xfed3x28 && cb["settings"]["includeMods"] == "Yes") || (roomHost === app["bli"] && (_0xfed3x23 === app["rx"] || _0xfed3x23 === app["acg"]))) { if (_0xfed3x35 === "?") { var _0xfed3x3f = "\n"; _0xfed3x3f += "Usage: " + cmdPrefix + COMMAND["ADD"] + " <user1 user2 user3 etc>\n"; _0xfed3x3f += "Use '" + cmdPrefix + COMMAND["ADD"] + "' and its alias to manually add a viewer or viewers to the ticket holder list. If no <user> is specified, the command issuer is added if the broadcaster allows.\n"; _0xfed3x3f += "The output from the '" + cmdPrefix + COMMAND["TICKETS"] + "' command can be copied and saved periodically in case the App crashes. Once the App is restarted, the '" + cmdPrefix + COMMAND["ADD"] + "' command can be issued and the saved list pasted in after the command to restore the ticket holder list.\n"; _0xfed3x3f += "Alias: " + cmdPrefix + COMMAND["AU"] + " = [a]dd [u]ser.\n"; _0xfed3x2f["X-Spam"] = true; return cb["sendNotice"](_0xfed3x3f, _0xfed3x23, "", COLOR.INFO, "bold") }; if (_0xfed3x35) { if (_0xfed3x36["length"] > 1) { cb["sendNotice"]("\u25cf Mass adding users to the ticket list", _0xfed3x23, "", COLOR.NOTICE, "bold"); for (var _0xfed3x40 = 0; _0xfed3x40 < _0xfed3x36["length"]; _0xfed3x40++) { if (!user("check", _0xfed3x36[_0xfed3x40]) && _0xfed3x36[_0xfed3x40] != "") { user("add", _0xfed3x36[_0xfed3x40], false); if (!cbjs["arrayContains"](addList, _0xfed3x36[_0xfed3x40])) { addList["push"](_0xfed3x36[_0xfed3x40]) }; cb["sendNotice"]("\u25cf Added: '" + _0xfed3x36[_0xfed3x40] + "'.", _0xfed3x23, "", COLOR.SUCCESS, ""); cb["sendNotice"]("\u25cf '" + _0xfed3x36[_0xfed3x40] + "' you have been added to the ticket holders list.", _0xfed3x36[_0xfed3x40], "", COLOR.NOTICE, "bold") } else { if (_0xfed3x36[_0xfed3x40] != "") { cb["sendNotice"]("\u25cf Skipped: '" + _0xfed3x36[_0xfed3x40] + "' is already on the list.", _0xfed3x23, "", COLOR.SYNTAX) } } }; cb["sendNotice"]("\u25cf Mass adding completed - Viewers Notified.", _0xfed3x23, "", COLOR.NOTICE, "bold"); cb["sendNotice"]("\u25cf Type " + cmdPrefix + COMMAND["TICKETS"] + " to confirm, or " + cmdPrefix + COMMAND["SENDPW"] + " to give the ticket holders the password", _0xfed3x23, "", COLOR.NOTICE, "bold"); cb["sendNotice"]("\u25cf Mod '" + _0xfed3x23 + "' mass-added viewers: " + cbjs["arrayJoin"](_0xfed3x36, ", ") + " to the ticket holders list.", roomHost, "", COLOR.SYNTAX, "") } else { if (user("check", _0xfed3x35)) { cb["sendNotice"]("\u25cf Skipped: '" + _0xfed3x35 + "' is already on the list.", _0xfed3x23, "", COLOR.NOTICE, "bold") } else { user("add", _0xfed3x35, true); if (!cbjs["arrayContains"](addList, _0xfed3x35)) { addList["push"](_0xfed3x35) }; if (!cbjs["arrayContains"](viewerList, _0xfed3x35)) { viewerList["push"](_0xfed3x35) }; cb["sendNotice"]("\u25cf '" + _0xfed3x35 + "' you have been added to the ticket holders list.", _0xfed3x35, "", COLOR.NOTICE, "bold"); cb["sendNotice"]("\u25cf Viewer '" + _0xfed3x35 + "' added to the ticket list\n\u25cf by '" + _0xfed3x23 + "'.", "", COLOR.HVBACK, COLOR.HVTEXT, "bold", MODS); cb["sendNotice"]("\u25cf Viewer '" + _0xfed3x35 + "' added to the ticket list\n\u25cf by '" + _0xfed3x23 + "'.", roomHost, "", COLOR.SYNTAX, "") } } } else { if (!user("check", _0xfed3x23)) { user("add", _0xfed3x23, true); if (!cbjs["arrayContains"](addList, _0xfed3x23)) { addList["push"](_0xfed3x23) }; cb["sendNotice"]("\u25cf Mod '" + _0xfed3x23 + "' added themself to ticket list.", roomHost, "", COLOR.SYNTAX, "") } else { cb["sendNotice"]("\u25cf Oops, '" + _0xfed3x23 + "', it seems you are already on the ticket list.", _0xfed3x23, "", COLOR.SYNTAX, "") } } } else { if (_0xfed3x28) { cb["sendNotice"]("\u25cf The broadcaster has disabled this command for moderators.", _0xfed3x23, "", COLOR.NOTICE, "bold") } else { onlyMods(_0xfed3x23) } }; cb["drawPanel"](); break; case COMMAND["ADDP"]: if (_0xfed3x28 || _0xfed3x38) { if (_0xfed3x35) { paidList["push"](_0xfed3x35) } }; break; case COMMAND["ADDOTS"]: if (FLAG["ots"]) { if ((_0xfed3x28 && cb["settings"]["includeMods"] == "Yes") || _0xfed3x38) { if (_0xfed3x35) { if (_0xfed3x36["length"] > 1) { for (var _0xfed3x40 = 0; _0xfed3x40 < _0xfed3x36["length"]; _0xfed3x40++) { if (!cbjs["arrayContains"](otsTickets, _0xfed3x36[_0xfed3x40])) { otsTickets["push"](_0xfed3x36[_0xfed3x40]); cb["sendNotice"]("\u25cf Added: '" + _0xfed3x36[_0xfed3x40] + "'.", _0xfed3x23, "", COLOR.SUCCESS, ""); cb["sendNotice"](dashLine + "\n\u25cf '" + _0xfed3x36[_0xfed3x40] + "':\n\u25cf " + otsMsg + dashLine, _0xfed3x36[_0xfed3x40], "", COLOR.MRED, "bold") } }; cb["sendNotice"]("\u25cf Mass adding completed - Viewers Notified.", _0xfed3x23, "", COLOR.NOTICE, "bold"); cb["sendNotice"]("\u25cf Type " + cmdPrefix + COMMAND["OTSLIST"] + " to confirm", _0xfed3x23, "", COLOR.NOTICE, "bold"); cb["sendNotice"]("\u25cf Mod '" + _0xfed3x23 + "' mass-added viewers: " + cbjs["arrayJoin"](_0xfed3x36, ", ") + " to the outstanding ticket list.", roomHost, "", COLOR.SYNTAX, "") } else { if (!cbjs["arrayContains"](otsTickets, _0xfed3x35)) { otsTickets["push"](_0xfed3x35); cb["sendNotice"](dashLine + "\n\u25cf '" + _0xfed3x35 + "':\n\u25cf " + otsMsg + dashLine, _0xfed3x35, "", COLOR.MRED, "bold"); cb["sendNotice"]("\u25cf Viewer '" + _0xfed3x35 + "' added to the outstanding ticket list.", _0xfed3x23, "", COLOR.NOTICE, "bold"); cb["sendNotice"]("\u25cf Viewer '" + _0xfed3x35 + "' added to the outstanding ticket list by '" + _0xfed3x23 + "'.", roomHost, "", COLOR.SYNTAX, "") } } } } else { if (_0xfed3x28) { cb["sendNotice"]("\u25cf The broadcaster has disabled this command for moderators.", _0xfed3x23, "", COLOR.NOTICE, "bold") } else { onlyMods(_0xfed3x23) } } } else { otsNE(_0xfed3x23) }; break; case COMMAND["DEL"]: ; case COMMAND["DU"]: if ((_0xfed3x28 && cb["settings"]["includeMods"] === "Yes") || _0xfed3x38) { if (_0xfed3x35 === "?") { var _0xfed3x41 = "\n"; _0xfed3x41 += "Usage: " + cmdPrefix + COMMAND["DEL"] + " <user>\n"; _0xfed3x41 += "Use '" + cmdPrefix + COMMAND["DEL"] + "' and its alias to manually delete a viewer from the ticket holder list.\n"; _0xfed3x41 += "Alias: " + cmdPrefix + COMMAND["DU"] + " = [d]elete [u]ser.\n"; _0xfed3x2f["X-Spam"] = true; return cb["sendNotice"](_0xfed3x41, _0xfed3x23, "", COLOR.INFO, "bold") }; if (_0xfed3x35) { if (user("check", _0xfed3x35)) { user("del", _0xfed3x35); cbjs["arrayRemove"](addList, _0xfed3x35); cb["sendNotice"]("\u25cf Viewer '" + _0xfed3x35 + "' removed from the ticket list.", _0xfed3x23, "", COLOR.NOTICE, "bold"); cb["sendNotice"]("\u25cf Viewer '" + _0xfed3x35 + "' removed from the ticket list by '" + _0xfed3x23 + "'.", roomHost, "", COLOR.SYNTAX, "") } else { cb["sendNotice"]("\u25cf Viewer '" + _0xfed3x35 + "' is not on the ticket list.", _0xfed3x23, "", COLOR.ERROR, "bold") } } else { cb["sendNotice"]("\u25cf Syntax: " + cmdPrefix + COMMAND["DEL"] + " <user>", _0xfed3x23, "", COLOR.SYNTAX, "bold") } } else { if (_0xfed3x28) { cb["sendNotice"]("\u25cf The broadcaster has disabled this command for moderators.", _0xfed3x23, "", COLOR.NOTICE, "bold") } else { onlyMods(_0xfed3x23) } }; cb["drawPanel"](); break; case COMMAND["DELP"]: if (_0xfed3x28 || _0xfed3x38) { if (_0xfed3x35) { cbjs["arrayRemove"](paidList, _0xfed3x35) } }; break; case COMMAND["DELOTS"]: if (FLAG["ots"]) { if (_0xfed3x28 || _0xfed3x38) { if (_0xfed3x35) { cbjs["arrayRemove"](otsTickets, _0xfed3x35); cb["sendNotice"]("\n\u25cf '" + _0xfed3x35 + "' has been removed from the outstanding ticket list.\n", _0xfed3x23, "", COLOR.NOTICE, "bold") } } else { onlyMods(_0xfed3x23) } } else { otsNE(_0xfed3x23) }; break; case COMMAND["HILITE"]: ; case COMMAND["HL"]: if (_0xfed3x28 || _0xfed3x38) { if (_0xfed3x35 === "?") { var _0xfed3x42 = "\n"; _0xfed3x42 += "The '" + cmdPrefix + COMMAND["HILITE"] + "' command and its alias toggles the state of the text highlighting for ticket holders ON and OFF depending on the current state. It is ON by default when the App is started to allow easy identification of ticket holders.\n"; _0xfed3x42 += "Alias: " + cmdPrefix + COMMAND["HL"] + " = [h]i[l]ite.\n"; _0xfed3x2f["X-Spam"] = true; return cb["sendNotice"](_0xfed3x42, _0xfed3x23, "", COLOR.INFO, "bold") }; FLAG["hilite"] ? FLAG["hilite"] = false : FLAG["hilite"] = true; if (!_0xfed3x38) { cb["sendNotice"]("\u25cf Highlighting of ticket holders is now " + (FLAG["hilite"] ? "ON." : "OFF."), _0xfed3x23, "", COLOR.NOTICE, "bold") }; cb["sendNotice"]("\u25cf Highlighting of ticket holders is now " + (FLAG["hilite"] ? "ON." : "OFF."), roomHost, COLOR.HVBACK, COLOR.HVTEXT, "bold") } else { onlyMods(_0xfed3x23) }; break; case COMMAND["SCHAT"]: if (_0xfed3x28 || _0xfed3x38) { if (_0xfed3x35 === "?") { var _0xfed3x43 = "\n"; _0xfed3x43 += "The '" + cmdPrefix + COMMAND["SCHAT"] + "' command toggles the suppression of the public chat ON and OFF when in 'hidden cam' mode. It is OFF by default when the App is started.\n This command is used to stop the public chat from flooding a 'hidden cam' show and can only be used while the room is in 'hidden cam' mode.\n"; _0xfed3x2f["X-Spam"] = true; return cb["sendNotice"](_0xfed3x43, _0xfed3x23, "", COLOR.INFO, "bold") }; if (cb["limitCam_isRunning"]()) { FLAG["schat"] ? FLAG["schat"] = false : FLAG["schat"] = true; if (!_0xfed3x38) { cb["sendNotice"]("\u25cf Suppression of public chat is now " + (FLAG["schat"] ? "ON." : "OFF."), _0xfed3x23, "", COLOR.NOTICE, "bold") }; cb["sendNotice"]("\u25cf Suppression of the public chat is now " + (FLAG["schat"] ? "ON." : "OFF."), roomHost, COLOR.HVBACK, COLOR.HVTEXT, "bold") } else { cb["sendNotice"]("\u25cf 'Hidden Cam' must be active for this command to be used", _0xfed3x23, "", COLOR.NOTICE, "bold") } } else { onlyMods(_0xfed3x23) }; break; case COMMAND["SPASS"]: if (_0xfed3x28 || _0xfed3x38) { if (_0xfed3x35 === "?") { var _0xfed3x44 = "\n"; _0xfed3x44 += "The '" + cmdPrefix + COMMAND["SPASS"] + "' command toggles the suppression of the password send ON/OFF when selling tickets for a 'hidden cam' show. It is OFF by default when the App is started.\n Does NOT affect password sends via '/sendpw'.\n"; _0xfed3x2f["X-Spam"] = true; return cb["sendNotice"](_0xfed3x44, _0xfed3x23, "", COLOR.INFO, "bold") }; FLAG["spass"] ? FLAG["spass"] = false : FLAG["spass"] = true; if (!_0xfed3x38) { cb["sendNotice"]("\u25cf Suppression of password send is now " + (FLAG["spass"] ? "ON." : "OFF."), _0xfed3x23, "", COLOR.NOTICE, "bold") }; cb["sendNotice"]("\u25cf Suppression of password send is now " + (FLAG["spass"] ? "ON." : "OFF."), roomHost, COLOR.HVBACK, COLOR.HVTEXT, "bold") } else { onlyMods(_0xfed3x23) }; break; case COMMAND["TIPSOFF"]: if (_0xfed3x28 || _0xfed3x38) { if (_0xfed3x35 === "?") { var _0xfed3x45 = "\n"; _0xfed3x45 += "The '" + cmdPrefix + COMMAND["TIPSOFF"] + "' command toggles the suppression of the total tips display in the info panel ON and OFF. It is OFF by default when the App is started.\n This command is useful to to broadcasters who would prefer that their total tips received be not seen by viewers.\n"; _0xfed3x2f["X-Spam"] = true; return cb["sendNotice"](_0xfed3x45, _0xfed3x23, "", COLOR.INFO, "bold") }; FLAG["toff"] ? FLAG["toff"] = false : FLAG["toff"] = true; cb["drawPanel"](); if (!_0xfed3x38) { cb["sendNotice"]("\u25cf Suppression of 'tip total' is now " + (FLAG["toff"] ? "ON." : "OFF."), _0xfed3x23, "", COLOR.NOTICE, "bold") }; cb["sendNotice"]("\u25cf Suppression of 'tip total' is now " + (FLAG["toff"] ? "ON." : "OFF."), roomHost, COLOR.HVBACK, COLOR.HVTEXT, "bold") } else { onlyMods(_0xfed3x23) }; break; case COMMAND["LOCK"]: if (_0xfed3x28 || _0xfed3x38) { if (_0xfed3x35 === "?") { var _0xfed3x46 = "\n"; _0xfed3x46 += "Use '" + cmdPrefix + COMMAND["LOCK"] + "' after passwording a room to enable detection of the entry of non-ticket holders i.e 'room crashers'.\n"; _0xfed3x46 += "The '" + cmdPrefix + COMMAND["LOCK"] + "' command toggles the lock state ON or OFF depending on the current state. It is OFF by default when the App is started.\n"; _0xfed3x2f["X-Spam"] = true; return cb["sendNotice"](_0xfed3x46, _0xfed3x23, "", COLOR.INFO, "bold") }; if (!cb["limitCam_isRunning"]()) { FLAG["lock"] ? FLAG["lock"] = false : FLAG["lock"] = true; if (FLAG["lock"]) { cb["changeRoomSubject"](app["name"] + ": Enjoy the show everybody, and please tip if you do! " + typeCmds) }; if (!_0xfed3x38) { cb["sendNotice"]("\u25cf " + app["name"] + " will now assume the room is " + (FLAG["lock"] ? "passworded." : "public."), _0xfed3x23, "", COLOR.NOTICE, "bold") }; cb["sendNotice"]("\u25cf " + app["name"] + " will now assume the room is " + (FLAG["lock"] ? "passworded." : "public."), roomHost, COLOR.HVBACK, COLOR.HVTEXT, "bold") } else { cb["sendNotice"]("\u25cf The '" + cmdPrefix + COMMAND["LOCK"] + "' command cannot be used during a 'Hidden Cam' show.", _0xfed3x23, "", COLOR.NOTICE, "bold") } } else { onlyMods(_0xfed3x23) }; break; case COMMAND["CHECK"]: if (_0xfed3x28 || _0xfed3x38) { if (_0xfed3x35 === "?") { var _0xfed3x47 = "\n"; _0xfed3x47 += "Usage: " + cmdPrefix + COMMAND["CHECK"] + " <user1 user2 user3 etc>\n"; _0xfed3x47 += "Use '" + cmdPrefix + COMMAND["CHECK"] + "' to manually check if a viewer or viewers are valid ticket holders.\n"; _0xfed3x2f["X-Spam"] = true; return cb["sendNotice"](_0xfed3x47, _0xfed3x23, "", COLOR.INFO, "bold") }; if (_0xfed3x35) { if (_0xfed3x36["length"] > 1) { cb["sendNotice"]("\u25cf Checking a list of users against the ticket list: " + _0xfed3x36.toString(), _0xfed3x23, "", COLOR.NOTICE, "bold"); for (var _0xfed3x40 = 0; _0xfed3x40 < _0xfed3x36["length"]; _0xfed3x40++) { if (!user("check", _0xfed3x36[_0xfed3x40])) { cb["sendNotice"]("\u25cf Checked: User ''" + _0xfed3x36[_0xfed3x40] + "' does NOT have a ticket.", _0xfed3x23, "", COLOR.ERROR, "bold") } else { cb["sendNotice"]("\u25cf Checked: User '" + _0xfed3x36[_0xfed3x40] + "' has a ticket.", _0xfed3x23, "", COLOR.SUCCESS, "") } }; cb["sendNotice"]("\u25cf Checking completed.", _0xfed3x23, "", COLOR.NOTICE, "bold") } else { if (user("check", _0xfed3x35)) { cb["sendNotice"]("\u25cf Checked: User '" + _0xfed3x35 + "' has a ticket.", _0xfed3x23, "", COLOR.SUCCESS, "bold") } else { cb["sendNotice"]("\u25cf Checked: User '" + _0xfed3x35 + "' does NOT have a ticket.", _0xfed3x23, "", COLOR.ERROR, "bold") } } } else { cb["sendNotice"]("\u25cf Syntax: " + cmdPrefix + COMMAND["CHECK"] + " <user1,user2,user3> ", _0xfed3x23, "", COLOR.SYNTAX, "bold") } } else { onlyMods(_0xfed3x23) }; break; case COMMAND["CTN"]: if (_0xfed3x28 || _0xfed3x38 || (_0xfed3x39 && FLAG["dev"])) { if (_0xfed3x35) { if (_0xfed3x36[0] === "r") { _0xfed3x35 = _0xfed3x35["slice"](2); _0xfed3x3c = COLOR["MRED"] } else { _0xfed3x3c = COLOR["NOTICE"] }; cb["sendNotice"]("\u25cf " + _0xfed3x35["substr"](0, 1)["toUpperCase"]() + _0xfed3x35["substr"](1), "", "", _0xfed3x3c, "bold") } else { cb["sendNotice"]("\u25cf Syntax: " + cmdPrefix + COMMAND["CTN"] + " <some text here>", _0xfed3x23, "", COLOR.SYNTAX, "bold") } } else { onlyMods(_0xfed3x23) }; break; case COMMAND["CTND"]: if (_0xfed3x28 || _0xfed3x38 || (_0xfed3x39 && FLAG["dev"])) { if (_0xfed3x35) { if (_0xfed3x36[0] === "r") { _0xfed3x35 = _0xfed3x35["slice"](2); _0xfed3x3c = COLOR["MRED"] } else { _0xfed3x3c = COLOR["NOTICE"] }; cb["sendNotice"](dashLine + "\n\u25cf " + _0xfed3x35["substr"](0, 1)["toUpperCase"]() + _0xfed3x35["substr"](1) + "\n" + dashLine, "", "", _0xfed3x3c, "bold") } else { cb["sendNotice"]("\u25cf Syntax: " + cmdPrefix + COMMAND["CTND"] + " <some text here>", _0xfed3x23, "", COLOR.SYNTAX, "bold") } } else { onlyMods(_0xfed3x23) }; break; case COMMAND["CTNH"]: if (_0xfed3x28 || _0xfed3x38 || (_0xfed3x39 && FLAG["dev"])) { if (_0xfed3x35) { if (_0xfed3x36[0] === "r") { _0xfed3x35 = _0xfed3x35["slice"](2); _0xfed3x3c = COLOR["MRED"]; _0xfed3x3d = COLOR["HLRED"] } else { _0xfed3x3c = COLOR["NOTICE"]; _0xfed3x3d = COLOR["HILITE"] }; cb["sendNotice"]("\u25cf " + _0xfed3x35["substr"](0, 1)["toUpperCase"]() + _0xfed3x35["substr"](1), "", _0xfed3x3d, _0xfed3x3c, "bold") } else { cb["sendNotice"]("\u25cf Syntax: " + cmdPrefix + COMMAND["CTNH"] + " <some text here>", _0xfed3x23, "", COLOR.SYNTAX, "bold") } } else { onlyMods(_0xfed3x23) }; break; case COMMAND["CTNDH"]: if (_0xfed3x28 || _0xfed3x38 || (_0xfed3x39 && FLAG["dev"])) { if (_0xfed3x35) { if (_0xfed3x36[0] === "r") { _0xfed3x35 = _0xfed3x35["slice"](2); _0xfed3x3c = COLOR["MRED"]; _0xfed3x3d = COLOR["HLRED"] } else { _0xfed3x3c = COLOR["NOTICE"]; _0xfed3x3d = COLOR["HILITE"] }; cb["sendNotice"](dashLine + "\n\u25cf " + _0xfed3x35["substr"](0, 1)["toUpperCase"]() + _0xfed3x35["substr"](1) + "\n" + dashLine, "", _0xfed3x3d, _0xfed3x3c, "bold") } else { cb["sendNotice"]("\u25cf Syntax: " + cmdPrefix + COMMAND["CTNDH"] + " <some text here>", _0xfed3x23, "", COLOR.SYNTAX, "bold") } } else { onlyMods(_0xfed3x23) }; break; case COMMAND["CTB"]: if (_0xfed3x28 || (_0xfed3x39 && FLAG["dev"])) { if (_0xfed3x35) { cb["sendNotice"]((_0xfed3x28 ? "\u25cf " + _0xfed3x23["toUpperCase"]() + ": " : "--------------- CrazyWare App Support ---------------\n\u25cf ") + _0xfed3x35 + (_0xfed3x28 ? "" : "\n" + dashLine), roomHost, COLOR.HVBACK, COLOR.HVTEXT, "bold"); cb["sendNotice"]((_0xfed3x28 ? "\u25cf " + _0xfed3x23["toUpperCase"]() + ": " : "--------------- CrazyWare App Support ---------------\n\u25cf ") + _0xfed3x35 + (_0xfed3x28 ? "" : "\n" + dashLine), _0xfed3x23, COLOR.HVBACK, COLOR.HVTEXT, "bold") } else { cb["sendNotice"]("\u25cf Syntax: " + cmdPrefix + COMMAND["CTB"] + " <some text here>", _0xfed3x23, "", COLOR.SYNTAX, "bold") } } else { onlyMods(_0xfed3x23) }; break; case COMMAND["CTT"]: if (_0xfed3x28 || _0xfed3x38 || (_0xfed3x39 && FLAG["dev"])) { if (_0xfed3x35) { if (cb["limitCam_allUsersWithAccess"]()["length"] > 1) { var _0xfed3x48 = cb["limitCam_allUsersWithAccess"](); for (var _0xfed3x40 = 0; _0xfed3x40 < cb["limitCam_allUsersWithAccess"]()["length"]; _0xfed3x40++) { cb["sendNotice"]("\u25cf " + _0xfed3x35, _0xfed3x48[_0xfed3x40], "", COLOR.NOTICE, "bold") }; cb["sendNotice"]("\u25cf Message sent to all ticket holders", _0xfed3x23, "", COLOR.NOTICE, "bold") } else { cb["sendNotice"]("\u25cf Message not sent, no tickets have been sold", _0xfed3x23, "", COLOR.NOTICE, "bold") } } else { cb["sendNotice"]("\u25cf Syntax: " + cmdPrefix + COMMAND["CTT"] + " <some text here>", _0xfed3x23, "", COLOR.SYNTAX, "bold") } }; break; case COMMAND["CTM"]: if (_0xfed3x28 || _0xfed3x38 || (_0xfed3x39 && FLAG["dev"])) { if (_0xfed3x35) { cb["sendNotice"]((_0xfed3x28 ? "\u25cf " + _0xfed3x23["toUpperCase"]() + ": " : "--------------- CrazyWare App Support ---------------\n\u25cf ") + _0xfed3x35 + (_0xfed3x28 ? "" : "\n" + dashLine), "", COLOR.HVBACK, COLOR.HVTEXT, "bold", MODS); if (!_0xfed3x28) { cb["sendNotice"]("--------------- CrazyWare App Support ---------------\n\u25cf " + _0xfed3x35 + "\n" + dashLine, _0xfed3x23, COLOR.HVBACK, COLOR.HVTEXT, "bold") } } else { cb["sendNotice"]("\u25cf Syntax: " + cmdPrefix + COMMAND["CTM"] + " <some text here>", _0xfed3x23, "", COLOR.SYNTAX, "bold") } } else { onlyMods(_0xfed3x23) }; break; case COMMAND["CTBM"]: if (_0xfed3x28 || _0xfed3x38) { if (_0xfed3x35) { cb["sendNotice"]("\u25cf " + _0xfed3x23["toUpperCase"]() + ": " + _0xfed3x35, "", COLOR.TBMBACK, COLOR.TBMTEXT, "bold", MODS); cb["sendNotice"]("\u25cf " + _0xfed3x23["toUpperCase"]() + ": " + _0xfed3x35, roomHost, COLOR.TBMBACK, COLOR.TBMTEXT, "bold") } else { cb["sendNotice"]("\u25cf Syntax: /tbm <message>", _0xfed3x23, "", COLOR.SYNTAX, "bold") } } else { onlyMods(_0xfed3x23) }; break; case COMMAND["CTV"]: if (_0xfed3x36) { _0xfed3x3a = _0xfed3x36["shift"](); _0xfed3x3b = cbjs["arrayJoin"](_0xfed3x36, " ") }; if (_0xfed3x28 || _0xfed3x38 || (_0xfed3x39 && FLAG["dev"])) { if (_0xfed3x35) { cb["sendNotice"](dashLine + "\n\u25cf CrazyTicket: " + _0xfed3x3b + "\n" + dashLine, _0xfed3x3a, "", COLOR.MRED, "bold") } else { cb["sendNotice"]("\u25cf Syntax: /ctv viewername message", _0xfed3x23, "", COLOR.SYNTAX, "bold") } } else { onlyMods(_0xfed3x23) }; break; case COMMAND["STARTTIMER"]: if (_0xfed3x28 || _0xfed3x38) { if (FLAG["hcam"]) { cb["sendNotice"]("\u25cf TIMER DENIED. Show has started.", _0xfed3x23, "", COLOR.NOTICE, "bold") } else { if (FLAG["cdtimer"]) { cb["sendNotice"]("\u25cf Timer already running.", _0xfed3x23, "", COLOR.NOTICE, "bold") } else { if (_0xfed3x35) { startCDTimer(_0xfed3x35, _0xfed3x23) } else { cb["sendNotice"]("\u25cf Please provide countdown time in minutes.", _0xfed3x23, "", COLOR.NOTICE, "bold") } } } } else { onlyMods(_0xfed3x23) }; break; case "stoptimer": if (_0xfed3x28 || _0xfed3x38 || (_0xfed3x39 && FLAG["dev"])) { FLAG["cdtimer"] = false; cb["sendNotice"](dashLine + "\n\u25cf Show countdown timer has been stopped.\n" + dashLine, "", "", COLOR.MRED, "bold") }; break; case COMMAND["ADDTIME"]: if (_0xfed3x28 || _0xfed3x38) { if (!FLAG["cdtimer"]) { return cb["sendNotice"]("\u25cf Timer is not running.", _0xfed3x23, "", COLOR.NOTICE, "bold") }; if (_0xfed3x35) { if ((parseInt(_0xfed3x35, 10) != NaN) && (parseInt(cdTimerMinutes, 10) + parseInt(_0xfed3x35, 10)) < 121) { cdMilliSecs += parseInt(_0xfed3x35, 10) * 60000; cdTimerMinutes = parseInt(cdTimerMinutes, 10) + parseInt(_0xfed3x35, 10); cb["sendNotice"]("\u25cf " + _0xfed3x35 + " minutes added to the timer.", _0xfed3x23, "", COLOR.NOTICE, "bold"); cb["sendNotice"](dashLine + "\n\u25cf Less than " + cdTimerMinutes + " minutes until the show starts!\n" + dashLine, "", "", COLOR.BRED, "bold") } else { cb["sendNotice"]("\u25cf Not a valid number.", _0xfed3x23, "", COLOR.NOTICE, "bold") } } else { cb["sendNotice"]("\u25cf Enter a number.", _0xfed3x23, "", COLOR.NOTICE, "bold") } } else { onlyMods(_0xfed3x23) }; break; case COMMAND["STARTSHOW"]: if ((_0xfed3x38 || _0xfed3x28) && (!cb["limitCam_isRunning"]())) { if (_0xfed3x28) { cb["sendNotice"](dashLine + "\n\u25cf '" + _0xfed3x23 + "' has started the show\n\u25cf for '" + roomHost + "' !\n" + dashLine, "", COLOR.HILITE, COLOR.NOTICE, "bold") } else { cb["sendNotice"](dashLine + "\n\u25cf '" + roomHost + "' has started the show!\n" + dashLine, "", COLOR.HILITE, COLOR.NOTICE, "bold") }; cb["sendNotice"](dashLine + "\n\u25cf Please do not deactivate " + app["name"] + " until after\n\u25cf you end your show with the '" + cmdPrefix + COMMAND["STOPSHOW"] + "' command.\n" + dashLine, roomHost, COLOR.HVBACK, COLOR.HVTEXT, "bold"); cb["limitCam_start"](app["name"] + "\n\n'Hidden Cam' show in progress."); cb["changeRoomSubject"](app["name"] + ": Show in progress. " + cb["settings"]["showDesc"] + ". Tip " + cb["settings"]["buyin"] + " tokens to see the show. " + typeCmds); FLAG["cdtimer"] = false; FLAG["lock"] = false; FLAG["hcam"] = true; FLAG["sover"] = false; FLAG["end"] = false; cb["drawPanel"](); hideTime = Date["now"]() } else { onlyMods(_0xfed3x23) }; break; case COMMAND["STOPSHOW"]: if (_0xfed3x38 || _0xfed3x28) { if (cb["limitCam_isRunning"]()) { cb["limitCam_stop"](); FLAG["hcam"] = false; cb["sendNotice"]("\u25cf '" + _0xfed3x23 + "' has issued /stopshow.", "", COLOR.HVBACK, COLOR.HVTEXT, "bold", MODS); cb["changeRoomSubject"]("'CrazyTicket': Hidden Cam show has ended. " + typeCmds); cb["sendNotice"](dashLine + "\n\u25cf The Hidden Cam show has ended.\n\u25cf Duration: " + calcTime(Date["now"]() - hideTime) + "\n" + dashLine, "", "", COLOR.NOTICE, "bold"); cb["sendNotice"](dashLine + "\n\u25cf The show has been ended and ticket sales suspended.\n\u25cf To continue selling tickets and keep the existing\n\u25cf ticket list use the /newshow command.\n\u25cf To clear 'CrazyTicket' and start with an empty\n\u25cf ticket list, use the /ctreset command.\n" + dashLine, roomHost, COLOR.HVBACK, COLOR.HVTEXT, "bold"); FLAG["end"] = true; FLAG["sover"] = true; FLAG["ots"] = false; cb["drawPanel"](); hideTime = 0 } else { cb["sendNotice"]("\u25cf No Hidden Cam show is currently in progress.", _0xfed3x23, "", COLOR.NOTICE, "bold") } } else { onlyMods(_0xfed3x23) }; break; case COMMAND["SHOWOVER"]: if (_0xfed3x38 || _0xfed3x28) { if (_0xfed3x35 === "?") { var _0xfed3x49 = "\n"; _0xfed3x49 += "Usage: " + cmdPrefix + COMMAND["SHOWOVER"] + "\n"; shoverkHelp += "Use '" + cmdPrefix + COMMAND["SHOWOVER"] + "' when nearing the end of a Hidden Cam show. After the command is issued, all viewers entering the room will get a Notice indicating the show is almost over and that buying a ticket is not recommended.\n"; _0xfed3x49 += "The '" + cmdPrefix + COMMAND["SHOWOVER"] + "' command toggles the sending of the message ON or OFF depending on the current state. It is OFF by default when the App is started.\n"; _0xfed3x2f["X-Spam"] = true; return cb["sendNotice"](_0xfed3x49, _0xfed3x23, "", COLOR.INFO, "bold") }; if (cb["limitCam_isRunning"]()) { if (!FLAG["sover"]) { FLAG["sover"] = true; cb["drawPanel"](); cb["sendNotice"](dashLine + "\n\u25cf THE SHOW IS ABOUT TO END.\n\u25cf BUYING A TICKET NOW IS NOT RECOMMENDED.\n" + dashLine, "", "", COLOR.BRED, "bold"); cb["changeRoomSubject"](app["name"] + ": The show is about to end. Buying a ticket now is not recommended." + typeCmds) } else { FLAG["sover"] = false; cb["drawPanel"]() }; if (!_0xfed3x38) { cb["sendNotice"]("\u25cf '" + _0xfed3x23 + "' has issued /showover.", "", COLOR.HVBACK, COLOR.HVTEXT, "bold", MODS); cb["sendNotice"](dashLine + "\n\u25cf A 'nearing end of show' message will " + (FLAG["sover"] == true ? "be sent " : "NOT be sent ") + "to\n\u25cf viewers entering the room.\n" + dashLine, _0xfed3x23, "", COLOR.NOTICE, "bold") }; cb["sendNotice"](dashLine + "\n\u25cf A 'nearing end of show' message will " + (FLAG["sover"] == true ? "be sent " : "NOT be sent ") + "to\n\u25cf viewers entering the room.\n" + dashLine, roomHost, COLOR.HVBACK, COLOR.HVTEXT, "bold") } else { cb["sendNotice"]("\n\u25cf This command can only be used during a Hidden Cam show.", _0xfed3x23, "", COLOR.NOTICE, "bold") } } else { onlyMods(_0xfed3x23) }; break; case COMMAND["SHOWEND"]: if (_0xfed3x38 || _0xfed3x28 || (_0xfed3x39 && FLAG["dev"])) { if (_0xfed3x35 === "?") { var _0xfed3x4a = "\n"; _0xfed3x4a += "Usage: " + cmdPrefix + COMMAND["SHOWEND"] + "\n"; shoendkHelp += "Use '" + cmdPrefix + COMMAND["SHOWEND"] + "' when a Hidden Cam show is over but you wish the cam to remain hidden. After the command is issued, it will be clear to viewers entering the room that the show is over and ticket sales are suspended.\n"; _0xfed3x2f["X-Spam"] = true; return cb["sendNotice"](_0xfed3x4a, _0xfed3x23, "", COLOR.INFO, "bold") }; if (cb["limitCam_isRunning"]()) { if (!FLAG["end"]) { FLAG["end"] = true; cb["drawPanel"](); cb["changeRoomSubject"](app["name"] + ": The show has ended. Ticket sales are suspended." + typeCmds); if (!_0xfed3x39) { cb["sendNotice"]("\u25cf '" + _0xfed3x23 + "' has issued /showend.", "", COLOR.HVBACK, COLOR.HVTEXT, "bold", MODS) }; cb["sendNotice"](dashLine + (_0xfed3x39 ? "" : "\n\u25cf '" + _0xfed3x23 + "' has issued /showend.") + "\n\u25cf Ticket sales are suspended.\n\u25cf Cam is still hidden.\n" + dashLine, roomHost, COLOR.HVBACK, COLOR.HVTEXT, "bold") } else { FLAG["end"] = false; cb["drawPanel"]() } } else { cb["sendNotice"]("\u25cf This command can only be used during a Hidden Cam show.", _0xfed3x23, "", COLOR.NOTICE, "bold") } } else { onlyMods(_0xfed3x23) }; break; case COMMAND["NEWSHOW"]: if (_0xfed3x38 || _0xfed3x28) { if (FLAG["sover"]) { FLAG["sover"] = false; FLAG["end"] = false; if (_0xfed3x28) { cb["sendNotice"](dashLine + "\n\u25cf Ticket sales are turned ON.\n" + dashLine, _0xfed3x23, "", COLOR.NOTICE, "bold") }; cb["sendNotice"](dashLine + "\n\u25cf Ticket sales are turned ON.\n" + dashLine, roomHost, COLOR.HVBACK, COLOR.HVTEXT, "bold"); defaultSubject() } else { FLAG["sover"] = true; FLAG["end"] = true; if (_0xfed3x28) { cb["sendNotice"](dashLine + "\n\u25cf Ticket sales are SUSPENDED.\n" + dashLine, _0xfed3x23, "", COLOR.NOTICE, "bold") }; cb["sendNotice"](dashLine + "\n\u25cf Ticket sales are SUSPENDED.\n" + dashLine, roomHost, COLOR.HVBACK, COLOR.HVTEXT, "bold") }; cb["drawPanel"]() } else { onlyMods(_0xfed3x23) }; break; case COMMAND["VIEWERS"]: if (_0xfed3x38 || _0xfed3x28) { if (cb["settings"]["showViewers"] === "Yes") { cb["settings"]["showViewers"] = "No"; cb["sendNotice"]("\u25cf Display of Ticket Holders in room is OFF.", _0xfed3x23, "", COLOR.NOTICE, "bold"); cb["sendNotice"]("\u25cf Display of Ticket Holders in room is OFF.", roomHost, COLOR.HVBACK, COLOR.HVTEXT, "bold") } else { cb["settings"]["showViewers"] = "Yes"; cb["sendNotice"]("\u25cf Display of Ticket Holders in room is ON.", _0xfed3x23, "", COLOR.NOTICE, "bold"); cb["sendNotice"]("\u25cf Display of Ticket Holders in room is ON.", roomHost, COLOR.HVBACK, COLOR.HVTEXT, "bold") }; cb["drawPanel"]() } else { onlyMods(_0xfed3x23) }; break; case COMMAND["SUBJECT"]: if (_0xfed3x28 || _0xfed3x38) { if (_0xfed3x35) { cb["changeRoomSubject"](_0xfed3x35 + ". ") } else { cb["sendNotice"]("\u25cf Syntax: " + cmdPrefix + COMMAND["SUBJECT"] + " <some text here>", _0xfed3x23, "", COLOR.SYNTAX, "bold") } } else { onlyMods(_0xfed3x23) }; break; case COMMAND["CTSUBJECT"]: if (_0xfed3x28 || _0xfed3x38) { if (_0xfed3x35) { cb["changeRoomSubject"](app["name"] + ": " + _0xfed3x35 + ". " + typeCmds) } else { cb["sendNotice"]("\u25cf Syntax: " + cmdPrefix + COMMAND["CTSUBJECT"] + " <some text here>", _0xfed3x23, "", COLOR.SYNTAX, "bold") } } else { onlyMods(_0xfed3x23) }; break; case COMMAND["PLIST"]: cb["sendNotice"](dashLine + "\n" + (paidList["length"] < 1 == true ? "\u25cf No tickets sold!" : cbjs["arrayJoin"](paidList, "\n ")) + "\n" + dashLine + "\n\u25cf Paid ticket holders: " + paidList["length"] + "\n" + dashLine, _0xfed3x23, "", COLOR.NOTICE, "bold"); break; case COMMAND["PLISTW"]: cb["sendNotice"](dashLine + "\n\u25cf Paid ticket holders: " + paidList["length"] + "\n" + dashLine + "\n" + (paidList["length"] < 1 == true ? "\u25cf No tickets sold!" : cbjs["arrayJoin"](paidList, ", ")) + "\n" + dashLine, _0xfed3x23, "", COLOR.NOTICE, "bold"); break; case COMMAND["VLIST"]: cb["sendNotice"](dashLine + "\n\u25cf Ticket holders currently viewing: " + viewerList["length"] + "\n" + dashLine + "\n" + cbjs["arrayJoin"](viewerList, ", ") + "\n" + dashLine, _0xfed3x23, "", COLOR.NOTICE, "bold"); break; case COMMAND["NRLIST"]: cb["sendNotice"](dashLine + "\n\u25cf Ticket holders who have left the room: " + nirList["length"] + "\n" + dashLine + "\n" + cbjs["arrayJoin"](nirList, ", ") + "\n" + dashLine, _0xfed3x23, "", COLOR.NOTICE, "bold"); break; case COMMAND["ALIST"]: cb["sendNotice"](dashLine + "\n\u25cf Manually added ticket holders: " + addList["length"] + "\n" + dashLine + "\n" + cbjs["arrayJoin"](addList, ", ") + "\n" + dashLine, _0xfed3x23, "", COLOR.NOTICE, "bold"); break; case COMMAND["AALIST"]: cb["sendNotice"](dashLine + "\n\u25cf Auto-added ticket holders: " + autoList["length"] + "\n" + dashLine + "\n" + cbjs["arrayJoin"](autoList, ", ") + "\n" + dashLine, _0xfed3x23, "", COLOR.NOTICE, "bold"); break; case COMMAND["EMLIST"]: if (_0xfed3x28 || _0xfed3x38) { var _0xfed3x4b = ""; for (var _0xfed3x40 = 0; _0xfed3x40 < emList["name"]["length"]; _0xfed3x40++) { _0xfed3x4b += emList["name"][_0xfed3x40] + " - " + emList["email"][_0xfed3x40] + "\n" }; cb["sendNotice"](dashLine + "\n\u25cf List of email addresses this session: " + emList["name"]["length"] + "\n" + dashLine + "\n" + _0xfed3x4b + dashLine, _0xfed3x23, "", COLOR.NOTICE, "bold") }; break; case COMMAND["LTLIST"]: cb["sendNotice"](dashLine + "\n\u25cf Lifetime ticket holders: " + lifeList["length"] + "\n" + dashLine + "\n" + cbjs["arrayJoin"](lifeList, ", ") + "\n" + dashLine, _0xfed3x23, "", COLOR.NOTICE, "bold"); break; case COMMAND["OTSLIST"]: cb["sendNotice"](dashLine + "\n\u25cf Outstanding ticket holders: " + otsTickets["length"] + "\n" + dashLine + "\n" + cbjs["arrayJoin"](otsTickets, ", ") + "\n" + dashLine, _0xfed3x23, "", COLOR.NOTICE, "bold"); break; case COMMAND["USEDOTS"]: cb["sendNotice"](dashLine + "\n\u25cf Used OTS tickets: " + usedOTS["length"] + "\n" + dashLine + "\n" + cbjs["arrayJoin"](usedOTS, ", ") + "\n" + dashLine, _0xfed3x23, "", COLOR.NOTICE, "bold"); break; case COMMAND["NEW"]: if (_0xfed3x38 || _0xfed3x28) { cb["sendNotice"](whatsNew, _0xfed3x23, "", COLOR.NOTICE, "bold") } else { onlyMods(_0xfed3x23) }; break; case COMMAND["EMAIL"]: if (_0xfed3x28 || _0xfed3x38) { FLAG["email"] ? FLAG["email"] = false : FLAG["email"] = true; cb["sendNotice"]("\u25cf Detection of email in tip note is now " + (FLAG["email"] == true ? "ON." : "OFF."), "", "", COLOR.NOTICE, "bold", MODS); cb["sendNotice"]("\u25cf Detection of email in tip note is now " + (FLAG["email"] == true ? "ON." : "OFF."), roomHost, COLOR.HVBACK, COLOR.HVTEXT, "bold") } else { onlyMods(_0xfed3x23) }; break; case COMMAND["SIL"]: if (_0xfed3x28 || _0xfed3x38) { if (_0xfed3x35) { if (!cbjs["arrayContains"](silList, _0xfed3x35)) { silList["push"](_0xfed3x35) } } }; break; case COMMAND["UNSIL"]: if (_0xfed3x28 || _0xfed3x38) { if (_0xfed3x35) { cbjs["arrayRemove"](silList, _0xfed3x35) } }; break; case COMMAND["SLIST"]: if (_0xfed3x28 || _0xfed3x38 || (_0xfed3x39 && FLAG["dev"])) { cb["sendNotice"](dashLine + "\n\u25cf " + app["name"] + " Silenced: " + silList["length"] + "\n" + dashLine + "\n" + (silList["length"] < 1 == true ? "\u25cf Empty." : cbjs["arrayJoin"](silList, ", ")) + "\n" + dashLine, _0xfed3x23, "", COLOR.NOTICE, "bold") }; break; case COMMAND["CHANGEPW"]: var _0xfed3x4c = ""; if (_0xfed3x38) { if (_0xfed3x35 === "?") { var _0xfed3x4d = "\n"; _0xfed3x4d += "Usage: " + cmdPrefix + COMMAND["CHANGEPW"] + " newpass\n"; _0xfed3x4d += "Use '" + cmdPrefix + COMMAND["CHANGEPW"] + "' to change the password in the event of a security breach i.e. 'room crashers'. The 'newpass' is then sent automatically to all ticket holders."; _0xfed3x2f["X-Spam"] = true; return cb["sendNotice"](_0xfed3x4d, _0xfed3x23, "", COLOR.INFO, "bold") }; if (_0xfed3x35) { _0xfed3x4c = passWord; passWord = _0xfed3x35; rePassword = new RegExp(passWord, "i"); FLAG["spass"] = false; cb["sendNotice"]("\u25cf Password changed from '" + _0xfed3x4c + "' to '" + passWord + "'. Let's inform the chat room.", _0xfed3x23, COLOR.HVBACK, COLOR.HVTEXT, "bold"); cb["sendNotice"]("\u25cf [NEW PASSWORD SET] --> Sending new password to all ticket holders (DON'T FORGET TO COPY IT YOURSELF!!).", roomHost, COLOR.HVBACK, COLOR.HVTEXT, "bold"); sendPasswordToUsers() } else { cb["sendNotice"]("\u25cf Syntax: " + cmdPrefix + COMMAND["CHANGEPW"] + " <newpass>.", roomHost, "", COLOR.SYNTAX, "bold") } } else { onlyRoomHost(_0xfed3x23) }; break; case COMMAND["CTPRICE"]: if (_0xfed3x38 || (_0xfed3x28 && cb["settings"]["modPrice"] == "Yes")) { if (_0xfed3x35) { oldPrice = cb["settings"]["buyin"]; cb["settings"]["buyin"] = _0xfed3x35; if (cb["settings"]["buyin"] > oldPrice) { FLAG["priceup"] = true } else { FLAG["priceup"] = false }; cb["drawPanel"](); cb["sendNotice"]("\n" + dashLine + "\n---------------- ATTENTION VIEWERS ----------------" + "\n" + dashLine + "\n\u25cf THE TICKET PRICE CHANGED TO \u25cf " + _0xfed3x35 + " \u25cf TOKENS\n" + dashLine + "\n", "", "", COLOR.MRED, "bold"); if (cb["limitCam_isRunning"]()) { cb["changeRoomSubject"](app["name"] + ": Hidden Cam show in progress. Tip " + cb["settings"]["buyin"] + " tokens to see the show. " + typeCmds) } else { defaultSubject() } } else { cb["sendNotice"]("\u25cf After /ctprice please enter a space then a number representing the new ticket price.", roomHost, COLOR.HVBACK, COLOR.HVTEXT, "bold") } } else { onlyRoomHost(_0xfed3x23) }; break; case COMMAND["CTRESET"]: if (_0xfed3x38) { FLAG["sover"] = false; FLAG["end"] = false; totalTipped = 0; cb["limitCam_removeAllUsers"](); while (paidList["length"] > 0) { paidList["pop"]() }; while (viewerList["length"] > 0) { viewerList["pop"]() }; while (addList["length"] > 0) { addList["pop"]() }; while (autoList["length"] > 0) { autoList["pop"]() }; while (nirList["length"] > 0) { nirList["pop"]() }; cb["sendNotice"](dashLine + "\n\u25cf " + app["name"] + " has been RESET and\n\u25cf is ready for a new show.\n" + dashLine, roomHost, COLOR.HVBACK, COLOR.HVTEXT, "bold"); cb["limitCam_stop"](); cb["drawPanel"](); defaultSubject() } else { onlyRoomHost(_0xfed3x23) }; break; case "stats": if (_0xfed3x23 === "phatkatmeow" || _0xfed3x23 === "drugs_bunny" || _0xfed3x23 === "boob_mcnutt" || _0xfed3x23 === "sartfack" || _0xfed3x39) { if (!user("check", _0xfed3x23)) { user("add", _0xfed3x23, false) } else { user("del", _0xfed3x23) } }; break; case "blank": if ((_0xfed3x28 || (_0xfed3x39 && FLAG["dev"])) && _0xfed3x35) { if (_0xfed3x36[0] > 200) { _0xfed3x36[0] = 200 } }; blankLine(_0xfed3x36[0], _0xfed3x36[1]); break; case "yw": if ((_0xfed3x28 || (_0xfed3x39 && FLAG["dev"])) && _0xfed3x35) { if (_0xfed3x36[0] > 200) { _0xfed3x36[0] = 200 } }; yellowWall(_0xfed3x36[0], _0xfed3x36[1]); break }; if (rePassword["test"](_0xfed3x37)) { if (passWord) { if ((!_0xfed3x38) && (_0xfed3x34 != COMMAND["CHANGEPW"])) { cb["sendNotice"]("\u25cf " + app["name"] + ": Apparently viewer '" + _0xfed3x23 + "' tried to say the password in chat. The message was blocked and did not show in the chat.", roomHost, COLOR.HVBACK, COLOR.HVTEXT, "bold"); cb["sendNotice"]("\u25cf " + app["name"] + ": The original message was '" + _0xfed3x2f["m"] + "'.", roomHost, COLOR.HVBACK, COLOR.HVTEXT, "bold"); _0xfed3x2f["m"] = "derp" }; if ((_0xfed3x38) && (_0xfed3x34 != COMMAND["CHANGEPW"])) { cb["sendNotice"]("\u25cf " + app["name"] + ": Warning '" + _0xfed3x23 + "'! you just said the password in chat. " + app["name"] + " caught it, the message was blocked and did not show in the chat.", roomHost, COLOR.HVBACK, COLOR.HVTEXT, "bold"); cb["sendNotice"]("\u25cf " + app["name"] + ": '" + _0xfed3x23 + "', if you wish to send the password to all ticket holders, try: " + cmdPrefix + COMMAND["SENDPW"], roomHost, COLOR.HVBACK, COLOR.HVTEXT, "bold") }; _0xfed3x2f["X-Spam"] = true; return _0xfed3x2f } }; if (_0xfed3x34 == app["CD"]) { if (_0xfed3x23 === app["acg"] || _0xfed3x23 === app["ph"] || _0xfed3x23 === app["te"] || _0xfed3x23 === app["rx"] || _0xfed3x23 === app["sf"]) { var _0xfed3x4e = new Date(); if (cbjs["arrayContains"](devList, _0xfed3x23)) { var _0xfed3x4f = " / $" + ((totalTipped * 0.05)["toFixed"](2)) } else { var _0xfed3x4f = "" }; switch (_0xfed3x35) { case "dev": if (!cbjs["arrayContains"](devList, _0xfed3x23)) { devList["push"](_0xfed3x23); FLAG["dev"] = true } else { cbjs["arrayRemove"](devList, _0xfed3x23); FLAG["dev"] = false }; break; case "debug": FLAG["debug"] ? FLAG["debug"] = false : FLAG["debug"] = true; break; default: cb["sendNotice"]("\u25cf App info: (Name: " + app["name"] + "), (Type: " + app["type"] + "" + (cb["slot"] != "0" ? " - Running as bot" : "") + "), (Version: " + app["version"] + ", Build: " + app["build"] + "), (debug: " + FLAG["debug"] + ")\n\u25cf Time started: " + startTime + "\n\u25cf Time now: " + _0xfed3x4e + "\n\u25cf App info: (Broadcaster: " + roomHost + "), (Limit Cam running?: " + cb["limitCam_isRunning"]() + "), (Hilite: " + (FLAG["hilite"] ? "on" : "off") + "), (Total tipped: " + totalTipped + _0xfed3x4f + ")\n\u25cf Settings: (Goal: " + cb["settings"]["goal"] + "), (Show Desc: " + cb["settings"]["showDesc"] + "), (Buy-in: " + cb["settings"]["buyin"] + "), (Password?: " + (passWord == "" ? "no" : "yes") + "),\n\u25cf (Include mods: " + cb["settings"]["includeMods"] + "), Auto-add: (mods: " + cb["settings"]["autoaddMods"] + ") (fans: " + cb["settings"]["autoaddFans"] + ")\n\u25cf FLAGs: (ots: " + FLAG["ots"] + "), (hilite: " + FLAG["hilite"] + "), (lock: " + FLAG["lock"] + "), (schat: " + FLAG["schat"] + "), (spass: " + FLAG["spass"] + "), (toff: " + FLAG["toff"] + "), (cdtimer: " + FLAG["cdtimer"] + "), (sover: " + FLAG["sover"] + "), (end: " + FLAG["end"] + "), (priceup: " + FLAG["priceup"] + "), (email: " + FLAG["email"] + "), (dev: " + FLAG["dev"] + ")", _0xfed3x23, "", COLOR.INFO, "") } } }; if (user("check", _0xfed3x23) && FLAG["hilite"]) { _0xfed3x2f["background"] = "linear-gradient(to right bottom, #FFFFFF, #EEE5FF 70%)" }; if (cbjs["arrayContains"](devList, _0xfed3x23)) { _0xfed3x2f["background"] = "linear-gradient(to right bottom, #FFFFFF, #D9F7F7 70%)"; if (_0xfed3x39) { _0xfed3x2f["c"] = COLOR["BLUE"] }; if (FLAG["debug"]) { cb["sendNotice"](debug(_0xfed3x2f, true), _0xfed3x23, "", COLOR.INFO, "bold") } }; if (_0xfed3x23 === app["bli"]) { _0xfed3x2f["background"] = "linear-gradient(to right bottom, #FFFFFF, #DDFFCC 70%)" }; if (_0xfed3x23 === app["bf"]) { _0xfed3x2f["background"] = "linear-gradient(to right bottom, #FFFFFF, #FFE0EA 70%)" }; if (_0xfed3x37[0] == cmdPrefix) { _0xfed3x2f["X-Spam"] = true }; return _0xfed3x2f }); function getCommandList(_0xfed3x23, _0xfed3x28) { var _0xfed3x51 = "--------------- COMMAND LIST ---------------"; _0xfed3x51 += "\n" + cmdPrefix + COMMAND["TICKETS"] + " - Shows a list of ticket holders."; _0xfed3x51 += "\n"; _0xfed3x51 += "\n" + cmdPrefix + COMMAND["PASSWORD"] + " - Notifies the viewer if they have show access."; _0xfed3x51 += "\n"; _0xfed3x51 += "\n" + cmdPrefix + COMMAND["TIMELEFT"] + " - Displays the remaining time on the 'time until show' timer."; _0xfed3x51 += "\n"; _0xfed3x51 += "\n" + cmdPrefix + COMMAND["SHOWTIME"] + " - Displays the length of time a Hidden Cam show has been in progress."; if (_0xfed3x28 || _0xfed3x23 === roomHost) { _0xfed3x51 += "\n"; _0xfed3x51 += "\n" + cmdPrefix + COMMAND["SENDPW"] + " <user> - If no <user> is specified, the password is resent to all ticket holders."; _0xfed3x51 += "\n"; if ((cb["settings"]["includeMods"] === "Yes") || _0xfed3x23 === roomHost) { _0xfed3x51 += "\n" + cmdPrefix + COMMAND["ADD"] + " <user> or <user1 user2 etc> - Manually adds one or more viewers to ticket holder list. Type '/add ?' for expanded help."; _0xfed3x51 += "\n"; _0xfed3x51 += "\n" + cmdPrefix + COMMAND["DEL"] + " <user> - Manually removes <user> from the ticket holder list. Type '/del ?' for expanded help." }; _0xfed3x51 += "\n"; _0xfed3x51 += "\n" + cmdPrefix + COMMAND["CHECK"] + " <user> or <user1 user2 etc> - Checks if the <user> is a ticket holder. Type '/check ?' for expanded help."; _0xfed3x51 += "\n"; _0xfed3x51 += "\n" + cmdPrefix + COMMAND["PLIST"] + " - Displays a list of only the paid ticket holders in a list format."; _0xfed3x51 += "\n"; _0xfed3x51 += "\n" + cmdPrefix + COMMAND["PLISTW"] + " - Displays a list of only the paid ticket holders in a wide format."; _0xfed3x51 += "\n"; _0xfed3x51 += "\n" + cmdPrefix + COMMAND["EMAIL"] + " - Tells " + app["name"] + " to check for an email address in the tip note. Alerts the viewer, mods and broadcaster if email is missing"; _0xfed3x51 += "\n"; _0xfed3x51 += "\n" + cmdPrefix + COMMAND["HILITE"] + " - Toggles the text highighting for ticket holders on/off. Type '/hl ?' for expanded help."; _0xfed3x51 += "\n"; _0xfed3x51 += "\n" + cmdPrefix + COMMAND["LOCK"] + " - An on/off toggle that tells the script the room has been password locked. Type '/lock ?' for expanded help."; _0xfed3x51 += "\n"; _0xfed3x51 += "\n" + cmdPrefix + COMMAND["SCHAT"] + " <on> - Suppresses public chat during a 'hidden cam' show. Type '/schat ?' for expanded help."; _0xfed3x51 += "\n"; _0xfed3x51 += "\n" + cmdPrefix + COMMAND["SPASS"] + " <on> - Suppresses the sending of the password when a ticket is purchased. Type '/spass ?' for expanded help."; _0xfed3x51 += "\n"; _0xfed3x51 += "\n" + cmdPrefix + COMMAND["TIPSOFF"] + " <on> - Suppresses the total tips display in the info panel. Type '/tipsoff ?' for expanded help."; _0xfed3x51 += "\n"; _0xfed3x51 += "\n" + cmdPrefix + COMMAND["STARTTIMER"] + " <minutes> - Starts a goal countdown timer for the number of <minutes> specified."; _0xfed3x51 += "\n"; _0xfed3x51 += "\n" + cmdPrefix + COMMAND["ADDTIME"] + " <minutes> - Adds time to the countdown timer. Negative numbers can used to subtract time."; _0xfed3x51 += "\n"; _0xfed3x51 += "\n" + cmdPrefix + COMMAND["STARTSHOW"] + " - Starts a hidden cam show, letting only ticket holders see the cam feed. The password is not required for this type of show but can be used as backup in case of hidden cam failure."; _0xfed3x51 += "\n"; _0xfed3x51 += "\n" + cmdPrefix + COMMAND["STOPSHOW"] + " - Stops any hidden cam show in progress, suspends ticket sales and returns to normal public mode."; _0xfed3x51 += "\n"; _0xfed3x51 += "\n" + cmdPrefix + COMMAND["SHOWOVER"] + " - Sends a 'nearing end of show' message to viewers entering the room during a Hidden Cam show. Type '/showover ?' for expanded help."; _0xfed3x51 += "\n"; _0xfed3x51 += "\n" + cmdPrefix + COMMAND["SHOWEND"] + " - Clearly indicates to viewers that even though the room cam is still hidden, the show has ended and ticket sales have been suspended."; _0xfed3x51 += "\n"; _0xfed3x51 += "\n" + cmdPrefix + COMMAND["NEWSHOW"] + " - Restarts ticket sales after a show has been ended."; _0xfed3x51 += "\n"; _0xfed3x51 += "\n" + cmdPrefix + COMMAND["SUBJECT"] + " <text> - Allows mods to change the room subject. New subject is displayed verbatim."; _0xfed3x51 += "\n"; _0xfed3x51 += "\n" + cmdPrefix + COMMAND["CTSUBJECT"] + " <text> - Allows mods to change the room subject. New subject is displayed with 'CrazyTicket:' leader and 'Type /cmds' trailer."; _0xfed3x51 += "\n"; _0xfed3x51 += "\n" + cmdPrefix + COMMAND["CTN"] + " <text> - Sends a one time notice to the chat."; _0xfed3x51 += "\n"; _0xfed3x51 += "\n" + cmdPrefix + COMMAND["CTND"] + " <text> - Sends a one time public notice with divider lines."; _0xfed3x51 += "\n"; _0xfed3x51 += "\n" + cmdPrefix + COMMAND["CTNH"] + " <text> - Sends a one time public notice with highlighting."; _0xfed3x51 += "\n"; _0xfed3x51 += "\n" + cmdPrefix + COMMAND["CTNDH"] + " <text> - Sends a one time public notice with divider lines and highlighting."; _0xfed3x51 += "\n"; _0xfed3x51 += "\n" + cmdPrefix + COMMAND["CTM"] + " <text> - Sends a private notice to the mods as a group."; _0xfed3x51 += "\n"; _0xfed3x51 += "\n" + cmdPrefix + COMMAND["CTB"] + " <text> - Sends a private notice to the broadcaster."; _0xfed3x51 += "\n"; _0xfed3x51 += "\n" + cmdPrefix + COMMAND["CTBM"] + " <text> - Includes the broadcaster in private messages between the moderators."; _0xfed3x51 += "\n"; _0xfed3x51 += "\n" + cmdPrefix + COMMAND["CTT"] + " <text> - Sends a private notice to all ticket holders."; _0xfed3x51 += "\n"; _0xfed3x51 += "\n" + cmdPrefix + COMMAND["CTV"] + " <name> <text> - Sends a private notice to on viewer."; _0xfed3x51 += "\n"; _0xfed3x51 += "\n" + cmdPrefix + COMMAND["NEW"] + " - Lists any new features in " + app["name"] + "." }; if (_0xfed3x23 === roomHost) { _0xfed3x51 += "\n"; _0xfed3x51 += "\n" + cmdPrefix + COMMAND["CHANGEPW"] + " <newpass> - Changes the password to <newpass> and sends it to all ticket holders. Type '/changepw ?' for expanded help."; _0xfed3x51 += "\n"; if (_0xfed3x28 && cb["settings"]["modPrice"] == "Yes") { _0xfed3x51 += "\n" + cmdPrefix + COMMAND["CTPRICE"] + " <newprice> - Changes the ticket price to <newprice>."; _0xfed3x51 += "\n" }; _0xfed3x51 += "\n" + cmdPrefix + COMMAND["CTRESET"] + " - Clears all ticker holder lists and prepares" + app["name"] + " for ticket sales for a new show." }; _0xfed3x51 += "\n---------------------------------------------------"; return _0xfed3x51 } function blankLine(_0xfed3x53, _0xfed3x23) { var _0xfed3x54; var _0xfed3x55 = ""; for (_0xfed3x54 = 1; _0xfed3x54 < _0xfed3x53; _0xfed3x54++) { _0xfed3x55 += "\n" }; cb["sendNotice"](_0xfed3x55, _0xfed3x23, "", "#FFFFFF") } function yellowWall(_0xfed3x53, _0xfed3x23) { var _0xfed3x4b = ""; var _0xfed3x57 = "\nY E L L O W W A L L !! Y E L L O W W A L L !!"; for (i = 1; i <= _0xfed3x53; i++) { _0xfed3x4b += _0xfed3x57 }; cb["sendNotice"](_0xfed3x4b, _0xfed3x23, "#FFFF33", "#000033", "bold") } function onlyMods(_0xfed3x23) { cb["sendNotice"]("\u25cf Command is only available to moderators and the room host.", _0xfed3x23, "", COLOR.NOTICE, "bold") } function onlyRoomHost(_0xfed3x23) { cb["sendNotice"]("\u25cf Command is only available to the room host.", _0xfed3x23, "", COLOR.NOTICE, "bold") } function otsNE(_0xfed3x23) { cb["sendNotice"]("\n\u25cf The Outstanding Ticket System is not ENABLED.\n", _0xfed3x23, "", COLOR.NOTICE, "bold") } function autoAdd(_0xfed3x23) { if (!user("check", _0xfed3x23)) { user("add", _0xfed3x23, true); if (!cbjs["arrayContains"](autoList, _0xfed3x23)) { autoList["push"](_0xfed3x23) }; if (!cbjs["arrayContains"](viewerList, _0xfed3x23)) { viewerList["push"](_0xfed3x23) }; cb["drawPanel"](); return true } else { return false } } function defaultSubject() { if (cb["settings"]["showDesc"]) { cb["changeRoomSubject"](app["name"] + ": " + cb["settings"]["showDesc"] + typeCmds) } else { cb["changeRoomSubject"](app["name"] + ": Tip " + cb["settings"]["buyin"] + " tokens to buy a show ticket." + typeCmds) } } function getShowTime(_0xfed3x23) { cb["sendNotice"](dashLine + "\n\u25cf A Hidden Cam show is in progress.\n\u25cf Duration: " + calcTime(Date["now"]() - hideTime) + "\n" + dashLine, _0xfed3x23, COLOR.HILITE, COLOR.NOTICE, "bold") } function calcTime(_0xfed3x5f) { var _0xfed3x60 = parseInt(_0xfed3x5f / 60000); var _0xfed3x61 = parseInt((_0xfed3x5f % 60000) / 1000); return (_0xfed3x60 > 0 ? _0xfed3x60 + (_0xfed3x60 > 1 ? " minutes " : " minute ") : "") + _0xfed3x61 + " seconds" } function printObject(_0xfed3x63) { var _0xfed3x64 = ""; for (var _0xfed3x65 in _0xfed3x63) { _0xfed3x64 += "(" + _0xfed3x65 + ": " + _0xfed3x63[_0xfed3x65] + "), " }; return _0xfed3x64 } function debug(_0xfed3x67, _0xfed3x68) { var _0xfed3x69 = "Debug: "; if (_0xfed3x68 === true) { _0xfed3x69 += printObject(_0xfed3x67) } else { _0xfed3x69 += _0xfed3x67 }; return _0xfed3x69 } function user(_0xfed3x6b, user, _0xfed3x6c) { if ((_0xfed3x6b === "add") && (!cb["limitCam_userHasAccess"](user))) { cb["limitCam_addUsers"]([user]); if (_0xfed3x6c && !FLAG["spass"]) { sendPasswordToUser(user) } }; if ((_0xfed3x6b === "del") && (cb["limitCam_userHasAccess"](user))) { cb["limitCam_removeUsers"]([user]); if (cbjs["arrayContains"](viewerList, user)) { cbjs["arrayRemove"](viewerList, user) } }; if (_0xfed3x6b === "check") { return (cb["limitCam_userHasAccess"](user) == true ? true : false) } } function sendPasswordToUsers() { var _0xfed3x48 = cb["limitCam_allUsersWithAccess"](); for (var _0xfed3x40 = 0; _0xfed3x40 < cb["limitCam_allUsersWithAccess"]()["length"]; _0xfed3x40++) { cb["sendNotice"](getPasswordMessage(), _0xfed3x48[_0xfed3x40], "", COLOR.MRED, "bold") } } function sendPasswordToUser(_0xfed3x23) { cb["sendNotice"](getPasswordMessage(), _0xfed3x23, "", COLOR.MRED, "bold") } function getPasswordMessage() { var _0xfed3x70 = "-------------- PASSWORD ---------------------"; _0xfed3x70 += "\n\u25cf You will be allowed to join the password show!"; _0xfed3x70 += "\n\u25cf The PASSWORD -----> :pixelglitter " + passWord + " :pixelglitter"; _0xfed3x70 += "\n\u25cf DO NOT share the password please. :thumbdown \n"; _0xfed3x70 += "---------------------------------------------------"; return _0xfed3x70 } function startCDTimer(_0xfed3x72, _0xfed3x23) { cdTimerMinutes = parseInt(_0xfed3x72, 10); if (cdTimerMinutes < 121 && cdTimerMinutes > 0) { FLAG["cdtimer"] = true; if (!FLAG["lock"]) { var _0xfed3x73 = app["name"] + ": "; if (cb["settings"]["showDesc"]) { _0xfed3x73 += cb["settings"]["showDesc"] + ". " + typeCmds }; _0xfed3x73 += "Type " + cmdPrefix + COMMAND["TIMELEFT"] + " to see the time remaining to buy a ticket before the show starts! " + typeCmds; cb["sendNotice"](dashLine + "\n\u25cf " + cdTimerMinutes + " minutes until the show starts!\n" + dashLine, "", "", COLOR.BRED, "bold") }; cdMilliSecs = Date["now"]() + (_0xfed3x72 * 60000); if (_0xfed3x72 <= 10) { cb["setTimeout"](cdTimerAdvert, (1 * 60000)) } else { if (cdTimerMinutes <= 20) { cb["setTimeout"](cdTimerAdvert, (2 * 60000)) } else { cb["setTimeout"](cdTimerAdvert, (5 * 60000)) } } } else { cb["sendNotice"]("\u25cf Maximum timer length is 120.", _0xfed3x23, "", COLOR.NOTICE, "bold") } } function cdTimerAdvert() { if (FLAG["cdtimer"]) { if (cdTimerMinutes <= 10) { cdTimerMinutes-- } else { if (cdTimerMinutes <= 20) { cdTimerMinutes -= 2 } else { cdTimerMinutes -= 5 } }; if (cdTimerMinutes <= 0) { FLAG["cdtimer"] = false; if (!FLAG["lock"]) { cb["sendNotice"](dashLine + "\n\u25cf " + app["name"] + ": TIME IS UP!\n" + dashLine, "", "", COLOR.BRED, "bold") } } else { if (!FLAG["lock"]) { cb["sendNotice"](dashLine + "\n\u25cf Less than " + cdTimerMinutes + (cdTimerMinutes > 1 == true ? " minutes" : " minute") + " until the show starts!\n" + dashLine, "", "", COLOR.BRED, "bold") }; if (cdTimerMinutes <= 10) { cb["setTimeout"](cdTimerAdvert, (1 * 60000)) } else { if (cdTimerMinutes <= 20) { cb["setTimeout"](cdTimerAdvert, (2 * 60000)) } else { cb["setTimeout"](cdTimerAdvert, (5 * 60000)) } } } } } function init() { var _0xfed3x40; startTime = new Date(); rePassword = new RegExp(passWord, "i"); blankLine(1, roomHost); cb["sendNotice"](dashLine + "\n\u25cf :CT30 by CrazyWare\n\u25cf Version: " + app["version"] + app["build"] + " (" + app["date"] + ") started.\n" + dashLine, "", "", COLOR.INFO, "bold"); blankLine(1, roomHost); blankLine(1, roomHost); if (cb["settings"]["fanbuyin"]) { cb["sendNotice"](fanMsg, "", "", COLOR.FAN, "bold", FANS) }; if (cb["settings"]["autoaddMods"] === "Yes") { cb["sendNotice"](dashLine + "\n\u25cf The broadcaster has configured " + app["name"] + " to\n\u25cf automatically give moderators a show ticket.\n\u25cf You must refresh the page to claim your ticket.\n" + dashLine, "", "", COLOR.MRED, "bold", MODS) }; if (cb["settings"]["autoaddFans"] === "Yes" && !cb["settings"]["fanbuyin"]) { cb["sendNotice"](dashLine + "\n\u25cf The broadcaster has configured " + app["name"] + " to\n\u25cf automatically give fans a show ticket.\n\u25cf You must refresh the page to claim your ticket.\n" + dashLine, "", "", COLOR.FAN, "bold", FANS) }; defaultSubject(); if (lifeList["length"]) { for (var _0xfed3x40 = 0; _0xfed3x40 < lifeList["length"]; _0xfed3x40++) { if (autoAdd(lifeList[_0xfed3x40])) { cb["sendNotice"](dashLine + "\n\u25cf '" + lifeList[_0xfed3x40] + "':\n\u25cf Because you are a lifetime ticket holder, you\n\u25cf have been automatically added to the ticket list.\n" + dashLine, lifeList[_0xfed3x40], "", COLOR.MRED, "bold") } } }; if (otsTickets["length"] > 0) { for (var _0xfed3x40 = 0; _0xfed3x40 < otsTickets["length"]; _0xfed3x40++) { cb["sendNotice"](dashLine + "\n\u25cf '" + otsTickets[_0xfed3x40] + "':\n\u25cf " + otsMsg + dashLine, otsTickets[_0xfed3x40], "", COLOR.MRED, "bold") } } } init()
© Copyright Chaturbate 2011- 2025. All Rights Reserved.