Commit 615d54cc authored by 聖園ミカ's avatar 聖園ミカ 🐟

str

parent 9317f65e
Pipeline #26944 passed with stages
in 18 minutes and 14 seconds
--绒武士 肋差绒耳狐
Duel.LoadScript("c33301000.lua")
local m,cm = rscf.DefineCard(33310600,"FurryWarrior")
if rsfw then return end
rsfw = cm
--code means card code ;
--cate,con,tg,op means 2nd effect's extra category/condition/target/operation
function rsfw.FurryFunction(c,code,cate,con,tg,op)
local cm,m=GetID()
cm.rssetcode="FurryWarrior"
function cm.initial_effect(c)
--special summon
local e1=Effect.CreateEffect(c)
e1:SetCategory(CATEGORY_SPECIAL_SUMMON)
......@@ -18,71 +14,48 @@ function rsfw.FurryFunction(c,code,cate,con,tg,op)
c:RegisterEffect(e1)
--to hand
local e2=Effect.CreateEffect(c)
e2:SetDescription(aux.Stringid(code,0))
e2:SetDescription(aux.Stringid(m,0))
e2:SetType(EFFECT_TYPE_QUICK_O)
e2:SetCategory(cate | CATEGORY_TOHAND)
e2:SetCategory(CATEGORY_DAMAGE+CATEGORY_TOHAND)
e2:SetCode(EVENT_PRE_DAMAGE_CALCULATE)
e2:SetRange(LOCATION_MZONE+LOCATION_GRAVE)
e2:SetCountLimit(1,code)
e2:SetCondition(cm.thcon(con))
e2:SetTarget(cm.thtg(tg))
e2:SetOperation(cm.thop(op))
e2:SetCountLimit(1,m)
e2:SetCondition(cm.thcon)
e2:SetTarget(cm.thtg)
e2:SetOperation(cm.thop)
c:RegisterEffect(e2)
return e1,e2
end
function cm.spcfilter(c)
return not c:IsFaceup() or not c:IsRace(RACE_BEAST)
end
function cm.spcon(e,tp,eg,ep,ev,re,r,rp)
return Duel.GetTurnPlayer() == tp and not Duel.IsExistingMatchingCard(cm.spcfilter,tp,LOCATION_MZONE,0,1,nil)
return Duel.GetTurnPlayer()==tp and not Duel.IsExistingMatchingCard(cm.spcfilter,tp,LOCATION_MZONE,0,1,nil)
end
function cm.sptg(e,tp,eg,ep,ev,re,r,rp,chk)
local c = e:GetHandler()
if chk == 0 then return c:IsCanBeSpecialSummoned(e,0,tp,false,false) and Duel.GetLocationCount(tp,LOCATION_MZONE)>0 end
local c=e:GetHandler()
if chk==0 then return c:IsCanBeSpecialSummoned(e,0,tp,false,false) and Duel.GetLocationCount(tp,LOCATION_MZONE)>0 end
Duel.SetOperationInfo(0,CATEGORY_SPECIAL_SUMMON,c,1,0,0)
end
function cm.spop(e,tp,eg,ep,ev,re,r,rp)
local c = e:GetHandler()
local c=e:GetHandler()
if not c:IsRelateToEffect(e) then return end
Duel.SpecialSummon(c,0,tp,tp,false,false,POS_FACEUP)
end
function cm.thcon(con)
return function(e,tp,eg,ep,ev,re,r,rp)
local ac = Duel.GetBattleMonster(tp)
if con and not con(e,tp,eg,ep,ev,re,r,rp) then return false end
return ac and ac:CheckSetCard("FurryWarrior")
end
end
function cm.thtg(tg)
return function(e,tp,eg,ep,ev,re,r,rp,chk)
local c = e:GetHandler()
if chk == 0 then return c:IsAbleToHand() and (not tg or tg(e,tp,eg,ep,ev,re,r,rp,0)) end
if tg then
tg(e,tp,eg,ep,ev,re,r,rp,1)
end
Duel.SetOperationInfo(0,CATEGORY_TOHAND,c,1,0,0)
end
end
function cm.thop(op)
return function(e,tp,eg,ep,ev,re,r,rp)
local c = e:GetHandler()
if not c:IsRelateToEffect(e) or Duel.SendtoHand(c,nil,REASON_EFFECT) <= 0 or not c:IsLocation(LOCATION_HAND) then return end
if op then
op(e,tp,eg,ep,ev,re,r,rp)
end
end
end
--/////////////////////////////
function cm.initial_effect(c)
local e1,e2 = rsfw.FurryFunction(c,m,CATEGORY_DAMAGE,nil,cm.damtg,cm.damop)
function cm.thcon(e,tp,eg,ep,ev,re,r,rp)
local ac=Duel.GetBattleMonster(tp)
return ac and ac.rssetcode and ac.rssetcode=="FurryWarrior"
end
function cm.damtg(e,tp,eg,ep,ev,re,r,rp,chk)
local ac = Duel.GetBattleMonster(tp)
if chk == 0 then return ac and ac:IsAttackAbove(1) end
function cm.thtg(e,tp,eg,ep,ev,re,r,rp,chk)
local c=e:GetHandler()
local ac=Duel.GetBattleMonster(tp)
if chk==0 then return c:IsAbleToHand() and ac and ac:IsAttackAbove(1) end
Duel.SetOperationInfo(0,CATEGORY_DAMAGE,nil,0,1-tp,ac:GetAttack())
Duel.SetOperationInfo(0,CATEGORY_TOHAND,c,1,0,0)
end
function cm.damop(e,tp,eg,ep,ev,re,r,rp)
local ac = Duel.GetBattleMonster(tp)
function cm.thop(e,tp,eg,ep,ev,re,r,rp)
local c=e:GetHandler()
if not c:IsRelateToEffect(e) or Duel.SendtoHand(c,nil,REASON_EFFECT)<=0 or not c:IsLocation(LOCATION_HAND) then return end
local ac=Duel.GetBattleMonster(tp)
if not ac:IsRelateToBattle() then return end
Duel.Damage(1-tp,ac:GetAttack(),REASON_EFFECT)
end
\ No newline at end of file
--绒武士 地藏刀狸
Duel.LoadScript("c33310600.lua")
local m,cm = rscf.DefineCard(33310601,"FurryWarrior")
local cm,m=GetID()
cm.rssetcode="FurryWarrior"
function cm.initial_effect(c)
local e1,e2 = rsfw.FurryFunction(c,m,CATEGORY_DEFCHANGE,cm.defcon,nil,cm.defop)
--special summon
local e1=Effect.CreateEffect(c)
e1:SetCategory(CATEGORY_SPECIAL_SUMMON)
e1:SetType(EFFECT_TYPE_FIELD+EFFECT_TYPE_TRIGGER_O)
e1:SetCode(EVENT_PHASE+PHASE_STANDBY)
e1:SetRange(LOCATION_HAND)
e1:SetCondition(cm.spcon)
e1:SetTarget(cm.sptg)
e1:SetOperation(cm.spop)
c:RegisterEffect(e1)
--to hand
local e2=Effect.CreateEffect(c)
e2:SetDescription(aux.Stringid(m,0))
e2:SetType(EFFECT_TYPE_QUICK_O)
e2:SetCategory(CATEGORY_DEFCHANGE+CATEGORY_TOHAND)
e2:SetCode(EVENT_PRE_DAMAGE_CALCULATE)
e2:SetRange(LOCATION_MZONE+LOCATION_GRAVE)
e2:SetCountLimit(1,m)
e2:SetCondition(cm.thcon)
e2:SetTarget(cm.thtg)
e2:SetOperation(cm.thop)
c:RegisterEffect(e2)
end
function cm.cfilter(c)
return c:IsFaceup() and c:IsRace(RACE_BEAST)
function cm.spcfilter(c)
return not c:IsFaceup() or not c:IsRace(RACE_BEAST)
end
function cm.spcon(e,tp,eg,ep,ev,re,r,rp)
return Duel.GetTurnPlayer()==tp and not Duel.IsExistingMatchingCard(cm.spcfilter,tp,LOCATION_MZONE,0,1,nil)
end
function cm.sptg(e,tp,eg,ep,ev,re,r,rp,chk)
local c=e:GetHandler()
if chk==0 then return c:IsCanBeSpecialSummoned(e,0,tp,false,false) and Duel.GetLocationCount(tp,LOCATION_MZONE)>0 end
Duel.SetOperationInfo(0,CATEGORY_SPECIAL_SUMMON,c,1,0,0)
end
function cm.spop(e,tp,eg,ep,ev,re,r,rp)
local c=e:GetHandler()
if not c:IsRelateToEffect(e) then return end
Duel.SpecialSummon(c,0,tp,tp,false,false,POS_FACEUP)
end
function cm.defcon(e,tp,eg,ep,ev,re,r,rp)
return Duel.IsExistingMatchingCard(cm.cfilter,tp,LOCATION_MZONE,0,1,e:GetHandler())
end
function cm.defop(e,tp,eg,ep,ev,re,r,rp)
local c = e:GetHandler()
local g = Duel.GetMatchingGroup(cm.cfilter,tp,LOCATION_MZONE,0,nil)
for tc in aux.Next(g) do
local e1=Effect.CreateEffect(c)
e1:SetType(EFFECT_TYPE_SINGLE)
e1:SetCode(EFFECT_UPDATE_DEFENSE)
e1:SetValue(500)
e1:SetReset(RESET_EVENT+RESETS_STANDARD+RESET_PHASE+PHASE_END)
tc:RegisterEffect(e1)
local e2=Effect.CreateEffect(c)
e2:SetType(EFFECT_TYPE_SINGLE)
e2:SetCode(EFFECT_INDESTRUCTABLE_BATTLE)
e2:SetValue(1)
e2:SetReset(RESET_EVENT+RESETS_STANDARD+RESET_PHASE+PHASE_END)
tc:RegisterEffect(e2)
end
function cm.thcon(e,tp,eg,ep,ev,re,r,rp)
local ac=Duel.GetBattleMonster(tp)
return ac and ac.rssetcode and ac.rssetcode=="FurryWarrior"
end
function cm.thtg(e,tp,eg,ep,ev,re,r,rp,chk)
local c=e:GetHandler()
local ac=Duel.GetBattleMonster(tp)
if chk==0 then return c:IsAbleToHand() end
Duel.SetOperationInfo(0,CATEGORY_TOHAND,c,1,0,0)
end
function cm.thop(e,tp,eg,ep,ev,re,r,rp)
local c=e:GetHandler()
if not c:IsRelateToEffect(e) or Duel.SendtoHand(c,nil,REASON_EFFECT)<=0 or not c:IsLocation(LOCATION_HAND) then return end
local e1=Effect.CreateEffect(c)
e1:SetType(EFFECT_TYPE_FIELD)
e1:SetCode(EFFECT_INDESTRUCTABLE_BATTLE)
e1:SetValue(1)
e1:SetTargetRange(LOCATION_MZONE,0)
e1:SetTarget(cm.bttg)
e1:SetReset(RESET_PHASE+PHASE_END)
Duel.RegisterEffect(e1,tp)
local e2=e1:Clone()
e2:SetCode(EFFECT_UPDATE_DEFENSE)
e2:SetValue(500)
Duel.RegisterEffect(e2,tp)
end
function cm.bttg(e,c)
return c:IsFaceup() and c:IsRace(RACE_BEAST)
end
\ No newline at end of file
--绒武士 花蝶刀
Duel.LoadScript("c33310600.lua")
local m,cm = rscf.DefineCard(33310602,"FurryWarrior")
local cm,m=GetID()
cm.rssetcode="FurryWarrior"
function cm.initial_effect(c)
local e1,e2 = rsfw.FurryFunction(c,m,0,nil,cm.tftg,cm.tfop)
--special summon
local e1=Effect.CreateEffect(c)
e1:SetCategory(CATEGORY_SPECIAL_SUMMON)
e1:SetType(EFFECT_TYPE_FIELD+EFFECT_TYPE_TRIGGER_O)
e1:SetCode(EVENT_PHASE+PHASE_STANDBY)
e1:SetRange(LOCATION_HAND)
e1:SetCondition(cm.spcon)
e1:SetTarget(cm.sptg)
e1:SetOperation(cm.spop)
c:RegisterEffect(e1)
--to hand
local e2=Effect.CreateEffect(c)
e2:SetDescription(aux.Stringid(m,0))
e2:SetType(EFFECT_TYPE_QUICK_O)
e2:SetCategory(CATEGORY_TOHAND)
e2:SetCode(EVENT_PRE_DAMAGE_CALCULATE)
e2:SetRange(LOCATION_MZONE+LOCATION_GRAVE)
e2:SetCountLimit(1,m)
e2:SetCondition(cm.thcon)
e2:SetTarget(cm.thtg)
e2:SetOperation(cm.thop)
c:RegisterEffect(e2)
end
function cm.tffilter(c)
return c:CheckSetCard("FurryWarrior") and not c:IsForbidden() and c:IsType(TYPE_CONTINUOUS)
function cm.spcfilter(c)
return not c:IsFaceup() or not c:IsRace(RACE_BEAST)
end
function cm.spcon(e,tp,eg,ep,ev,re,r,rp)
return Duel.GetTurnPlayer()==tp and not Duel.IsExistingMatchingCard(cm.spcfilter,tp,LOCATION_MZONE,0,1,nil)
end
function cm.sptg(e,tp,eg,ep,ev,re,r,rp,chk)
local c=e:GetHandler()
if chk==0 then return c:IsCanBeSpecialSummoned(e,0,tp,false,false) and Duel.GetLocationCount(tp,LOCATION_MZONE)>0 end
Duel.SetOperationInfo(0,CATEGORY_SPECIAL_SUMMON,c,1,0,0)
end
function cm.spop(e,tp,eg,ep,ev,re,r,rp)
local c=e:GetHandler()
if not c:IsRelateToEffect(e) then return end
Duel.SpecialSummon(c,0,tp,tp,false,false,POS_FACEUP)
end
function cm.tftg(e,tp,eg,ep,ev,re,r,rp,chk)
if chk == 0 then return Duel.IsExistingMatchingCard(cm.tffilter,tp,LOCATION_DECK+LOCATION_GRAVE,0,1,nil) and Duel.GetLocationCount(tp,LOCATION_SZONE)>0 end
function cm.thcon(e,tp,eg,ep,ev,re,r,rp)
local ac=Duel.GetBattleMonster(tp)
return ac and ac.rssetcode and ac.rssetcode=="FurryWarrior"
end
function cm.tfop(e,tp,eg,ep,ev,re,r,rp)
if Duel.GetLocationCount(tp,LOCATION_SZONE) <= 0 then return end
function cm.thtg(e,tp,eg,ep,ev,re,r,rp,chk)
local c=e:GetHandler()
local ac=Duel.GetBattleMonster(tp)
if chk==0 then return c:IsAbleToHand() and Duel.IsExistingMatchingCard(cm.tffilter,tp,LOCATION_DECK+LOCATION_GRAVE,0,1,nil) and Duel.GetLocationCount(tp,LOCATION_SZONE)>0 end
Duel.SetOperationInfo(0,CATEGORY_TOHAND,c,1,0,0)
end
function cm.thop(e,tp,eg,ep,ev,re,r,rp)
local c=e:GetHandler()
if not c:IsRelateToEffect(e) or Duel.SendtoHand(c,nil,REASON_EFFECT)<=0 or not c:IsLocation(LOCATION_HAND) then return end
if Duel.GetLocationCount(tp,LOCATION_SZONE)<=0 then return end
Duel.Hint(HINT_SELECTMSG,tp,HINTMSG_TOFIELD)
local tc = Duel.SelectMatchingCard(tp,aux.NecroValleyFilter(cm.tffilter),tp,LOCATION_DECK+LOCATION_GRAVE,0,1,1,nil):GetFirst()
local tc=Duel.SelectMatchingCard(tp,aux.NecroValleyFilter(cm.tffilter),tp,LOCATION_DECK+LOCATION_GRAVE,0,1,1,nil):GetFirst()
if tc then
Duel.MoveToField(tc,tp,tp,LOCATION_SZONE,POS_FACEUP,true)
end
end
function cm.tffilter(c)
return c and c.rssetcode and c.rssetcode=="FurryWarrior" and not c:IsForbidden() and c:IsType(TYPE_CONTINUOUS)
end
\ No newline at end of file
--绒武士 铁拳晓狼
Duel.LoadScript("c33310600.lua")
local m,cm = rscf.DefineCard(33310603,"FurryWarrior")
local cm,m=GetID()
cm.rssetcode="FurryWarrior"
function cm.initial_effect(c)
local e1,e2 = rsfw.FurryFunction(c,m,CATEGORY_ATKCHANGE,cm.atkcon,nil,cm.atkop)
--special summon
local e1=Effect.CreateEffect(c)
e1:SetCategory(CATEGORY_SPECIAL_SUMMON)
e1:SetType(EFFECT_TYPE_FIELD+EFFECT_TYPE_TRIGGER_O)
e1:SetCode(EVENT_PHASE+PHASE_STANDBY)
e1:SetRange(LOCATION_HAND)
e1:SetCondition(cm.spcon)
e1:SetTarget(cm.sptg)
e1:SetOperation(cm.spop)
c:RegisterEffect(e1)
--to hand
local e2=Effect.CreateEffect(c)
e2:SetDescription(aux.Stringid(m,0))
e2:SetType(EFFECT_TYPE_QUICK_O)
e2:SetCategory(CATEGORY_TOHAND+CATEGORY_ATKCHANGE)
e2:SetCode(EVENT_PRE_DAMAGE_CALCULATE)
e2:SetRange(LOCATION_MZONE+LOCATION_GRAVE)
e2:SetCountLimit(1,m)
e2:SetCondition(cm.thcon)
e2:SetTarget(cm.thtg)
e2:SetOperation(cm.thop)
c:RegisterEffect(e2)
end
function cm.cfilter(c)
return c:IsFaceup() and c:IsRace(RACE_BEAST)
function cm.spcfilter(c)
return not c:IsFaceup() or not c:IsRace(RACE_BEAST)
end
function cm.spcon(e,tp,eg,ep,ev,re,r,rp)
return Duel.GetTurnPlayer()==tp and not Duel.IsExistingMatchingCard(cm.spcfilter,tp,LOCATION_MZONE,0,1,nil)
end
function cm.sptg(e,tp,eg,ep,ev,re,r,rp,chk)
local c=e:GetHandler()
if chk==0 then return c:IsCanBeSpecialSummoned(e,0,tp,false,false) and Duel.GetLocationCount(tp,LOCATION_MZONE)>0 end
Duel.SetOperationInfo(0,CATEGORY_SPECIAL_SUMMON,c,1,0,0)
end
function cm.spop(e,tp,eg,ep,ev,re,r,rp)
local c=e:GetHandler()
if not c:IsRelateToEffect(e) then return end
Duel.SpecialSummon(c,0,tp,tp,false,false,POS_FACEUP)
end
function cm.atkcon(e,tp,eg,ep,ev,re,r,rp)
return Duel.IsExistingMatchingCard(cm.cfilter,tp,LOCATION_MZONE,0,1,e:GetHandler())
end
function cm.atkop(e,tp,eg,ep,ev,re,r,rp)
local c = e:GetHandler()
local g = Duel.GetMatchingGroup(cm.cfilter,tp,LOCATION_MZONE,0,nil)
for tc in aux.Next(g) do
local e1=Effect.CreateEffect(c)
e1:SetType(EFFECT_TYPE_SINGLE)
e1:SetCode(EFFECT_UPDATE_ATTACK)
e1:SetValue(1000)
e1:SetReset(RESET_EVENT+RESETS_STANDARD+RESET_PHASE+PHASE_END)
tc:RegisterEffect(e1)
end
function cm.thcon(e,tp,eg,ep,ev,re,r,rp)
local ac=Duel.GetBattleMonster(tp)
return ac and ac.rssetcode and ac.rssetcode=="FurryWarrior"
end
function cm.thtg(e,tp,eg,ep,ev,re,r,rp,chk)
local c=e:GetHandler()
local ac=Duel.GetBattleMonster(tp)
if chk==0 then return c:IsAbleToHand() and Duel.IsExistingMatchingCard(cm.tffilter,tp,LOCATION_DECK+LOCATION_GRAVE,0,1,nil) and Duel.GetLocationCount(tp,LOCATION_SZONE)>0 end
Duel.SetOperationInfo(0,CATEGORY_TOHAND,c,1,0,0)
end
function cm.thop(e,tp,eg,ep,ev,re,r,rp)
local c=e:GetHandler()
if not c:IsRelateToEffect(e) or Duel.SendtoHand(c,nil,REASON_EFFECT)<=0 or not c:IsLocation(LOCATION_HAND) then return end
local e1=Effect.CreateEffect(c)
e1:SetType(EFFECT_TYPE_FIELD)
e1:SetCode(EFFECT_UPDATE_ATTACK)
e1:SetValue(1000)
e1:SetTargetRange(LOCATION_MZONE,0)
e1:SetTarget(cm.bttg)
e1:SetReset(RESET_PHASE+PHASE_END)
Duel.RegisterEffect(e1,tp)
end
function cm.bttg(e,c)
return c:IsFaceup() and c:IsRace(RACE_BEAST)
end
\ No newline at end of file
--绒武士 晶霜冰剑犬
Duel.LoadScript("c33310600.lua")
local m,cm = rscf.DefineCard(33310604,"FurryWarrior")
local cm,m=GetID()
cm.rssetcode="FurryWarrior"
function cm.initial_effect(c)
local e1,e2 = rsfw.FurryFunction(c,m,CATEGORY_ATKCHANGE+CATEGORY_DEFCHANGE,cm.adcon,nil,cm.adop)
--special summon
local e1=Effect.CreateEffect(c)
e1:SetCategory(CATEGORY_SPECIAL_SUMMON)
e1:SetType(EFFECT_TYPE_FIELD+EFFECT_TYPE_TRIGGER_O)
e1:SetCode(EVENT_PHASE+PHASE_STANDBY)
e1:SetRange(LOCATION_HAND)
e1:SetCondition(cm.spcon)
e1:SetTarget(cm.sptg)
e1:SetOperation(cm.spop)
c:RegisterEffect(e1)
--to hand
local e2=Effect.CreateEffect(c)
e2:SetDescription(aux.Stringid(m,0))
e2:SetType(EFFECT_TYPE_QUICK_O)
e2:SetCategory(CATEGORY_TOHAND+CATEGORY_ATKCHANGE+CATEGORY_DEFCHANGE)
e2:SetCode(EVENT_PRE_DAMAGE_CALCULATE)
e2:SetRange(LOCATION_MZONE+LOCATION_GRAVE)
e2:SetCountLimit(1,m)
e2:SetCondition(cm.thcon)
e2:SetTarget(cm.thtg)
e2:SetOperation(cm.thop)
c:RegisterEffect(e2)
end
function cm.spcfilter(c)
return not c:IsFaceup() or not c:IsRace(RACE_BEAST)
end
function cm.spcon(e,tp,eg,ep,ev,re,r,rp)
return Duel.GetTurnPlayer()==tp and not Duel.IsExistingMatchingCard(cm.spcfilter,tp,LOCATION_MZONE,0,1,nil)
end
function cm.sptg(e,tp,eg,ep,ev,re,r,rp,chk)
local c=e:GetHandler()
if chk==0 then return c:IsCanBeSpecialSummoned(e,0,tp,false,false) and Duel.GetLocationCount(tp,LOCATION_MZONE)>0 end
Duel.SetOperationInfo(0,CATEGORY_SPECIAL_SUMMON,c,1,0,0)
end
function cm.spop(e,tp,eg,ep,ev,re,r,rp)
local c=e:GetHandler()
if not c:IsRelateToEffect(e) then return end
Duel.SpecialSummon(c,0,tp,tp,false,false,POS_FACEUP)
end
function cm.cfilter(c)
return c:IsFaceup() and c:IsRace(RACE_BEAST)
function cm.thcon(e,tp,eg,ep,ev,re,r,rp)
local ac,bc=Duel.GetBattleMonster(tp)
return ac and ac.rssetcode and ac.rssetcode=="FurryWarrior" and bc and (bc:IsAttackAbove(1) or bc:IsDefenseAbove(1)) and bc:IsControler(1-tp)
end
function cm.adcon(e,tp,eg,ep,ev,re,r,rp)
local ac,bc = Duel.GetBattleMonster(tp)
return bc and (bc:IsAttackAbove(1) or bc:IsDefenseAbove(1)) and bc:IsControler(1-tp)
function cm.thtg(e,tp,eg,ep,ev,re,r,rp,chk)
local c=e:GetHandler()
local ac=Duel.GetBattleMonster(tp)
if chk==0 then return c:IsAbleToHand() and Duel.IsExistingMatchingCard(cm.tffilter,tp,LOCATION_DECK+LOCATION_GRAVE,0,1,nil) and Duel.GetLocationCount(tp,LOCATION_SZONE)>0 end
Duel.SetOperationInfo(0,CATEGORY_TOHAND,c,1,0,0)
end
function cm.adop(e,tp,eg,ep,ev,re,r,rp)
local c = e:GetHandler()
local ac,bc = Duel.GetBattleMonster(tp)
function cm.thop(e,tp,eg,ep,ev,re,r,rp)
local c=e:GetHandler()
if not c:IsRelateToEffect(e) or Duel.SendtoHand(c,nil,REASON_EFFECT)<=0 or not c:IsLocation(LOCATION_HAND) then return end
local ac,bc=Duel.GetBattleMonster(tp)
local e1=Effect.CreateEffect(c)
e1:SetType(EFFECT_TYPE_SINGLE)
e1:SetCode(EFFECT_SET_ATTACK_FINAL)
......
--绒武士 太刀柴犬
Duel.LoadScript("c33310600.lua")
local m,cm = rscf.DefineCard(33310605,"FurryWarrior")
local cm,m=GetID()
cm.rssetcode="FurryWarrior"
function cm.initial_effect(c)
c:EnableReviveLimit()
aux.AddXyzProcedure(c,aux.FilterBoolFunction(Card.IsRace,RACE_BEAST),2,2)
......@@ -33,16 +33,16 @@ function cm.tgcon(e,tp,eg,ep,ev,re,r,rp)
return e:GetHandler():IsSummonType(SUMMON_TYPE_XYZ)
end
function cm.tgfilter(c)
return c:CheckSetCard("FurryWarrior") and c:IsAbleToGrave()
return c and c.rssetcode and c.rssetcode=="FurryWarrior" and c:IsAbleToGrave()
end
function cm.tgtg(e,tp,eg,ep,ev,re,r,rp,chk)
if chk == 0 then return Duel.IsExistingMatchingCard(cm.tgfilter,tp,LOCATION_DECK,0,1,nil) end
if chk==0 then return Duel.IsExistingMatchingCard(cm.tgfilter,tp,LOCATION_DECK,0,1,nil) end
Duel.SetOperationInfo(0,CATEGORY_TOGRAVE,nil,1,tp,LOCATION_DECK)
end
function cm.tgop(e,tp,eg,ep,ev,re,r,rp)
Duel.Hint(HINT_SELECTMSG,tp,HINTMSG_TOGRAVE)
local g = Duel.SelectMatchingCard(tp,cm.tgfilter,tp,LOCATION_DECK,0,1,1,nil)
if #g > 0 then
local g=Duel.SelectMatchingCard(tp,cm.tgfilter,tp,LOCATION_DECK,0,1,1,nil)
if #g>0 then
Duel.SendtoGrave(g,REASON_EFFECT)
end
end
......@@ -51,29 +51,29 @@ function cm.descost(e,tp,eg,ep,ev,re,r,rp,chk)
return true
end
function cm.destg(e,tp,eg,ep,ev,re,r,rp,chk)
local c = e:GetHandler()
local dg = Duel.GetFieldGroup(tp,LOCATION_ONFIELD,LOCATION_ONFIELD)
if chk == 0 then
if e:GetLabel() ~= 100 then
local c=e:GetHandler()
local dg=Duel.GetFieldGroup(tp,LOCATION_ONFIELD,LOCATION_ONFIELD)
if chk==0 then
if e:GetLabel()~=100 then
e:SetLabel(0)
return false
end
return c:CheckRemoveOverlayCard(tp,1,REASON_COST) and #dg > 0
return c:CheckRemoveOverlayCard(tp,1,REASON_COST) and #dg>0
end
e:SetLabel(0)
local dct = c:RemoveOverlayCard(tp,1,#dg,REASON_COST)
local dct=c:RemoveOverlayCard(tp,1,#dg,REASON_COST)
Duel.SetOperationInfo(0,CATEGORY_DESTROY,nil,dct,tp,LOCATION_ONFIELD)
e:SetValue(dct)
end
function cm.desop(e,tp,eg,ep,ev,re,r,rp)
local c = e:GetHandler()
local dct = e:GetValue()
local c=e:GetHandler()
local dct=e:GetValue()
Duel.Hint(HINT_SELECTMSG,tp,HINTMSG_DESTROY)
local dg = Duel.SelectMatchingCard(tp,aux.TRUE,tp,LOCATION_ONFIELD,LOCATION_ONFIELD,dct,dct,nil)
local dg=Duel.SelectMatchingCard(tp,aux.TRUE,tp,LOCATION_ONFIELD,LOCATION_ONFIELD,dct,dct,nil)
if #dg > 0 then
Duel.HintSelection(dg)
if Duel.Destroy(dg,REASON_EFFECT) <= 0 or not c:IsRelateToEffect(e) or not c:IsAbleToRemove() or not Duel.SelectYesNo(tp,aux.Stringid(m,2)) or Duel.Remove(c,POS_FACEUP,REASON_EFFECT+REASON_TEMPORARY) <= 0 or not c:IsLocation(LOCATION_REMOVED) then return end
local fid = c:GetFieldID()
if Duel.Destroy(dg,REASON_EFFECT)<=0 or not c:IsRelateToEffect(e) or not c:IsAbleToRemove() or not Duel.SelectYesNo(tp,aux.Stringid(m,2)) or Duel.Remove(c,POS_FACEUP,REASON_EFFECT+REASON_TEMPORARY)<=0 or not c:IsLocation(LOCATION_REMOVED) then return end
local fid=c:GetFieldID()
c:RegisterFlagEffect(m,RESET_EVENT+RESETS_STANDARD,0,1,fid)
local e1=Effect.CreateEffect(c)
e1:SetType(EFFECT_TYPE_FIELD+EFFECT_TYPE_CONTINUOUS)
......@@ -87,15 +87,15 @@ function cm.desop(e,tp,eg,ep,ev,re,r,rp)
end
end
function cm.retcon(e,tp)
local c = e:GetLabelObject()
if c:GetFlagEffectLabel(m) == e:GetLabel() then return true
local c=e:GetLabelObject()
if c:GetFlagEffectLabel(m)==e:GetLabel() then return true
else
e:Reset()
return false
end
end
function cm.retop(e,tp)
local c = e:GetLabelObject()
local c=e:GetLabelObject()
Duel.Hint(HINT_CARD,0,m)
Duel.ReturnToField(c)
e:Reset()
......
--绒武士技 居合1
Duel.LoadScript("c33310600.lua")
local m,cm = rscf.DefineCard(33310606,"FurryWarrior")
--绒武士技 居合
local cm,m=GetID()
cm.rssetcode="FurryWarrior"
function cm.initial_effect(c)
--Activate
local e1=Effect.CreateEffect(c)
......@@ -29,46 +29,46 @@ function cm.initial_effect(c)
e3:SetOperation(cm.atkop)
c:RegisterEffect(e3)
end
function cm.cfilter(c)
return c:IsFaceup() and c:CheckSetCard("FurryWarrior")
function cm.filter(c)
return c:IsFaceup() and c.rssetcode and c.rssetcode=="FurryWarrior"
end
function cm.actcon(e)
local ph = Duel.GetCurrentPhase()
return Duel.IsExistingMatchingCard(cm.cfilter,e:GetHandlerPlayer(),LOCATION_MZONE,0,1,nil) and ph > PHASE_MAIN1 and ph < PHASE_MAIN2
local ph=Duel.GetCurrentPhase()
return Duel.IsExistingMatchingCard(cm.filter,e:GetHandlerPlayer(),LOCATION_MZONE,0,1,nil) and ph>PHASE_MAIN1 and ph<PHASE_MAIN2
end
function cm.atkcon(e,tp,eg,ep,ev,re,r,rp)
local ac = Duel.GetBattleMonster(tp)
return ac and ac:CheckSetCard("FurryWarrior") and ac:GetBaseAttack() > 0 and not e:GetHandler():IsStatus(STATUS_CHAINING)
local ac=Duel.GetBattleMonster(tp)
return ac and ac.rssetcode and ac.rssetcode=="FurryWarrior" and ac:GetBaseAttack()>0 and not e:GetHandler():IsStatus(STATUS_CHAINING)
end
function cm.cfilter(c)
return c:IsAbleToGrave() and (c:IsLocation(LOCATION_HAND) or c:IsFaceup()) and c:IsRace(RACE_BEAST)
end
function cm.atktg(e,tp,eg,ep,ev,re,r,rp,chk)
local ac = Duel.GetBattleMonster(tp)
if chk == 0 then return Duel.IsExistingMatchingCard(cm.cfilter,tp,LOCATION_HAND+LOCATION_MZONE,0,1,1,ac) end
local ac=Duel.GetBattleMonster(tp)
if chk==0 then return Duel.IsExistingMatchingCard(cm.cfilter,tp,LOCATION_HAND+LOCATION_MZONE,0,1,1,ac) end
Duel.SetOperationInfo(0,CATEGORY_TOGRAVE,nil,1,tp,LOCATION_HAND+LOCATION_MZONE)
end
function cm.ofilter(c)
return c:IsRace(RACE_BEAST) and c:IsLevelBelow(2) and c:IsCanOverlay()
end
function cm.atkop(e,tp,eg,ep,ev,re,r,rp)
local c = e:GetHandler()
local ac = Duel.GetBattleMonster(tp)
local c=e:GetHandler()
local ac=Duel.GetBattleMonster(tp)
if not ac:IsRelateToBattle() or ac:IsFacedown() then return end
Duel.Hint(HINT_SELECTMSG,tp,HINTMSG_TOGRAVE)
local tg = Duel.SelectMatchingCard(tp,cm.cfilter,tp,LOCATION_HAND+LOCATION_MZONE,0,1,1,nil)
if #tg > 0 and Duel.SendtoGrave(tg,REASON_EFFECT) > 0 and tg:GetFirst():IsLocation(LOCATION_GRAVE) then
local tg=Duel.SelectMatchingCard(tp,cm.cfilter,tp,LOCATION_HAND+LOCATION_MZONE,0,1,1,nil)
if #tg>0 and Duel.SendtoGrave(tg,REASON_EFFECT)>0 and tg:GetFirst():IsLocation(LOCATION_GRAVE) then
local e1=Effect.CreateEffect(c)
e1:SetType(EFFECT_TYPE_SINGLE)
e1:SetCode(EFFECT_UPDATE_ATTACK)
e1:SetValue(ac:GetBaseAttack())
e1:SetReset(RESET_EVENT+RESETS_STANDARD)
ac:RegisterEffect(e1)
local og = Duel.GetMatchingGroup(cm.ofilter,tp,LOCATION_DECK,0,nil)
if not ac:IsImmuneToEffect(e) and ac:IsType(TYPE_XYZ) and #og > 0 and Duel.SelectYesNo(tp,aux.Stringid(m,1)) then
local og=Duel.GetMatchingGroup(cm.ofilter,tp,LOCATION_DECK,0,nil)
if not ac:IsImmuneToEffect(e) and ac:IsType(TYPE_XYZ) and #og>0 and Duel.SelectYesNo(tp,aux.Stringid(m,1)) then
Duel.BreakEffect()
Duel.Hint(HINT_SELECTMSG,tp,HINTMSG_XMATERIAL)
local og2 = og:Select(tp,1,1,nil)
local og2=og:Select(tp,1,1,nil)
Duel.Overlay(ac,og2)
end
end
......
--绒武士技 燕返
Duel.LoadScript("c33310600.lua")
local m,cm = rscf.DefineCard(33310607,"FurryWarrior")
local cm,m=GetID()
cm.rssetcode="FurryWarrior"
function cm.initial_effect(c)
--Activate
local e1=Effect.CreateEffect(c)
......@@ -32,13 +32,13 @@ function cm.cfilter(c,tp)
return c:IsSummonPlayer(1-tp)
end
function cm.condition(e,tp,eg,ep,ev,re,r,rp)
return Duel.GetCurrentChain() == 0 and eg:IsExists(cm.cfilter,1,nil,tp)
return Duel.GetCurrentChain()==0 and eg:IsExists(cm.cfilter,1,nil,tp)
end
function cm.spfilter(c,e,tp)
return c:CheckSetCard("FurryWarrior") and c:IsCanBeSpecialSummoned(e,0,tp,false,false) and (c:IsFaceup() or c:IsLocation(LOCATION_GRAVE))
return c.rssetcode and c.rssetcode=="FurryWarrior" and c:IsCanBeSpecialSummoned(e,0,tp,false,false) and (c:IsFaceup() or c:IsLocation(LOCATION_GRAVE))
end
function cm.target(e,tp,eg,ep,ev,re,r,rp,chk)
if chk == 0 then return Duel.GetLocationCount(tp,LOCATION_MZONE) > 0 and Duel.IsExistingMatchingCard(cm.spfilter,tp,LOCATION_GRAVE+LOCATION_REMOVED,0,1,nil,e,tp) end
if chk==0 then return Duel.GetLocationCount(tp,LOCATION_MZONE)>0 and Duel.IsExistingMatchingCard(cm.spfilter,tp,LOCATION_GRAVE+LOCATION_REMOVED,0,1,nil,e,tp) end
Duel.SetOperationInfo(0,CATEGORY_DISABLE_SUMMON,eg,eg:GetCount(),0,0)
Duel.SetOperationInfo(0,CATEGORY_TODECK,eg,eg:GetCount(),0,0)
end
......@@ -47,42 +47,42 @@ function cm.xyzfilter(c)
end
function cm.activate(e,tp,eg,ep,ev,re,r,rp)
Duel.NegateSummon(eg)
if Duel.Destroy(eg,REASON_EFFECT) > 0 then
local matg = eg:Filter(cm.xyzfilter,nil)
if Duel.Destroy(eg,REASON_EFFECT)>0 then
local matg=eg:Filter(cm.xyzfilter,nil)
Duel.Hint(HINT_SELECTMSG,tp,HINTMSG_SPSUMMON)
local tc = Duel.SelectMatchingCard(tp,aux.NecroValleyFilter(cm.spfilter),tp,LOCATION_GRAVE+LOCATION_REMOVED,0,1,1,nil,e,tp):GetFirst()
if not tc or Duel.SpecialSummon(tc,0,tp,tp,false,false,POS_FACEUP) <= 0 or not tc:IsType(TYPE_XYZ) or #matg <= 0 or not Duel.SelectYesNo(tp,aux.Stringid(m,0)) then return end
local tc=Duel.SelectMatchingCard(tp,aux.NecroValleyFilter(cm.spfilter),tp,LOCATION_GRAVE+LOCATION_REMOVED,0,1,1,nil,e,tp):GetFirst()
if not tc or Duel.SpecialSummon(tc,0,tp,tp,false,false,POS_FACEUP)<=0 or not tc:IsType(TYPE_XYZ) or #matg<=0 or not Duel.SelectYesNo(tp,aux.Stringid(m,0)) then return end
Duel.Overlay(tc,matg)
end
end
function cm.tdcost(e,tp,eg,ep,ev,re,r,rp,chk)
if chk == 0 then return Duel.IsExistingMatchingCard(Card.IsDiscardable,tp,LOCATION_HAND,0,1,nil) end
if chk==0 then return Duel.IsExistingMatchingCard(Card.IsDiscardable,tp,LOCATION_HAND,0,1,nil) end
Duel.DiscardHand(tp,Card.IsDiscardable,1,1,REASON_COST+REASON_DISCARD,nil)
end
function cm.thfilter(c,e,tp)
return (c:IsAbleToHand() or (c:IsCanBeSpecialSummoned(e,0,tp,false,false) and Duel.GetLocationCount(tp,LOCATION_MZONE)>0)) and c:CheckSetCard("FurryWarrior")
return (c:IsAbleToHand() or (c:IsCanBeSpecialSummoned(e,0,tp,false,false) and Duel.GetLocationCount(tp,LOCATION_MZONE)>0)) and c.rssetcode and c.rssetcode=="FurryWarrior"
end
function cm.tdtg(e,tp,eg,ep,ev,re,r,rp,chk)
local c = e:GetHandler()
if chk == 0 then return Duel.IsExistingMatchingCard(cm.thfilter,tp,LOCATION_GRAVE,0,1,nil,e,tp) and c:IsAbleToDeck() end
local c=e:GetHandler()
if chk==0 then return Duel.IsExistingMatchingCard(cm.thfilter,tp,LOCATION_GRAVE,0,1,c,e,tp) and c:IsAbleToDeck() end
Duel.SetOperationInfo(0,CATEGORY_TOHAND,nil,0,tp,LOCATION_GRAVE)
Duel.SetOperationInfo(0,CATEGORY_TODECK,c,1,0,0)
end
function cm.tdop(e,tp)
local c = aux.ExceptThisCard(e)
local c=aux.ExceptThisCard(e)
Duel.Hint(HINT_SELECTMSG,tp,HINTMSG_SELF)
local g = Duel.SelectMatchingCard(tp,aux.NecroValleyFilter(cm.thfilter),tp,LOCATION_GRAVE,0,1,1,c,e,tp)
if #g <= 0 then return end
local g=Duel.SelectMatchingCard(tp,aux.NecroValleyFilter(cm.thfilter),tp,LOCATION_GRAVE,0,1,1,c,e,tp)
if #g<=0 then return end
Duel.HintSelection(g)
local tc = g:GetFirst()
local ct = 0
if tc:IsAbleToHand() and (not tc:IsCanBeSpecialSummoned(e,0,tp,false,false) or Duel.GetLocationCount(tp,LOCATION_MZONE) <= 0 or Duel.SelectOption(tp,1190,1152) == 0) then
ct = Duel.SendtoHand(tc,nil,REASON_EFFECT)
local tc=g:GetFirst()
local ct=0
if tc:IsAbleToHand() and (not tc:IsCanBeSpecialSummoned(e,0,tp,false,false) or Duel.GetLocationCount(tp,LOCATION_MZONE)<=0 or Duel.SelectOption(tp,1190,1152)==0) then
ct=Duel.SendtoHand(tc,nil,REASON_EFFECT)
Duel.ConfirmCards(1-tp,tc)
else
ct= Duel.SpecialSummon(tc,0,tp,tp,false,false,POS_FACEUP)
ct=Duel.SpecialSummon(tc,0,tp,tp,false,false,POS_FACEUP)
end
if ct <= 0 or not c then return end
if ct<=0 or not c then return end
Duel.BreakEffect()
Duel.SendtoDeck(c,nil,2,REASON_EFFECT)
end
\ No newline at end of file
Markdown is supported
0% or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment