Solved Event triggered when up or down arrow is pressed in chat.

Discussion in 'Plugin Development' started by InspiredOne, Aug 29, 2013.

Thread Status:
Not open for further replies.
  1. Offline

    InspiredOne

    I know that bukkit cannot detect any key that is pressed, but I do know that there are certain events that do have key presses linked to them: namely, the PlayerChatTabCompleteEvent. The existence of this event makes me hopeful that bukkit also has a chat event for when the player hits up or down in the chat bar to scroll through previous sent messages. I've looked through the API and I haven't been able to find it, but I thought I would check here just to be sure.

    Question: Is there a bukkit event that is triggered when the player hits up and down to scroll through previous chat messages?
     
  2. Offline

    The_Doctor_123

    Yeah, I'm 90% sure that doesn't exist. :/
     
  3. Offline

    Ghilliedrone

    No there isn't :(
     
  4. Offline

    MrSoLegitimate

    That's client sided man, has nothing to do with bukkit.
     
  5. Offline

    InspiredOne

    What is the difference between this and hitting the Tab key?
     
  6. Offline

    Drkmaster83

    Packets, I'm pretty sure. There's a packet somewhere called Packet<Number>ChatTabComplete or something to that effect.
     
  7. Offline

    Axe2760

    InspiredOne http://wiki.vg

    Seems as though it would be a client feature. There really isn't too much that the server can do about this, the client doesn't send a packet when using the up arrow.

    Edit: Half-ninja'd by Drkmaster83 xD
     
  8. Offline

    Drkmaster83

    Ah, I found this in my library of infinite knowledge that I don't own but what I would like to pretend I do.
     
  9. Offline

    InspiredOne

  10. Offline

    The_Doctor_123

  11. Offline

    chasechocolate

  12. Offline

    The_Doctor_123

    The client actually sends data when you scroll up/down in the chat? That seems quite worthless, to me..
     
  13. Offline

    InspiredOne

    Yeah, I've decided to listen to the TabComplete event. I'm using it to cycle through options in a menu (not its intended purpose but serves what I need it to do) I created this thread to make sure I wasn't overlooking something obvious that would make my life a little easier.



    No, that data is not sent, but when a player hits Tab in chat, there is a packet sent to the server to retrieve the list of Strings that match the player's substring. There is also a function that allows players to retype previous messages really fast by hitting the up arrow. This, as it turns out, is all client-side, much to my dismay. At any rate, the TabComplete event is suitable for what I need to do, so I can use it.
     
Thread Status:
Not open for further replies.

Share This Page