Card.IsStatus
Signature
lua
Card.IsStatus(Card c, int status) -> boolDescription
Checks whether c currently has at least one status flag from status. Common legality checks use this for temporary engine states such as STATUS_BATTLE_DESTROYED before allowing a Damage Step Quick Effect.
Parameters
cCard- Card whose current status flags are checked.statusint- Status flag or combined status mask, such as STATUS_BATTLE_DESTROYED.
Returns
bool- true if c has any flag included in status.
Source
D:\Programs\GitHub\ygopro-core\libcard.cpp:3559
Guided Examples
Learn how to use this function in context:
Used By
Generated from the local Scripts/ folder and cards.cdb.
- Detected in 461 indexed script(s).
- Search this function in the Script Explorer with
Card.IsStatus.
Script Examples
Salamandra with Chain (62091148)
Source: Scripts/c62091148.lua
lua
function s.operation(e,tp,eg,ep,ev,re,r,rp)
local c=e:GetHandler()
if not c:IsRelateToEffect(e) or c:IsStatus(STATUS_LEAVE_CONFIRMED) then return end
local tc=Duel.GetFirstTarget()
if tc:IsRelateToEffect(e) and tc:IsFaceup() and Duel.Equip(tp,c,tc) thenEternal Favorite (87532344)
Source: Scripts/c87532344.lua
lua
local c=e:GetHandler()
if chk==0 then return Duel.IsExistingMatchingCard(Card.IsDiscardable,tp,LOCATION_HAND,0,1,e:GetHandler())
and c:IsAbleToGraveAsCost() and c:IsStatus(STATUS_EFFECT_ENABLED) end
Duel.DiscardHand(tp,Card.IsDiscardable,1,1,REASON_COST+REASON_DISCARD)
Duel.SendtoGrave(c,REASON_COST)Enneacraft - Asta.PIXEA (28454232)
Source: Scripts/c28454232.lua
lua
function s.discon(e,tp,eg,ep,ev,re,r,rp)
local c=e:GetHandler()
if c:IsStatus(STATUS_BATTLE_DESTROYED) then return false end
if not re:IsHasProperty(EFFECT_FLAG_CARD_TARGET) then return false end
local tg=Duel.GetChainInfo(ev,CHAININFO_TARGET_CARDS)