1.7 Changes and What They Could Mean

Discussion in 'Plugin Development' started by Doamax, Nov 5, 2013.

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

    Doamax

    With these two I think we will have a lot of fun with "ChatInteractEvent" or "ChatClickNameEvent." Anyone have any ideas how you would use this. Any ideas about what the other changes this update could do?
     
  2. Offline

    CaptainBern Retired Staff

    Doamax I'm pretty sure the clicking on someones name to chat is completly client side and will in no way notify the server about it, I think this is going to be the same for the urls.
     
  3. Offline

    Janmm14

    Doamax
    Players now have a fixed id because minecraft is shiftig over to them for allowing name changes in the future, so storing names is not good in the future.

    CaptainBern
    Players can hover on any text, get an information popup and if they click, a command is sent to the server.

    EDIT by Moderator: merged posts, please use the edit button instead of double posting.
     
    Last edited by a moderator: Jun 5, 2016
  4. Offline

    ZeusAllMighty11 Retired Staff


    How can you be so sure? The way the client detects links may be different than the way it detects player names or achievements or such.
     
  5. Offline

    CaptainBern Retired Staff

    Janmm14 ZeusAllMighty11 I decompiled the server code of 1.7 and I don't see any packet that could transmit this. As for the hover stuff, mojang changed the messages to a json object which contains several keys and values that tell the client how to display it and what to do when the client hovers over it and what to do when he/she clicks. As for the click on playername to send him/her a message, I am pretty sure there will be no packet send to the server, why? Simple, why would they?

    I think it is going to be the same as the urls that are clickable, the server also doesn't get notified when the client clicks on one.
    That being said I wish I am wrong here because if we could detect the click or hover then we get a whole new set of possibilities.
     
    justcool393 likes this.
  6. Offline

    BungeeTheCookie

  7. Offline

    CaptainBern Retired Staff

    BungeeTheCookie A long time ago :p, no I decompiled 1.6 and then just took a clean 1.7 (using jd-gui), putted them both in one folder, then defined what classes in 1.7 are similar to packets in 1.6, so I knew which packet is wich class and then it is just looking around :p.
     
  8. Offline

    ccrama

    1.7 also allows for lore IN chat (when you get an achievement, if you hover over the text saying "ccrama has gotten the achievement [Blah], if you hover over the [blah] it shows Lore). [​IMG]
     
  9. Offline

    BungeeTheCookie

    Seems legit.
     
  10. Offline

    ZeusAllMighty11 Retired Staff


    really? You should be helping update MCP then ;)
     
  11. Offline

    CaptainBern Retired Staff

    ZeusAllMighty11 Oh no, it's not clean enough for that. The end product is just a folder with the classes I assume to be the class now known as Connection, PlayerConnection, Packet, and a new class that stores the packets. If I just was able to find the class where all packets are registered then I could all give them an ID, but thus far I haven't succeed in finding his class :/
     
  12. Offline

    lycano

    Assuming that there is a private message system in development or will go live when a player is identified by its ID then they could use this to send messages privately as PM.

    Some could also send a PM to a player when he is offline (requires a friend list). If this is how its done then i agree. This would be client side.

    But i do believe that (if such system is implemented) then there is also a server method available that can send such messages to a player id which then could be used by a plugin or triggered when interacting with an entity.
     
  13. Offline

    CaptainBern Retired Staff

    lycano It is already, just click on a player in the chat in 1.7 and in your chat bar a /msg <playername> will appear. It seems kinda pointless to notify the server about this so this is why I believe it won't be detectable/changeable. However there is a chance because since 1.7 minecraft is going to use PlayerProfiles instead of the name of a player to identify them.

    So this could mean that when the client clicks on the player name, it sends a packet to the server and then the server will respond by sending this playerprofile as a JSON object. But I do not believe this is the case; because 2 reasons/other possible ways:
    - It could be that when the client receives the online player list or the Packet20NamedEntitySpawn that it caches the PlayerProfile data.
    - Or a more realistic way; when the client clicks on a player name it just puts in /msg <clicked name>. (And what if the clicked player name is a nickname, you say? Well I guess that it detects the name trough the PlayerProfile that in this case is send to the client whenever a player sends a message in the chat.

    If anyone wants to see the packet stuff of 1.7, just ask and I'll put it on mediafire. Don't expect too much of it, I didn't renamed the classes (well I renamed some classes) and it also doesn't contain all packets.
     
  14. Offline

    lycano

    CaptainBern well i could not really look into 1.7 stuff since i do not have a working internet connection at home at the moment but if you say the message is send client side through mojang then there should be an url somewhere in the code that accepts such messages as POST/GET request since its not p2p.
     
  15. Offline

    CaptainBern Retired Staff

    lycano Well, I guess we will have to wait untill the mcp guys did ther magic and we can take a look at all packet classes :p.
     
  16. Offline

    BungeeTheCookie

    All i know is that all of those nms projects will break. Think of all of those server owners. WHY MY PLUGIN NO WORK? Good times, happens every update :)
     
  17. Offline

    lycano

    BungeeTheCookie i fear the day when 1.7 is out. dl.bukkit.org will be down for hours i believe ^^
     
Thread Status:
Not open for further replies.

Share This Page