Advertisement
  1. This site uses cookies. By continuing to use this site, you are agreeing to our use of cookies. Learn More.

New API TextPacket class

Comments in 'Plugin Development' started by aliuly, May 1, 2015.

  1. aliuly
    Offline

    aliuly Notable Member Plugin Developer

    Joined:
    Feb 8, 2014
    Posts:
    1,086
    Plugins:
    17
    I was looking at the new API documentation, and saw that the TextPacket class defines the following:

    PHP:
    const TYPE_RAW 0
    const TYPE_CHAT 1
    const TYPE_TRANSLATION 2
    const TYPE_POPUP 3
    const TYPE_TIP 4

    So, chat and popup seem to be self explanatory. I am wondering what is the Tip for?

    Don't know what Raw and Translation are supposed to mean, either.
  2. PEMapModder
    Offline

    PEMapModder Notable Member Plugin Developer

    Joined:
    Oct 9, 2013
    Posts:
    7,294
    Plugins:
    11
    Minecraft User:
    PEMapModder
    Popup, tip and raw are sendPopup(), sendTip() and sendMessage() in the player class respectively.
    Chat is only used for chat packets sent from the client.
    Translation is when the packet message only contains a translation ID and lets the client translate it.
  3. aliuly
    Offline

    aliuly Notable Member Plugin Developer

    Joined:
    Feb 8, 2014
    Posts:
    1,086
    Plugins:
    17
    Where are the tips displayed?
  4. aliuly
    Offline

    aliuly Notable Member Plugin Developer

    Joined:
    Feb 8, 2014
    Posts:
    1,086
    Plugins:
    17
    Where are the tips displayed?
  5. PEMapModder
    Offline

    PEMapModder Notable Member Plugin Developer

    Joined:
    Oct 9, 2013
    Posts:
    7,294
    Plugins:
    11
    Minecraft User:
    PEMapModder
    Test it. I want to know too.
  6. xpyctum
    Offline

    xpyctum Active Member Plugin Developer

    Joined:
    Jan 13, 2014
    Posts:
    292
    Plugins:
    4
    Minecraft User:
    tylerdisney
    higher than popupMessage
  7. shoghicp
    Offline

    shoghicp Staff Member PocketMine Team

    Joined:
    Aug 22, 2013
    Posts:
    433
    Plugins:
    14
    Minecraft User:
    shoghicp
    Popup is the item name message, tip the message that shows up when you enter a boat/minecart
    Falk, PixelGuy75, iJoshuaHD and 2 others like this.

Share This Page

Advertisement