mirror of
https://github.com/magefree/mage.git
synced 2025-12-25 13:02:06 -08:00
* Added a test.
This commit is contained in:
parent
1904f838ca
commit
17afa3b3c1
2 changed files with 53 additions and 0 deletions
|
|
@ -46,12 +46,34 @@ public interface Effect extends Serializable {
|
|||
|
||||
void newId();
|
||||
|
||||
/**
|
||||
* Some general behaviours for rule text handling: Rule text of effects get
|
||||
* automatically a full stop "." at the end, if not another effect e.g. with
|
||||
* a starting "and" follows. So at least for effects of the framework, that
|
||||
* are used from multiple cards, it's better to set no full stop at the end
|
||||
* of the rule text of an effect. Also the starting letter of an effect is
|
||||
* automatically converted to upper case if the rule text starts with this
|
||||
* text. So There is no need to let the effect text start with upper case,
|
||||
* even if extracted from a filter message. Also here it's important to use
|
||||
* only lower cases for effects located in the framework, so if used for a
|
||||
* triggered abilitiy, the effect text needs to start with lower case after
|
||||
* the comma.
|
||||
*
|
||||
* @param mode the selected mode of the ability (mostly there is only one)
|
||||
* @return
|
||||
*/
|
||||
String getText(Mode mode);
|
||||
|
||||
Effect setText(String staticText);
|
||||
|
||||
boolean apply(Game game, Ability source);
|
||||
|
||||
/**
|
||||
* The outcome is used for the AI to decide if an effect does bad or good to
|
||||
* the targets.
|
||||
*
|
||||
* @return
|
||||
*/
|
||||
Outcome getOutcome();
|
||||
|
||||
void setOutcome(Outcome outcome);
|
||||
|
|
|
|||
Loading…
Add table
Add a link
Reference in a new issue