コード例 #1
0
 public void func_994_a(Entity entity, AxisAlignedBB axisalignedbb, List list) {
   int i = MathHelper.func_1108_b((axisalignedbb.field_1697_b - 2D) / 16D);
   int j = MathHelper.func_1108_b((axisalignedbb.field_1702_e + 2D) / 16D);
   if (i < 0) {
     i = 0;
   }
   if (j >= field_1528_m.length) {
     j = field_1528_m.length - 1;
   }
   for (int k = i; k <= j; k++) {
     List list1 = field_1528_m[k];
     for (int l = 0; l < list1.size(); l++) {
       Entity entity1 = (Entity) list1.get(l);
       if (entity1 == entity || !entity1.field_601_au.func_1178_a(axisalignedbb)) {
         continue;
       }
       list.add(entity1);
       Entity aentity[] = entity1.func_40048_X();
       if (aentity == null) {
         continue;
       }
       for (int i1 = 0; i1 < aentity.length; i1++) {
         Entity entity2 = aentity[i1];
         if (entity2 != entity && entity2.field_601_au.func_1178_a(axisalignedbb)) {
           list.add(entity2);
         }
       }
     }
   }
 }
コード例 #2
0
 public void func_1000_a(Entity entity) {
   field_1523_r = true;
   int i = MathHelper.func_1108_b(entity.field_611_ak / 16D);
   int j = MathHelper.func_1108_b(entity.field_609_am / 16D);
   if (i != field_1531_j || j != field_1530_k) {
     System.out.println(
         (new StringBuilder()).append("Wrong location! ").append(entity).toString());
     Thread.dumpStack();
   }
   int k = MathHelper.func_1108_b(entity.field_610_al / 16D);
   if (k < 0) {
     k = 0;
   }
   if (k >= field_1528_m.length) {
     k = field_1528_m.length - 1;
   }
   entity.field_621_aZ = true;
   entity.field_657_ba = field_1531_j;
   entity.field_656_bb = k;
   entity.field_654_bc = field_1530_k;
   field_1528_m[k].add(entity);
 }
コード例 #3
0
 public void func_1013_a(Class class1, AxisAlignedBB axisalignedbb, List list) {
   int i = MathHelper.func_1108_b((axisalignedbb.field_1697_b - 2D) / 16D);
   int j = MathHelper.func_1108_b((axisalignedbb.field_1702_e + 2D) / 16D);
   if (i < 0) {
     i = 0;
   } else if (i >= field_1528_m.length) {
     i = field_1528_m.length - 1;
   }
   if (j >= field_1528_m.length) {
     j = field_1528_m.length - 1;
   } else if (j < 0) {
     j = 0;
   }
   for (int k = i; k <= j; k++) {
     List list1 = field_1528_m[k];
     for (int l = 0; l < list1.size(); l++) {
       Entity entity = (Entity) list1.get(l);
       if (class1.isAssignableFrom(entity.getClass())
           && entity.field_601_au.func_1178_a(axisalignedbb)) {
         list.add(entity);
       }
     }
   }
 }