V0.2.0: Horn of Plenty number tweaking

This commit is contained in:
Evan Debenham 2014-08-28 16:37:16 -04:00
parent 8733e99e03
commit 116d2b501f
8 changed files with 17 additions and 13 deletions

View File

@ -131,12 +131,16 @@ public class HornOfPlenty extends Artifact {
public boolean act() {
if (charge < chargeCap) {
partialCharge += (1f/(200-level));
//generates 0.2 food value every round, +0.02 value per level
//to a max of 0.8 food value per round (0.2+0.6, at level 30)
partialCharge += (1f*(0.2+(0.02*level)));
if (partialCharge >= 1) {
//charge is in increments of 36 food value.
if (partialCharge >= 36) {
charge++;
//TODO: change sprite based on fullness.
partialCharge -= 1;
//we'll do it at 3/0, 7/10, and 10/10, to relate to food items.
partialCharge -= 36;
if (charge == chargeCap){
GLog.p("Your horn is full of food.");
partialCharge = 0;
@ -158,7 +162,7 @@ public class HornOfPlenty extends Artifact {
public void onSelect( Item item ) {
if (item != null && item instanceof Food) {
if (item instanceof Blandfruit && ((Blandfruit) item).potionAttrib == null){
GLog.w("the horn rejects your unprepared blandfruit.");
GLog.w("your horn rejects the unprepared blandfruit.");
} else {
Hero hero = Dungeon.hero;
hero.sprite.operate( hero.pos );
@ -166,8 +170,8 @@ public class HornOfPlenty extends Artifact {
hero.spend( TIME_TO_EAT );
curItem.level += ((Food)item).hornValue;
if (curItem.level >= 150){
curItem.level = 150;
if (curItem.level >= 30){
curItem.level = 30;
GLog.p("your horn has consumed all the food it can!");
} else
GLog.p("the horn consumes your food offering and grows in strength!");

View File

@ -37,7 +37,7 @@ public class Blandfruit extends Food {
stackable = false;
image = ItemSpriteSheet.BLANDFRUIT;
energy = (Hunger.STARVING - Hunger.HUNGRY)/2;
hornValue = 15;
hornValue = 3; //only applies when blandfruit is cooked
}
@Override

View File

@ -26,7 +26,7 @@ public class ChargrilledMeat extends Food {
name = "chargrilled meat";
image = ItemSpriteSheet.STEAK;
energy = Hunger.STARVING - Hunger.HUNGRY;
hornValue = 5;
hornValue = 1;
}
@Override

View File

@ -41,7 +41,7 @@ public class Food extends Item {
public float energy = Hunger.HUNGRY;
public String message = "That food tasted delicious!";
public int hornValue = 15;
public int hornValue = 3;
{
stackable = true;

View File

@ -37,7 +37,7 @@ public class FrozenCarpaccio extends Food {
name = "frozen carpaccio";
image = ItemSpriteSheet.CARPACCIO;
energy = Hunger.STARVING - Hunger.HUNGRY;
hornValue = 5;
hornValue = 1;
}
@Override

View File

@ -36,7 +36,7 @@ public class MysteryMeat extends Food {
image = ItemSpriteSheet.MEAT;
energy = Hunger.STARVING - Hunger.HUNGRY;
message = "That food tasted... strange.";
hornValue = 5;
hornValue = 1;
}
@Override

View File

@ -27,7 +27,7 @@ public class OverpricedRation extends Food {
image = ItemSpriteSheet.OVERPRICED;
energy = Hunger.STARVING - Hunger.HUNGRY;
message = "That food tasted ok.";
hornValue = 5;
hornValue = 1;
}
@Override

View File

@ -26,7 +26,7 @@ public class Pasty extends Food {
name = "pasty";
image = ItemSpriteSheet.PASTY;
energy = Hunger.STARVING;
hornValue = 25;
hornValue = 5;
}
@Override