Commit 582493e1 authored by 聖園ミカ's avatar 聖園ミカ 🐟

54188

parent a1669e87
Pipeline #31077 passed with stages
in 46 minutes and 53 seconds
...@@ -5,7 +5,7 @@ stages: ...@@ -5,7 +5,7 @@ stages:
variables: variables:
GIT_DEPTH: "1" GIT_DEPTH: "1"
LAST_UPDATE_DATE: "2024.10.28" LAST_UPDATE_DATE: "2024.10.28"
CURRENT_UPDATE_DATE: "2024.11.10" CURRENT_UPDATE_DATE: "2024.11.11"
redtext: redtext:
stage: prepare stage: prepare
......
...@@ -55,7 +55,6 @@ ...@@ -55,7 +55,6 @@
16400261 16400261
16400292 16400292
#extra #extra
4270024
11901550 11901550
12825624 12825624
12841231 12841231
......
No preview for this file type
...@@ -1389,11 +1389,6 @@ ...@@ -1389,11 +1389,6 @@
40010896 0 --微小的和平 40010896 0 --微小的和平
40011557 0 --云上骑士·天律 40011557 0 --云上骑士·天律
#440 #440
44000006 1 --骰娘炼成 鱼仙
44000017 0 --骰娘之主 古
44000018 1 --骰娘之主 追仙
44000019 0 --骰娘之主 多多
44000030 0 --骰投死道 安颜色
44000101 1 --日冕:苍烟落 44000101 1 --日冕:苍烟落
44000103 0 --游天知 44000103 0 --游天知
44001001 0 --血祭魇的狩夹 埃文 44001001 0 --血祭魇的狩夹 埃文
......
...@@ -38,7 +38,7 @@ function cm.initial_effect(c) ...@@ -38,7 +38,7 @@ function cm.initial_effect(c)
c:RegisterEffect(e2) c:RegisterEffect(e2)
end end
function cm.thfilter(c) function cm.thfilter(c)
return (c:IsCode(17090000) or (c:IsType(TYPE_PENDULUM) and c:IsRace(RACE_WINDBEAST) and c:IsAttribute(ATTRIBUTE_WIND) and c:IsType(TYPE_RITUAL)) and c:IsAbleToHand() return (c:IsCode(17090000) or (c:IsType(TYPE_PENDULUM) and c:IsRace(RACE_WINDBEAST) and c:IsAttribute(ATTRIBUTE_WIND) and c:IsType(TYPE_RITUAL))) and c:IsAbleToHand()
and not c:IsCode(m) and not c:IsCode(m)
end end
function cm.thtg(e,tp,eg,ep,ev,re,r,rp,chk) function cm.thtg(e,tp,eg,ep,ev,re,r,rp,chk)
......
...@@ -35,8 +35,8 @@ function cm.initial_effect(c) ...@@ -35,8 +35,8 @@ function cm.initial_effect(c)
e5:SetCategory(CATEGORY_TOHAND) e5:SetCategory(CATEGORY_TOHAND)
e5:SetType(EFFECT_TYPE_SINGLE+EFFECT_TYPE_TRIGGER_O) e5:SetType(EFFECT_TYPE_SINGLE+EFFECT_TYPE_TRIGGER_O)
e5:SetProperty(EFFECT_FLAG_DELAY+EFFECT_FLAG_DAMAGE_STEP+EFFECT_FLAG_DAMAGE_CAL) e5:SetProperty(EFFECT_FLAG_DELAY+EFFECT_FLAG_DAMAGE_STEP+EFFECT_FLAG_DAMAGE_CAL)
e6:SetCode(EVENT_REMOVE) e5:SetCode(EVENT_REMOVE)
e6:SetRange(LOCATION_REMOVED) e5:SetRange(LOCATION_REMOVED)
e5:SetCountLimit(1,18700017) e5:SetCountLimit(1,18700017)
e5:SetTarget(cm.sptg3) e5:SetTarget(cm.sptg3)
e5:SetOperation(cm.spop3) e5:SetOperation(cm.spop3)
......
...@@ -11,7 +11,7 @@ function cm.initial_effect(c) ...@@ -11,7 +11,7 @@ function cm.initial_effect(c)
local e1=Effect.CreateEffect(c) local e1=Effect.CreateEffect(c)
e1:SetDescription(aux.Stringid(m,0)) e1:SetDescription(aux.Stringid(m,0))
e1:SetCategory(CATEGORY_SPECIAL_SUMMON) e1:SetCategory(CATEGORY_SPECIAL_SUMMON)
e3:SetType(EFFECT_TYPE_IGNITION) e1:SetType(EFFECT_TYPE_IGNITION)
e1:SetRange(LOCATION_SZONE) e1:SetRange(LOCATION_SZONE)
e1:SetCountLimit(1,18700023) e1:SetCountLimit(1,18700023)
e1:SetProperty(EFFECT_FLAG_DELAY+EFFECT_FLAG_CARD_TARGET) e1:SetProperty(EFFECT_FLAG_DELAY+EFFECT_FLAG_CARD_TARGET)
......
--奇物-9 星之彩 --奇物-9 星之彩
local m=18700175 local m=18700173
local cm=_G["c"..m] local cm=_G["c"..m]
xpcall(function() require("expansions/script/1") end,function() require("script/1") end) xpcall(function() require("expansions/script/1") end,function() require("script/1") end)
function cm.initial_effect(c) function cm.initial_effect(c)
......
...@@ -64,6 +64,7 @@ function cm.activate(e,tp,eg,ep,ev,re,r,rp) ...@@ -64,6 +64,7 @@ function cm.activate(e,tp,eg,ep,ev,re,r,rp)
if g2 then if g2 then
Duel.Overlay(sc,g2) Duel.Overlay(sc,g2)
end end
end
end end
end end
function cm.discon(e,tp,eg,ep,ev,re,r,rp) function cm.discon(e,tp,eg,ep,ev,re,r,rp)
......
...@@ -14,7 +14,7 @@ function cm.initial_effect(c) ...@@ -14,7 +14,7 @@ function cm.initial_effect(c)
c:RegisterEffect(e0) c:RegisterEffect(e0)
local e1=Effect.CreateEffect(c) local e1=Effect.CreateEffect(c)
e1:SetDescription(aux.Stringid(m,0)) e1:SetDescription(aux.Stringid(m,0))
e:SetCategory(CATEGORY_EQUIP) e1:SetCategory(CATEGORY_EQUIP)
e1:SetType(EFFECT_TYPE_QUICK_O) e1:SetType(EFFECT_TYPE_QUICK_O)
e1:SetCode(EVENT_FREE_CHAIN) e1:SetCode(EVENT_FREE_CHAIN)
e1:SetRange(LOCATION_MZONE) e1:SetRange(LOCATION_MZONE)
......
...@@ -53,7 +53,7 @@ function s.initial_effect(c) ...@@ -53,7 +53,7 @@ function s.initial_effect(c)
c:RegisterEffect(e1) c:RegisterEffect(e1)
local e3=e2:Clone() local e3=e2:Clone()
e2:SetType(EFFECT_TYPE_SINGLE+EFFECT_TYPE_TRIGGER_O) e3:SetType(EFFECT_TYPE_SINGLE+EFFECT_TYPE_TRIGGER_O)
e3:SetCode(EVENT_BE_BATTLE_TARGET) e3:SetCode(EVENT_BE_BATTLE_TARGET)
c:RegisterEffect(e3) c:RegisterEffect(e3)
local e4=e2:Clone() local e4=e2:Clone()
......
--雪鸮的外包
Duel.LoadScript("c10199990.lua")
--[[
2020.9.15 "Mrs_Dice" Complete
--]]
\ No newline at end of file
--骰娘炼成 此奈
Duel.LoadScript("c44000000.lua")
local m,cm=rscf.DefineCard(44000001,"MrsDice_Taught")
if rsmd then return end
rsmd = cm
rscf.DefineSet(rsmd,"MrsDice",1)
rscf.DefineSet(rsmd,"MrsDice_Taught",2)
rscf.DefineSet(rsmd,"MrsDice_Taught_Master",3)
rsmd.acteffect={}
function rsmd.SetActCount(e1,...)
local elist={e1,...}
for _,e in pairs(elist) do
e:SetCountLimit(99)
e:SetCondition(cm.ctcon(e:GetCondition()))
e:SetTarget(cm.cttg(e:GetTarget()))
end
end
function cm.ctcon(con)
return function(e,tp,...)
if con and not con(e,tp,...) then return false end
local c=e:GetHandler()
local flag=c:GetFlagEffect(m)
local ct=Duel.GetFieldGroupCount(tp,LOCATION_ONFIELD,LOCATION_ONFIELD)
if c:IsHasEffect(44000013) then
return flag<ct
else
return flag==0
end
end
end
function cm.cttg(tg)
return function(e,tp,eg,ep,ev,re,r,rp,chk,chkc,...)
if chkc or chk==0 then return not tg or tg(e,tp,eg,ep,ev,re,r,rp,chk,chkc,...) end
tg(e,tp,eg,ep,ev,re,r,rp,chk,chkc,...)
local c=e:GetHandler()
c:RegisterFlagEffect(m,rsreset.est_pend,0,1)
end
end
function rsmd.ToGraveFun(c,code)
local e1=rsef.STO(c,EVENT_TO_GRAVE,"sp",{1,code+100},"sp","de",nil,nil,rsop.target(cm.tgspfilter,"sp",rsloc.hdg),cm.tgspop)
return e1
end
function cm.tgspop(e,tp)
rsop.SelectSpecialSummon(tp,aux.NecroValleyFilter(cm.tgspfilter),tp,rsloc.hdg,0,1,1,nil,{},e,tp)
end
function cm.tgspfilter(c,e,tp)
return rsmd.IsSet2(c) and not rsmd.IsSet3(c) and rscf.spfilter2()(c,e,tp)
end
-----------------------------------------------
function cm.initial_effect(c)
local e1=rsef.FTO(c,EVENT_SUMMON_SUCCESS,{m,0},1,"dice,ctrl,se,th",nil,LOCATION_MZONE,cm.con,nil,cm.tg,cm.op)
local e2=rsef.RegisterClone(c,e1,"code",EVENT_SPSUMMON_SUCCESS)
local e3=rsef.RegisterClone(c,e1,"code",EVENT_FLIP_SUMMON_SUCCESS)
rsmd.SetActCount(e1,e2,e3)
end
cm.toss_dice=true
function cm.cfilter(c,tp)
return c:GetSummonPlayer()==tp
end
function cm.con(e,tp,eg)
return eg:IsExists(cm.cfilter,1,nil,1-tp)
end
function cm.thfilter(c,tp)
return cm.cfilter(c,tp) and c:IsAbleToHand()
end
function cm.thfilter2(c)
return c:IsAbleToHand() and rsmd.IsSetM2(c)
end
function cm.tg(e,tp,eg,ep,ev,re,r,rp,chk)
local b1=e:GetHandler():IsControlerCanBeChanged()
local b2=eg:IsExists(cm.thfilter,1,nil,1-tp)
local b3=Duel.IsExistingMatchingCard(cm.thfilter2,tp,rsloc.dg,0,1,nil)
if chk==0 then return b1 or b2 or b3 end
Duel.SetTargetCard(eg)
Duel.SetOperationInfo(0,CATEGORY_DICE,nil,0,tp,1)
end
function cm.op(e,tp,eg,ep,ev,re,r,rp)
local dc=Duel.TossDice(tp,1)
if dc==1 or dc==2 then
local c=e:GetHandler()
if not c:IsRelateToEffect(e) or c:IsFacedown() then return end
Duel.GetControl(c,1-tp)
elseif dc==3 or dc==4 then
local tg=rsgf.GetTargetGroup():Filter(cm.thfilter,nil,1-tp)
if #tg>0 then
Duel.SendtoHand(tg,nil,REASON_EFFECT)
end
elseif dc==5 or dc==6 then
rsop.SelectToHand(tp,aux.NecroValleyFilter(cm.thfilter2),tp,rsloc.dg,0,1,1,nil,{})
end
end
\ No newline at end of file
--骰娘炼成 丛雨
Duel.LoadScript("c44000001.lua")
local m,cm=rscf.DefineCard(44000002,"MrsDice_Taught")
function cm.initial_effect(c)
local e1=rsef.QO(c,EVENT_CHAINING,{m,0},1,"dice,rec,neg,des","dcal,dsp",LOCATION_MZONE,cm.con,nil,cm.tg,cm.op)
rsmd.SetActCount(e1)
end
cm.toss_dice=true
function cm.con(e,tp,eg,ep,ev,re,r,rp)
return rp==1-tp
end
function cm.tg(e,tp,eg,ep,ev,re,r,rp,chk)
if chk==0 then return true end
Duel.SetOperationInfo(0,CATEGORY_DICE,nil,0,tp,1)
end
function cm.op(e,tp,eg,ep,ev,re,r,rp,chk)
local dc=Duel.TossDice(tp,1)
if dc==1 or dc==3 or dc==5 then
Duel.Recover(1-tp,300,REASON_EFFECT)
elseif dc==2 or dc==4 or dc==6 then
if Duel.NegateActivation(ev) and re:GetHandler():IsRelateToEffect(re) then
Duel.Destroy(eg,REASON_EFFECT)
end
end
end
\ No newline at end of file
--骰娘炼成 惠惠
Duel.LoadScript("c44000001.lua")
local m,cm=rscf.DefineCard(44000003,"MrsDice_Taught")
function cm.initial_effect(c)
local e1=rsef.FTO(c,EVENT_ATTACK_ANNOUNCE,{m,0},1,"dice,atk,dam",nil,LOCATION_MZONE,rscon.turno,nil,cm.tg,cm.op)
rsmd.SetActCount(e1)
end
cm.toss_dice=true
function cm.tg(e,tp,eg,ep,ev,re,r,rp,chk)
if chk==0 then return true end
Duel.SetOperationInfo(0,CATEGORY_DICE,nil,0,tp,1)
end
function cm.op(e,tp,eg,ep,ev,re,r,rp,chk)
local c=e:GetHandler()
local tc=Duel.GetAttacker()
if not tc:IsRelateToBattle() then return end
local dc=Duel.TossDice(tp,1)
if dc==1 then
local e1=Effect.CreateEffect(c)
e1:SetType(EFFECT_TYPE_SINGLE)
e1:SetCode(EFFECT_EXTRA_ATTACK)
e1:SetValue(1)
e1:SetReset(rsreset.est_pend)
tc:RegisterEffect(e1)
elseif dc>1 and dc<6 then
local e1=rscf.QuickBuff({c,tc},"atk+",dc>=3 and -600 or 600)
elseif dc==6 then
if Duel.NegateAttack() and tc:GetAttack()>0 then
Duel.Damage(1-tp,tc:GetAttack(),REASON_EFFECT)
end
end
end
\ No newline at end of file
--骰娘的孤注一掷!
Duel.LoadScript("c44000001.lua")
local m,cm=rscf.DefineCard(44000004,"MrsDice")
function cm.initial_effect(c)
local e1=rsef.ACT(c,nil,nil,{1,m,1},"dr,td",nil,nil,cm.cost,rsop.target({ cm.tdfilter,"td",LOCATION_HAND },{1,"dr"}),cm.act)
Duel.AddCustomActivityCounter(m,ACTIVITY_SPSUMMON,rsmd.IsSet1)
end
function cm.cost(e,tp,eg,ep,ev,re,r,rp,chk)
if chk==0 then return Duel.GetCustomActivityCount(m,tp,ACTIVITY_SPSUMMON)==0 end
local e1=rsef.FV_LIMIT_PLAYER({e:GetHandler(),tp},"sp",nil,cm.splimit,{1,0},nil,rsreset.pend)
end
function cm.splimit(e,c)
return not rsmd.IsSet1(c)
end
function cm.tdfilter(c)
return rsmd.IsSet2(c) and c:IsAbleToDeck() and not c:IsPublic()
end
function cm.act(e,tp)
Duel.Hint(HINT_SELECTMSG,tp,HINTMSG_TODECK)
local g=Duel.SelectMatchingCard(tp,cm.tdfilter,tp,LOCATION_HAND,0,1,99,nil)
if #g>0 then
Duel.ConfirmCards(1-tp,g)
local ct=Duel.SendtoDeck(g,nil,2,REASON_EFFECT)
Duel.ShuffleDeck(tp)
Duel.BreakEffect()
Duel.Draw(tp,ct+1,REASON_EFFECT)
end
end
--无可避免的检定
Duel.LoadScript("c44000001.lua")
local m,cm=rscf.DefineCard(44000005,"MrsDice_Taught")
function cm.initial_effect(c)
local e1=rsef.ACT(c)
--destroy replace
local e2=Effect.CreateEffect(c)
e2:SetType(EFFECT_TYPE_CONTINUOUS+EFFECT_TYPE_FIELD)
e2:SetCode(EFFECT_DESTROY_REPLACE)
e2:SetRange(LOCATION_SZONE)
e2:SetTarget(cm.destg)
e2:SetValue(cm.value)
e2:SetOperation(cm.desop)
c:RegisterEffect(e2)
local e3,e4=rsef.FV_CANNOT_DISABLE(c,"dise,neg",rsval.cdisneg(cm.filter))
end
function cm.dfilter(c,tp)
return c:IsControler(tp) and c:IsReason(REASON_BATTLE) and rsmd.IsSetM1(c)
end
function cm.repfilter(c)
return rsmd.IsSetM1(c) and c:IsAbleToRemove()
end
function cm.destg(e,tp,eg,ep,ev,re,r,rp,chk)
if chk==0 then return eg:IsExists(cm.dfilter,1,nil,tp)
and Duel.IsExistingMatchingCard(cm.repfilter,tp,LOCATION_GRAVE,0,1,nil) end
return Duel.SelectEffectYesNo(tp,e:GetHandler(),96)
end
function cm.value(e,c)
return c:IsControler(e:GetHandlerPlayer()) and c:IsReason(REASON_BATTLE) and rsmd.IsSetM1(c)
end
function cm.desop(e,tp,eg,ep,ev,re,r,rp)
rshint.Card(m)
Duel.Hint(HINT_SELECTMSG,tp,HINTMSG_TOGRAVE)
local g=Duel.SelectMatchingCard(tp,cm.repfilter,tp,LOCATION_GRAVE,0,1,1,nil)
Duel.Remove(g,POS_FACEUP,REASON_EFFECT)
end
function cm.filter(e,p,te,tp)
return rsmd.IsSet2(te:GetHandler()) and te:IsActiveType(TYPE_MONSTER)
end
\ No newline at end of file
--骰娘炼成 鱼仙
Duel.LoadScript("c44000001.lua")
local id,s = rscf.DefineCard(44000006,"MrsDice_Taught")
local m,cm = id,s
function cm.initial_effect(c)
c:EnableReviveLimit()
aux.AddLinkProcedure(c,rsmd.IsSet2,1)
--local e1=rsef.STO(c,EVENT_SPSUMMON_SUCCESS,{m,0},{1,m},"se,dice","de,dsp",rscon.sumtype("link"),nil,cm.tg,cm.op)
local e1 = rsef.STO(c,EVENT_SPSUMMON_SUCCESS,"th",{1,id},"se,th","de",
rscon.sumtyps("link"),nil,rsop.target(s.thfilter2,"th",LOCATION_DECK),s.thop)
--dice
local e2=Effect.CreateEffect(c)
e2:SetType(EFFECT_TYPE_FIELD+EFFECT_TYPE_CONTINUOUS)
e2:SetRange(LOCATION_GRAVE)
e2:SetCode(EVENT_TOSS_DICE_NEGATE)
e2:SetCondition(cm.dicecon)
e2:SetOperation(cm.diceop)
c:RegisterEffect(e2)
rsmd.acteffect[m]={e1}
end
cm.toss_coin=true
function s.thfilter2(c)
return c:IsCode(44000011) and c:IsAbleToHand()
end
function s.thop(e,tp)
rsop.SelectOperate("th",tp,cm.thfilter2,tp,LOCATION_DECK,0,1,1,nil,{})
end
function cm.spfilter(c,e,tp)
return rsmd.IsSetM2(c) and rscf.spfilter2()(c,e,tp)
end
function cm.thfilter(c)
return rsmd.IsSetM2(c) and c:IsAbleToHand()
end
function cm.tg(e,tp,eg,ep,ev,re,r,rp,chk)
local b1=Duel.IsExistingMatchingCard(cm.spfilter,tp,LOCATION_DECK,0,1,nil,e,tp)
local b2=Duel.IsExistingMatchingCard(cm.thfilter,tp,LOCATION_DECK,0,1,nil)
if chk==0 then return b1 or b2 end
Duel.SetOperationInfo(0,CATEGORY_DICE,nil,0,tp,1)
end
function cm.op(e,tp,eg,ep,ev,re,r,rp)
local dc=Duel.TossDice(tp,1)
if dc<4 then
rsop.SelectSpecialSummon(tp,cm.spfilter,tp,LOCATION_DECK,0,1,1,nil,{},e,tp)
elseif dc<7 then
rsop.SelectToHand(tp,cm.thfilter,tp,LOCATION_DECK,0,1,1,nil,{})
end
end
function cm.dicecon(e,tp,eg,ep,ev,re,r,rp)
return ep==tp and e:GetHandler():IsAbleToRemove() and rsmd.IsSetM2(re:GetHandler()) and Duel.GetFlagEffect(tp,m)==0
end
function cm.diceop(e,tp,eg,ep,ev,re,r,rp)
local c=e:GetHandler()
if Duel.GetFlagEffect(tp,m)~=0 then return end
if Duel.SelectEffectYesNo(tp,c,aux.Stringid(m,1)) then
Duel.Hint(HINT_CARD,0,m)
Duel.Remove(c,POS_FACEUP,REASON_EFFECT)
local ct1=bit.band(ev,0xff)
local ct2=bit.rshift(ev,16)
Duel.TossDice(ep,ct1,ct2)
Duel.RegisterFlagEffect(tp,m,RESET_PHASE+PHASE_END,0,1)
end
end
\ No newline at end of file
--当骰娘焕发生机之时
Duel.LoadScript("c44000001.lua")
local m,cm=rscf.DefineCard(44000007,"MrsDice_Taught")
function cm.initial_effect(c)
local e1=aux.AddRitualProcGreaterCode(c,44000008,LOCATION_HAND+LOCATION_GRAVE)
e1:SetTarget(cm.tg(e1:GetTarget()))
local e2=Effect.CreateEffect(c)
e2:SetCategory(CATEGORY_TOHAND+CATEGORY_SEARCH)
e2:SetType(EFFECT_TYPE_IGNITION)
e2:SetRange(LOCATION_GRAVE)
e2:SetCondition(aux.exccon)
e2:SetCost(aux.bfgcost)
e2:SetTarget(cm.thtg)
e2:SetOperation(cm.thop)
c:RegisterEffect(e2)
end
function cm.tg(tg)
return function(e,tp,eg,ep,ev,re,r,rp,chk)
if chk==0 then return tg(e,tp,eg,ep,ev,re,r,rp,chk) end
if e:IsHasType(EFFECT_TYPE_ACTIVATE) then
Duel.SetChainLimit(aux.FALSE)
end
end
end
function cm.thfilter(c)
return rsmd.IsSetST2(c) and c:IsAbleToHand()
end
function cm.thtg(e,tp,eg,ep,ev,re,r,rp,chk)
if chk==0 then return Duel.IsExistingMatchingCard(cm.thfilter,tp,LOCATION_DECK,0,1,nil) end
Duel.SetOperationInfo(0,CATEGORY_TOHAND,nil,1,tp,LOCATION_DECK)
end
function cm.thop(e,tp,eg,ep,ev,re,r,rp)
Duel.Hint(HINT_SELECTMSG,tp,HINTMSG_ATOHAND)
local g=Duel.SelectMatchingCard(tp,cm.thfilter,tp,LOCATION_DECK,0,1,1,nil)
if #g>0 then
Duel.SendtoHand(g,nil,REASON_EFFECT)
Duel.ConfirmCards(1-tp,g)
end
end
\ No newline at end of file
--众骰之始 溯洄
Duel.LoadScript("c44000001.lua")
local m,cm=rscf.DefineCard(44000008,"MrsDice_Taught")
function cm.initial_effect(c)
rscf.SetSummonCondition(c,false,aux.ritlimit)
local e1=rsef.STO(c,EVENT_SPSUMMON_SUCCESS,{m,0},{1,m},"sp","de,dsp",rscon.sumtype("rit"),nil,rsop.target(cm.spfilter,"sp",rsloc.hg),cm.spop)
local e2=rsef.I(c,{m,1},{1,m+1},nil,"tg",LOCATION_MZONE,nil,nil,rstg.target(rscf.fufilter(rsmd.IsSet2),nil,LOCATION_MZONE),cm.indop)
local e3=rsef.QO(c,nil,{m,2},1,"rm","tg",LOCATION_MZONE,cm.ctcon(2),nil,rstg.target(Card.IsAbleToRemove,"rm",0,LOCATION_MZONE),cm.rmop)
local e4=rsef.QO_NEGATE(c,"neg",1,"rm",LOCATION_MZONE,aux.AND(rscon.negcon(0),cm.ctcon(4)))
rsmd.acteffect[m]={e1,e2,e3,e4}
end
function cm.spfilter(c,e,tp)
return rscf.spfilter2(rsmd.IsSet2)(c,e,tp)
end
function cm.spop(e,tp)
local ft=Duel.GetLocationCount(tp,LOCATION_MZONE)
local sg=Duel.GetMatchingGroup(aux.NecroValleyFilter(cm.spfilter),tp,rsloc.hg,0,nil,e,tp)
local sct=math.min(ft,#sg)
if sct<=0 then return end
sct = rscon.bsdcheck(tp) and 1 or sct
rsgf.SelectSpecialSummon(sg,tp,aux.TRUE,sct,sct,nil,{})
end
function cm.indop(e,tp)
local c=e:GetHandler()
local tc=rscf.GetTargetCard()
if not tc then return end
local resetct= (Duel.GetTurnPlayer()==tp and Duel.GetCurrentPhase()<=PHASE_STANDBY) and 2 or 1
local e1=rsef.SV_INDESTRUCTABLE({c,tc},"effect",aux.indoval,nil,{rsreset.est+RESET_PHASE+PHASE_STANDBY+RESET_SELF_TURN,resetct},"cd")
end
function cm.ctcon(ct)
return function(e,tp)
local g=Duel.GetMatchingGroup(rsmd.IsSetM2,tp,LOCATION_GRAVE,0,nil)
return g:GetClassCount(Card.GetCode)>=ct
end
end
function cm.rmop(e,tp)
local c,tc=e:GetHandler(),rscf.GetTargetCard()
local fid=c:GetFieldID()
if not tc or Duel.Remove(tc,POS_FACEUP,REASON_EFFECT+REASON_TEMPORARY)<=0 then return end
tc:RegisterFlagEffect(m,rsreset.est_pend,0,1)
local e1=rsef.FC({c,tp},EVENT_PHASE+PHASE_END,nil,1,nil,nil,cm.retcon,cm.retop,rsreset.pend)
e1:SetLabelObject(tc)
end
function cm.retcon(e,tp,eg,ep,ev,re,r,rp)
return e:GetLabelObject():GetFlagEffect(m)~=0
end
function cm.retop(e,tp,eg,ep,ev,re,r,rp)
Duel.ReturnToField(e:GetLabelObject())
end
\ No newline at end of file
--骰娘源码
Duel.LoadScript("c44000001.lua")
local id,s = rscf.DefineCard(44000009,"MrsDice_Taught")
local m,cm = id,s
function cm.initial_effect(c)
--local e1=rsef.ACT(c,nil,nil,nil,"se,th",nil,nil,rscost.cost(cm.tgfilter,"tg",LOCATION_HAND,0,1,1,c),rsop.target({cm.thfilter,cm.ritcheck},"th",rsloc.dg,0,2),cm.act)
local e1 = rsef.A(c,nil,nil,{1,id},"sp",nil,nil,nil,
rsop.target(s.spfilter,"sp",rsloc.hg),s.act2)
local e2 = rsef.I(c,"td",{1,id+100},"td,th","tg",LOCATION_GRAVE,nil,
aux.bfgcost,rstg.target({s.tdfilter,"td",LOCATION_GRAVE},
{s.thfilter,"th",LOCATION_GRAVE}),s.tdop)
end
function s.tdfilter(c)
return c:IsComplexType(TYPE_RITUAL+TYPE_MONSTER) and c:IsAbleToDeck() and rsmd.IsSet2(c)
end
function s.thfilter(c)
return c:IsComplexType(TYPE_RITUAL+TYPE_SPELL) and c:IsAbleToHand() and rsmd.IsSet2(c)
end
function s.tdop(e,tp)
local g = rsgf.GetTargetGroup()
if #g ~= 2 then return end
local tc = g:GetFirst()
local tc2 = g:GetNext()
if tc2:IsType(TYPE_MONSTER) then tc,tc2 = tc2, tc end
if Duel.SendtoDeck(tc,nil,2,REASON_EFFECT) > 0 and tc:IsLocation(LOCATION_DECK) then
Duel.SendtoHand(tc2,nil,REASON_EFFECT)
Duel.ConfirmCards(1-tp,tc2)
end
end
function s.spfilter(c,e,tp)
return rscf.spfilter2()(c,e,tp) and rsmd.IsSet2(c)
end
function s.act2(e,tp)
rsop.SelectOperate("th",tp,aux.NecroValleyFilter(s.spfilter),tp,rsloc.hg,0,1,1,nil,{},e,tp)
end
function cm.tgfilter(c)
return c:IsAbleToGraveAsCost() and rsmd.IsSet1(c)
end
function cm.thfilter(c)
return c:IsType(TYPE_RITUAL) and rsmd.IsSet2(c) and c:IsAbleToHand()
end
function cm.ritcheck(g)
return g:IsExists(Card.IsType,1,nil,TYPE_MONSTER) and g:IsExists(Card.IsType,1,nil,TYPE_SPELL)
end
function cm.act(e,tp)
local g=Duel.GetMatchingGroup(aux.NecroValleyFilter(cm.thfilter),tp,rsloc.dg,0,nil)
rshint.Select(tp,"th")
local tg=g:SelectSubGroup(tp,cm.ritcheck,false,2,2)
if #tg==2 then
rsop.SendtoHand(tg,nil,REASON_EFFECT)
end
end
--广播骰娘 辉夜
Duel.LoadScript("c44000001.lua")
local m,cm=rscf.DefineCard(44000010,"MrsDice")
function cm.initial_effect(c)
c:EnableReviveLimit()
aux.AddLinkProcedure(c,aux.FilterBoolFunction(Card.IsLinkRace,RACE_CYBERSE),2,3,cm.gf)
local e1=rsef.SV_CANNOT_BE_TARGET(c,"effect")
--local e2,e3=rsef.FV_CANNOT_DISABLE(c,"dise,neg",rsval.cdisneg(cm.filter))
local e4=rsef.FTO(c,EVENT_SUMMON_SUCCESS,{m,0},1,"des","de",LOCATION_MZONE,rscon.sumtolz(true),nil,rsop.target(aux.TRUE,"des",0,LOCATION_ONFIELD),cm.desop)
local e5=rsef.RegisterClone(c,e4,"code",EVENT_SPSUMMON_SUCCESS)
end
function cm.gf(g)
return g:IsExists(rsmd.IsLinkSet2,1,nil)
end
function cm.filter(e,p,te,tp)
return rsmd.IsSet2(te:GetHandler()) and te:IsActiveType(TYPE_MONSTER)
end
function cm.desop(e,tp)
rsop.SelectDestroy(tp,aux.TRUE,tp,0,LOCATION_ONFIELD,1,1,nil,{})
end
\ No newline at end of file
--骰娘齐聚 腐鱼云城
Duel.LoadScript("c44000001.lua")
local id,s = rscf.DefineCard(44000011,"MrsDice_Taught")
local m,cm = id,s
function cm.initial_effect(c)
local e1=rsef.ACT(c)
local e2,e3=rsef.FV_UPDATE(c,"atk,def",400,aux.TargetBoolFunction(rsmd.IsSet1),{ LOCATION_MZONE,LOCATION_MZONE })
--local e4=rsef.FTO(c,EVENT_SPSUMMON_SUCCESS,{m,0},1,nil,"tg,de",LOCATION_FZONE,cm.setcon,nil,rstg.target(cm.setfilter,nil,LOCATION_GRAVE),cm.setop)
local e4=rsef.FTO(c,EVENT_SPSUMMON_SUCCESS,"th",{1,id},"th","tg,de",LOCATION_FZONE,s.thcon,nil,rstg.target(s.thfilter,nil,LOCATION_GRAVE),s.thop)
--local e5=rsef.STO(c,EVENT_TO_GRAVE,{m,1},nil,"td","tg",cm.tdcon,nil,rstg.target(cm.tdfilter,"td",LOCATION_REMOVED,0,2),cm.tdop)
local e5=rsef.STO(c,EVENT_DESTROYED,"td",{1,id+100},"td","tg",s.tdcon,nil,rstg.target(cm.tdfilter,"td",rsloc.gr,0,2),s.tdop)
end
function s.thcon(e,tp,eg)
return eg:IsExists(cm.cfilter,1,nil,tp)
end
function s.thfilter(c)
return c:IsAbleToHand() and rsmd.IsSetST1(c)
end
function s.thop(e,tp)
local tc = rscf.GetTargetCard()
if not tc then return end
Duel.SendtoHand(tc,nil,REASON_EFFECT)
Duel.ConfirmCards(1-tp,tc)
end
function cm.cfilter(c,tp)
return rsmd.IsSet1(c) and c:IsSummonType(SUMMON_TYPE_LINK) and c:GetSummonPlayer()==tp
end
function cm.setcon(e,tp,eg)
return eg:IsExists(cm.cfilter,1,nil,tp)
end
function cm.setfilter(c)
return c:IsSSetable() and rsmd.IsSetST1(c)
end
function cm.setop(e,tp)
local tc=rscf.GetTargetCard()
if tc and Duel.SSet(tp,tc)>0 then
local e1=Effect.CreateEffect(e:GetHandler())
e1:SetType(EFFECT_TYPE_SINGLE)
e1:SetCode(EFFECT_CANNOT_TRIGGER)
e1:SetReset(RESET_EVENT+RESETS_STANDARD+RESET_PHASE+PHASE_END)
tc:RegisterEffect(e1)
end
end
function cm.tdcon(e,tp)
local c=e:GetHandler()
return c:IsComplexReason(REASON_DESTROY+REASON_EFFECT) and c:GetReasonPlayer()~=tp
end
function cm.tdfilter(c)
return rsmd.IsSetM1(c) and c:IsAbleToDeck() and rscf.RemovePosCheck(c)--c:IsFaceup()
end
function cm.tdop(e,tp)
local tg=rsgf.GetTargetGroup()
if #tg>0 then
Duel.SendtoDeck(tg,nil,REASON_EFFECT)
end
end
\ No newline at end of file
--骰娘的超负荷运作
Duel.LoadScript("c44000001.lua")
local m,cm=rscf.DefineCard(44000012,"MrsDice_Taught")
function cm.initial_effect(c)
local e1=rsef.ACT(c,nil,nil,nil,"tg",nil,nil,cm.cost,rsop.target(Card.IsAbleToGrave,"tg",0,LOCATION_ONFIELD,true),cm.act)
end
function cm.cost(e,tp,eg,ep,ev,re,r,rp,chk)
local c=e:GetHandler()
local g=Duel.GetMatchingGroup(aux.TRUE,tp,LOCATION_ONFIELD,0,c)
if chk==0 then return #g>0 and g:FilterCount(Card.IsAbleToGraveAsCost,nil)==#g and g:IsExists(rsmd.IsSet1,3,nil) end
Duel.SendtoGrave(g,REASON_COST)
local og=Duel.GetOperatedGroup()
local ctype=0
for tc in aux.Next(og) do
for i,type in ipairs({TYPE_MONSTER,TYPE_SPELL,TYPE_TRAP}) do
if tc:GetOriginalType() & type ~= 0 then
ctype=ctype | type
end
end
end
if e:IsHasType(EFFECT_TYPE_ACTIVATE) then
Duel.SetChainLimit(cm.chlimit(ctype))
end
end
function cm.chlimit(ctype)
return function(e,ep,tp)
return tp==ep or e:GetHandler():GetOriginalType() & ctype==0
end
end
function cm.act(e,tp)
local g=Duel.GetFieldGroup(tp,0,LOCATION_ONFIELD)
Duel.SendtoGrave(g,REASON_EFFECT)
end
\ No newline at end of file
--骰娘心选 神田
Duel.LoadScript("c44000001.lua")
local m,cm=rscf.DefineCard(44000013,"MrsDice_Taught")
function cm.initial_effect(c)
c:EnableReviveLimit()
aux.AddLinkProcedure(c,rsmd.IsLinkSet2,2)
local e2=Effect.CreateEffect(c)
e2:SetType(EFFECT_TYPE_FIELD)
e2:SetCode(m)
e2:SetRange(LOCATION_MZONE)
e2:SetProperty(EFFECT_FLAG_IGNORE_IMMUNE)
e2:SetTarget(cm.efftg)
e2:SetTargetRange(LOCATION_MZONE,LOCATION_MZONE)
c:RegisterEffect(e2)
local e3=rsef.QO(c,EVENT_CHAINING,{m,0},1,"dice,dr,neg","dcal,dsp",LOCATION_MZONE,cm.con,nil,cm.tg,cm.op)
rsmd.SetActCount(e3)
end
cm.toss_dice=true
function cm.efftg(e,c)
return rsmd.IsOriSet2(c)
end
function cm.con(e,tp,eg,ep,ev,re,r,rp)
return rp==1-tp and re:IsHasCategory(CATEGORY_SEARCH)
end
function cm.tg(e,tp,eg,ep,ev,re,r,rp,chk)
if chk==0 then return true end
Duel.SetOperationInfo(0,CATEGORY_DICE,nil,0,tp,1)
end
function cm.op(e,tp,eg,ep,ev,re,r,rp,chk)
local dc=Duel.TossDice(tp,1)
if dc==1 or dc==4 then
Duel.Draw(1-tp,1,REASON_EFFECT)
elseif dc==2 or dc==5 then
local e1=rsef.FV_LIMIT_PLAYER({e:GetHandler(),tp},"act",cm.aclimit,nil,{0,1},nil,rsreset.pend)
elseif dc==3 or dc==6 then
Duel.NegateActivation(ev)
end
end
function cm.aclimit(e,re,tp)
return re:GetHandler():IsLocation(LOCATION_HAND)
end
\ No newline at end of file
--骰娘的流派分化
Duel.LoadScript("c44000001.lua")
local m,cm=rscf.DefineCard(44000015,"MrsDice")
function cm.initial_effect(c)
local e1=rsef.ACT(c,nil,nil,nil,"dr,rm,tg,td",nil,nil,nil,rsop.target(1,"dr",0,1),cm.act)
end
function cm.act(e,tp)
Duel.ShuffleDeck(1-tp)
if Duel.Draw(1-tp,1,REASON_EFFECT)<=0 then return end
local dc=Duel.GetOperatedGroup():GetFirst()
Duel.ConfirmCards(tp,dc)
if dc:IsType(TYPE_MONSTER) then
local g=Duel.GetFieldGroup(tp,0,LOCATION_HAND)
if #g>0 and g:FilterCount(Card.IsAbleToRemove,nil)==#g and Duel.Remove(g,POS_FACEUP,REASON_EFFECT)>0 then
Duel.Draw(1-tp,Duel.GetOperatedGroup():GetCount(),REASON_EFFECT)
end
elseif dc:IsType(TYPE_SPELL) then
local g=Duel.GetFieldGroup(tp,0,LOCATION_REMOVED)
if #g>0 then
Duel.SendtoGrave(g,REASON_EFFECT+REASON_RETURN)
end
elseif dc:IsType(TYPE_TRAP) then
local g=Duel.GetMatchingGroup(Card.IsAbleToDeck,tp,0,LOCATION_GRAVE,nil)
if #g>0 then
Duel.SendtoDeck(g,nil,2,REASON_EFFECT)
end
end
end
\ No newline at end of file
--异构同骰 铃心
Duel.LoadScript("c44000001.lua")
local m,cm=rscf.DefineCard(44000016,"MrsDice")
function cm.initial_effect(c)
c:EnableReviveLimit()
aux.AddLinkProcedure(c,aux.FilterBoolFunction(Card.IsLinkType,TYPE_EFFECT),3,6,cm.gf)
local e0=rsef.SC(c,EVENT_SPSUMMON_SUCCESS,nil,nil,"cd,uc",rscon.sumtype("link"),cm.speak)
local e1=rsef.STO(c,EVENT_SPSUMMON_SUCCESS,"tg",nil,"tg","de",rscon.sumtype("link"),nil,rsop.target2(rstg.chainlimit(0,0),cm.tgfilter,"tg",0,LOCATION_ONFIELD,true),cm.tgop)
local e2=rsef.SV_IMMUNE_EFFECT(c)
--cannot activate
local e3=Effect.CreateEffect(c)
e3:SetType(EFFECT_TYPE_FIELD)
e3:SetCode(EFFECT_CANNOT_ACTIVATE)
e3:SetProperty(EFFECT_FLAG_PLAYER_TARGET)
e3:SetRange(LOCATION_MZONE)
e3:SetTargetRange(0,1)
e3:SetCondition(cm.lcon)
e3:SetValue(aux.TRUE)
c:RegisterEffect(e3)
end
function cm.speak()
--Debug.Message("“无用者应予废弃,无能者施以规矩。方圆轮转,再分界限!连接召唤,「异构同骰 铃心」!”")
end
function cm.gf(g)
return g:IsExists(rsmd.IsLinkSet2,1,nil)
end
function cm.tgfilter(c)
return c:IsAbleToGrave() and c:IsType(TYPE_SPELL+TYPE_TRAP)
end
function cm.setfilter(c)
return c:IsType(TYPE_SPELL+TYPE_TRAP) and c:IsSSetable()
end
function cm.tgop(e,tp)
local g=Duel.GetMatchingGroup(cm.tgfilter,tp,0,LOCATION_ONFIELD,nil)
if #g>0 and Duel.SendtoGrave(g,REASON_EFFECT)>0 and Duel.GetOperatedGroup():IsExists(Card.IsLocation,1,nil,LOCATION_GRAVE) then
rsop.SelectOC("set",true)
rsop.SelectSSet(tp,cm.setfilter,tp,0,LOCATION_GRAVE,1,1,nil,{})
end
end
function cm.lcon(e)
local ph=Duel.GetCurrentPhase()
return ph>=PHASE_BATTLE_START and ph<=PHASE_BATTLE and e:GetHandler():GetMutualLinkedGroupCount()>0
end
\ No newline at end of file
--骰娘之主 古
Duel.LoadScript("c44000001.lua")
local m,cm=rscf.DefineCard(44000017,"MrsDice_Taught_Master")
function cm.initial_effect(c)
--local e1=rsmd.ToGraveFun(c,m)
local e1 = rsef.STO(c,EVENT_SPSUMMON_SUCCESS,"sp",{1,m},"sp","de",nil,nil,
rsop.target(cm.spfilter,"sp",LOCATION_HAND),cm.spop)
local e3 = rsef.RegisterClone(c,e1,"code",EVENT_SPSUMMON_SUCCESS)
local e2=rsef.QO(c,nil,"td",{1,m},"td",nil,LOCATION_GRAVE,nil,aux.bfgcost,rsop.target(Card.IsAbleToDeck,"td",0,LOCATION_ONFIELD),cm.tdop)
end
function cm.tdop(e,tp)
rsop.SelectToDeck(tp,Card.IsAbleToDeck,tp,0,LOCATION_ONFIELD,1,1,nil,{})
end
function cm.spfilter(c,e,tp)
return rscf.spfilter2()(c,e,tp) and c:IsLevel(4) and rsmd.IsSet2(c) and not rsmd.IsSet3(c)
end
function cm.spop(e,tp)
rsop.SelectOperate("sp",tp,cm.spfilter,tp,LOCATION_HAND,0,1,1,nil,{},e,tp)
end
\ No newline at end of file
--骰娘之主 追仙
Duel.LoadScript("c44000001.lua")
local m,cm=rscf.DefineCard(44000018,"MrsDice_Taught_Master")
function cm.initial_effect(c)
--local e1=rsmd.ToGraveFun(c,m)
local e1 = rsef.STO(c,EVENT_TO_GRAVE,"sp",{1,m},"sp","de",nil,nil,
rsop.target(cm.spfilter,"sp",LOCATION_GRAVE),cm.spop)
local e2=rsef.STO(c,EVENT_SPSUMMON_SUCCESS,"se",{1,m},"se,th","de",nil,nil,rsop.target(cm.thfilter,"th",LOCATION_DECK),cm.thop)
local e3=rsef.RegisterClone(c,e2,"code",EVENT_SUMMON_SUCCESS)
end
function cm.thfilter(c)
return c:IsAbleToHand() and rsmd.IsSet1(c)
end
function cm.thop(e,tp)
rsop.SelectToHand(tp,cm.thfilter,tp,LOCATION_DECK,0,1,1,nil,{})
end
function cm.spfilter(c,e,tp)
return rscf.spfilter2()(c,e,tp) and c:IsLevel(4) and rsmd.IsSet2(c) and not rsmd.IsSet3(c)
end
function cm.spop(e,tp)
rsop.SelectOperate("sp",tp,aux.NecroValleyFilter(cm.spfilter),tp,LOCATION_GRAVE,0,1,1,nil,{},e,tp)
end
\ No newline at end of file
--骰娘之主 多多
Duel.LoadScript("c44000001.lua")
local m,cm=rscf.DefineCard(44000019,"MrsDice_Taught_Master")
function cm.initial_effect(c)
--local e1=rsmd.ToGraveFun(c,m)
local e1 = rsef.I(c,"sp",{1,m},"sp",nil,LOCATION_MZONE,
rscon.excard2(cm.cfilter,LOCATION_MZONE),nil,
rsop.target(cm.spfilter,"sp",LOCATION_DECK),cm.spop)
--end battle phase
local e1=Effect.CreateEffect(c)
e1:SetDescription(aux.Stringid(m,0))
e1:SetType(EFFECT_TYPE_QUICK_O)
e1:SetCode(EVENT_ATTACK_ANNOUNCE)
e1:SetRange(LOCATION_GRAVE)
e1:SetCountLimit(1,m)
e1:SetCondition(cm.condition)
e1:SetCost(cm.cost)
e1:SetOperation(cm.operation)
c:RegisterEffect(e1)
end
function cm.cfilter(c)
return not c:IsCode(m) and rsmd.IsSet1(c)
end
function cm.condition(e,tp,eg,ep,ev,re,r,rp)
local at=Duel.GetAttacker()
return at:GetControler()~=tp
end
function cm.cost(e,tp,eg,ep,ev,re,r,rp,chk)
if chk==0 then return e:GetHandler():IsAbleToDeckAsCost() end
Duel.SendtoDeck(e:GetHandler(),nil,2,REASON_COST)
end
function cm.operation(e,tp,eg,ep,ev,re,r,rp)
if Duel.NegateAttack() then
Duel.BreakEffect()
Duel.SkipPhase(1-tp,PHASE_BATTLE,RESET_PHASE+PHASE_BATTLE_STEP,1)
end
end
function cm.spfilter(c,e,tp)
return rscf.spfilter2()(c,e,tp) and c:IsLevel(4) and rsmd.IsSet2(c) and not rsmd.IsSet3(c)
end
function cm.spop(e,tp)
rsop.SelectOperate("sp",tp,cm.spfilter,tp,LOCATION_DECK,0,1,1,nil,{},e,tp)
end
--骰娘的自检重启
Duel.LoadScript("c44000001.lua")
local m,cm=rscf.DefineCard(44000021,"MrsDice_Taught")
function cm.initial_effect(c)
local e1 = rsef.A(c,EVENT_DESTROYED,nil,{1,m},"te,td","de",cm.con,nil,rsop.target({cm.tefilter,"te",true,true,1},{Card.IsAbleToDeck,"td",LOCATION_ONFIELD,LOCATION_ONFIELD,1,1,c}),cm.act)
local e2 = rsef.QO(c,nil,"td",{1,m+100},"td,sp","tg",LOCATION_GRAVE,aux.exccon,aux.bfgcost,rstg.target({cm.tdfilter,"td",LOCATION_REMOVED },{"opc",Card.IsAbleToDeck,"td",0,LOCATION_MZONE}),cm.tdop)
end
function cm.con(e,tp,eg)
return #eg == 1
end
function cm.tefilter(c,e,tp,eg)
return c:IsPreviousLocation(LOCATION_MZONE) and c:IsAbleToExtra() and c:IsPreviousControler(tp) and c:GetPreviousTypeOnField() & TYPE_LINK ~= 0 and rsmd.IsPreSet1(c) and c:IsLinkAbove(1)
end
function cm.act(e,tp,eg)
local tc = eg:GetFirst()
if not tc:IsRelateToEffect(e) or Duel.SendtoDeck(tc,nil,2,REASON_EFFECT) <= 0 then return end
if not rsop.CheckOperateSuccess(LOCATION_EXTRA) then return end
local link = tc:GetLink()
rsop.SelectOC(nil,true)
rsop.SelectOperate("td",tp,Card.IsAbleToDeck,tp,LOCATION_ONFIELD,LOCATION_ONFIELD,1,link,aux.ExceptThisCard(e),{})
end
function cm.tdfilter(c)
return c:IsFaceup() and rsmd.IsSetM1(c) and c:IsAbleToDeck()
end
function cm.spfilter(c,e,tp)
return rsmd.IsSet1(c) and c:IsLinkBelow(2) and rscf.spfilter2()(c,e,tp)
end
function cm.tdop(e,tp)
local tc = rscf.GetTargetCard()
if not tc then return end
local og, tc2 = rsop.SelectCards("td",tp,Card.IsAbleToDeck,tp,0,LOCATION_MZONE,1,1,nil,{})
if not tc2 or Duel.SendtoDeck(Group.FromCards(tc,tc2) , nil, 2 , REASON_EFFECT ) <= 0 or not rsop.CheckOperateSuccess(rsloc.de) then return end
rsop.SelectOC("sp",true)
rsop.SelectOperate("sp",tp,cm.spfilter,tp,LOCATION_EXTRA,0,1,1,nil,{},e,tp)
end
\ No newline at end of file
--骰娘的系统转换
Duel.LoadScript("c44000001.lua")
local m,cm=rscf.DefineCard(44000022,"MrsDice_Taught")
function cm.initial_effect(c)
local e1 = rsef.A(c,EVENT_DESTROYED,nil,{1,m},"sp,dd,res","de",nil,nil,cm.target,cm.activate)
local e2 = rsef.FTO(c,EVENT_DESTROYED,"sset",{1,m + 100},nil,"de",LOCATION_GRAVE,cm.setcon,aux.bfgcost,rsop.target(cm.setfilter,"sset",LOCATION_DECK),cm.setop)
end
function cm.setcon(e,tp,eg)
return #eg == 1 and aux.exccon(e,tp) and eg:GetFirst():GetReasonPlayer() ~= tp and rsmd.IsSetST1(eg:GetFirst())
end
function cm.setfilter(c,e,tp,eg)
if not rsmd.IsSetST2(c) or c:IsCode(eg:GetFirst():GetCode()) then return false end
local b1 = c:IsSSetable()
local b2 = c:IsType(TYPE_CONTINUOUS) and c:GetActivateEffect() and c:GetActivateEffect():IsActivatable(tp,true,true)
return b1 or b2
end
function cm.setop(e,tp,eg)
local og,tc = rsop.SelectCards("sset",tp,cm.setfilter,tp,LOCATION_DECK,0,1,1,nil,e,tp,eg)
if not tc then return end
local b1 = tc:IsSSetable()
local b2 = tc:IsType(TYPE_CONTINUOUS) and tc:GetActivateEffect() and tc:GetActivateEffect():IsActivatable(tp,true,true)
local op = rshint.SelectOption(tp,b1,"sset",b2,"act")
if op == 1 then
Duel.SSet(tp,tc)
else
rsop.MoveToField_Activate(tc,tp,tp,LOCATION_SZONE,POS_FACEUP,true)
end
end
function cm.dfilter(c)
return rsmd.IsSet2(c) and c:IsLevelAbove(1) and c:IsAbleToGrave()
end
function cm.filter(ec)
return function(c,e,tp)
return rsmd.IsSet2(c) and not c:IsCode(ec:GetCode())
end
end
function cm.rcheck(tp,g,c)
local ct = Duel.GetFieldGroupCount(tp,0,LOCATION_ONFIELD) - Duel.GetFieldGroupCount(tp,LOCATION_ONFIELD,0)
if ct <= 0 then return false end
--return g:FilterCount(Card.IsLocation,nil,LOCATION_DECK) <= ct
return g:FilterCount(Card.IsLocation,nil,LOCATION_DECK) <= 1
end
function cm.rgcheck(g)
local tp = g:GetFirst():GetControler()
local ct = Duel.GetFieldGroupCount(tp,0,LOCATION_ONFIELD) - Duel.GetFieldGroupCount(tp,LOCATION_ONFIELD,0)
if ct <= 0 then return false end
--return g:FilterCount(Card.IsLocation,nil,LOCATION_DECK)<=ct
return g:FilterCount(Card.IsLocation,nil,LOCATION_DECK) <= 1
end
function cm.target(e,tp,eg,ep,ev,re,r,rp,chk)
if chk==0 then
if #eg ~= 1 then return false end
local ec = eg:GetFirst()
if not rsmd.IsPreSet2(ec) and ec:IsPreviousControler(tp) and ec:IsPreviousLocation(LOCATION_MZONE) and ec:GetPreviousTypeOnField() & TYPE_RITUAL ~= 0 then return false end
local mg=Duel.GetRitualMaterial(tp)
local dg=Duel.GetMatchingGroup(cm.dfilter,tp,LOCATION_DECK,0,nil)
aux.RCheckAdditional=cm.rcheck
aux.RGCheckAdditional=cm.rgcheck
local res=Duel.IsExistingMatchingCard(aux.RitualUltimateFilter,tp,LOCATION_GRAVE,0,1,nil,cm.filter(ec),e,tp,mg,dg,Card.GetLevel,"Greater")
aux.RCheckAdditional=nil
aux.RGCheckAdditional=nil
return res
end
Duel.SetOperationInfo(0,CATEGORY_SPECIAL_SUMMON,nil,1,tp,LOCATION_GRAVE)
end
function cm.activate(e,tp,eg,ep,ev,re,r,rp)
local m=Duel.GetRitualMaterial(tp)
local dg=Duel.GetMatchingGroup(cm.dfilter,tp,LOCATION_DECK,0,nil)
Duel.Hint(HINT_SELECTMSG,tp,HINTMSG_SPSUMMON)
aux.RCheckAdditional=cm.rcheck
aux.RGCheckAdditional=cm.rgcheck
local tg=Duel.SelectMatchingCard(tp,aux.NecroValleyFilter(aux.RitualUltimateFilter),tp,LOCATION_GRAVE,0,1,1,nil,cm.filter(eg:GetFirst()),e,tp,m,dg,Card.GetLevel,"Greater")
local tc=tg:GetFirst()
if tc then
local mg=m:Filter(Card.IsCanBeRitualMaterial,tc,tc)
mg:Merge(dg)
if tc.mat_filter then
mg=mg:Filter(tc.mat_filter,tc,tp)
else
mg:RemoveCard(tc)
end
Duel.Hint(HINT_SELECTMSG,tp,HINTMSG_RELEASE)
aux.GCheckAdditional=aux.RitualCheckAdditional(tc,tc:GetLevel(),"Greater")
local mat=mg:SelectSubGroup(tp,aux.RitualCheck,false,1,tc:GetLevel(),tp,tc,tc:GetLevel(),"Greater")
aux.GCheckAdditional=nil
if not mat or mat:GetCount()==0 then
aux.RCheckAdditional=nil
aux.RGCheckAdditional=nil
return
end
tc:SetMaterial(mat)
local dmat=mat:Filter(Card.IsLocation,nil,LOCATION_DECK)
if dmat:GetCount()>0 then
mat:Sub(dmat)
Duel.SendtoGrave(dmat,REASON_EFFECT+REASON_MATERIAL+REASON_RITUAL)
end
Duel.ReleaseRitualMaterial(mat)
Duel.BreakEffect()
Duel.SpecialSummon(tc,SUMMON_TYPE_RITUAL,tp,tp,false,true,POS_FACEUP)
local e1 = rsef.SV_Card({e:GetHandler(),tc},"im",cm.imval,nil,nil,nil,{rsrst.ep, 2})
tc:CompleteProcedure()
end
aux.RCheckAdditional=nil
aux.RGCheckAdditional=nil
end
function cm.imval(e,re)
return rsval.imoe(e,re) and re:IsActiveType(TYPE_MONSTER)
end
\ No newline at end of file
--各有所见的骰娘炼成
Duel.LoadScript("c44000001.lua")
local m,cm=rscf.DefineCard(44000023,"MrsDice_Taught")
function cm.initial_effect(c)
--Activate
local e1 = aux.AddRitualProcGreater2(c,rsmd.IsSet2,nil,aux.FilterBoolFunction(Card.IsRace,RACE_CYBERSE))
e1:SetOperation(cm.act(e1:GetOperation()))
local e2 = rsef.I(c,"th",{1,m},"th",nil,LOCATION_GRAVE,
cm.thcon,nil,rsop.target(Card.IsAbleToHand,"th"),cm.thop)
end
function cm.act(op)
return function(e,tp,...)
op(e,tp,...)
local tc = Duel.GetOperatedGroup():GetFirst()
if tc and tc:IsLocation(LOCATION_MZONE) and tc:GetReasonEffect() == e then
local e1=Effect.CreateEffect(e:GetHandler())
e1:SetType(EFFECT_TYPE_SINGLE)
e1:SetProperty(EFFECT_FLAG_SINGLE_RANGE)
e1:SetRange(LOCATION_MZONE)
e1:SetCode(EFFECT_IMMUNE_EFFECT)
e1:SetReset(RESET_EVENT+RESETS_STANDARD+RESET_PHASE+PHASE_END)
e1:SetValue(cm.efilter)
e1:SetOwnerPlayer(tp)
tc:RegisterEffect(e1)
end
end
end
function cm.efilter(e,re)
return e:GetOwnerPlayer()~=re:GetOwnerPlayer() and re:IsActiveType(TYPE_SPELL+TYPE_TRAP)
end
function cm.cfilter(c)
return c:IsFaceup() and rsmd.IsSetM2(c) and c:IsType(TYPE_RITUAL)
end
function cm.thcon(e,tp)
local g = Duel.GetMatchingGroup(cm.cfilter,tp,rsloc.mg,0,nil)
return g:GetClassCount(Card.GetCode)>=2
end
function cm.thop(e,tp)
local c = rscf.GetSelf(e)
if c then
Duel.SendtoHand(c,nil,REASON_EFFECT)
end
end
\ No newline at end of file
--齐骰并进 仑质
Duel.LoadScript("c44000001.lua")
local m,cm=rscf.DefineCard(44000024,"MrsDice_Taught")
function cm.initial_effect(c)
c:EnableReviveLimit()
--indes
local e1=Effect.CreateEffect(c)
e1:SetType(EFFECT_TYPE_FIELD)
e1:SetCode(EFFECT_INDESTRUCTABLE_BATTLE)
e1:SetRange(LOCATION_MZONE)
e1:SetTargetRange(LOCATION_MZONE,0)
e1:SetTarget(rsmd.IsSet2)
e1:SetValue(1)
c:RegisterEffect(e1)
--search
local e4=Effect.CreateEffect(c)
e4:SetDescription(aux.Stringid(m,0))
e4:SetCategory(CATEGORY_TOHAND+CATEGORY_SEARCH)
e4:SetType(EFFECT_TYPE_SINGLE+EFFECT_TYPE_TRIGGER_O)
e4:SetProperty(EFFECT_FLAG_DAMAGE_STEP+EFFECT_FLAG_DELAY)
e4:SetCode(EVENT_TO_GRAVE)
e4:SetCountLimit(1,m)
e4:SetTarget(cm.thtg)
e4:SetOperation(cm.thop)
c:RegisterEffect(e4)
end
function cm.thfilter(c)
return c:IsRace(RACE_SPELLCASTER) and rsmd.IsSet2(c) and not c:IsCode(m) and c:IsAbleToHand()
end
function cm.thtg(e,tp,eg,ep,ev,re,r,rp,chk)
if chk==0 then return Duel.IsExistingMatchingCard(cm.thfilter,tp,LOCATION_DECK,0,1,nil) end
Duel.SetOperationInfo(0,CATEGORY_TOHAND,nil,1,tp,LOCATION_DECK)
end
function cm.thop(e,tp,eg,ep,ev,re,r,rp)
Duel.Hint(HINT_SELECTMSG,tp,HINTMSG_ATOHAND)
local g=Duel.SelectMatchingCard(tp,cm.thfilter,tp,LOCATION_DECK,0,1,1,nil)
if g:GetCount()>0 then
Duel.SendtoHand(g,nil,REASON_EFFECT)
Duel.ConfirmCards(1-tp,g)
end
end
--万面千骰 惠惠
Duel.LoadScript("c44000001.lua")
local m,cm=rscf.DefineCard(44000025,"MrsDice_Taught")
function cm.initial_effect(c)
c:EnableReviveLimit()
local e1 = rsef.SV_Card(c,"race+",RACE_CYBERSE,"sr",rsloc.mg)
local e2 = rsef.QO(c,EVENT_CHAINING,"des",{1,m},nil,nil,LOCATION_MZONE,
cm.rcon,nil,cm.rtg,cm.rop)
local e3 = rsef.STO(c,EVENT_DESTROYED,"sp",{1,m+100},"sp","de",nil,
nil,rsop.target(cm.spfilter,"sp",rsloc.hdg),cm.spop)
end
function cm.spfilter(c,e,tp)
return c:IsCode(44000003) and rscf.spfilter2()(c,e,tp)
end
function cm.spop(e,tp)
local c = e:GetHandler()
local ct,og,tc = rsop.SelectOperate("sp",tp,aux.NecroValleyFilter(cm.spfilter),tp,rsloc.hdg,0,1,1,nil,{},e,tp)
if not tc then return end
local e1=Effect.CreateEffect(c)
local reset=RESET_EVENT+RESETS_STANDARD-RESET_TURN_SET+RESET_PHASE+PHASE_END
e1:SetType(EFFECT_TYPE_SINGLE)
e1:SetCode(EFFECT_UNRELEASABLE_SUM)
e1:SetReset(reset)
e1:SetValue(1)
tc:RegisterEffect(e1)
local e2=Effect.CreateEffect(c)
e2:SetType(EFFECT_TYPE_SINGLE)
e2:SetCode(EFFECT_UNRELEASABLE_NONSUM)
e2:SetReset(reset)
e2:SetValue(1)
tc:RegisterEffect(e2)
end
function cm.rcon(e,tp,eg,ep,ev,re,r,rp)
return ep~=tp and re:IsActiveType(TYPE_MONSTER)
end
function cm.rtg(e,tp,eg,ep,ev,re,r,rp,chk)
if chk==0 then return Duel.IsExistingMatchingCard(aux.TRUE,rp,0,LOCATION_ONFIELD,1,nil) end
end
function cm.rop(e,tp,eg,ep,ev,re,r,rp)
local g=Group.CreateGroup()
Duel.ChangeTargetCard(ev,g)
Duel.ChangeChainOperation(ev,cm.repop)
end
function cm.repop(e,tp,eg,ep,ev,re,r,rp)
rsop.SelectOperate("des",tp,aux.TRUE,tp,LOCATION_ONFIELD,0,1,1,nil,{})
end
\ No newline at end of file
--骰极 斯塔尼亚
Duel.LoadScript("c44000001.lua")
local m,cm=rscf.DefineCard(44000026,"MrsDice_Taught")
function cm.initial_effect(c)
c:EnableReviveLimit()
local e1 = rsef.SV_Card(c,"mat",cm.val,"cd")
local e2 = rsef.STO(c,EVENT_SPSUMMON_SUCCESS,"th",nil,"th","de",
rscon.sumtyps("rit"),nil,
rsop.target2(cm.fun,cm.thfilter,"th",0,LOCATION_ONFIELD),cm.thop)
e2:SetLabelObject(e1)
local e3 = rsef.STO(c,EVENT_LEAVE_FIELD,"sp",nil,"th,sp","de,tg",
cm.spcon,rscost.cost(cm.tgfilter,"tg",LOCATION_HAND),
rstg.target(cm.spfilter,"sp,th",LOCATION_REMOVED),cm.spop)
end
function cm.spfilter(c,e,tp)
return c:IsFaceup() and rsmd.IsSetM2(c) and (rscf.spfilter2()(c,e,tp) or c:IsAbleToHand())
end
function cm.spop(e,tp)
local tc = rscf.GetTargetCard()
if not tc then return end
local b1 = rscf.spfilter2()(tc,e,tp)
local b2 = tc:IsAbleToHand()
local op = rshint.SelectOption(tp,b1,"sp",b2,"th")
if op == 1 then
Duel.SpecialSummon(tc,0,tp,tp,false,false,POS_FACEUP)
else
Duel.SendtoHand(tc,nil,REASON_EFFECT)
end
end
function cm.tgfilter(c)
return c:IsRace(RACE_CYBERSE) and c:IsLevel(4) and c:IsAbleToGraveAsCost()
end
function cm.fun(g,e,tp)
if e:GetLabelObject():GetLabel() == 100 then
e:SetCategory(CATEGORY_TOHAND+CATEGORY_REMOVE)
else
e:SetCategory(CATEGORY_TOHAND)
end
end
function cm.thfilter(c)
return c:IsFacedown()
end
function cm.gcheck(g,e,tp)
return g:FilterCount(Card.IsAbleToHand,nil) == #g or (g:FilterCount(Card.IsAbleToRemove,nil,tp,POS_FACEDOWN) == #g and e:GetLabelObject():GetLabel() == 100)
end
function cm.thop(e,tp)
local g = rsop.SelectCards("th",tp,{cm.thfilter,cm.gcheck},tp,0,LOCATION_ONFIELD,1,2,nil,{},e,tp)
if #g <= 0 then return end
local b1 = g:FilterCount(Card.IsAbleToHand,nil) == #g
local b2 = g:FilterCount(Card.IsAbleToRemove,nil,tp,POS_FACEDOWN) == #g and e:GetLabelObject():GetLabel() == 100
local op = rshint.SelectOption(tp,b1,"th",b2,"rm")
if op == 1 then
Duel.SendtoHand(g,nil,REASON_EFFECT)
else
Duel.Remove(g,POS_FACEDOWN,REASON_EFFECT)
end
end
function cm.cfilter(c)
return rsmd.IsSetM2(c) and c:IsType(TYPE_RITUAL) and not c:IsCode(m)
end
function cm.val(e,c)
e:SetLabel(0)
local mat = c:GetMaterial()
if mat:IsExists(cm.cfilter,1,nil) then
e:SetLabel(100)
end
end
--骰娘炼成 扫晴娘
Duel.LoadScript("c44000001.lua")
local id,s = rscf.DefineCard(44000027,"MrsDice_Taught")
function s.initial_effect(c)
--special summon
local e1=Effect.CreateEffect(c)
e1:SetDescription(aux.Stringid(id,0))
e1:SetType(EFFECT_TYPE_FIELD)
e1:SetProperty(EFFECT_FLAG_UNCOPYABLE)
e1:SetCode(EFFECT_SPSUMMON_PROC)
e1:SetRange(LOCATION_HAND)
e1:SetCountLimit(1,id+EFFECT_COUNT_CODE_OATH)
e1:SetCondition(s.spcon)
e1:SetValue(s.spval)
c:RegisterEffect(e1)
local e2 = rsef.STO(c,EVENT_SPSUMMON_SUCCESS,"dice",{1,id+100},"dice,se,th,sp","de",
s.thcon,nil,
rsop.target(s.thfilter,"dum",LOCATION_DECK),s.thop)
local e3 = rsef.RegisterClone(c,e2,"code",EVENT_SUMMON_SUCCESS)
rsmd.SetActCount(e2,e3)
end
function s.thcon(e,tp)
local c = e:GetHandler()
local zone = s.checkzone(tp)
return c:IsLocation(LOCATION_MZONE) and (2^c:GetSequence()) & zone > 0
end
function s.cfilter(c)
return c:IsFaceup() and rsmd.IsSetM2(c) and c:IsType(TYPE_LINK)
end
function s.checkzone(tp)
local zone=0
local g=Duel.GetMatchingGroup(s.cfilter,tp,LOCATION_MZONE,LOCATION_MZONE,nil)
for tc in aux.Next(g) do
zone=bit.bor(zone,tc:GetLinkedZone(tp))
end
return bit.band(zone,0x1f)
end
function s.spcon(e,c)
if c==nil then return true end
local tp=c:GetControler()
local zone=s.checkzone(tp)
return Duel.GetLocationCount(tp,LOCATION_MZONE,tp,LOCATION_REASON_TOFIELD,zone)>0
end
function s.spval(e,c)
local tp=c:GetControler()
local zone=s.checkzone(tp)
return 0,zone
end
function s.thfilter(c,e,tp)
local dice = e:GetLabel()
local b1 = rsmd.IsSetM2(c) and rscf.spfilter2()(c,e,tp) and c:IsRace(RACE_SPELLCASTER)
local b2 = rsmd.IsSetST2(c) and c:IsAbleToHand()
if dice == 0 then return b1 or b2
elseif dice == 1 or dice == 2 or dice == 6 then return b1
elseif dice == 3 or dice == 4 or dice == 5 then return b2
end
return false
end
function s.thop(e,tp)
local dice = Duel.TossDice(tp,1)
e:SetLabel(dice)
if dice == 1 or dice == 2 or dice == 6 then
rsop.SelectOperate("sp",tp,s.thfilter,tp,LOCATION_DECK,0,1,1,nil,{0,tp,tp,false,false,POS_FACEUP,nil,{"dis,dise",1}},e,tp)
elseif dice == 3 or dice == 4 or dice == 5 then
rsop.SelectOperate("th",tp,s.thfilter,tp,LOCATION_DECK,0,1,1,nil,{})
else
end
e:SetLabel(0)
end
\ No newline at end of file
--骰娘之主 小黑
Duel.LoadScript("c44000001.lua")
local id,s = rscf.DefineCard(44000028,"MrsDice_Taught")
function s.initial_effect(c)
local e1 = rsef.I(c,"th",{1,id},"se,th,tg",nil,LOCATION_HAND,nil,
rscost.cost(0,"dh"),rsop.target({s.tgfilter,"tg",LOCATION_DECK},
{aux.TRUE,"th",LOCATION_DECK}),s.thop)
local e2 = rsef.I(c,"sp",{1,id},"sp",nil,LOCATION_GRAVE,nil,
rscost.cost(s.rmfilter,"rm",LOCATION_GRAVE,0,1,1,c),
rsop.target(rscf.spfilter2(),"sp"),s.spop)
end
function s.tgfilter(c,e,tp)
return c:IsComplexType(TYPE_MONSTER+TYPE_RITUAL) and rsmd.IsSetM2(c) and c:IsAbleToGrave() and Duel.IsExistingMatchingCard(s.thfilter,tp,LOCATION_DECK,0,1,c,c:GetCode())
end
function s.thfilter(c,code)
return rsmd.IsSetM2(c) and c:IsAbleToHand() and c:IsComplexType(TYPE_MONSTER+TYPE_RITUAL) and not c:IsCode(code)
end
function s.thop(e,tp)
if rsop.SelectOperate("tg",tp,s.tgfilter,tp,LOCATION_DECK,0,1,1,nil,{},e,tp) > 0 and
rsop.CheckOperateCorrectly(LOCATION_GRAVE) then
rsop.SelectOperate("th",tp,s.thfilter,tp,LOCATION_DECK,0,1,1,nil,{},Duel.GetOperatedGroup():GetFirst():GetCode())
end
end
function s.rmfilter(c)
return rsmd.IsSet2(c) and c:IsAbleToRemoveAsCost()
end
function s.spop(e,tp)
local c = rscf.GetSelf(e)
if c then
rssf.SpecialSummon(c,0,tp,tp,false,false,POS_FACEUP,nil,{"rlf",LOCATION_REMOVED})
end
end
\ No newline at end of file
--取巧骰机 青木莲
Duel.LoadScript("c44000001.lua")
local id,s = rscf.DefineCard(44000029,"MrsDice_Taught")
function s.initial_effect(c)
c:EnableReviveLimit()
aux.AddLinkProcedure(c,aux.FilterBoolFunction(Card.IsLinkRace,RACE_SPELLCASTER+RACE_CYBERSE),2)
local e1 = rsef.QO(c,nil,"dis",{1,id},"dis","tg",LOCATION_MZONE,nil,nil,
rstg.target(aux.NegateAnyFilter,"dis",0,LOCATION_ONFIELD,s.ct1,s.ct2),s.disop)
local e2 = rsef.STO(c,EVENT_RELEASE,"th",{1,id+1},"se,th","de",nil,nil,
rsop.target(s.thfilter,"th",rsloc.dg),s.thop)
end
function s.ct1(e,tp)
local g = Duel.GetMatchingGroup(rscf.IsComplexType,tp,LOCATION_GRAVE,0,nil,TYPE_MONSTER,true,TYPE_RITUAL,TYPE_LINK)
return math.min(#g,1)
end
function s.ct2(e,tp)
local g = Duel.GetMatchingGroup(rscf.IsComplexType,tp,LOCATION_GRAVE,0,nil,TYPE_MONSTER,true,TYPE_RITUAL,TYPE_LINK)
local ct = 0
if g:IsExists(Card.IsType,1,nil,TYPE_RITUAL) then ct = ct + 1 end
if g:IsExists(Card.IsType,1,nil,TYPE_LINK) then ct = ct + 1 end
return math.max(ct,1)
end
function s.disop(e,tp)
local g = rsgf.GetTargetGroup(Card.IsFaceup)
for tc in aux.Next(g) do
local e1,e2 = rscf.QuickBuff({e:GetHandler(),tc},"dis,dise",1,"rst",rsrst.std_ep)
end
end
function s.thfilter(c)
return rsmd.IsSet2(c) and c:IsAbleToHand()
end
function s.thop(e,tp)
rsop.SelectOperate("th",tp,aux.NecroValleyFilter(s.thfilter),tp,rsloc.dg,0,1,1,nil,{})
end
\ No newline at end of file
--骰投死道 安颜色
Duel.LoadScript("c44000001.lua")
local id,s = rscf.DefineCard(44000030,"MrsDice_Taught")
function s.initial_effect(c)
local e1 = rscf.SetSummonCondition(c,false,aux.ritlimit)
local e2 = rsef.FV_Player(c,"sp~",1,s.lmtg,{0,1},nil,LOCATION_MZONE)
local e3 = rsef.FTO(c,EVENT_CHAINING,"tg",{1,id},"tg","de",LOCATION_MZONE,
s.tgcon,nil,rsop.target({s.tgfilter,"tg",LOCATION_EXTRA},
{Card.IsAbleToGrave,"tg",0,LOCATION_EXTRA}),s.tgop)
local e4 = rsef.STO(c,EVENT_TO_GRAVE,"sp",{1,id+100},"sp","de",
rscon.sumtyps("rit"),nil,rsop.target({s.spfilter,s.gchk},
"sp",LOCATION_EXTRA,0,1,5),s.spop)
end
function s.lmtg(e,c)
return not c:IsLocation(LOCATION_EXTRA) or c:IsType(TYPE_LINK)
end
function s.tgcon(e,tp,eg,ep,ev,re,r,rp)
return rp ~= tp
end
function s.tgfilter(c)
return c:IsType(TYPE_LINK)
end
function s.tgfilter(c,lnk)
return c:IsType(TYPE_LINK) and c:IsAbleToGrave() and c:IsLink(lnk)
end
function s.tgop(e,tp)
local ct,og,tc = rsop.SelectOperate("cfm",tp,s.tgfilter,tp,LOCATION_EXTRA,0,1,1,nil,{})
if not tc then return end
local g = Duel.GetFieldGroup(tp,0,LOCATION_EXTRA)
if #g <= 0 then return end
Duel.BreakEffect()
Duel.ConfirmCards(tp,g)
rsop.SelectOperate("tg",tp,s.tgfilter,tp,0,LOCATION_EXTRA,1,1,nil,{},tc:GetLink())
end
function s.spfilter(c,e,tp)
return c:IsCanBeSpecialSummoned(e,SUMMON_TYPE_LINK,tp,false,false) and rsmd.IsSet2(c) and c:IsType(TYPE_LINK) and c:IsLinkAbove(1) and aux.MustMaterialCheck(nil,tp,EFFECT_MUST_BE_LMATERIAL)
end
function s.gchk(g,e,tp)
local lnk = g:GetSum(Card.GetLink)
local lv = math.floor(e:GetHandler():GetLevel()/2)
if #g >= 2 and rssf.CheckBlueEyesSpiritDragon(tp) then return false end
return Duel.GetLocationCountFromEx(tp,tp,nil,TYPE_LINK) >= #g and lnk == lv
end
function s.spop(e,tp)
local e1 = rsef.FV_Player(c,"sp~",1,s.lmtg2,{1,0},nil,LOCATION_MZONE,nil,rsrst.ep)
rsop.SelectOperate("sp",tp,{s.spfilter,s.gchk},tp,LOCATION_EXTRA,0,1,5,nil,{SUMMON_TYPE_LINK,tp,tp,false,false,POS_FACEUP,nil,{"cp",true,"mat",Group.CreateGroup()}},e,tp)
end
function s.lmtg2(e,c)
return not c:IsLocation(LOCATION_EXTRA) or (c:IsType(TYPE_LINK) and rsmd.IsSet2(c))
end
\ No newline at end of file
--骰娘炼成编年史
Duel.LoadScript("c44000001.lua")
local id,s = rscf.DefineCard(44000031,"MrsDice_Taught")
function s.initial_effect(c)
local e1 = rsef.A(c)
local e2 = rsef.FV_Card(c,"inde",aux.indoval,aux.TargetBoolFunction(
rsmd.IsSet1),{LOCATION_MZONE,0},nil,LOCATION_SZONE)
local e3 = rsef.FV_Player(c,id,1,nil,{1,0},nil,LOCATION_SZONE)
rsef.effet_no_register = true
local e4 = rsef.I(c,"sp",1,"sp",nil,LOCATION_MZONE,s.spcon,nil,
rsop.target(s.spfilter,"sp",rsloc.gr),s.spop)
rsef.effet_no_register = false
local e5=Effect.CreateEffect(c)
e5:SetType(EFFECT_TYPE_FIELD+EFFECT_TYPE_GRANT)
e5:SetRange(LOCATION_SZONE)
e5:SetTargetRange(LOCATION_MZONE,0)
e5:SetTarget(s.eftg)
e5:SetLabelObject(e4)
c:RegisterEffect(e5)
local ge1 = rsef.FC_Global(0,EVENT_SPSUMMON_SUCCESS,id,s.regcon,s.regop)
local ge2 = rsef.FC_Global(0,EVENT_ADJUST,id,nil,s.efop)
end
if not rsmd.cplist then
rsmd.cplist = { }
end
function s.rfilter(c)
return rsmd.IsSet2(c) and c:IsType(TYPE_RITUAL) and c:IsSummonType(SUMMON_TYPE_RITUAL) and c:GetMaterialCount() > 0
end
function s.regcon(e,tp,eg)
return eg:IsExists(s.rfilter,nil,1)
end
function s.mfilter(c)
return c:IsReason(REASON_RELEASE+REASON_EFFECT+REASON_MATERIAL) and rsmd.IsSetM1(c)
end
function s.regop(e,tp,eg)
local rg = eg:Filter(s.rfilter,nil)
for tc in aux.Next(rg) do
tc:RegisterFlagEffect(id,rsrst.std,0,1)
end
end
function s.effilter(c)
return c:GetFlagEffect(id) > 0 and c:GetFlagEffect(id + 1) == 0 and Duel.IsPlayerAffectedByEffect(c:GetControler(),id)
end
function s.rstfilter(c)
return c:GetFlagEffect(id) > 0 and c:GetFlagEffect(id + 1) > 0
end
function s.efop(e,tp,eg)
local g = Duel.GetMatchingGroup(s.effilter,tp,LOCATION_MZONE,LOCATION_MZONE,nil)
for tc in aux.Next(g) do
local clist = { }
local mat = tc:GetMaterial():Filter(s.mfilter,nil)
for mc in aux.Next(mat) do
local cid = tc:CopyEffect(mc:GetOriginalCodeRule(),rsrst.std)
table.insert(clist,cid)
end
rsmd.cplist[tc] = clist
tc:RegisterFlagEffect(id + 1,rsrst.std,0,1)
end
for p = 0, 1 do
if not Duel.IsPlayerAffectedByEffect(p,id) then
local rg = Duel.GetMatchingGroup(s.rstfilter,p,LOCATION_MZONE,0,nil)
for tc in aux.Next(rg) do
local clist = rsmd.cplist[tc] or { }
if clist and #clist > 0 then
for _,cid in pairs(clist) do
tc:ResetEffect(cid,RESET_COPY)
tc:ResetEffect(RESET_DISABLE,RESET_EVENT)
tc:ResetFlagEffect(id + 1)
end
end
end
end
end
end
function s.eftg(e,c)
return rsmd.IsSet1(c) and c:IsType(TYPE_LINK)
end
function s.spcon(e,tp)
local c = e:GetHandler()
return c:IsLinkAbove(3)
end
function s.spfilter(c,e,tp)
local lc = e:GetHandler()
local zone = lc:GetLinkedZone()
return rsmd.IsSet2(c) and not c:IsCode(e:GetHandler():GetCode()) and rscf.RemovePosCheck(c) and zone > 0 and c:IsCanBeSpecialSummoned(e,0,tp,false,false,POS_FACEUP,tp,zone) and not c:IsType(TYPE_LINK)
end
function s.spop(e,tp)
local c = rscf.GetFaceUpSelf(e)
if not c then return end
local zone = c:GetLinkedZone()
rsop.SelectOperate("sp",tp,aux.NecroValleyFilter(s.spfilter),tp,rsloc.gr,0,1,1,nil,{0,tp,tp,false,false,POS_FACEUP,zone},e,tp)
end
\ No newline at end of file
--骰娘炼成·补完式
Duel.LoadScript("c44000001.lua")
local id,s = rscf.DefineCard(44000032,"MrsDice_Taught")
function s.initial_effect(c)
--Activate
local e1=Effect.CreateEffect(c)
e1:SetCategory(CATEGORY_SPECIAL_SUMMON)
e1:SetType(EFFECT_TYPE_ACTIVATE)
e1:SetCode(EVENT_FREE_CHAIN)
e1:SetTarget(s.target)
e1:SetOperation(s.operation)
c:RegisterEffect(e1)
local e2 = rsef.I(c,"td",{1,id},"td,ga","tg",LOCATION_GRAVE,nil,nil,
rstg.target({s.tdfilter,"td",LOCATION_GRAVE},{"opc",Card.IsAbleToDeck,"td"}),s.tdop)
end
function s.tdfilter(c)
return c:IsType(TYPE_LINK) and c:IsAbleToDeck() and rsmd.IsSet2(c)
end
function s.tdop(e,tp)
local tc = rscf.GetTargetCard()
local c = rscf.GetSelf(e)
local mg = rsgf.Mix2(c,tc)
if #mg < 2 then return end
if Duel.IsExistingMatchingCard(s.exfilter,tp,LOCATION_MZONE,0,1,nil) then
local b1 = c:IsAbleToHand()
local b2 = c:IsAbleToDeck()
local op = rshint.SelectOption(tp,b1,"th",b2,"td")
if op == 1 then
Duel.SendtoDeck(tc,nil,2,REASON_EFFECT)
Duel.SendtoHand(c,nil,REASON_EFFECT)
else
Duel.SendtoDeck(mg,nil,2,REASON_EFFECT)
end
else
Duel.SendtoDeck(mg,nil,2,REASON_EFFECT)
end
end
function s.exfilter(c)
return c:IsFaceup() and c:IsType(TYPE_RITUAL) and rsmd.IsSet2(c)
end
function s.NBLV(c)
local x = c:GetLevel()
if c:IsType(TYPE_LINK) and c:IsRace(RACE_CYBERSE) then
x = c:GetLink() *2
end
if x>MAX_PARAMETER then
return MAX_PARAMETER
else
return x
end
end
function s.target(e,tp,eg,ep,ev,re,r,rp,chk)
if chk==0 then
local mg=Duel.GetRitualMaterialEx(tp):Filter(Card.IsOnField,nil)
return Duel.IsExistingMatchingCard(s.RitualUltimateFilter,tp,LOCATION_HAND+LOCATION_GRAVE,0,1,nil,nil,e,tp,mg,nil,s.NBLV,"Greater")
end
Duel.SetOperationInfo(0,CATEGORY_SPECIAL_SUMMON,nil,1,tp,LOCATION_HAND+LOCATION_GRAVE)
end
function s.operation(e,tp,eg,ep,ev,re,r,rp)
local mg=Duel.GetRitualMaterialEx(tp):Filter(Card.IsOnField,nil)
Duel.Hint(HINT_SELECTMSG,tp,HINTMSG_SPSUMMON)
local tg=Duel.SelectMatchingCard(tp,aux.NecroValleyFilter(s.RitualUltimateFilter),tp,LOCATION_HAND+LOCATION_GRAVE,0,1,1,nil,nil,e,tp,mg,nil,s.NBLV,"Greater")
local tc=tg:GetFirst()
if tc then
mg=mg:Filter(Card.IsCanBeRitualMaterial,tc,tc)
if sg then
mg:Merge(sg)
end
if tc.mat_filter then
mg=mg:Filter(tc.mat_filter,tc,tp)
else
mg:RemoveCard(tc)
end
Duel.Hint(HINT_SELECTMSG,tp,HINTMSG_RELEASE)
aux.GCheckAdditional=s.RitualCheckAdditional(tc,s.NBLV(tc),"Greater")
local mat=mg:SelectSubGroup(tp,s.RitualCheck,false,1,#mg,tp,tc,s.NBLV(tc),"Greater")
aux.GCheckAdditional=nil
if not mat or mat:GetCount()==0 then return end
tc:SetMaterial(mat)
Duel.ReleaseRitualMaterial(mat)
Duel.BreakEffect()
Duel.SpecialSummon(tc,SUMMON_TYPE_RITUAL,tp,tp,false,true,POS_FACEUP)
tc:CompleteProcedure()
end
end
function s.RitualCheckGreater(g,c,lv)
if lv==0 then return false end
Duel.SetSelectedCard(g)
return g:CheckWithSumGreater(s.NBLV,lv)
end
function s.RitualCheckEqual(g,c,lv)
if lv==0 then return false end
return g:CheckWithSumEqual(s.NBLV,lv,#g,#g)
end
function s.RitualCheck(g,tp,c,lv,greater_or_equal)
return s["RitualCheck"..greater_or_equal](g,c,lv) and Duel.GetMZoneCount(tp,g,tp)>0 and (not c.mat_group_check or c.mat_group_check(g,tp))
and (not aux.RCheckAdditional or aux.RCheckAdditional(tp,g,c))
end
function s.RitualCheckAdditional(c,lv,greater_or_equal)
if greater_or_equal=="Equal" then
return function(g)
return (not aux.RGCheckAdditional or aux.RGCheckAdditional(g)) and g:GetSum(s.NBLV)<=lv
end
else
return function(g,ec)
if lv==0 then return #g<=1 end
if ec then
return (not aux.RGCheckAdditional or aux.RGCheckAdditional(g,ec)) and g:GetSum(s.NBLV)-s.NBLV(ec)<=lv
else
return not aux.RGCheckAdditional or aux.RGCheckAdditional(g)
end
end
end
end
function s.RitualUltimateFilter(c,filter,e,tp,m1,m2,lv_function,greater_or_equal,chk)
if bit.band(c:GetType(),0x81)~=0x81 or (filter and not filter(c,e,tp,chk)) or not c:IsCanBeSpecialSummoned(e,SUMMON_TYPE_RITUAL,tp,false,true) then return false end
local mg=m1:Filter(Card.IsCanBeRitualMaterial,c,c)
if m2 then
mg:Merge(m2)
end
if c.mat_filter then
mg=mg:Filter(c.mat_filter,c,tp)
else
mg:RemoveCard(c)
end
local lv=lv_function(c)
aux.GCheckAdditional=s.RitualCheckAdditional(c,lv,greater_or_equal)
local res=mg:CheckSubGroup(s.RitualCheck,1,#mg,tp,c,lv,greater_or_equal)
aux.GCheckAdditional=nil
return res
end
...@@ -8,7 +8,7 @@ function cm.initial_effect(c) ...@@ -8,7 +8,7 @@ function cm.initial_effect(c)
e2:SetType(EFFECT_TYPE_FIELD) e2:SetType(EFFECT_TYPE_FIELD)
e2:SetRange(LOCATION_PZONE) e2:SetRange(LOCATION_PZONE)
e2:SetCode(EFFECT_CANNOT_SPECIAL_SUMMON) e2:SetCode(EFFECT_CANNOT_SPECIAL_SUMMON)
e2:SetProperty(EFFECT_FLAG_PLAYER_TARGET+EFFECT_FLAG_CANNOT_DISABLE+EFFECT_FLAG_CANNOT_NEGATE) e2:SetProperty(EFFECT_FLAG_PLAYER_TARGET+EFFECT_FLAG_CANNOT_DISABLE)
e2:SetTargetRange(1,0) e2:SetTargetRange(1,0)
e2:SetTarget(cm.splimit) e2:SetTarget(cm.splimit)
c:RegisterEffect(e2) c:RegisterEffect(e2)
......
...@@ -8,7 +8,7 @@ function cm.initial_effect(c) ...@@ -8,7 +8,7 @@ function cm.initial_effect(c)
e2:SetType(EFFECT_TYPE_FIELD) e2:SetType(EFFECT_TYPE_FIELD)
e2:SetRange(LOCATION_PZONE) e2:SetRange(LOCATION_PZONE)
e2:SetCode(EFFECT_CANNOT_SPECIAL_SUMMON) e2:SetCode(EFFECT_CANNOT_SPECIAL_SUMMON)
e2:SetProperty(EFFECT_FLAG_PLAYER_TARGET+EFFECT_FLAG_CANNOT_DISABLE+EFFECT_FLAG_CANNOT_NEGATE) e2:SetProperty(EFFECT_FLAG_PLAYER_TARGET+EFFECT_FLAG_CANNOT_DISABLE)
e2:SetTargetRange(1,0) e2:SetTargetRange(1,0)
e2:SetTarget(cm.splimit) e2:SetTarget(cm.splimit)
c:RegisterEffect(e2) c:RegisterEffect(e2)
......
...@@ -8,7 +8,7 @@ function cm.initial_effect(c) ...@@ -8,7 +8,7 @@ function cm.initial_effect(c)
e2:SetType(EFFECT_TYPE_FIELD) e2:SetType(EFFECT_TYPE_FIELD)
e2:SetRange(LOCATION_PZONE) e2:SetRange(LOCATION_PZONE)
e2:SetCode(EFFECT_CANNOT_SPECIAL_SUMMON) e2:SetCode(EFFECT_CANNOT_SPECIAL_SUMMON)
e2:SetProperty(EFFECT_FLAG_PLAYER_TARGET+EFFECT_FLAG_CANNOT_DISABLE+EFFECT_FLAG_CANNOT_NEGATE) e2:SetProperty(EFFECT_FLAG_PLAYER_TARGET+EFFECT_FLAG_CANNOT_DISABLE)
e2:SetTargetRange(1,0) e2:SetTargetRange(1,0)
e2:SetTarget(cm.splimit) e2:SetTarget(cm.splimit)
c:RegisterEffect(e2) c:RegisterEffect(e2)
......
...@@ -20,7 +20,7 @@ function cm.initial_effect(c) ...@@ -20,7 +20,7 @@ function cm.initial_effect(c)
e2:SetCode(EVENT_TO_GRAVE) e2:SetCode(EVENT_TO_GRAVE)
e2:SetRange(LOCATION_GRAVE) e2:SetRange(LOCATION_GRAVE)
e2:SetCountLimit(1,m) e2:SetCountLimit(1,m)
e2:SetCondition(m.setcon) e2:SetCondition(cm.setcon)
e2:SetTarget(cm.settg) e2:SetTarget(cm.settg)
e2:SetOperation(cm.setop) e2:SetOperation(cm.setop)
c:RegisterEffect(e2) c:RegisterEffect(e2)
......
--罗德岛·术士干员-远山 --罗德岛·术士干员-远山
local cm,m,o=GetID()
function cm.initial_effect(c) function cm.initial_effect(c)
--synchro summon --synchro summon
aux.AddSynchroProcedure(c,nil,aux.NonTuner(nil),1) aux.AddSynchroProcedure(c,nil,aux.NonTuner(nil),1)
......
...@@ -17,7 +17,7 @@ function cm.initial_effect(c) ...@@ -17,7 +17,7 @@ function cm.initial_effect(c)
e2:SetRange(LOCATION_GRAVE) e2:SetRange(LOCATION_GRAVE)
e2:SetCost(cm.lvcost) e2:SetCost(cm.lvcost)
e2:SetTarget(cm.lvtg) e2:SetTarget(cm.lvtg)
e2:SetOperation(m.lvop) e2:SetOperation(cm.lvop)
c:RegisterEffect(e2) c:RegisterEffect(e2)
end end
function cm.condition(e,tp,eg,ep,ev,re,r,rp) function cm.condition(e,tp,eg,ep,ev,re,r,rp)
......
...@@ -28,7 +28,7 @@ function cm.initial_effect(c) ...@@ -28,7 +28,7 @@ function cm.initial_effect(c)
e2:SetOperation(cm.desop2) e2:SetOperation(cm.desop2)
c:RegisterEffect(e2) c:RegisterEffect(e2)
end end
function m.matfilter(c) function cm.matfilter(c)
return c:IsLinkSetCard(0x362a) return c:IsLinkSetCard(0x362a)
end end
function cm.spcon(e,tp,eg,ep,ev,re,r,rp) function cm.spcon(e,tp,eg,ep,ev,re,r,rp)
......
...@@ -20,7 +20,7 @@ function cm.initial_effect(c) ...@@ -20,7 +20,7 @@ function cm.initial_effect(c)
e2:SetCode(EFFECT_INDESTRUCTABLE_COUNT) e2:SetCode(EFFECT_INDESTRUCTABLE_COUNT)
e2:SetCountLimit(1) e2:SetCountLimit(1)
e2:SetRange(LOCATION_MZONE) e2:SetRange(LOCATION_MZONE)
e2:SetValue(m.valcon) e2:SetValue(cm.valcon)
c:RegisterEffect(e2) c:RegisterEffect(e2)
--spsummon --spsummon
local e3=Effect.CreateEffect(c) local e3=Effect.CreateEffect(c)
......
--喀兰贸易·辅助干员-初雪 --喀兰贸易·辅助干员-初雪
function c79029070.initial_effect(c) function c60007205.initial_effect(c)
--link summon --link summon
aux.AddLinkProcedure(c,c79029070.matfilter,2,3) aux.AddLinkProcedure(c,c60007205.matfilter,2,3)
c:EnableReviveLimit() c:EnableReviveLimit()
--atk/def --atk/def
local e1=Effect.CreateEffect(c) local e1=Effect.CreateEffect(c)
...@@ -9,7 +9,7 @@ function c79029070.initial_effect(c) ...@@ -9,7 +9,7 @@ function c79029070.initial_effect(c)
e1:SetCode(EFFECT_UPDATE_ATTACK) e1:SetCode(EFFECT_UPDATE_ATTACK)
e1:SetRange(LOCATION_MZONE) e1:SetRange(LOCATION_MZONE)
e1:SetTargetRange(0,LOCATION_MZONE) e1:SetTargetRange(0,LOCATION_MZONE)
e1:SetTarget(c79029070.atktg) e1:SetTarget(c60007205.atktg)
e1:SetValue(-700) e1:SetValue(-700)
c:RegisterEffect(e1) c:RegisterEffect(e1)
local e2=e1:Clone() local e2=e1:Clone()
...@@ -22,9 +22,9 @@ function c79029070.initial_effect(c) ...@@ -22,9 +22,9 @@ function c79029070.initial_effect(c)
e3:SetCode(EVENT_FREE_CHAIN) e3:SetCode(EVENT_FREE_CHAIN)
e3:SetProperty(EFFECT_FLAG_CARD_TARGET) e3:SetProperty(EFFECT_FLAG_CARD_TARGET)
e3:SetRange(LOCATION_MZONE) e3:SetRange(LOCATION_MZONE)
e3:SetCountLimit(1,79029070) e3:SetCountLimit(1,60007205)
e3:SetTarget(c79029070.dstg) e3:SetTarget(c60007205.dstg)
e3:SetOperation(c79029070.dsop) e3:SetOperation(c60007205.dsop)
c:RegisterEffect(e3) c:RegisterEffect(e3)
--destory --destory
local e4=Effect.CreateEffect(c) local e4=Effect.CreateEffect(c)
...@@ -32,26 +32,26 @@ function c79029070.initial_effect(c) ...@@ -32,26 +32,26 @@ function c79029070.initial_effect(c)
e4:SetType(EFFECT_TYPE_SINGLE+EFFECT_TYPE_TRIGGER_O) e4:SetType(EFFECT_TYPE_SINGLE+EFFECT_TYPE_TRIGGER_O)
e4:SetProperty(EFFECT_FLAG_DELAY) e4:SetProperty(EFFECT_FLAG_DELAY)
e4:SetCode(EVENT_TO_GRAVE) e4:SetCode(EVENT_TO_GRAVE)
e4:SetCountLimit(1,09029070) e4:SetCountLimit(1,60097205)
e4:SetCondition(c79029070.thcon2) e4:SetCondition(c60007205.thcon2)
e4:SetTarget(c79029070.thtg2) e4:SetTarget(c60007205.thtg2)
e4:SetOperation(c79029070.thop2) e4:SetOperation(c60007205.thop2)
c:RegisterEffect(e4) c:RegisterEffect(e4)
end end
function c79029070.matfilter(c) function c60007205.matfilter(c)
return c:IsLinkSetCard(0xa900) return c:IsLinkSetCard(0x362a)
end end
function c79029070.atktg(e,c) function c60007205.atktg(e,c)
return c:GetMutualLinkedGroupCount()==0 return c:GetMutualLinkedGroupCount()==0
end end
function c79029070.dstg(e,tp,eg,ep,ev,re,r,rp,chk) function c60007205.dstg(e,tp,eg,ep,ev,re,r,rp,chk)
if chk==0 then return Duel.IsExistingTarget(nil,tp,LOCATION_MZONE,LOCATION_MZONE,1,nil) end if chk==0 then return Duel.IsExistingTarget(nil,tp,LOCATION_MZONE,LOCATION_MZONE,1,nil) end
local tc=Duel.SelectTarget(tp,nil,tp,LOCATION_MZONE,LOCATION_MZONE,1,1,nil) local tc=Duel.SelectTarget(tp,nil,tp,LOCATION_MZONE,LOCATION_MZONE,1,1,nil)
Duel.SetOperationInfo(0,CATEGORY_DISABLE,tc,1,0,LOCATION_MZONE) Duel.SetOperationInfo(0,CATEGORY_DISABLE,tc,1,0,LOCATION_MZONE)
end end
function c79029070.dsop(e,tp,eg,ep,ev,re,r,rp) function c60007205.dsop(e,tp,eg,ep,ev,re,r,rp)
Debug.Message("铃声已至,风雪缠足。") Debug.Message("铃声已至,风雪缠足。")
Duel.Hint(HINT_SOUND,0,aux.Stringid(79029070,0)) Duel.Hint(HINT_SOUND,0,aux.Stringid(60007205,0))
local c=e:GetHandler() local c=e:GetHandler()
local tc=Duel.GetFirstTarget() local tc=Duel.GetFirstTarget()
if tc and tc:IsRelateToEffect(e) then if tc and tc:IsRelateToEffect(e) then
...@@ -78,22 +78,22 @@ function c79029070.dsop(e,tp,eg,ep,ev,re,r,rp) ...@@ -78,22 +78,22 @@ function c79029070.dsop(e,tp,eg,ep,ev,re,r,rp)
tc:RegisterFlagEffect(e4) tc:RegisterFlagEffect(e4)
end end
end end
function c79029070.thcon2(e,tp,eg,ep,ev,re,r,rp) function c60007205.thcon2(e,tp,eg,ep,ev,re,r,rp)
return e:GetHandler():IsPreviousLocation(LOCATION_ONFIELD) return e:GetHandler():IsPreviousLocation(LOCATION_ONFIELD)
end end
function c79029070.filter(c) function c60007205.filter(c)
return c:IsType(TYPE_SPELL+TYPE_TRAP) return c:IsType(TYPE_SPELL+TYPE_TRAP)
end end
function c79029070.thtg2(e,tp,eg,ep,ev,re,r,rp,chk) function c60007205.thtg2(e,tp,eg,ep,ev,re,r,rp,chk)
local c=e:GetHandler() local c=e:GetHandler()
if chk==0 then return Duel.IsExistingMatchingCard(c79029070.filter,tp,0,LOCATION_ONFIELD,1,c) end if chk==0 then return Duel.IsExistingMatchingCard(c60007205.filter,tp,0,LOCATION_ONFIELD,1,c) end
local sg=Duel.GetMatchingGroup(c79029070.filter,tp,0,LOCATION_ONFIELD,c) local sg=Duel.GetMatchingGroup(c60007205.filter,tp,0,LOCATION_ONFIELD,c)
Duel.SetOperationInfo(0,CATEGORY_DESTROY,sg,sg:GetCount(),0,0) Duel.SetOperationInfo(0,CATEGORY_DESTROY,sg,sg:GetCount(),0,0)
end end
function c79029070.thop2(e,tp,eg,ep,ev,re,r,rp) function c60007205.thop2(e,tp,eg,ep,ev,re,r,rp)
Debug.Message("如有神助,正是此般。") Debug.Message("如有神助,正是此般。")
Duel.Hint(HINT_SOUND,0,aux.Stringid(79029070,1)) Duel.Hint(HINT_SOUND,0,aux.Stringid(60007205,1))
local sg=Duel.GetMatchingGroup(c79029070.filter,tp,0,LOCATION_ONFIELD,aux.ExceptThisCard(e)) local sg=Duel.GetMatchingGroup(c60007205.filter,tp,0,LOCATION_ONFIELD,aux.ExceptThisCard(e))
Duel.Destroy(sg,REASON_EFFECT) Duel.Destroy(sg,REASON_EFFECT)
end end
...@@ -20,7 +20,7 @@ function cm.initial_effect(c) ...@@ -20,7 +20,7 @@ function cm.initial_effect(c)
e2:SetCategory(CATEGORY_NEGATE) e2:SetCategory(CATEGORY_NEGATE)
e2:SetType(EFFECT_TYPE_QUICK_O) e2:SetType(EFFECT_TYPE_QUICK_O)
e2:SetCode(EVENT_CHAINING) e2:SetCode(EVENT_CHAINING)
e2:SetProperty(EFFECT_FLAG_DAMAGE_STEP+EFFECT_FLAG_DAMAGE_CAL+EFFECT_FLAG_CANNOT_INACTIVATE+EFFECT_FLAG_CANNOT_DISABLE+EFFECT_FLAG_CANNOT_NEGATE) e2:SetProperty(EFFECT_FLAG_DAMAGE_STEP+EFFECT_FLAG_DAMAGE_CAL+EFFECT_FLAG_CANNOT_INACTIVATE+EFFECT_FLAG_CANNOT_DISABLE)
e2:SetRange(LOCATION_MZONE) e2:SetRange(LOCATION_MZONE)
e2:SetCondition(cm.imcon) e2:SetCondition(cm.imcon)
e2:SetCost(cm.imcost) e2:SetCost(cm.imcost)
......
...@@ -8,7 +8,7 @@ function cm.initial_effect(c) ...@@ -8,7 +8,7 @@ function cm.initial_effect(c)
e2:SetType(EFFECT_TYPE_FIELD) e2:SetType(EFFECT_TYPE_FIELD)
e2:SetRange(LOCATION_PZONE) e2:SetRange(LOCATION_PZONE)
e2:SetCode(EFFECT_CANNOT_SPECIAL_SUMMON) e2:SetCode(EFFECT_CANNOT_SPECIAL_SUMMON)
e2:SetProperty(EFFECT_FLAG_PLAYER_TARGET+EFFECT_FLAG_CANNOT_DISABLE+EFFECT_FLAG_CANNOT_NEGATE) e2:SetProperty(EFFECT_FLAG_PLAYER_TARGET+EFFECT_FLAG_CANNOT_DISABLE)
e2:SetTargetRange(1,0) e2:SetTargetRange(1,0)
e2:SetTarget(cm.splimit) e2:SetTarget(cm.splimit)
c:RegisterEffect(e2) c:RegisterEffect(e2)
......
...@@ -13,7 +13,7 @@ function cm.initial_effect(c) ...@@ -13,7 +13,7 @@ function cm.initial_effect(c)
e2:SetType(EFFECT_TYPE_FIELD) e2:SetType(EFFECT_TYPE_FIELD)
e2:SetRange(LOCATION_PZONE) e2:SetRange(LOCATION_PZONE)
e2:SetCode(EFFECT_CANNOT_SPECIAL_SUMMON) e2:SetCode(EFFECT_CANNOT_SPECIAL_SUMMON)
e2:SetProperty(EFFECT_FLAG_PLAYER_TARGET+EFFECT_FLAG_CANNOT_DISABLE+EFFECT_FLAG_CANNOT_NEGATE) e2:SetProperty(EFFECT_FLAG_PLAYER_TARGET+EFFECT_FLAG_CANNOT_DISABLE)
e2:SetTargetRange(1,0) e2:SetTargetRange(1,0)
e2:SetTarget(cm.splimit) e2:SetTarget(cm.splimit)
c:RegisterEffect(e2) c:RegisterEffect(e2)
......
...@@ -44,7 +44,7 @@ function cm.activate(e,tp,eg,ep,ev,re,r,rp) ...@@ -44,7 +44,7 @@ function cm.activate(e,tp,eg,ep,ev,re,r,rp)
local val=Duel.Recover(tp,math.ceil(ev),REASON_EFFECT) local val=Duel.Recover(tp,math.ceil(ev),REASON_EFFECT)
if val<800 then return end if val<800 then return end
Duel.BreakEffect() Duel.BreakEffect()
for val>=800 do for val>799 do
Duel.Draw(tp,1,REASON_EFFECT) Duel.Draw(tp,1,REASON_EFFECT)
val=val-800 val=val-800
end end
......
...@@ -64,4 +64,5 @@ function cm.atkop(e,tp,eg,ep,ev,re,r,rp) ...@@ -64,4 +64,5 @@ function cm.atkop(e,tp,eg,ep,ev,re,r,rp)
local g=Duel.SelectReleaseGroup(tp,cm.cfilter,1,1,nil,lg) local g=Duel.SelectReleaseGroup(tp,cm.cfilter,1,1,nil,lg)
if Duel.Release(g,REASON_EFFECT)~=0 then if Duel.Release(g,REASON_EFFECT)~=0 then
Duel.Draw(tp,1,REASON_EFFECT) Duel.Draw(tp,1,REASON_EFFECT)
end end
\ No newline at end of file end
\ No newline at end of file
...@@ -11,7 +11,7 @@ function c60159907.initial_effect(c) ...@@ -11,7 +11,7 @@ function c60159907.initial_effect(c)
e12:SetType(EFFECT_TYPE_SINGLE) e12:SetType(EFFECT_TYPE_SINGLE)
e12:SetProperty(EFFECT_FLAG_SINGLE_RANGE) e12:SetProperty(EFFECT_FLAG_SINGLE_RANGE)
e12:SetCode(EFFECT_ADD_ATTRIBUTE) e12:SetCode(EFFECT_ADD_ATTRIBUTE)
e12:SetProperty(EFFECT_FLAG_CANNOT_DISABLE+EFFECT_FLAG_CANNOT_NEGATE) e12:SetProperty(EFFECT_FLAG_CANNOT_DISABLE)
e12:SetRange(LOCATION_MZONE) e12:SetRange(LOCATION_MZONE)
e12:SetValue(ATTRIBUTE_DARK) e12:SetValue(ATTRIBUTE_DARK)
c:RegisterEffect(e12) c:RegisterEffect(e12)
......
...@@ -58,8 +58,7 @@ function s.activate(e,tp,eg,ep,ev,re,r,rp) ...@@ -58,8 +58,7 @@ function s.activate(e,tp,eg,ep,ev,re,r,rp)
local tc=g:GetFirst() local tc=g:GetFirst()
if tc and Duel.SendtoHand(g,nil,REASON_EFFECT)~=0 then if tc and Duel.SendtoHand(g,nil,REASON_EFFECT)~=0 then
Duel.ConfirmCards(1-tp,g) Duel.ConfirmCards(1-tp,g)
if Duel.IsPlayerCanDraw(tp,1) then if Duel.IsPlayerCanDraw(tp,1) and Duel.SelectYesNo(tp,aux.Stringid(id,1)) then
and Duel.SelectYesNo(tp,aux.Stringid(id,1)) then
Duel.BreakEffect() Duel.BreakEffect()
Duel.Draw(tp,1,REASON_EFFECT) Duel.Draw(tp,1,REASON_EFFECT)
end end
......
...@@ -28,7 +28,6 @@ end ...@@ -28,7 +28,6 @@ end
function c65820050.spfilter(c,e,tp) function c65820050.spfilter(c,e,tp)
return c:IsCode(65820000,65820005) and c:IsCanBeSpecialSummoned(e,0,tp,false,false) return c:IsCode(65820000,65820005) and c:IsCanBeSpecialSummoned(e,0,tp,false,false)
aux.NecroValleyFilter()
end end
function c65820050.target(e,tp,eg,ep,ev,re,r,rp,chk) function c65820050.target(e,tp,eg,ep,ev,re,r,rp,chk)
if chk==0 then return Duel.GetLocationCount(tp,LOCATION_MZONE)>0 if chk==0 then return Duel.GetLocationCount(tp,LOCATION_MZONE)>0
...@@ -38,7 +37,7 @@ end ...@@ -38,7 +37,7 @@ end
function c65820050.activate(e,tp,eg,ep,ev,re,r,rp) function c65820050.activate(e,tp,eg,ep,ev,re,r,rp)
if Duel.GetLocationCount(tp,LOCATION_MZONE)<=0 then return end if Duel.GetLocationCount(tp,LOCATION_MZONE)<=0 then return end
Duel.Hint(HINT_SELECTMSG,tp,HINTMSG_SPSUMMON) Duel.Hint(HINT_SELECTMSG,tp,HINTMSG_SPSUMMON)
local g=Duel.SelectMatchingCard(tp,c65820050.spfilter,tp,LOCATION_DECK+LOCATION_GRAVE+LOCATION_HAND+LOCATION_REMOVED,0,1,1,nil,e,tp) local g=Duel.SelectMatchingCard(tp,aux.NecroValleyFilter(c65820050.spfilter),tp,LOCATION_DECK+LOCATION_GRAVE+LOCATION_HAND+LOCATION_REMOVED,0,1,1,nil,e,tp)
if g:GetCount()>0 then if g:GetCount()>0 then
Duel.SpecialSummon(g,0,tp,tp,false,false,POS_FACEUP) Duel.SpecialSummon(g,0,tp,tp,false,false,POS_FACEUP)
end end
......
...@@ -87,9 +87,9 @@ function c71403014.op1(e,tp,eg,ep,ev,re,r,rp) ...@@ -87,9 +87,9 @@ function c71403014.op1(e,tp,eg,ep,ev,re,r,rp)
yume.OptionalPendulum(e,c,tp) yume.OptionalPendulum(e,c,tp)
end end
end end
function s.retcon(e,tp,eg,ep,ev,re,r,rp) function c71403014.retcon(e,tp,eg,ep,ev,re,r,rp)
return e:GetLabelObject():GetFlagEffect(71403014)~=0 return e:GetLabelObject():GetFlagEffect(71403014)~=0
end end
function s.retop(e,tp,eg,ep,ev,re,r,rp) function c71403014.retop(e,tp,eg,ep,ev,re,r,rp)
Duel.ReturnToField(e:GetLabelObject()) Duel.ReturnToField(e:GetLabelObject())
end end
\ No newline at end of file
...@@ -22,7 +22,7 @@ function cm.initial_effect(c) ...@@ -22,7 +22,7 @@ function cm.initial_effect(c)
e2:SetType(EFFECT_TYPE_IGNITION) e2:SetType(EFFECT_TYPE_IGNITION)
e2:SetProperty(EFFECT_FLAG_CARD_TARGET) e2:SetProperty(EFFECT_FLAG_CARD_TARGET)
e2:SetRange(LOCATION_HAND+LOCATION_GRAVE) e2:SetRange(LOCATION_HAND+LOCATION_GRAVE)
e2:SetCountLimit(1,m+) e2:SetCountLimit(1,m)
e2:SetCost(cm.cost) e2:SetCost(cm.cost)
e2:SetTarget(cm.sptg) e2:SetTarget(cm.sptg)
e2:SetOperation(cm.spop) e2:SetOperation(cm.spop)
......
...@@ -77,7 +77,6 @@ function cm.activate(e,tp,eg,ep,ev,re,r,rp) ...@@ -77,7 +77,6 @@ function cm.activate(e,tp,eg,ep,ev,re,r,rp)
local e4=e3:Clone() local e4=e3:Clone()
e4:SetCode(EFFECT_INDESTRUCTABLE_EFFECT) e4:SetCode(EFFECT_INDESTRUCTABLE_EFFECT)
Duel.RegisterEffect(e4,tp) Duel.RegisterEffect(e4,tp)
end
end end
function cm.etarget(e,c) function cm.etarget(e,c)
return c:IsFaceup() and c:GetBaseAttack()==0 return c:IsFaceup() and c:GetBaseAttack()==0
......
This diff is collapsed.
This diff is collapsed.
This diff is collapsed.
This diff is collapsed.
This diff is collapsed.
This diff is collapsed.
This diff is collapsed.
This diff is collapsed.
This diff is collapsed.
This diff is collapsed.
This diff is collapsed.
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