Villager
public interface Merchant
Modifier and Type | Method | Description |
---|---|---|
MerchantRecipe |
getRecipe(int i) |
Get the recipe at a certain index of this merchant's trade list.
|
int |
getRecipeCount() |
Get the number of trades this merchant currently has available.
|
java.util.List<MerchantRecipe> |
getRecipes() |
Get a list of trades currently available from this merchant.
|
HumanEntity |
getTrader() |
Gets the player this merchant is trading with, or null if it is not
currently trading.
|
boolean |
isTrading() |
Gets whether this merchant is currently trading.
|
void |
setRecipe(int i,
MerchantRecipe recipe) |
Set the recipe at a certain index of this merchant's trade list.
|
void |
setRecipes(java.util.List<MerchantRecipe> recipes) |
Set the list of trades currently available from this merchant.
|
java.util.List<MerchantRecipe> getRecipes()
void setRecipes(java.util.List<MerchantRecipe> recipes)
recipes
- a list of recipesMerchantRecipe getRecipe(int i) throws java.lang.IndexOutOfBoundsException
i
- the indexjava.lang.IndexOutOfBoundsException
void setRecipe(int i, MerchantRecipe recipe) throws java.lang.IndexOutOfBoundsException
i
- the indexrecipe
- the recipejava.lang.IndexOutOfBoundsException
int getRecipeCount()
boolean isTrading()
HumanEntity getTrader()
Copyright © 2018. All rights reserved.