|
||||||||||
| PREV CLASS NEXT CLASS | FRAMES NO FRAMES | |||||||||
| SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD | |||||||||
java.lang.Objectnet.sf.magicproject.clickable.ability.Ability
net.sf.magicproject.clickable.ability.UserAbility
net.sf.magicproject.clickable.ability.TriggeredAbility
net.sf.magicproject.clickable.ability.ReplacementAbility
public class ReplacementAbility
TODO is it important to keep cost ?
| Field Summary |
|---|
| Fields inherited from class net.sf.magicproject.clickable.ability.Ability |
|---|
optimizer, priority |
| Constructor Summary | |
|---|---|
ReplacementAbility(java.io.InputStream inputFile,
MCard card)
Creates a new instance of ReplacementAbility Structure of InputStream : Data[size] name name + '\0' [...] |
|
| Method Summary | |
|---|---|
Ability |
clone(MCard container)
return a copy of this ability TODO remove param container since it is not used in this constructor As default, return null |
boolean |
hasHighPriority()
Indicates wether this ability is choosen in priority to the others without this tag. |
boolean |
isAutoResolve()
Indicates if this ability is immediatly after it has been added to the stack. |
boolean |
isHidden()
Indicates if this ability is immediatly after it has been added to the stack (like isAutoResolve), and if no information is displayed or prompted to the users. |
boolean |
isMatching()
compare the current event to the event activating this ability. |
void |
registerToManager()
Add this ability to the looked for events. |
void |
removeFromManager()
Remove from the event manager this listener. |
void |
resolveStack()
called when the stack is resolving |
boolean |
triggerIt(ContextEventListener context)
called when this ability is going to be triggered This method would add this ability to the triggered zone, or perform another play action |
| Methods inherited from class net.sf.magicproject.clickable.ability.TriggeredAbility |
|---|
getAbilityTitle, getDelayedCard, getLog, isDelayedAbility, setDelayedCard, toHtmlString |
| Methods inherited from class net.sf.magicproject.clickable.ability.UserAbility |
|---|
actionList, checkObjectActions, checkTargetActions, clickOn, effectList, eventComing, getCard, manaNeeded, mouseClicked, recheckTargets, toString |
| Methods inherited from class net.sf.magicproject.clickable.ability.Ability |
|---|
addLinkedAbility, equals, getCardCopy, getController, getName, getPictureName, getTargetable, getTriggeredClone, getTriggeredCloneChoice, hashCode, isPlayAsSpell, optimizeRegisterToManager, setEvent |
| Methods inherited from class java.lang.Object |
|---|
equals, getClass, notify, notifyAll, wait, wait, wait |
| Constructor Detail |
|---|
public ReplacementAbility(java.io.InputStream inputFile,
MCard card)
throws java.io.IOException
inputFile - card -
java.io.IOException - if error occurred during the reading process from the specified
input stream| Method Detail |
|---|
public boolean triggerIt(ContextEventListener context)
Ability
triggerIt in class UserAbilitycontext - the context needed by event activated
public void resolveStack()
ResolveStackHandler
resolveStack in interface ResolveStackHandlerresolveStack in class AbilityStackManager.resolveStack()public Ability clone(MCard container)
Ability
clone in class TriggeredAbilitycontainer - is not used here
public boolean isMatching()
Ability
isMatching in class TriggeredAbilitypublic void removeFromManager()
Unregisterable
removeFromManager in interface UnregisterableremoveFromManager in class TriggeredAbilitypublic final boolean isAutoResolve()
ResolveStackHandler
isAutoResolve in interface ResolveStackHandlerisAutoResolve in class Abilitypublic final boolean isHidden()
ResolveStackHandler
isHidden in interface ResolveStackHandlerisHidden in class AbilityResolveStackHandler.isAutoResolve()public final boolean hasHighPriority()
Ability
hasHighPriority in class Abilitypublic void registerToManager()
Ability
registerToManager in class Ability
|
||||||||||
| PREV CLASS NEXT CLASS | FRAMES NO FRAMES | |||||||||
| SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD | |||||||||