Fix anim_state deciding whether you're allowed to send a message or not (the only thing that should decide that is if text is done processing or not)
Fix objections forcing a missingno to appear when you object to someone mid-preanim, and their preanim ends before objection shout finishes. This also resolves a crapton of other bugs related to preanim_done() signal. Move evidence display from handle_ic_speaking to start_chat_ticking (makes more sense over here) Remove a misplaced set_static_duration for ui_vp_player_char (must've got here over a strange merge conflict or smth) Remove useless anim_state and text_state setters in reload_theme func, the func that calls the BG to display already handles everything needed for IC reset
This commit is contained in:
parent
8f0913d30e
commit
e36ac916a9
@ -1667,7 +1667,7 @@ void Courtroom::on_chat_return_pressed()
|
|||||||
if (is_muted)
|
if (is_muted)
|
||||||
return;
|
return;
|
||||||
|
|
||||||
if ((anim_state < 3 || text_state < 2) && objection_state == 0)
|
if (text_state < 2 && objection_state == 0)
|
||||||
return;
|
return;
|
||||||
|
|
||||||
ui_ic_chat_message->blockSignals(true);
|
ui_ic_chat_message->blockSignals(true);
|
||||||
@ -2186,8 +2186,6 @@ bool Courtroom::handle_objection()
|
|||||||
objection_mod = m_chatmessage[OBJECTION_MOD].toInt();
|
objection_mod = m_chatmessage[OBJECTION_MOD].toInt();
|
||||||
}
|
}
|
||||||
|
|
||||||
|
|
||||||
|
|
||||||
// if an objection is used
|
// if an objection is used
|
||||||
if (objection_mod <= 4 && objection_mod >= 1) {
|
if (objection_mod <= 4 && objection_mod >= 1) {
|
||||||
ui_vp_objection->set_static_duration(shout_static_time);
|
ui_vp_objection->set_static_duration(shout_static_time);
|
||||||
@ -2523,7 +2521,6 @@ void Courtroom::initialize_chatbox()
|
|||||||
if (f_charid >= 0 && f_charid < char_list.size() &&
|
if (f_charid >= 0 && f_charid < char_list.size() &&
|
||||||
(m_chatmessage[SHOWNAME].isEmpty() || !ui_showname_enable->isChecked())) {
|
(m_chatmessage[SHOWNAME].isEmpty() || !ui_showname_enable->isChecked())) {
|
||||||
QString real_name = char_list.at(f_charid).name;
|
QString real_name = char_list.at(f_charid).name;
|
||||||
ui_vp_player_char->set_static_duration(0);
|
|
||||||
QString f_showname = ao_app->get_showname(real_name);
|
QString f_showname = ao_app->get_showname(real_name);
|
||||||
|
|
||||||
ui_vp_showname->setText(f_showname);
|
ui_vp_showname->setText(f_showname);
|
||||||
@ -2671,8 +2668,6 @@ void Courtroom::display_evidence_image()
|
|||||||
|
|
||||||
void Courtroom::handle_ic_speaking()
|
void Courtroom::handle_ic_speaking()
|
||||||
{
|
{
|
||||||
// Display the evidence
|
|
||||||
display_evidence_image();
|
|
||||||
QString side = m_chatmessage[SIDE];
|
QString side = m_chatmessage[SIDE];
|
||||||
int emote_mod = m_chatmessage[EMOTE_MOD].toInt();
|
int emote_mod = m_chatmessage[EMOTE_MOD].toInt();
|
||||||
// emote_mod 5 is zoom and emote_mod 6 is zoom w/ preanim.
|
// emote_mod 5 is zoom and emote_mod 6 is zoom w/ preanim.
|
||||||
@ -3182,6 +3177,9 @@ void Courtroom::play_preanim(bool immediate)
|
|||||||
|
|
||||||
void Courtroom::preanim_done()
|
void Courtroom::preanim_done()
|
||||||
{
|
{
|
||||||
|
// Currently, someone's talking over us mid-preanim...
|
||||||
|
if (anim_state != 1 && anim_state != 4)
|
||||||
|
return;
|
||||||
anim_state = 1;
|
anim_state = 1;
|
||||||
switch(m_chatmessage[DESK_MOD].toInt()) {
|
switch(m_chatmessage[DESK_MOD].toInt()) {
|
||||||
case 4:
|
case 4:
|
||||||
@ -3211,6 +3209,9 @@ void Courtroom::start_chat_ticking()
|
|||||||
if (text_state != 0)
|
if (text_state != 0)
|
||||||
return;
|
return;
|
||||||
|
|
||||||
|
// Display the evidence
|
||||||
|
display_evidence_image();
|
||||||
|
|
||||||
if (m_chatmessage[EFFECTS] != "") {
|
if (m_chatmessage[EFFECTS] != "") {
|
||||||
QStringList fx_list = m_chatmessage[EFFECTS].split("|");
|
QStringList fx_list = m_chatmessage[EFFECTS].split("|");
|
||||||
QString fx = fx_list[0];
|
QString fx = fx_list[0];
|
||||||
@ -5254,8 +5255,6 @@ void Courtroom::on_reload_theme_clicked()
|
|||||||
enter_courtroom();
|
enter_courtroom();
|
||||||
gen_char_rgb_list(ao_app->get_chat(current_char));
|
gen_char_rgb_list(ao_app->get_chat(current_char));
|
||||||
|
|
||||||
anim_state = 4;
|
|
||||||
text_state = 3;
|
|
||||||
objection_custom = "";
|
objection_custom = "";
|
||||||
|
|
||||||
// to update status on the background
|
// to update status on the background
|
||||||
|
Loading…
Reference in New Issue
Block a user