Skip to content

EffectCondition

subtype of function

A function used to check an activated effect's condition, usually passed to Effect.SetCondition. Conditions refer to those explicitly stated in the card text, (e.g. "If you control a monster:"), not for activation legality (e.g. checking if you have a Field Spell in your Deck to activate Terraforming), which is checked by the EffectTarget instead.

Functions that use this type as parameter

Functions that use this type as parameter

Signature

function(Effect e, int tp, Group eg, int ep, Group ev, Effect re, int r, int rp) → bool

lua
function(e,tp,eg,ep,ev,re,r,rp)

Parameters

  • Effect e

    The effect being checked.

  • int tp

    The player activating the effect.

  • Group eg

    A group of cards associated to the event that prompted the effect activation. The specifics of this group vary depending on the event code.

  • int ep

    The player associated to the event that prompted the effect activation.

  • Group ev

    A value associated to the event that prompted the effect activation. The specifics of this value vary depending on the event code.

  • Effect re

    The effect that caused the event that prompted the effect activation.

  • int r

    Composite Reason value of the event that prompted the effect activation.

  • int rp

    The player that caused the event that prompted the effect activation.

Returns

  • bool

    If the effect can be activated.


under-construction