diff --git a/base/sounds/general/adminhelp.ogg b/base/sounds/general/adminhelp.ogg new file mode 100644 index 0000000..704c0fd Binary files /dev/null and b/base/sounds/general/adminhelp.ogg differ diff --git a/base/themes/default/courtroom_design.ini b/base/themes/default/courtroom_design.ini index fe8fadf..f2dd2d7 100644 --- a/base/themes/default/courtroom_design.ini +++ b/base/themes/default/courtroom_design.ini @@ -107,7 +107,7 @@ pre = 5, 490, 80, 21 flip = 104, 490, 51, 21 ; Guard button -guard = 200, 560, 61, 21 +guard = 200, 580, 81, 21 pre_no_interrupt = 200, 490, 80, 21 diff --git a/base/themes/default/courtroom_sounds.ini b/base/themes/default/courtroom_sounds.ini index b24e2ce..050576e 100644 --- a/base/themes/default/courtroom_sounds.ini +++ b/base/themes/default/courtroom_sounds.ini @@ -3,6 +3,6 @@ witness_testimony = sfx-testimony2.wav cross_examination = sfx-testimony.wav evidence_present = sfx-evidenceshoop.wav word_call = sfx-gaspen-yeah!.wav -mod_call = sfx-gallery.wav +mod_call = adminhelp.ogg not_guilty = sfx-notguilty.wav guilty = sfx-guilty.wav \ No newline at end of file diff --git a/src/courtroom.cpp b/src/courtroom.cpp index ce4ccf1..da1b090 100644 --- a/src/courtroom.cpp +++ b/src/courtroom.cpp @@ -193,7 +193,7 @@ Courtroom::Courtroom(AOApplication *p_ao_app) : QMainWindow() ui_flip->setText("Flip"); ui_flip->hide(); ui_guard = new QCheckBox(this); - ui_guard->setText("Guard"); + ui_guard->setText("Disable Modcalls"); ui_guard->hide(); ui_casing = new QCheckBox(this); ui_casing->setChecked(ao_app->get_casing_enabled()); @@ -1085,6 +1085,12 @@ void Courtroom::append_server_chatmessage(QString p_name, QString p_message, QSt colour = ao_app->get_color("ooc_default_color", "courtroom_design.ini").name(); if (p_colour == "1") colour = ao_app->get_color("ooc_server_color", "courtroom_design.ini").name(); + qDebug() << p_message; + if(p_message == "Logged in as a moderator.") + { + ui_guard->show(); + append_server_chatmessage("CLIENT", "You were granted the Disable Modcalls button.", "1"); + } ui_server_chatlog->append_chatmessage(p_name, p_message, colour); } @@ -2855,7 +2861,7 @@ void Courtroom::toggle_judge_buttons(bool is_on) void Courtroom::mod_called(QString p_ip) { ui_server_chatlog->append(p_ip); - if (ui_guard->isChecked()) + if (!ui_guard->isChecked()) { modcall_player->play(ao_app->get_sfx("mod_call")); ao_app->alert(this); @@ -2897,11 +2903,6 @@ void Courtroom::on_ooc_return_pressed() toggle_judge_buttons(false); } } - else if (ooc_message.startsWith("/login")) - { - ui_guard->show(); - append_server_chatmessage("CLIENT", "You were granted the Guard button.", "1"); - } else if (ooc_message.startsWith("/rainbow") && ao_app->yellow_text_enabled && !rainbow_appended) { //ui_text_color->addItem("Rainbow");