當前位置: 首頁>>代碼示例>>Java>>正文


Java Controller類代碼示例

本文整理匯總了Java中li.cil.oc.api.nanomachines.Controller的典型用法代碼示例。如果您正苦於以下問題:Java Controller類的具體用法?Java Controller怎麽用?Java Controller使用的例子?那麽, 這裏精選的類代碼示例或許可以為您提供幫助。


Controller類屬於li.cil.oc.api.nanomachines包,在下文中一共展示了Controller類的4個代碼示例,這些例子默認根據受歡迎程度排序。您可以為喜歡或者感覺有用的代碼點讚,您的評價將有助於係統推薦出更棒的Java代碼示例。

示例1: getController

import li.cil.oc.api.nanomachines.Controller; //導入依賴的package包/類
/**
 * Get the nanomachine controller of the specified player.
 * <p/>
 * If the player has a controller installed, this will initialize the
 * controller if it has not already been loaded. If the player has no
 * controller, this will return <tt>null</tt>.
 *
 * @param player the player to get the controller for.
 * @return the controller for the specified player.
 */
public static Controller getController(EntityPlayer player) {
    if (API.nanomachines != null)
        return API.nanomachines.getController(player);
    return null;
}
 
開發者ID:Herobone,項目名稱:HeroUtils,代碼行數:16,代碼來源:Nanomachines.java

示例2: installController

import li.cil.oc.api.nanomachines.Controller; //導入依賴的package包/類
/**
 * Install a controller for the specified player if it doesn't already
 * have one.
 * <p/>
 * This will also initialize the controller if it has not already been
 * initialized.
 *
 * @param player the player to install a nanomachine controller for.
 */
public static Controller installController(EntityPlayer player) {
    if (API.nanomachines != null)
        return API.nanomachines.installController(player);
    return null;
}
 
開發者ID:Herobone,項目名稱:HeroUtils,代碼行數:15,代碼來源:Nanomachines.java

示例3: getController

import li.cil.oc.api.nanomachines.Controller; //導入依賴的package包/類
/**
 * Get the nanomachine controller of the specified player.
 * <p/>
 * If the player has a controller installed, this will initialize the
 * controller if it has not already been loaded. If the player has no
 * controller, this will return <tt>null</tt>.
 *
 * @param player the player to get the controller for.
 * @return the controller for the specified player.
 */
Controller getController(EntityPlayer player);
 
開發者ID:Herobone,項目名稱:HeroUtils,代碼行數:12,代碼來源:NanomachinesAPI.java

示例4: installController

import li.cil.oc.api.nanomachines.Controller; //導入依賴的package包/類
/**
 * Install a controller for the specified player if it doesn't already
 * have one.
 * <p/>
 * This will also initialize the controller if it has not already been
 * initialized.
 *
 * @param player the player to install a nanomachine controller for.
 * @return the controller for the specified player.
 */
Controller installController(EntityPlayer player);
 
開發者ID:Herobone,項目名稱:HeroUtils,代碼行數:12,代碼來源:NanomachinesAPI.java


注:本文中的li.cil.oc.api.nanomachines.Controller類示例由純淨天空整理自Github/MSDocs等開源代碼及文檔管理平台,相關代碼片段篩選自各路編程大神貢獻的開源項目,源碼版權歸原作者所有,傳播和使用請參考對應項目的License;未經允許,請勿轉載。