@Override public Item sampleOutput(ArrayList<Item> ingredients) { if (!testIngredients(ingredients)) return null; return new Blandfruit().cook((Seed) ingredients.get(1)); } }
@Override public void reset() { if (potionAttrib != null) imbuePotion(potionAttrib); else super.reset(); }
@Override public void activate( Char ch ) { Dungeon.level.drop( new Blandfruit(), pos ).sprite.drop(); }
Seed seed = (Seed) ingredients.get(1); if (fruit.quantity() >= 1 && fruit.potionAttrib == null && seed.quantity() >= 1){
@Override public void activate( Char ch ) { Dungeon.level.drop( new Blandfruit(), pos ).sprite.drop(); }
Seed seed = (Seed) ingredients.get(1); if (fruit.quantity() >= 1 && fruit.potionAttrib == null && seed.quantity() >= 1){
@Override public Item sampleOutput(ArrayList<Item> ingredients) { if (!testIngredients(ingredients)) return null; return new Blandfruit().cook((Seed) ingredients.get(1)); } }
public Item cook(Seed seed){ try { return imbuePotion(Potion.SeedToPotion.types.get(seed.getClass()).newInstance()); } catch (Exception e) { ShatteredPixelDungeon.reportException(e); return null; } }
result.add(null); result.add(new QuickRecipe( new Blandfruit.CookFruit(), new ArrayList<>(Arrays.asList(new Blandfruit(), new Plant.Seed.PlaceHolder())), new Blandfruit(){
@Override public Item brew(ArrayList<Item> ingredients) { if (!testIngredients(ingredients)) return null; ingredients.get(0).quantity(ingredients.get(0).quantity() - 1); ingredients.get(1).quantity(ingredients.get(1).quantity() - 1); return new Blandfruit().cook((Seed) ingredients.get(1)); }
@Override public void reset() { if (potionAttrib != null) imbuePotion(potionAttrib); else super.reset(); }
result.add(null); result.add(new QuickRecipe( new Blandfruit.CookFruit(), new ArrayList<>(Arrays.asList(new Blandfruit(), new Plant.Seed.PlaceHolder())), new Blandfruit(){
@Override public Item brew(ArrayList<Item> ingredients) { if (!testIngredients(ingredients)) return null; ingredients.get(0).quantity(ingredients.get(0).quantity() - 1); ingredients.get(1).quantity(ingredients.get(1).quantity() - 1); return new Blandfruit().cook((Seed) ingredients.get(1)); }
public Item cook(Seed seed){ try { return imbuePotion(Potion.SeedToPotion.types.get(seed.getClass()).newInstance()); } catch (Exception e) { ShatteredPixelDungeon.reportException(e); return null; } }
"_-_ Lloyd's beacon has been replaced by alchemy recipes, Cape of Thorns will likely return in some form in the future.")); changes.addButton( new ChangeButton(new Blandfruit(), "Blandfruit has been changed to be more consistent with potions.\n\n" + "All blandfruit types now exactly mimic their potion counterparts, there are now no blandfruit-exclusive effects.\n\n" + "Dev commentary will be added here in the future.")); changes.addButton( new ChangeButton(new Blandfruit(), "Players who chance upon gardens or who get lucky while trampling grass may come across a new plant: the _Blandfruit._\n\n" + "As the name implies, the fruit from this plant is pretty unexceptional, and will barely do anything for you on its own. Perhaps there is some way to prepare the fruit with another ingredient..."));
@Override public void restoreFromBundle(Bundle bundle) { super.restoreFromBundle(bundle); if (bundle.contains(POTIONATTRIB)) { imbuePotion((Potion) bundle.get(POTIONATTRIB)); } }
"_-_ Lloyd's beacon has been replaced by alchemy recipes, Cape of Thorns will likely return in some form in the future.")); changes.addButton( new ChangeButton(new Blandfruit(), "Blandfruit has been changed to be more consistent with potions.\n\n" + "All blandfruit types now exactly mimic their potion counterparts, there are now no blandfruit-exclusive effects.\n\n" + "Dev commentary will be added here in the future.")); changes.addButton( new ChangeButton(new Blandfruit(), "Players who chance upon gardens or who get lucky while trampling grass may come across a new plant: the _Blandfruit._\n\n" + "As the name implies, the fruit from this plant is pretty unexceptional, and will barely do anything for you on its own. Perhaps there is some way to prepare the fruit with another ingredient..."));
@Override public void restoreFromBundle(Bundle bundle) { super.restoreFromBundle(bundle); if (bundle.contains(POTIONATTRIB)) { imbuePotion((Potion) bundle.get(POTIONATTRIB)); } }