Работа с DATA пакетами

Discussion in 'Разработка плагинов' started by MrPVB, 27/1/17.

  1. This site uses cookies. By continuing to use this site, you are agreeing to our use of cookies. Learn More.
Dismiss Notice
We welcome you on our site. This site is devoted to the Nukkit project and all that is connected with him. Here you can communicate, download plugins, also many other things get acquainted! Register the account right now :3
  1. MrPVB

    MrPVB Пользователь

    Messages:
    5
    Likes Received:
    1
    Minecraft:
    MrPVB
    Пытался поработать с пакетами, и чёт не вышло
    Сделал такой код:
    ((Player) sender).setDataProperty(Player.DATA_SCALE, Player.DATA_TYPE_FLOAT, 0.50);
    По идеи юзер должен уменьшиться, но данная строка не работает, пробывал всякие вариации ,но всё четно.
    В php это выглядит так: $sender->setDataProperty(Player:: DATA_SCALE, Player:: DATA_TYPE_FLOAT, 0.50);
    И всё робит,а в Java некак(
     
  2. Pub4Game

    Pub4Game Модератор всея Nukkit.ru Moderator

    Messages:
    62
    Likes Received:
    32
    Minecraft:
    Pub4Game
    Code:
    ((Player) sender).setDataProperty(new FloatEntityData(Player.DATA_SCALE, 0.50));
     
    anonymous and MrPVB like this.

Share This Page