Commit c0e3f945 authored by Vury Leo's avatar Vury Leo

Add 接触するG

parent f246090a
...@@ -3826,11 +3826,6 @@ function Synchro.SynCondition(tuner_race,tuner_level,tuner_filter,non_tuner_race ...@@ -3826,11 +3826,6 @@ function Synchro.SynCondition(tuner_race,tuner_level,tuner_filter,non_tuner_race
mg=mg or Synchro.GetSynchroMaterial(c:GetControler(),c,level_mapper) mg=mg or Synchro.GetSynchroMaterial(c:GetControler(),c,level_mapper)
local candidates={} local candidates={}
for mc in aux.Next(mg) do
if mc~=smat then
table.insert(candidates,mc)
end
end
local pre_selected_arr={} local pre_selected_arr={}
if smat~=nil then if smat~=nil then
...@@ -3839,6 +3834,22 @@ function Synchro.SynCondition(tuner_race,tuner_level,tuner_filter,non_tuner_race ...@@ -3839,6 +3834,22 @@ function Synchro.SynCondition(tuner_race,tuner_level,tuner_filter,non_tuner_race
end end
table.insert(pre_selected_arr,smat) table.insert(pre_selected_arr,smat)
end end
--- 接触するG
local must_be_materials=Duel.GetMustMaterial(c:GetControler(),EFFECT_MUST_BE_SMATERIAL)
for mc in aux.Next(must_be_materials) do
if not mg:IsContains(mc) then
return false
end
table.insert(pre_selected_arr,mc)
end
for mc in aux.Next(mg) do
if mc~=smat and not must_be_materials:IsContains(mc) then
table.insert(candidates,mc)
end
end
local pre_selected_states=Synchro.BuildStatesFromSelection(pre_selected_arr,tuner_race,tuner_level,tuner_filter,non_tuner_race,non_tuner_level,non_tuner_filter,level_mapper,hand_count_mapper,c,math.huge,skip_hand_count_check) local pre_selected_states=Synchro.BuildStatesFromSelection(pre_selected_arr,tuner_race,tuner_level,tuner_filter,non_tuner_race,non_tuner_level,non_tuner_filter,level_mapper,hand_count_mapper,c,math.huge,skip_hand_count_check)
for _,state in ipairs(pre_selected_states) do for _,state in ipairs(pre_selected_states) do
...@@ -3891,6 +3902,15 @@ function Synchro.SynTarget(tuner_race,tuner_level,tuner_filter,non_tuner_race,no ...@@ -3891,6 +3902,15 @@ function Synchro.SynTarget(tuner_race,tuner_level,tuner_filter,non_tuner_race,no
sg:AddCard(smat) sg:AddCard(smat)
end end
--- 接触するG
local must_be_materials=Duel.GetMustMaterial(tp,EFFECT_MUST_BE_SMATERIAL)
for mc in aux.Next(must_be_materials) do
if not mg:IsContains(mc) then
return false
end
sg:AddCard(mc)
end
local function GroupToArray(group) local function GroupToArray(group)
local arr={} local arr={}
for card in aux.Next(group) do table.insert(arr,card) end for card in aux.Next(group) do table.insert(arr,card) end
...@@ -3988,7 +4008,7 @@ function Synchro.SynTarget(tuner_race,tuner_level,tuner_filter,non_tuner_race,no ...@@ -3988,7 +4008,7 @@ function Synchro.SynTarget(tuner_race,tuner_level,tuner_filter,non_tuner_race,no
end end
else else
if sg:IsContains(picked) then if sg:IsContains(picked) then
if picked~=smat then if picked~=smat and not must_be_materials:IsContains(picked) then
sg:RemoveCard(picked) sg:RemoveCard(picked)
end end
else else
......
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