aboutsummaryrefslogtreecommitdiff
path: root/src/packet_distribution.cpp
diff options
context:
space:
mode:
authoriamgoofball <iamgoofball@gmail.com>2019-01-23 07:35:29 -0800
committeriamgoofball <iamgoofball@gmail.com>2019-01-23 07:35:29 -0800
commit0649e7b28e16a054072d8656a5046c7cc3cfefb6 (patch)
treeae5a5e0bf48a6b588314e337f36d8c1e9164a316 /src/packet_distribution.cpp
parentf9406d0a7f2363843d9d7c09a9e8d3422c967a64 (diff)
Case Announcer: Witness Support also some other shit
Diffstat (limited to 'src/packet_distribution.cpp')
-rw-r--r--src/packet_distribution.cpp25
1 files changed, 20 insertions, 5 deletions
diff --git a/src/packet_distribution.cpp b/src/packet_distribution.cpp
index 0cbf4631..7ad24739 100644
--- a/src/packet_distribution.cpp
+++ b/src/packet_distribution.cpp
@@ -460,9 +460,24 @@ void AOApplication::server_packet_received(AOPacket *p_packet)
{
if (f_contents.size() < 3)
goto end;
-
- if (courtroom_constructed)
- w_courtroom->enter_courtroom(f_contents.at(2).toInt());
+ if(f_contents.size() < 4){
+ if (courtroom_constructed)
+ w_courtroom->enter_courtroom(f_contents.at(2).toInt());
+ }
+ else
+ {
+ if (courtroom_constructed)
+ {
+ if(f_contents.at(3) == "True")
+ {
+ w_courtroom->set_character(f_contents.at(2).toInt());
+ }
+ else
+ {
+ w_courtroom->enter_courtroom(f_contents.at(2).toInt());
+ }
+ }
+ }
}
else if (header == "MS")
{
@@ -577,8 +592,8 @@ void AOApplication::server_packet_received(AOPacket *p_packet)
}
else if (header == "CASEA")
{
- if (courtroom_constructed && f_contents.size() > 6)
- w_courtroom->case_called(f_contents.at(0), f_contents.at(1) == "1", f_contents.at(2) == "1", f_contents.at(3) == "1", f_contents.at(4) == "1", f_contents.at(5) == "1");
+ if (courtroom_constructed && f_contents.size() > 7)
+ w_courtroom->case_called(f_contents.at(0), f_contents.at(1) == "1", f_contents.at(2) == "1", f_contents.at(3) == "1", f_contents.at(4) == "1", f_contents.at(5) == "1", f_contents.at(6) == "1");
}
end: