diff --git a/Mage/src/mage/abilities/effects/ContinuousRuleModifiyingEffect.java b/Mage/src/mage/abilities/effects/ContinuousRuleModifiyingEffect.java index f6bc9981b64..d985ef1c7e9 100644 --- a/Mage/src/mage/abilities/effects/ContinuousRuleModifiyingEffect.java +++ b/Mage/src/mage/abilities/effects/ContinuousRuleModifiyingEffect.java @@ -40,7 +40,7 @@ public interface ContinuousRuleModifiyingEffect extends ContinuousEffect { /** * This check for the relevant events is called at first to prevent further actions if - * the current event is ignored from this effect + * the current event is ignored from this effect. Speeds up event handling. * @param event * @param game * @return diff --git a/Mage/src/mage/abilities/effects/ContinuousRuleModifiyingEffectImpl.java b/Mage/src/mage/abilities/effects/ContinuousRuleModifiyingEffectImpl.java index ee3fdadb0e3..39769df3677 100644 --- a/Mage/src/mage/abilities/effects/ContinuousRuleModifiyingEffectImpl.java +++ b/Mage/src/mage/abilities/effects/ContinuousRuleModifiyingEffectImpl.java @@ -62,7 +62,17 @@ public abstract class ContinuousRuleModifiyingEffectImpl extends ContinuousEffec public ContinuousRuleModifiyingEffectImpl(Duration duration, Outcome outcome) { this(duration, outcome, true, false); } - + + /** + * + * @param duration + * @param outcome + * @param messageToUser - Every time the effect replaces an event, the user gets a message in a dialog window. + * Don't set it to true if the event heppens regularly or very often. The message can be + * changed by overriding the getInfoMessage method. + * @param messageToLog - Every time the effect replaces an event, a message is posted to the game log. The message + * can be changed by overriding the getInfoMessage method. + */ public ContinuousRuleModifiyingEffectImpl(Duration duration, Outcome outcome, boolean messageToUser, boolean messageToLog) { super(duration, outcome); this.effectType = EffectType.CONTINUOUS_RULE_MODIFICATION; @@ -78,6 +88,14 @@ public abstract class ContinuousRuleModifiyingEffectImpl extends ContinuousEffec this.messageToGameLog = effect.messageToGameLog; } + /** + * An early check for the event types this effect applies to. This check was added + * to speed up event handling. Once all existing ContinuousRuleModifiyingEffects have + * implemented this method, the method should be changed to abstract here or removed. + * @param event + * @param game + * @return + */ @Override public boolean checksEventType(GameEvent event, Game game) { return true;