public class Fortune extends java.lang.Object implements Attributes
| Constructor and Description |
|---|
Fortune(java.lang.String name,
int hpBonus,
int armor,
int hitModifier)
Basic constructor assuming no DamageDice replacement
|
Fortune(java.lang.String name,
int hpBonus,
int armor,
int hitModifier,
DiceType type)
Constructor with a damage dice replacement by DiceType type
|
| Modifier and Type | Method and Description |
|---|---|
int |
getArmor()
Return the amount of bonus to the knights armor
|
DiceType |
getDamageDie()
Returns the replacement damage dice for the knight.
|
int |
getHitModifier()
Returns the the bonus to the knights hit modifier.
|
int |
getMaxHP()
return the amount of bonus to the knights maxHP
|
java.lang.String |
getName()
returns the name of the fortune card - often named after the knightly virtues.
|
java.lang.String |
toString()
Returns a nicely formatted String value of the fortune.
|
public Fortune(java.lang.String name,
int hpBonus,
int armor,
int hitModifier)
name - name of fortune cardhpBonus - hp bonusarmor - armor bonushitModifier - to hit bonuspublic Fortune(java.lang.String name,
int hpBonus,
int armor,
int hitModifier,
DiceType type)
name - name of fortune cardhpBonus - hp bonusarmor - armor bonushitModifier - to hit bonustype - the damage dice replacement valuepublic int getArmor()
getArmor in interface Attributespublic int getMaxHP()
getMaxHP in interface Attributespublic DiceType getDamageDie()
getDamageDie in interface Attributespublic int getHitModifier()
getHitModifier in interface Attributespublic java.lang.String getName()
public java.lang.String toString()
+======================+ |Nobility | |HP Bonus: +10| |AC Bonus: +1| |Hit Bonus: +1| |Damage Adj: -| +======================+Spacing is -22s for the name, 12s for the HP Bonus, 12s for the AC bonus, 11s for the hit bonus and 10s for the damage adj.
toString in class java.lang.Object