chat test
目前為
此腳本不應該直接安裝,它是一個供其他腳本使用的函式庫。欲使用本函式庫,請在腳本 metadata 寫上: // @require https://update.gf.qytechs.cn/scripts/534139/1578638/koc%20chat.js
Tabs.chat = {
tabOrder: 9002,
tabLabel: 'Chat(no mods)',
tabColor: 'purple',
myDiv: null,
Options: {
Counter: 0, // This counter doesn't seem to be used
},
init: function(div) {
var t = Tabs.chat;
t.myDiv = div;
// Simplified options initialization
Options.chat = Options.chat || t.Options;
},
hide: function() {
// Currently does nothing, but could be used to pause chat updates or
// remove the iframe to save resources. For example:
// this.myDiv.innerHTML = '';
},
show: function() {
var t = Tabs.chat;
var m = 'https://us28.chatzy.com/m/21183371900079'; // Corrected URL formatting
t.myDiv.innerHTML = '<iframe src="' + m + '" style="width:100%; height:500px; border:none;"></iframe>';
// Removed redundant code. Options.chat.Counter is unused.
},
};