Okay, so we used xAndrewx's IRC tabs and it's not working properly....
Weapon: -System/Report
PHP Code:
function onActionServerSide() {
if (params[0] == "SendReport") {
for (temp.rc: IRC.rcplayers)
temp.rc.sendtoirc("privmsg", "REPORT", "Reports", params[1] @ " reported " @ params[3] @ " for " @ params[2]);
player.chat = "Report Sent Successfully!";
}
}
//#CLIENTSIDE
function onPlayerChats() {
if (player.chat == "/report") {
John612_ReportGUI_Window1.show();
new GuiWindowCtrl("John612_ReportGUI_Window1") {
profile = GuiBlueWindowProfile;
clientrelative = true;
clientextent = "137,282";
canclose = false;
canmaximize = false;
canmove = true;
canresize = true;
closequery = false;
destroyonhide = false;
text = "Report";
x = 226;
y = 3;
new GuiTextEditCtrl("John612_ReportGUI_TextEdit1") {
profile = GuiBlueTextEditProfile;
height = 20;
width = 89;
x = 26;
y = 22;
}
new GuiTextCtrl("John612_ReportGUI_Text1") {
profile = GuiBlueTextProfile;
height = 20;
text = "Account";
width = 48;
x = 46;
y = 1;
}
new GuiTextCtrl("John612_ReportGUI_Text2") {
profile = GuiBlueTextProfile;
height = 20;
text = "Reason";
width = 45;
x = 47;
y = 49;
}
new GuiScrollCtrl("John612_ReportGUI_MultiLineEdit1_Scroll") {
profile = GuiBlueScrollProfile;
height = 127;
hscrollbar = "dynamic";
vscrollbar = "dynamic";
width = 132;
x = 2;
y = 74;
new GuiMLTextEditCtrl("John612_ReportGUI_MultiLineEdit1") {
profile = GuiBlueMLTextEditProfile;
height = 17;
horizsizing = "width";
width = 107;
}
}
new GuiButtonCtrl("John612_ReportGUI_Button1") {
profile = GuiBlueButtonProfile;
text = "Send Report";
width = 87;
x = 26;
y = 209;
}
new GuiButtonCtrl("John612_ReportGUI_Button2") {
profile = GuiBlueButtonProfile;
text = "Cancel";
width = 87;
x = 26;
y = 246;
}
}
}
}
function John612_ReportGUI_Button1.onAction() {
if (John612_ReportGUI_MultiLineEdit1.text == "" || John612_ReportGUI_TextEdit1.text == "") {
player.chat = "Please Fill Out All Forms Completely!";
}
else {
triggerserver("gui", name, "SendReport", player.account, John612_ReportGUI_MultiLineEdit1.text, John612_ReportGUI_TextEdit1.text);
John612_ReportGUI_Window1.hide();
John612_ReportGUI_MultiLineEdit1.text = "";
John612_ReportGUI_TextEdit1.text = "";
}
}
function John612_ReportGUI_Button2.onAction() {
John612_ReportGUI_Window1.hide();
John612_ReportGUI_MultiLineEdit1.text = "";
John612_ReportGUI_TextEdit1.text = "";
}
Control NPC: IRC
PHP Code:
temp.oldrcplayers = this.rcplayers;
this.rcplayers = {"Graal771281", "Graal756538"};
this.clientrcplayers = {"Graal771281", "Graal756538"};
for (temp.pl: allplayers) {
if (temp.pl.level == NULL) {
if (temp.pl.adminlevel >= 1) {
}
continue;
}
if (temp.pl.adminlevel >= 1)
this.clientrcplayers.add(temp.pl);
}
Can anyone tell me what I'm missing?
It's not adding any text/chat to the "Reports" tab when it's called to...