Chemicalizer Wing
- Card ID:
120272057 - Format: Rush Duel
- Script:
Rush/Scripts/c120272057.lua
Stats
| Field | Value |
|---|---|
| Type | 0x4 |
| ATK | 0 |
| DEF | 0 |
| Level/Rank/Link | 0x0 |
| Race | 0x0 |
| Attribute | 0x0 |
| Category | 0x240402 |
Card Text
text
[REQUIREMENT]
When a monster(s) on your field is destroyed by an opponent's attack or their card effect, shuffle 2 FIRE Attribute monsters from your Graveyard into the Deck.
[EFFECT]
Destroy 1 face-up Level 8 or lower monster on your opponent's field. Then, you can Special Summon 1 "Chemicalized Salamander" from your Graveyard face-up to your field.Detected API Calls
Auxiliary.NecroValleyFilterAuxiliary.StringidCard.IsAbleToDeckOrExtraAsCostCard.IsAttributeCard.IsCodeCard.IsFaceupCard.IsLevelBelowCard.IsPreviousControlerCard.IsPreviousLocationCard.IsReasonCard.RegisterEffectDuel.DestroyDuel.GetAttackTargetDuel.GetMatchingGroupDuel.IsExistingMatchingCardDuel.SetOperationInfoEffect.CreateEffectEffect.SetCategoryEffect.SetCodeEffect.SetConditionEffect.SetCostEffect.SetOperationEffect.SetPropertyEffect.SetTargetEffect.SetTypeGroup.IsExistsRushDuel.AddCodeListRushDuel.CanSelectAndSpecialSummonRushDuel.CostSendGraveToDeckRushDuel.IsCanBeSpecialSummonedRushDuel.SelectAndDoAction
Script
lua
local cm,m=GetID()
local list={120222020}
cm.name="化学化弹·翼"
function cm.initial_effect(c)
RD.AddCodeList(c,list)
--Activate
local e1=Effect.CreateEffect(c)
e1:SetCategory(CATEGORY_DESTROY)
e1:SetType(EFFECT_TYPE_ACTIVATE)
e1:SetCode(EVENT_DESTROYED)
e1:SetProperty(EFFECT_FLAG_DAMAGE_STEP)
e1:SetCondition(cm.condition)
e1:SetCost(cm.cost)
e1:SetTarget(cm.target)
e1:SetOperation(cm.activate)
c:RegisterEffect(e1)
end
--Activate
function cm.confilter(c,tp,rp)
return c:IsPreviousControler(tp) and c:IsPreviousLocation(LOCATION_MZONE)
and ((rp==1-tp and c:IsReason(REASON_EFFECT)) or c==Duel.GetAttackTarget())
end
function cm.costfilter(c)
return c:IsAttribute(ATTRIBUTE_FIRE) and c:IsAbleToDeckOrExtraAsCost()
end
function cm.desfilter(c)
return c:IsFaceup() and c:IsLevelBelow(8)
end
function cm.spfilter(c,e,tp)
return c:IsCode(list[1]) and RD.IsCanBeSpecialSummoned(c,e,tp,POS_FACEUP)
end
function cm.condition(e,tp,eg,ep,ev,re,r,rp)
return eg:IsExists(cm.confilter,1,nil,tp,rp)
end
cm.cost=RD.CostSendGraveToDeck(cm.costfilter,2,2)
function cm.target(e,tp,eg,ep,ev,re,r,rp,chk)
if chk==0 then return Duel.IsExistingMatchingCard(cm.desfilter,tp,0,LOCATION_MZONE,1,nil) end
local g=Duel.GetMatchingGroup(cm.desfilter,tp,0,LOCATION_MZONE,nil)
Duel.SetOperationInfo(0,CATEGORY_DESTROY,g,1,0,0)
end
function cm.activate(e,tp,eg,ep,ev,re,r,rp)
RD.SelectAndDoAction(HINTMSG_DESTROY,cm.desfilter,tp,0,LOCATION_MZONE,1,1,nil,function(g)
if Duel.Destroy(g,REASON_EFFECT)~=0 then
RD.CanSelectAndSpecialSummon(aux.Stringid(m,1),aux.NecroValleyFilter(cm.spfilter),tp,LOCATION_GRAVE,0,1,1,nil,e,POS_FACEUP,true)
end
end)
end