Fixed onDisable throwing an error.
This commit is contained in:
parent
8967d5dfd4
commit
ff7caf015e
4
pom.xml
4
pom.xml
@ -13,8 +13,8 @@
|
||||
<groupId>org.apache.maven.plugins</groupId>
|
||||
<artifactId>maven-compiler-plugin</artifactId>
|
||||
<configuration>
|
||||
<source>7</source>
|
||||
<target>7</target>
|
||||
<source>8</source>
|
||||
<target>8</target>
|
||||
</configuration>
|
||||
</plugin>
|
||||
</plugins>
|
||||
|
@ -44,15 +44,13 @@ public class Main extends HabboPlugin implements EventListener {
|
||||
Field f = PacketManager.class.getDeclaredField("incoming");
|
||||
f.setAccessible(true);
|
||||
THashMap<Integer, Class<? extends MessageHandler>> incoming = (THashMap<Integer, Class<? extends MessageHandler>>)f.get(packetManager);
|
||||
incoming.remove(Incoming.CameraRoomThumbnailEvent);
|
||||
incoming.remove(Incoming.CameraPublishToWebEvent);
|
||||
incoming.remove(Incoming.CameraPurchaseEvent);
|
||||
incoming.remove(Incoming.CameraRoomThumbnailEvent);
|
||||
packetManager.registerHandler(Incoming.CameraRoomPictureEvent, CameraRoomPictureEvent.class);
|
||||
packetManager.registerHandler(Incoming.CameraPublishToWebEvent, CameraPublishToWebEvent.class);
|
||||
packetManager.registerHandler(Incoming.CameraPurchaseEvent, CameraPurchaseEvent.class);
|
||||
packetManager.registerHandler(Incoming.CameraRoomThumbnailEvent, CameraRoomThumbnailEvent.class);
|
||||
}
|
||||
incoming.remove(Incoming.CameraRoomPictureEvent, CameraRoomPictureEvent.class);
|
||||
incoming.remove(Incoming.CameraPublishToWebEvent, CameraPublishToWebEvent.class);
|
||||
incoming.remove(Incoming.CameraPurchaseEvent, CameraPurchaseEvent.class);
|
||||
incoming.remove(Incoming.CameraRoomThumbnailEvent, CameraRoomThumbnailEvent.class);
|
||||
Emulator.getLogging().logStart("[Apollyon] Bye Bye.");
|
||||
|
||||
}
|
||||
|
||||
|
||||
@EventHandler
|
||||
|
Loading…
Reference in New Issue
Block a user