Skip to content

Commit ce21466

Browse files
committed
Update "Concours de Cuisine (Culinary Confrontation)"
Fixed a bug where the player would be prevented for using materials for contact-like summons (which are not treated as the types listed)
1 parent 76a30f7 commit ce21466

1 file changed

Lines changed: 6 additions & 14 deletions

File tree

official/c14283055.lua

Lines changed: 6 additions & 14 deletions
Original file line numberDiff line numberDiff line change
@@ -57,25 +57,16 @@ function s.target(e,tp,eg,ep,ev,re,r,rp,chk)
5757
end
5858
function s.operation(e,tp,eg,ep,ev,re,r,rp)
5959
local c=e:GetHandler()
60-
--Cannot use monsters as material for a Fusion/Synchro/Xyz/Link Summon, except "Nouvelles" and "Patissciel" monsters
60+
--You cannot use monsters as material for a Fusion, Synchro, Xyz, or Link Summon, except "Nouvelles" and "Patissciel" monsters
6161
local e1=Effect.CreateEffect(c)
6262
e1:SetType(EFFECT_TYPE_FIELD)
6363
e1:SetProperty(EFFECT_FLAG_SET_AVAILABLE+EFFECT_FLAG_IGNORE_IMMUNE)
64-
e1:SetCode(EFFECT_CANNOT_BE_FUSION_MATERIAL)
64+
e1:SetCode(EFFECT_CANNOT_BE_MATERIAL)
6565
e1:SetTargetRange(LOCATION_ALL,LOCATION_ALL)
6666
e1:SetTarget(function(e,c) return not c:IsSetCard({SET_NOUVELLES,SET_PATISSCIEL}) end)
6767
e1:SetValue(s.sumlimit)
6868
e1:SetReset(RESET_PHASE|PHASE_END)
6969
Duel.RegisterEffect(e1,tp)
70-
local e2=e1:Clone()
71-
e2:SetCode(EFFECT_CANNOT_BE_SYNCHRO_MATERIAL)
72-
Duel.RegisterEffect(e2,tp)
73-
local e3=e1:Clone()
74-
e3:SetCode(EFFECT_CANNOT_BE_XYZ_MATERIAL)
75-
Duel.RegisterEffect(e3,tp)
76-
local e4=e1:Clone()
77-
e4:SetCode(EFFECT_CANNOT_BE_LINK_MATERIAL)
78-
Duel.RegisterEffect(e4,tp)
7970
aux.RegisterClientHint(c,nil,tp,1,0,aux.Stringid(id,2))
8071
--Special Summon 1 "Nouvelles" monster and 1 "Patissciel" monster
8172
local g1=Duel.GetMatchingGroup(s.cfilter,tp,locs,0,nil,SET_NOUVELLES)
@@ -91,9 +82,10 @@ function s.operation(e,tp,eg,ep,ev,re,r,rp)
9182
Duel.SpecialSummonStep(sc2,0,tp,1-tp,false,false,POS_FACEUP)
9283
Duel.SpecialSummonComplete()
9384
end
94-
function s.sumlimit(e,c)
95-
if not c then return false end
96-
return c:IsControler(e:GetHandlerPlayer())
85+
function s.sumlimit(e,sumc,sumtype,sumplayer)
86+
if not sumc then return false end
87+
local tp=e:GetHandlerPlayer()
88+
return sumplayer==tp and sumc:IsControler(tp) and (sumtype&(SUMMON_TYPE_FUSION|SUMMON_TYPE_SYNCHRO|SUMMON_TYPE_XYZ|SUMMON_TYPE_LINK))>0
9789
end
9890
function s.atktg(e,tp,eg,ep,ev,re,r,rp,chk,chkc)
9991
local ct=Duel.GetMatchingGroupCount(Card.IsSetCard,tp,LOCATION_GRAVE,LOCATION_GRAVE,nil,SET_RECIPE)

0 commit comments

Comments
 (0)