mirror of
https://gitlab.com/phoenix-dvpmt/mmoitems.git
synced 2025-01-03 06:37:47 +01:00
Fixed dupe bug
Fixed null pointer error Pray to build bot this builds...
This commit is contained in:
parent
028b2161a2
commit
9332aeb17d
@ -50,11 +50,11 @@ public class CraftingRecipe extends Recipe {
|
||||
* yaml format is 'output-item: false' under options
|
||||
*/
|
||||
public boolean isItemRecipe() {
|
||||
return config.getConfigurationSection("options").getBoolean("output-item", true);
|
||||
return config.getBoolean("options.output-item", true);
|
||||
}
|
||||
|
||||
public boolean isSilent() {
|
||||
return config.getConfigurationSection("options").getBoolean("silent-craft", false);
|
||||
return config.getBoolean("options.silent-craft", false);
|
||||
}
|
||||
|
||||
public ConfigMMOItem getOutput() {
|
||||
|
@ -12,7 +12,7 @@ public class CommandTrigger extends Trigger {
|
||||
super("command");
|
||||
|
||||
config.validate("format");
|
||||
player = config.getBoolean("player");
|
||||
player = config.getBoolean("player", false);
|
||||
command = config.getString("format");
|
||||
}
|
||||
|
||||
|
@ -189,10 +189,12 @@ public class CraftingStationView extends PluginInventory {
|
||||
data.getPlayer().playSound(data.getPlayer().getLocation(), Sound.ENTITY_EXPERIENCE_ORB_PICKUP, 1, 1);
|
||||
if (recipe.isItemRecipe())
|
||||
new SmartGive(data.getPlayer()).give(craftedItem);
|
||||
} else
|
||||
}
|
||||
else {
|
||||
data.getPlayer().playSound(data.getPlayer().getLocation(), Sound.ENTITY_EXPERIENCE_ORB_PICKUP, 1, 1);
|
||||
for (Ingredient ingredient : craft.getRecipe().getIngredients())
|
||||
new SmartGive(data.getPlayer()).give(ingredient.generateItemStack());
|
||||
}
|
||||
|
||||
updateData();
|
||||
open();
|
||||
|
Loading…
Reference in New Issue
Block a user