Class PlayerLootedNumberOfItemsCondition
java.lang.Object
games.stendhal.server.entity.npc.condition.PlayerLootedNumberOfItemsCondition
- All Implemented Interfaces:
ChatCondition
,PreTransitionCondition
@Dev(category=ITEMS_LOOTED,
label="Item?")
public class PlayerLootedNumberOfItemsCondition
extends Object
implements ChatCondition
Checks if a player has looted a minimum number of item(s).
- Author:
- madmetzger
-
Constructor Summary
ConstructorDescriptionPlayerLootedNumberOfItemsCondition(int number, String... item)
Create a new PlayerLootedNumberOfItemsCondition -
Method Summary
-
Constructor Details
-
PlayerLootedNumberOfItemsCondition
Create a new PlayerLootedNumberOfItemsCondition- Parameters:
number
- required number of each itemitem
- list of required items
-
-
Method Details
-
fire
Description copied from interface:PreTransitionCondition
can the transition be done?- Specified by:
fire
in interfaceChatCondition
- Specified by:
fire
in interfacePreTransitionCondition
- Parameters:
player
- player who caused the transitionsentence
- text he/she saidnpc
- the NPC doing the transition- Returns:
- true, if the transition is possible, false otherwise
-
hashCode
public int hashCode() -
equals
-
toString
-