Commit b99cb482 authored by wind2009's avatar wind2009

TW02 check

parent f29210c2
Pipeline #31427 passed with stages
in 1 minute and 48 seconds
......@@ -53,7 +53,7 @@ merge_databases:
FIELDS: 'name,desc,overallString,picUrl'
GIT_DEPTH: '1000'
OUTPUT_FILENAME: test-release.json
REF_COMMIT: '9.9' # 更新的时候改这里,修改成上一个tag的版本号
REF_COMMIT: '9.10' # 更新的时候改这里,修改成上一个tag的版本号
script:
- apt update;apt -y install wget
- currentPath=$PWD
......
......@@ -27,7 +27,7 @@ function s.initial_effect(c)
e2:SetTarget(s.tglimit)
e2:SetValue(aux.tgoval)
c:RegisterEffect(e2)
--search
--draw
local e3=Effect.CreateEffect(c)
e3:SetDescription(aux.Stringid(id,2))
e3:SetCategory(CATEGORY_DRAW|CATEGORY_HANDES)
......
......@@ -10,7 +10,7 @@ function s.initial_effect(c)
e1:SetCategory(CATEGORY_RELEASE|CATEGORY_CONTROL)
e1:SetType(EFFECT_TYPE_QUICK_O)
e1:SetCode(EVENT_FREE_CHAIN)
e1:SetHintTiming(TIMING_ATTACK,0x11e0)
e1:SetHintTiming(0,TIMINGS_CHECK_MONSTER|TIMING_MAIN_END)
e1:SetRange(LOCATION_MZONE)
e1:SetCountLimit(1)
e1:SetCondition(s.ctcon)
......@@ -30,8 +30,7 @@ function s.initial_effect(c)
c:RegisterEffect(e2)
end
function s.ctcon(e,tp,eg,ep,ev,re,r,rp)
local ph=Duel.GetCurrentPhase()
return ph==PHASE_MAIN1 or ph==PHASE_MAIN2
return Duel.IsMainPhase()
end
function s.rfilter(c,tp)
return c:IsSetCard(0x35) and c:IsType(TYPE_MONSTER) and Duel.GetMZoneCount(tp,c,tp,LOCATION_REASON_CONTROL)>0
......@@ -47,8 +46,9 @@ function s.cttg(e,tp,eg,ep,ev,re,r,rp,chk,chkc)
end
function s.ctop(e,tp,eg,ep,ev,re,r,rp)
local c=e:GetHandler()
local rg=Duel.GetReleaseGroup(tp,false,REASON_EFFECT):Filter(s.rfilter,nil,tp)
local og=Duel.GetMatchingGroup(s.ctfilter,tp,0,LOCATION_MZONE,nil)
if og:GetCount()==0 then return end
local rg=Duel.GetReleaseGroup(tp,false,REASON_EFFECT):Filter(s.rfilter,nil,tp)
Duel.Hint(HINT_SELECTMSG,tp,HINTMSG_RELEASE)
local sg=rg:Select(tp,1,og:GetCount(),nil)
local ct=Duel.Release(sg,REASON_EFFECT)
......
......@@ -24,7 +24,7 @@ function s.initial_effect(c)
e3:SetCode(EVENT_CHAIN_END)
e3:SetOperation(s.limop2)
c:RegisterEffect(e3)
--special summon
--activate
local e4=Effect.CreateEffect(c)
e4:SetDescription(aux.Stringid(id,1))
e4:SetType(EFFECT_TYPE_IGNITION)
......@@ -41,7 +41,7 @@ end
function s.activate(e,tp,eg,ep,ev,re,r,rp)
local g=Duel.GetMatchingGroup(s.ssfilter,tp,LOCATION_DECK,0,nil,tp)
if g:GetCount()>0 and Duel.SelectYesNo(tp,aux.Stringid(id,2)) then
Duel.Hint(HINT_SELECTMSG,tp,HINTMSG_TOFIELD)
Duel.Hint(HINT_SELECTMSG,tp,HINTMSG_SET)
local sg=g:Select(tp,1,1,nil)
Duel.SSet(tp,sg:GetFirst())
end
......@@ -125,6 +125,7 @@ function s.operation(e,tp,eg,ep,ev,re,r,rp)
local p,d=Duel.GetChainInfo(0,CHAININFO_TARGET_PLAYER,CHAININFO_TARGET_PARAM)
Duel.Draw(p,d,REASON_EFFECT)
elseif e:GetLabel()==2 then
if Duel.GetLocationCount(tp,LOCATION_MZONE)==0 then return end
Duel.Hint(HINT_SELECTMSG,tp,HINTMSG_SPSUMMON)
local g=Duel.SelectMatchingCard(tp,aux.NecroValleyFilter(s.spfilter),tp,LOCATION_GRAVE+LOCATION_REMOVED,0,1,1,nil,e,tp)
if g:GetCount()>0 then
......
......@@ -57,15 +57,16 @@ function s.dhfilter(c)
return c:IsSetCard(0x22) and c:IsDiscardable()
end
function s.drtg(e,tp,eg,ep,ev,re,r,rp,chk)
if chk==0 then return Duel.IsExistingMatchingCard(s.dhfilter,tp,LOCATION_HAND,0,1,nil)
and Duel.IsExistingMatchingCard(Card.IsDiscardable,tp,LOCATION_HAND,0,2,nil)
and Duel.IsPlayerCanDraw(tp,2) end
if chk==0 then
local g=Duel.GetFieldGroup(tp,LOCATION_HAND,0)
return Duel.IsPlayerCanDraw(tp,2) and g:CheckSubGroup(s.gselect,2,2)
end
Duel.SetTargetPlayer(tp)
Duel.SetTargetParam(2)
Duel.SetOperationInfo(0,CATEGORY_DRAW,nil,0,tp,2)
end
function s.gselect(g)
return g:IsExists(Card.IsSetCard,1,nil,0x22) and g:FilterCount(Card.IsDiscardable,nil)==2
return g:IsExists(Card.IsSetCard,1,nil,0x22) and g:FilterCount(Card.IsDiscardable,nil,REASON_EFFECT)==2
end
function s.drop(e,tp,eg,ep,ev,re,r,rp)
local p,d=Duel.GetChainInfo(0,CHAININFO_TARGET_PLAYER,CHAININFO_TARGET_PARAM)
......@@ -73,7 +74,7 @@ function s.drop(e,tp,eg,ep,ev,re,r,rp)
if #g>=2 and g:CheckSubGroup(s.gselect,2,2) then
Duel.Hint(HINT_SELECTMSG,p,HINTMSG_DISCARD)
local g1=g:SelectSubGroup(tp,s.gselect,false,2,2)
if g1 and g1:GetCount()>0 and Duel.SendtoGrave(g1,REASON_DISCARD+REASON_EFFECT)~=0 then
if g1 and g1:GetCount()==2 and Duel.SendtoGrave(g1,REASON_DISCARD+REASON_EFFECT)~=0 then
Duel.BreakEffect()
Duel.Draw(p,d,REASON_EFFECT)
end
......
......@@ -32,8 +32,7 @@ function s.initial_effect(c)
c:RegisterEffect(e2)
end
function s.spcon(e,tp,eg,ep,ev,re,r,rp)
local ph=Duel.GetCurrentPhase()
return ph==PHASE_MAIN1 or ph==PHASE_MAIN2
return Duel.IsMainPhase()
end
function s.spcost(e,tp,eg,ep,ev,re,r,rp,chk)
if chk==0 then return e:GetHandler():IsAbleToGraveAsCost() end
......
......@@ -68,8 +68,7 @@ function s.thop(e,tp,eg,ep,ev,re,r,rp)
end
end
function s.damcon(e,tp,eg,ep,ev,re,r,rp)
local ph=Duel.GetCurrentPhase()
return ph==PHASE_MAIN1 or ph==PHASE_MAIN2
return Duel.IsMainPhase()
end
function s.damval(e,re,val,r,rp,rc)
if r&REASON_EFFECT==REASON_EFFECT then
......
......@@ -13,7 +13,6 @@ function s.initial_effect(c)
e1:SetOperation(s.activate)
c:RegisterEffect(e1)
end
s.fusion_effect=true
function s.filter0(c)
return c:IsSetCard(0x1047) and not c:IsRace(RACE_ROCK)
and c:IsType(TYPE_MONSTER) and c:IsCanBeFusionMaterial() and c:IsAbleToGrave()
......
......@@ -74,8 +74,7 @@ function s.rmop(e,tp,eg,ep,ev,re,r,rp)
end
end
function s.rmcon2(e,tp,eg,ep,ev,re,r,rp)
local ph=Duel.GetCurrentPhase()
return ph==PHASE_MAIN1 or ph==PHASE_MAIN2
return Duel.IsMainPhase()
end
function s.rmfilter2(c)
return c:IsType(TYPE_MONSTER) and c:IsFaceup() and c:IsAbleToRemove()
......
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