mirror of
https://github.com/KAMKEEL/CustomNPC-Plus.git
synced 2026-11-12 13:07:29 +00:00
Added the repeatKey field to KeyEvent, distinguishing whether the event was triggered by the key being held down or the first press.
This commit is contained in:
1 parent
4c0ff9bf2e
commit
5c9424bac8
4 files changed
+13
-9
No files matched your search
@@ -69,6 +69,7 @@ public class PacketHandlerPlayer{
|
||||
boolean isShiftPressed = buffer.readBoolean();
|
||||
boolean isAltPressed = buffer.readBoolean();
|
||||
boolean isMetaPressed = buffer.readBoolean();
|
||||
boolean repeatKey = buffer.readBoolean();
|
||||
boolean buttonDown = buffer.readBoolean();
|
||||
|
||||
String ints = Server.readString(buffer);
|
||||
@@ -88,7 +89,7 @@ public class PacketHandlerPlayer{
|
||||
keysDown = new int[0];
|
||||
}
|
||||
|
||||
EventHooks.onPlayerKeyPressed(player, button, isCtrlPressed, isShiftPressed, isAltPressed, isMetaPressed, buttonDown, keysDown);
|
||||
EventHooks.onPlayerKeyPressed(player, button, isCtrlPressed, isShiftPressed, isAltPressed, isMetaPressed, repeatKey, buttonDown, keysDown);
|
||||
}
|
||||
else if(type == EnumPlayerPacket.MouseClicked) {
|
||||
if(ScriptController.Instance.languages.isEmpty()) {
|
||||
|
||||
Reference in new issue
Block a user