Package org.spout.vanilla.protocol.msg.entity.pos

Examples of org.spout.vanilla.protocol.msg.entity.pos.EntityTeleportMessage


     * Two scenarios:
     * - The entity moves more than 4 blocks and maybe changes rotation.
     * - The entity moves less than 4 blocks and maybe changes rotation.
     */
    if (force || deltaX > 128 || deltaX < -128 || deltaY > 128 || deltaY < -128 || deltaZ > 128 || deltaZ < -128) {
      messages.add(new EntityTeleportMessage(entity.getId(), newX, newY, newZ, newYaw, newPitch));
      if (force || looked) {
        messages.add(new EntityYawMessage(entity.getId(), newYaw, newPitch));
      }
    } else if (deltaX != 0 || deltaY != 0 || deltaZ != 0 || deltaYaw != 0 || deltaPitch != 0) {
      if (looked) {
View Full Code Here


    int x = buffer.readInt();
    int y = buffer.readInt();
    int z = buffer.readInt();
    int rotation = buffer.readUnsignedByte();
    int pitch = buffer.readUnsignedByte();
    return new EntityTeleportMessage(id, x, y, z, rotation, pitch);
  }
View Full Code Here

TOP

Related Classes of org.spout.vanilla.protocol.msg.entity.pos.EntityTeleportMessage

Copyright © 2018 www.massapicom. All rights reserved.
All source code are property of their respective owners. Java is a trademark of Sun Microsystems, Inc and owned by ORACLE Inc. Contact coftware#gmail.com.