Class DefenseItem
java.lang.Object
model.item.Item
model.item.DefenseItem
- All Implemented Interfaces:
Applicable
Increases the user's defense. The effect is removed after the battle ends (reset).
-
Field Summary
Fields -
Constructor Summary
Constructors -
Method Summary
Modifier and TypeMethodDescriptionvoidIncreases the target entity's defense.Returns a description of the effect for display in the UI.
-
Field Details
-
defBonus
private final int defBonusDefense bonus to apply.
-
-
Constructor Details
-
DefenseItem
public DefenseItem(int defBonus) create DefenseItem- Parameters:
defBonus- Defense bonus to apply.
-
-
Method Details
-
apply
Increases the target entity's defense.- Specified by:
applyin interfaceApplicable- Specified by:
applyin classItem- Parameters:
target- Entity to buff
-
getEffectDescription
Returns a description of the effect for display in the UI.- Specified by:
getEffectDescriptionin interfaceApplicable- Specified by:
getEffectDescriptionin classItem- Returns:
- Effect description text
-