Make ChatC and ChatB postViaChecks as temporary workaround to PE parsing limitations.
This commit is contained in:
1 parent
4b514e7098
commit
31107ec4b5
3 files changed
+5
-2
No files matched your search
@@ -42,6 +42,7 @@ public class ChatB extends Check implements PacketCheck {
|
||||
}
|
||||
|
||||
if (event.getPacketType() == PacketType.Play.Client.CHAT_COMMAND) {
|
||||
// TODO make previa after making wrapper parse by client version instead of server version
|
||||
String command = "/" + new WrapperPlayClientChatCommand(event).getCommand();
|
||||
if (!command.trim().equals(command)) {
|
||||
if (flagAndAlert("command=" + command)) {
|
||||
|
||||
@@ -28,6 +28,7 @@ public class ChatC extends Check implements PacketCheck {
|
||||
@Override
|
||||
public void onPacketReceive(PacketReceiveEvent event) {
|
||||
if (event.getPacketType() == PacketType.Play.Client.CHAT_MESSAGE) {
|
||||
// TODO make previa after making wrapper parse by client version instead of server version
|
||||
check(new WrapperPlayClientChatMessage(event).getMessage(), event);
|
||||
}
|
||||
|
||||
@@ -36,6 +37,7 @@ public class ChatC extends Check implements PacketCheck {
|
||||
}
|
||||
|
||||
if (event.getPacketType() == PacketType.Play.Client.CHAT_COMMAND) {
|
||||
// TODO make previa after making wrapper parse by client version instead of server version
|
||||
check("/" + new WrapperPlayClientChatCommand(event).getCommand(), event);
|
||||
}
|
||||
}
|
||||
|
||||
@@ -88,8 +88,6 @@ public class CheckManager {
|
||||
.put(ExploitA.class, new ExploitA(player))
|
||||
.put(ExploitB.class, new ExploitB(player))
|
||||
.put(ChatA.class, new ChatA(player))
|
||||
.put(ChatB.class, new ChatB(player))
|
||||
.put(ChatC.class, new ChatC(player))
|
||||
.put(ChatD.class, new ChatD(player))
|
||||
.put(PacketOrderB.class, new PacketOrderB(player))
|
||||
.put(PacketOrderC.class, new PacketOrderC(player))
|
||||
@@ -142,6 +140,8 @@ public class CheckManager {
|
||||
.put(TeamHandler.class, new TeamHandler(player))
|
||||
.put(ClientBrand.class, new ClientBrand(player))
|
||||
.put(NoFall.class, new NoFall(player))
|
||||
.put(ChatB.class, new ChatB(player))
|
||||
.put(ChatC.class, new ChatC(player))
|
||||
.put(CrashD.class, new CrashD(player))
|
||||
.put(SetbackBlocker.class, new SetbackBlocker(player)) // Must be last class otherwise we can't check while blocking packets
|
||||
.build();
|
||||
|
||||
Reference in new issue
Block a user