Skip to content

Commit 0b9a3a2

Browse files
committed
Update cards related to "Chaos Distill"
Added official code for "Chaos Distill" to allow proper functionality/added notes to scripts/polished as needed.
1 parent 4ae7279 commit 0b9a3a2

File tree

8 files changed

+61
-76
lines changed

8 files changed

+61
-76
lines changed

unofficial/c100000657.lua

Lines changed: 7 additions & 9 deletions
Original file line numberDiff line numberDiff line change
@@ -1,4 +1,5 @@
11
--錫の魔法陣
2+
--Tin Spell Circle
23
local s,id=GetID()
34
function s.initial_effect(c)
45
--Activate
@@ -11,28 +12,25 @@ function s.initial_effect(c)
1112
e1:SetOperation(s.activate)
1213
c:RegisterEffect(e1)
1314
end
14-
s.listed_names={100000651,100000650}
15+
s.listed_names={100000651,6500778} --"Alchemy Beast - Aretos the Tin", "Chaos Distill"
1516
function s.spfilter(c,e,tp)
1617
return c:IsCode(100000651) and c:IsCanBeSpecialSummoned(e,0,tp,true,false)
1718
end
18-
function s.cfilter(c)
19-
return c:IsFaceup() and c:IsCode(100000650)
20-
end
2119
function s.condition(e,tp,eg,ep,ev,re,r,rp)
22-
return Duel.IsExistingMatchingCard(s.cfilter,tp,LOCATION_ONFIELD,LOCATION_ONFIELD,1,nil)
23-
and Duel.IsExistingMatchingCard(s.spfilter,tp,LOCATION_DECK|LOCATION_HAND,0,1,nil,e,tp)
20+
return Duel.IsExistingMatchingCard(aux.FaceupFilter(Card.IsCode,6500778),tp,LOCATION_ONFIELD,LOCATION_ONFIELD,1,nil)
21+
and Duel.IsExistingMatchingCard(s.spfilter,tp,LOCATION_HAND|LOCATION_DECK,0,1,nil,e,tp)
2422
end
2523
function s.target(e,tp,eg,ep,ev,re,r,rp,chk)
2624
if chk==0 then return true end
27-
Duel.SetOperationInfo(0,CATEGORY_SPECIAL_SUMMON,nil,1,0,LOCATION_DECK|LOCATION_HAND)
25+
Duel.SetOperationInfo(0,CATEGORY_SPECIAL_SUMMON,nil,1,0,LOCATION_HAND|LOCATION_DECK)
2826
end
2927
function s.activate(e,tp,eg,ep,ev,re,r,rp)
3028
if Duel.GetLocationCount(tp,LOCATION_MZONE)<=0 then return end
3129
Duel.Hint(HINT_SELECTMSG,tp,HINTMSG_SPSUMMON)
32-
local g=Duel.SelectMatchingCard(tp,s.spfilter,tp,LOCATION_DECK|LOCATION_HAND,0,1,1,nil,e,tp)
30+
local g=Duel.SelectMatchingCard(tp,s.spfilter,tp,LOCATION_HAND|LOCATION_DECK,0,1,1,nil,e,tp)
3331
local tc=g:GetFirst()
3432
if tc then
3533
Duel.SpecialSummon(tc,0,tp,tp,true,false,POS_FACEUP)
3634
tc:CompleteProcedure()
3735
end
38-
end
36+
end

unofficial/c100000658.lua

Lines changed: 7 additions & 9 deletions
Original file line numberDiff line numberDiff line change
@@ -1,4 +1,5 @@
11
--鉄のランプ
2+
--Steel Lamp
23
local s,id=GetID()
34
function s.initial_effect(c)
45
--Activate
@@ -11,28 +12,25 @@ function s.initial_effect(c)
1112
e1:SetOperation(s.activate)
1213
c:RegisterEffect(e1)
1314
end
14-
s.listed_names={100000652,100000650}
15+
s.listed_names={100000652,6500778} --"Alchemy Beast - Salamndra the Steel", "Chaos Distill"
1516
function s.spfilter(c,e,tp)
1617
return c:IsCode(100000652) and c:IsCanBeSpecialSummoned(e,0,tp,true,false)
1718
end
18-
function s.cfilter(c)
19-
return c:IsFaceup() and c:IsCode(100000650)
20-
end
2119
function s.condition(e,tp,eg,ep,ev,re,r,rp)
22-
return Duel.IsExistingMatchingCard(s.cfilter,tp,LOCATION_ONFIELD,LOCATION_ONFIELD,1,nil)
23-
and Duel.IsExistingMatchingCard(s.spfilter,tp,LOCATION_DECK|LOCATION_HAND,0,1,nil,e,tp)
20+
return Duel.IsExistingMatchingCard(aux.FaceupFilter(Card.IsCode,6500778),tp,LOCATION_ONFIELD,LOCATION_ONFIELD,1,nil)
21+
and Duel.IsExistingMatchingCard(s.spfilter,tp,LOCATION_HAND|LOCATION_DECK,0,1,nil,e,tp)
2422
end
2523
function s.target(e,tp,eg,ep,ev,re,r,rp,chk)
2624
if chk==0 then return true end
27-
Duel.SetOperationInfo(0,CATEGORY_SPECIAL_SUMMON,nil,1,0,LOCATION_DECK|LOCATION_HAND)
25+
Duel.SetOperationInfo(0,CATEGORY_SPECIAL_SUMMON,nil,1,0,LOCATION_HAND|LOCATION_DECK)
2826
end
2927
function s.activate(e,tp,eg,ep,ev,re,r,rp)
3028
if Duel.GetLocationCount(tp,LOCATION_MZONE)<=0 then return end
3129
Duel.Hint(HINT_SELECTMSG,tp,HINTMSG_SPSUMMON)
32-
local g=Duel.SelectMatchingCard(tp,s.spfilter,tp,LOCATION_DECK|LOCATION_HAND,0,1,1,nil,e,tp)
30+
local g=Duel.SelectMatchingCard(tp,s.spfilter,tp,LOCATION_HAND|LOCATION_DECK,0,1,1,nil,e,tp)
3331
local tc=g:GetFirst()
3432
if tc then
3533
Duel.SpecialSummon(tc,0,tp,tp,true,false,POS_FACEUP)
3634
tc:CompleteProcedure()
3735
end
38-
end
36+
end

unofficial/c100000659.lua

Lines changed: 7 additions & 9 deletions
Original file line numberDiff line numberDiff line change
@@ -1,4 +1,5 @@
11
--錫の魔法陣
2+
--Bronze Scale
23
local s,id=GetID()
34
function s.initial_effect(c)
45
--Activate
@@ -11,28 +12,25 @@ function s.initial_effect(c)
1112
e1:SetOperation(s.activate)
1213
c:RegisterEffect(e1)
1314
end
14-
s.listed_names={100000653,100000650}
15+
s.listed_names={100000653,6500778} --"Alchemy Beast - Ouroboros the Bronze", "Chaos Distill"
1516
function s.spfilter(c,e,tp)
1617
return c:IsCode(100000653) and c:IsCanBeSpecialSummoned(e,0,tp,true,false)
1718
end
18-
function s.cfilter(c)
19-
return c:IsFaceup() and c:IsCode(100000650)
20-
end
2119
function s.condition(e,tp,eg,ep,ev,re,r,rp)
22-
return Duel.IsExistingMatchingCard(s.cfilter,tp,LOCATION_ONFIELD,LOCATION_ONFIELD,1,nil)
23-
and Duel.IsExistingMatchingCard(s.spfilter,tp,LOCATION_DECK|LOCATION_HAND,0,1,nil,e,tp)
20+
return Duel.IsExistingMatchingCard(aux.FaceupFilter(Card.IsCode,6500778),tp,LOCATION_ONFIELD,LOCATION_ONFIELD,1,nil)
21+
and Duel.IsExistingMatchingCard(s.spfilter,tp,LOCATION_HAND|LOCATION_DECK,0,1,nil,e,tp)
2422
end
2523
function s.target(e,tp,eg,ep,ev,re,r,rp,chk)
2624
if chk==0 then return true end
27-
Duel.SetOperationInfo(0,CATEGORY_SPECIAL_SUMMON,nil,1,0,LOCATION_DECK|LOCATION_HAND)
25+
Duel.SetOperationInfo(0,CATEGORY_SPECIAL_SUMMON,nil,1,0,LOCATION_HAND|LOCATION_DECK)
2826
end
2927
function s.activate(e,tp,eg,ep,ev,re,r,rp)
3028
if Duel.GetLocationCount(tp,LOCATION_MZONE)<=0 then return end
3129
Duel.Hint(HINT_SELECTMSG,tp,HINTMSG_SPSUMMON)
32-
local g=Duel.SelectMatchingCard(tp,s.spfilter,tp,LOCATION_DECK|LOCATION_HAND,0,1,1,nil,e,tp)
30+
local g=Duel.SelectMatchingCard(tp,s.spfilter,tp,LOCATION_HAND|LOCATION_DECK,0,1,1,nil,e,tp)
3331
local tc=g:GetFirst()
3432
if tc then
3533
Duel.SpecialSummon(tc,0,tp,tp,true,false,POS_FACEUP)
3634
tc:CompleteProcedure()
3735
end
38-
end
36+
end

unofficial/c100000660.lua

Lines changed: 7 additions & 9 deletions
Original file line numberDiff line numberDiff line change
@@ -1,4 +1,5 @@
11
--鉛のコンパス
2+
--Lead Compass
23
local s,id=GetID()
34
function s.initial_effect(c)
45
--Activate
@@ -11,28 +12,25 @@ function s.initial_effect(c)
1112
e1:SetOperation(s.activate)
1213
c:RegisterEffect(e1)
1314
end
14-
s.listed_names={100000654,100000650}
15+
s.listed_names={100000654,6500778} --"Alchemy Beast - Leon the Lead", "Chaos Distill"
1516
function s.spfilter(c,e,tp)
1617
return c:IsCode(100000654) and c:IsCanBeSpecialSummoned(e,0,tp,true,false)
1718
end
18-
function s.cfilter(c)
19-
return c:IsFaceup() and c:IsCode(100000650)
20-
end
2119
function s.condition(e,tp,eg,ep,ev,re,r,rp)
22-
return Duel.IsExistingMatchingCard(s.cfilter,tp,LOCATION_ONFIELD,LOCATION_ONFIELD,1,nil)
23-
and Duel.IsExistingMatchingCard(s.spfilter,tp,LOCATION_DECK|LOCATION_HAND,0,1,nil,e,tp)
20+
return Duel.IsExistingMatchingCard(aux.FaceupFilter(Card.IsCode,6500778),tp,LOCATION_ONFIELD,LOCATION_ONFIELD,1,nil)
21+
and Duel.IsExistingMatchingCard(s.spfilter,tp,LOCATION_HAND|LOCATION_DECK,0,1,nil,e,tp)
2422
end
2523
function s.target(e,tp,eg,ep,ev,re,r,rp,chk)
2624
if chk==0 then return true end
27-
Duel.SetOperationInfo(0,CATEGORY_SPECIAL_SUMMON,nil,1,0,LOCATION_DECK|LOCATION_HAND)
25+
Duel.SetOperationInfo(0,CATEGORY_SPECIAL_SUMMON,nil,1,0,LOCATION_HAND|LOCATION_DECK)
2826
end
2927
function s.activate(e,tp,eg,ep,ev,re,r,rp)
3028
if Duel.GetLocationCount(tp,LOCATION_MZONE)<=0 then return end
3129
Duel.Hint(HINT_SELECTMSG,tp,HINTMSG_SPSUMMON)
32-
local g=Duel.SelectMatchingCard(tp,s.spfilter,tp,LOCATION_DECK|LOCATION_HAND,0,1,1,nil,e,tp)
30+
local g=Duel.SelectMatchingCard(tp,s.spfilter,tp,LOCATION_HAND|LOCATION_DECK,0,1,1,nil,e,tp)
3331
local tc=g:GetFirst()
3432
if tc then
3533
Duel.SpecialSummon(tc,0,tp,tp,true,false,POS_FACEUP)
3634
tc:CompleteProcedure()
3735
end
38-
end
36+
end

unofficial/c100000661.lua

Lines changed: 7 additions & 9 deletions
Original file line numberDiff line numberDiff line change
@@ -1,4 +1,5 @@
11
--銀の鍵
2+
--Silver Key
23
local s,id=GetID()
34
function s.initial_effect(c)
45
--Activate
@@ -11,28 +12,25 @@ function s.initial_effect(c)
1112
e1:SetOperation(s.activate)
1213
c:RegisterEffect(e1)
1314
end
14-
s.listed_names={100000655,100000650}
15+
s.listed_names={100000655,6500778} --"Alchemy Beast - Moonface the Silver", "Chaos Distill"
1516
function s.spfilter(c,e,tp)
1617
return c:IsCode(100000655) and c:IsCanBeSpecialSummoned(e,0,tp,true,false)
1718
end
18-
function s.cfilter(c)
19-
return c:IsFaceup() and c:IsCode(100000650)
20-
end
2119
function s.condition(e,tp,eg,ep,ev,re,r,rp)
22-
return Duel.IsExistingMatchingCard(s.cfilter,tp,LOCATION_ONFIELD,LOCATION_ONFIELD,1,nil)
23-
and Duel.IsExistingMatchingCard(s.spfilter,tp,LOCATION_DECK|LOCATION_HAND,0,1,nil,e,tp)
20+
return Duel.IsExistingMatchingCard(aux.FaceupFilter(Card.IsCode,6500778),tp,LOCATION_ONFIELD,LOCATION_ONFIELD,1,nil)
21+
and Duel.IsExistingMatchingCard(s.spfilter,tp,LOCATION_HAND|LOCATION_DECK,0,1,nil,e,tp)
2422
end
2523
function s.target(e,tp,eg,ep,ev,re,r,rp,chk)
2624
if chk==0 then return true end
27-
Duel.SetOperationInfo(0,CATEGORY_SPECIAL_SUMMON,nil,1,0,LOCATION_DECK|LOCATION_HAND)
25+
Duel.SetOperationInfo(0,CATEGORY_SPECIAL_SUMMON,nil,1,0,LOCATION_HAND|LOCATION_DECK)
2826
end
2927
function s.activate(e,tp,eg,ep,ev,re,r,rp)
3028
if Duel.GetLocationCount(tp,LOCATION_MZONE)<=0 then return end
3129
Duel.Hint(HINT_SELECTMSG,tp,HINTMSG_SPSUMMON)
32-
local g=Duel.SelectMatchingCard(tp,s.spfilter,tp,LOCATION_DECK|LOCATION_HAND,0,1,1,nil,e,tp)
30+
local g=Duel.SelectMatchingCard(tp,s.spfilter,tp,LOCATION_HAND|LOCATION_DECK,0,1,1,nil,e,tp)
3331
local tc=g:GetFirst()
3432
if tc then
3533
Duel.SpecialSummon(tc,0,tp,tp,true,false,POS_FACEUP)
3634
tc:CompleteProcedure()
3735
end
38-
end
36+
end

unofficial/c100000662.lua

Lines changed: 7 additions & 9 deletions
Original file line numberDiff line numberDiff line change
@@ -1,4 +1,5 @@
11
--水銀の砂時計
2+
--Mercury Hourglass
23
local s,id=GetID()
34
function s.initial_effect(c)
45
--Activate
@@ -11,28 +12,25 @@ function s.initial_effect(c)
1112
e1:SetOperation(s.activate)
1213
c:RegisterEffect(e1)
1314
end
14-
s.listed_names={100000656,100000650}
15+
s.listed_names={100000656,6500778} --"Alchemy Beast - Ekenas the Mercury", "Chaos Distill"
1516
function s.spfilter(c,e,tp)
1617
return c:IsCode(100000656) and c:IsCanBeSpecialSummoned(e,0,tp,true,false)
1718
end
18-
function s.cfilter(c)
19-
return c:IsFaceup() and c:IsCode(100000650)
20-
end
2119
function s.condition(e,tp,eg,ep,ev,re,r,rp)
22-
return Duel.IsExistingMatchingCard(s.cfilter,tp,LOCATION_ONFIELD,LOCATION_ONFIELD,1,nil)
23-
and Duel.IsExistingMatchingCard(s.spfilter,tp,LOCATION_DECK|LOCATION_HAND,0,1,nil,e,tp)
20+
return Duel.IsExistingMatchingCard(aux.FaceupFilter(Card.IsCode,6500778),tp,LOCATION_ONFIELD,LOCATION_ONFIELD,1,nil)
21+
and Duel.IsExistingMatchingCard(s.spfilter,tp,LOCATION_HAND|LOCATION_DECK,0,1,nil,e,tp)
2422
end
2523
function s.target(e,tp,eg,ep,ev,re,r,rp,chk)
2624
if chk==0 then return true end
27-
Duel.SetOperationInfo(0,CATEGORY_SPECIAL_SUMMON,nil,1,0,LOCATION_DECK|LOCATION_HAND)
25+
Duel.SetOperationInfo(0,CATEGORY_SPECIAL_SUMMON,nil,1,0,LOCATION_HAND|LOCATION_DECK)
2826
end
2927
function s.activate(e,tp,eg,ep,ev,re,r,rp)
3028
if Duel.GetLocationCount(tp,LOCATION_MZONE)<=0 then return end
3129
Duel.Hint(HINT_SELECTMSG,tp,HINTMSG_SPSUMMON)
32-
local g=Duel.SelectMatchingCard(tp,s.spfilter,tp,LOCATION_DECK|LOCATION_HAND,0,1,1,nil,e,tp)
30+
local g=Duel.SelectMatchingCard(tp,s.spfilter,tp,LOCATION_HAND|LOCATION_DECK,0,1,1,nil,e,tp)
3331
local tc=g:GetFirst()
3432
if tc then
3533
Duel.SpecialSummon(tc,0,tp,tp,true,false,POS_FACEUP)
3634
tc:CompleteProcedure()
3735
end
38-
end
36+
end

unofficial/c100000663.lua

Lines changed: 7 additions & 9 deletions
Original file line numberDiff line numberDiff line change
@@ -1,4 +1,5 @@
11
--白の過程-アルベド
2+
--White Process - Albedo
23
local s,id=GetID()
34
function s.initial_effect(c)
45
--Activate
@@ -11,28 +12,25 @@ function s.initial_effect(c)
1112
e1:SetOperation(s.activate)
1213
c:RegisterEffect(e1)
1314
end
14-
s.listed_names={27408609,100000650}
15+
s.listed_names={27408609,6500778} --"Golden Homunculus", "Chaos Distill"
1516
function s.spfilter(c,e,tp)
1617
return c:IsCode(27408609) and c:IsCanBeSpecialSummoned(e,0,tp,true,false)
1718
end
18-
function s.cfilter(c)
19-
return c:IsFaceup() and c:IsCode(100000650)
20-
end
2119
function s.condition(e,tp,eg,ep,ev,re,r,rp)
22-
return Duel.IsExistingMatchingCard(s.cfilter,tp,LOCATION_ONFIELD,LOCATION_ONFIELD,1,nil)
23-
and Duel.IsExistingMatchingCard(s.spfilter,tp,LOCATION_DECK|LOCATION_HAND,0,1,nil,e,tp)
20+
return Duel.IsExistingMatchingCard(aux.FaceupFilter(Card.IsCode,6500778),tp,LOCATION_ONFIELD,LOCATION_ONFIELD,1,nil)
21+
and Duel.IsExistingMatchingCard(s.spfilter,tp,LOCATION_HAND|LOCATION_DECK,0,1,nil,e,tp)
2422
end
2523
function s.target(e,tp,eg,ep,ev,re,r,rp,chk)
2624
if chk==0 then return true end
27-
Duel.SetOperationInfo(0,CATEGORY_SPECIAL_SUMMON,nil,1,0,LOCATION_DECK|LOCATION_HAND)
25+
Duel.SetOperationInfo(0,CATEGORY_SPECIAL_SUMMON,nil,1,0,LOCATION_HAND|LOCATION_DECK)
2826
end
2927
function s.activate(e,tp,eg,ep,ev,re,r,rp)
3028
if Duel.GetLocationCount(tp,LOCATION_MZONE)<=0 then return end
3129
Duel.Hint(HINT_SELECTMSG,tp,HINTMSG_SPSUMMON)
32-
local g=Duel.SelectMatchingCard(tp,s.spfilter,tp,LOCATION_DECK|LOCATION_HAND,0,1,1,nil,e,tp)
30+
local g=Duel.SelectMatchingCard(tp,s.spfilter,tp,LOCATION_HAND|LOCATION_DECK,0,1,1,nil,e,tp)
3331
local tc=g:GetFirst()
3432
if tc then
3533
Duel.SpecialSummon(tc,0,tp,tp,true,false,POS_FACEUP)
3634
tc:CompleteProcedure()
3735
end
38-
end
36+
end

unofficial/c100000664.lua

Lines changed: 12 additions & 13 deletions
Original file line numberDiff line numberDiff line change
@@ -1,4 +1,5 @@
11
--黒の過程-ニグレド
2+
--Black Process - Negledo
23
local s,id=GetID()
34
function s.initial_effect(c)
45
--Activate
@@ -11,38 +12,36 @@ function s.initial_effect(c)
1112
e1:SetOperation(s.activate)
1213
c:RegisterEffect(e1)
1314
end
14-
s.listed_names={100000650}
15-
function s.filter(c)
15+
s.listed_series={0x501} --"Alchemy Beast" archetype
16+
s.listed_names={6500778} --"Chaos Distill"
17+
function s.rmfilter(c)
1618
return c:IsFaceup() and c:IsSetCard(0x501) and c:IsAbleToRemove()
1719
end
18-
function s.cfilter(c)
19-
return c:IsFaceup() and c:IsCode(100000650)
20-
end
2120
function s.condition(e,tp,eg,ep,ev,re,r,rp)
2221
local c=e:GetHandler()
2322
if c==nil then return true end
24-
return Duel.IsExistingMatchingCard(s.cfilter,tp,LOCATION_ONFIELD,LOCATION_ONFIELD,1,nil)
25-
and Duel.IsExistingMatchingCard(s.filter,tp,LOCATION_MZONE,0,1,nil)
23+
return Duel.IsExistingMatchingCard(aux.FaceupFilter(Card.IsCode,6500778),tp,LOCATION_ONFIELD,LOCATION_ONFIELD,1,nil)
24+
and Duel.IsExistingMatchingCard(s.rmfilter,tp,LOCATION_MZONE,0,1,nil)
2625
and (Duel.GetFieldGroupCount(c:GetControler(),LOCATION_HAND,0)==1 and not Duel.IsExistingMatchingCard(nil,tp,LOCATION_HAND,0,1,c))
2726
or Duel.GetFieldGroupCount(c:GetControler(),LOCATION_HAND,0)==0
2827
end
2928
function s.target(e,tp,eg,ep,ev,re,r,rp,chk)
3029
if chk==0 then return Duel.IsPlayerCanDraw(tp,2) end
31-
local g=Duel.GetMatchingGroup(s.filter,tp,LOCATION_MZONE,0,nil)
30+
local g=Duel.GetMatchingGroup(s.rmfilter,tp,LOCATION_MZONE,0,nil)
3231
Duel.SetTargetPlayer(tp)
33-
Duel.SetOperationInfo(0,CATEGORY_DRAW,nil,0,tp,#g)
32+
Duel.SetOperationInfo(0,CATEGORY_DRAW,nil,0,tp,#g*2)
3433
end
35-
function s.filter1(c)
34+
function s.rmchkfilter(c)
3635
return c:IsFaceup() and c:IsSetCard(0x501) and c:IsLocation(LOCATION_REMOVED)
3736
end
3837
function s.activate(e,tp,eg,ep,ev,re,r,rp)
3938
local p=Duel.GetChainInfo(0,CHAININFO_TARGET_PLAYER)
40-
local g=Duel.GetMatchingGroup(s.filter,tp,LOCATION_MZONE,0,nil)
39+
local g=Duel.GetMatchingGroup(s.rmfilter,tp,LOCATION_MZONE,0,nil)
4140
if Duel.Remove(g,POS_FACEUP,REASON_EFFECT)>0 then
4241
local og=Duel.GetOperatedGroup()
43-
local dc=og:FilterCount(s.filter1,nil)
42+
local dc=og:FilterCount(s.rmchkfilter,nil)
4443
if dc>0 then
4544
Duel.Draw(p,dc*2,REASON_EFFECT)
4645
end
4746
end
48-
end
47+
end

0 commit comments

Comments
 (0)