Beispiel #1
0
  /** Enable or disable a entity flag, see getEntityFlag to read the know flags. */
  protected void setFlag(int par1, boolean par2) {
    byte byte0 = dataWatcher.getWatchableObjectByte(0);

    if (par2) {
      dataWatcher.updateObject(0, Byte.valueOf((byte) (byte0 | 1 << par1)));
    } else {
      dataWatcher.updateObject(0, Byte.valueOf((byte) (byte0 & ~(1 << par1))));
    }
  }
Beispiel #2
0
 public void setAir(int par1) {
   dataWatcher.updateObject(1, Short.valueOf((short) par1));
 }