Package net.minecraft.server

Examples of net.minecraft.server.WatchableObject


   * @param type of data to get
   * @param def to return on failure
   * @return data, or def if not found
   */
  public <K> K getWatchedData(int index, Class<K> type, K def) {
    WatchableObject object = (WatchableObject) DataWatcherRef.read.invoke(h().getDataWatcher(), index);
    if (object == null) {
      return def;
    }
    return Conversion.convert(object.b(), type, def);
  }
View Full Code Here

TOP

Related Classes of net.minecraft.server.WatchableObject

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.