Java 类net.minecraft.network.packet.Packet34EntityTeleport 实例源码

项目:RuneCraftery    文件:NetClientHandler.java   
public void handleEntityTeleport(Packet34EntityTeleport par1Packet34EntityTeleport)
{
    Entity entity = this.getEntityByID(par1Packet34EntityTeleport.entityId);

    if (entity != null)
    {
        entity.serverPosX = par1Packet34EntityTeleport.xPosition;
        entity.serverPosY = par1Packet34EntityTeleport.yPosition;
        entity.serverPosZ = par1Packet34EntityTeleport.zPosition;
        double d0 = (double)entity.serverPosX / 32.0D;
        double d1 = (double)entity.serverPosY / 32.0D + 0.015625D;
        double d2 = (double)entity.serverPosZ / 32.0D;
        float f = (float)(par1Packet34EntityTeleport.yaw * 360) / 256.0F;
        float f1 = (float)(par1Packet34EntityTeleport.pitch * 360) / 256.0F;
        entity.setPositionAndRotation2(d0, d1, d2, f, f1, 3);
    }
}
项目:BetterNutritionMod    文件:NetClientHandler.java   
public void handleEntityTeleport(Packet34EntityTeleport par1Packet34EntityTeleport)
{
    Entity entity = this.getEntityByID(par1Packet34EntityTeleport.entityId);

    if (entity != null)
    {
        entity.serverPosX = par1Packet34EntityTeleport.xPosition;
        entity.serverPosY = par1Packet34EntityTeleport.yPosition;
        entity.serverPosZ = par1Packet34EntityTeleport.zPosition;
        double d0 = (double)entity.serverPosX / 32.0D;
        double d1 = (double)entity.serverPosY / 32.0D + 0.015625D;
        double d2 = (double)entity.serverPosZ / 32.0D;
        float f = (float)(par1Packet34EntityTeleport.yaw * 360) / 256.0F;
        float f1 = (float)(par1Packet34EntityTeleport.pitch * 360) / 256.0F;
        entity.setPositionAndRotation2(d0, d1, d2, f, f1, 3);
    }
}
项目:RuneCraftery    文件:NetClientHandler.java   
public void func_72512_a(Packet34EntityTeleport p_72512_1_) {
   Entity var2 = this.func_72545_a(p_72512_1_.field_73319_a);
   if(var2 != null) {
      var2.field_70118_ct = p_72512_1_.field_73317_b;
      var2.field_70117_cu = p_72512_1_.field_73318_c;
      var2.field_70116_cv = p_72512_1_.field_73315_d;
      double var3 = (double)var2.field_70118_ct / 32.0D;
      double var5 = (double)var2.field_70117_cu / 32.0D + 0.015625D;
      double var7 = (double)var2.field_70116_cv / 32.0D;
      float var9 = (float)(p_72512_1_.field_73316_e * 360) / 256.0F;
      float var10 = (float)(p_72512_1_.field_73314_f * 360) / 256.0F;
      var2.func_70056_a(var3, var5, var7, var9, var10, 3);
   }
}
项目:forge_world_downloader    文件:WDLNetClientHandler.java   
@Override
public void handleEntityTeleport(Packet34EntityTeleport par1Packet34EntityTeleport)
{
    nch.handleEntityTeleport(par1Packet34EntityTeleport);       
}
项目:RuneCraftery    文件:NetHandler.java   
public void func_72512_a(Packet34EntityTeleport p_72512_1_) {
   this.func_72509_a(p_72512_1_);
}