Commit 12a96645 authored by VanillaSalt's avatar VanillaSalt

fix

parent 006f3319
...@@ -350,8 +350,7 @@ int32 effect::is_activate_check(uint8 playerid, const tevent& e, int32 neglect_c ...@@ -350,8 +350,7 @@ int32 effect::is_activate_check(uint8 playerid, const tevent& e, int32 neglect_c
uint8 op = pduel->game_field->core.reason_player; uint8 op = pduel->game_field->core.reason_player;
pduel->game_field->core.reason_effect = this; pduel->game_field->core.reason_effect = this;
pduel->game_field->core.reason_player = playerid; pduel->game_field->core.reason_player = playerid;
int32 result = TRUE; int32 result = is_activate_ready(playerid, e, neglect_cond, neglect_cost, neglect_target);
result = is_activate_ready(playerid, e, neglect_cond, neglect_cost, neglect_target);
pduel->game_field->core.reason_effect = oreason; pduel->game_field->core.reason_effect = oreason;
pduel->game_field->core.reason_player = op; pduel->game_field->core.reason_player = op;
pduel->game_field->restore_lp_cost(); pduel->game_field->restore_lp_cost();
......
...@@ -472,11 +472,10 @@ int32 field::get_useable_count(uint8 playerid, uint8 location, uint8 uplayer, ui ...@@ -472,11 +472,10 @@ int32 field::get_useable_count(uint8 playerid, uint8 location, uint8 uplayer, ui
if(list) if(list)
*list = flag; *list = flag;
if(eset.count) { if(eset.count) {
int32 max = 5;
pduel->lua->add_param(playerid, PARAM_TYPE_INT); pduel->lua->add_param(playerid, PARAM_TYPE_INT);
pduel->lua->add_param(uplayer, PARAM_TYPE_INT); pduel->lua->add_param(uplayer, PARAM_TYPE_INT);
pduel->lua->add_param(reason, PARAM_TYPE_INT); pduel->lua->add_param(reason, PARAM_TYPE_INT);
max = eset.get_last()->get_value(3); int32 max = eset.get_last()->get_value(3);
int32 block = 5 - field_used_count[flag]; int32 block = 5 - field_used_count[flag];
int32 limit = max - field_used_count[used_flag]; int32 limit = max - field_used_count[used_flag];
return block < limit ? block : limit; return block < limit ? block : limit;
......
...@@ -4024,7 +4024,6 @@ int32 field::process_turn(uint16 step, uint8 turn_player) { ...@@ -4024,7 +4024,6 @@ int32 field::process_turn(uint16 step, uint8 turn_player) {
core.flipsummon_state_count[p] = 0; core.flipsummon_state_count[p] = 0;
core.spsummon_state_count[p] = 0; core.spsummon_state_count[p] = 0;
core.spsummon_state_count_rst[p] = 0; core.spsummon_state_count_rst[p] = 0;
core.spsummon_rst = false;
core.attack_state_count[p] = 0; core.attack_state_count[p] = 0;
core.battle_phase_count[p] = 0; core.battle_phase_count[p] = 0;
core.summon_count[p] = 0; core.summon_count[p] = 0;
...@@ -4032,6 +4031,7 @@ int32 field::process_turn(uint16 step, uint8 turn_player) { ...@@ -4032,6 +4031,7 @@ int32 field::process_turn(uint16 step, uint8 turn_player) {
core.spsummon_once_map[p].clear(); core.spsummon_once_map[p].clear();
core.spsummon_once_map_rst[p].clear(); core.spsummon_once_map_rst[p].clear();
} }
core.spsummon_rst = false;
for(auto rit = effects.rechargeable.begin(); rit != effects.rechargeable.end(); ++rit) for(auto rit = effects.rechargeable.begin(); rit != effects.rechargeable.end(); ++rit)
if(!((*rit)->flag & EFFECT_FLAG_NO_TURN_RESET)) if(!((*rit)->flag & EFFECT_FLAG_NO_TURN_RESET))
(*rit)->recharge(); (*rit)->recharge();
...@@ -4051,7 +4051,7 @@ int32 field::process_turn(uint16 step, uint8 turn_player) { ...@@ -4051,7 +4051,7 @@ int32 field::process_turn(uint16 step, uint8 turn_player) {
for(auto iter = effects.spsummon_count_eff.begin(); iter != effects.spsummon_count_eff.end(); ++iter) { for(auto iter = effects.spsummon_count_eff.begin(); iter != effects.spsummon_count_eff.end(); ++iter) {
effect* peffect = *iter; effect* peffect = *iter;
card* pcard = peffect->handler; card* pcard = peffect->handler;
if(!(peffect->flag & EFFECT_FLAG_NO_TURN_RESET)){ if(!(peffect->flag & EFFECT_FLAG_NO_TURN_RESET)) {
pcard->spsummon_counter[0] = pcard->spsummon_counter[1] = 0; pcard->spsummon_counter[0] = pcard->spsummon_counter[1] = 0;
pcard->spsummon_counter_rst[0] = pcard->spsummon_counter_rst[1] = 0; pcard->spsummon_counter_rst[0] = pcard->spsummon_counter_rst[1] = 0;
} }
...@@ -4448,22 +4448,25 @@ int32 field::add_chain(uint16 step) { ...@@ -4448,22 +4448,25 @@ int32 field::add_chain(uint16 step) {
auto& optarget = clit.opinfos[0x200]; auto& optarget = clit.opinfos[0x200];
if(optarget.op_cards) { if(optarget.op_cards) {
if(optarget.op_player == PLAYER_ALL) { if(optarget.op_player == PLAYER_ALL) {
auto spcard = optarget.op_cards->container.begin(); auto opit = optarget.op_cards->container.begin();
uint32 plr = optarget.op_param; uint32 sumplayer = optarget.op_param;
if((*spcard)->spsummon_code) { if((*opit)->spsummon_code) {
core.spsummon_once_map[plr][(*spcard)->spsummon_code]++; core.spsummon_once_map[sumplayer][(*opit)->spsummon_code]++;
core.spsummon_once_map_rst[plr][(*spcard)->spsummon_code]++; core.spsummon_once_map_rst[sumplayer][(*opit)->spsummon_code]++;
} }
++spcard; ++opit;
if((*spcard)->spsummon_code) { if((*opit)->spsummon_code) {
core.spsummon_once_map[1 - plr][(*spcard)->spsummon_code]++; core.spsummon_once_map[1 - sumplayer][(*opit)->spsummon_code]++;
core.spsummon_once_map_rst[1 - plr][(*spcard)->spsummon_code]++; core.spsummon_once_map_rst[1 - sumplayer][(*opit)->spsummon_code]++;
} }
} else { } else {
for(auto spcard = optarget.op_cards->container.begin(); spcard != optarget.op_cards->container.end(); ++spcard) { uint32 sumplayer = clit.triggering_player;
if((*spcard)->spsummon_code) { if(optarget.op_player == 1)
core.spsummon_once_map[clit.triggering_player][(*spcard)->spsummon_code]++; sumplayer = 1 - sumplayer;
core.spsummon_once_map_rst[clit.triggering_player][(*spcard)->spsummon_code]++; for(auto opit = optarget.op_cards->container.begin(); opit != optarget.op_cards->container.end(); ++opit) {
if((*opit)->spsummon_code) {
core.spsummon_once_map[sumplayer][(*opit)->spsummon_code]++;
core.spsummon_once_map_rst[sumplayer][(*opit)->spsummon_code]++;
} }
} }
} }
...@@ -4582,7 +4585,7 @@ int32 field::solve_chain(uint16 step, uint32 skip_new) { ...@@ -4582,7 +4585,7 @@ int32 field::solve_chain(uint16 step, uint32 skip_new) {
if(core.spsummon_rst) { if(core.spsummon_rst) {
set_spsummon_counter(0, false, true); set_spsummon_counter(0, false, true);
set_spsummon_counter(1, false, true); set_spsummon_counter(1, false, true);
for(int plr = 0; plr <= 1; ++plr) { for(int plr = 0; plr < 2; ++plr) {
for(auto iter = core.spsummon_once_map[plr].begin(); iter != core.spsummon_once_map[plr].end(); ++iter) { for(auto iter = core.spsummon_once_map[plr].begin(); iter != core.spsummon_once_map[plr].end(); ++iter) {
auto spcode = iter->first; auto spcode = iter->first;
core.spsummon_once_map[plr][spcode] -= core.spsummon_once_map_rst[plr][spcode]; core.spsummon_once_map[plr][spcode] -= core.spsummon_once_map_rst[plr][spcode];
...@@ -4621,10 +4624,10 @@ int32 field::solve_chain(uint16 step, uint32 skip_new) { ...@@ -4621,10 +4624,10 @@ int32 field::solve_chain(uint16 step, uint32 skip_new) {
if((core.global_flag & GLOBALFLAG_SPSUMMON_ONCE) && (peffect->flag & EFFECT_FLAG_CARD_TARGET)) { if((core.global_flag & GLOBALFLAG_SPSUMMON_ONCE) && (peffect->flag & EFFECT_FLAG_CARD_TARGET)) {
auto& optarget = cait->opinfos[0x200]; auto& optarget = cait->opinfos[0x200];
if(optarget.op_cards) { if(optarget.op_cards) {
for(auto spcard = optarget.op_cards->container.begin(); spcard != optarget.op_cards->container.end(); ++spcard) { for(auto opit = optarget.op_cards->container.begin(); opit != optarget.op_cards->container.end(); ++opit) {
if((*spcard)->spsummon_code) { if((*opit)->spsummon_code) {
uint8 sumpl = optarget.op_player ? 1 : 0; uint8 sumpl = optarget.op_player ? 1 : 0;
core.spsummon_once_map[sumpl][(*spcard)->spsummon_code]--; core.spsummon_once_map[sumpl][(*opit)->spsummon_code]--;
} }
} }
} }
...@@ -4692,10 +4695,10 @@ int32 field::solve_chain(uint16 step, uint32 skip_new) { ...@@ -4692,10 +4695,10 @@ int32 field::solve_chain(uint16 step, uint32 skip_new) {
if((core.global_flag & GLOBALFLAG_SPSUMMON_ONCE) && (peffect->flag & EFFECT_FLAG_CARD_TARGET)) { if((core.global_flag & GLOBALFLAG_SPSUMMON_ONCE) && (peffect->flag & EFFECT_FLAG_CARD_TARGET)) {
auto& optarget = cait->opinfos[0x200]; auto& optarget = cait->opinfos[0x200];
if(optarget.op_cards) { if(optarget.op_cards) {
for(auto spcard = optarget.op_cards->container.begin(); spcard!= optarget.op_cards->container.end(); ++spcard) { for(auto opit = optarget.op_cards->container.begin(); opit != optarget.op_cards->container.end(); ++opit) {
if((*spcard)->spsummon_code) { if((*opit)->spsummon_code) {
uint8 sumpl = optarget.op_player ? 1 : 0; uint8 sumpl = optarget.op_player ? 1 : 0;
core.spsummon_once_map[sumpl][(*spcard)->spsummon_code]--; core.spsummon_once_map[sumpl][(*opit)->spsummon_code]--;
} }
} }
} }
...@@ -4712,7 +4715,7 @@ int32 field::solve_chain(uint16 step, uint32 skip_new) { ...@@ -4712,7 +4715,7 @@ int32 field::solve_chain(uint16 step, uint32 skip_new) {
return FALSE; return FALSE;
} }
case 4: { case 4: {
if(core.units.begin()->peffect == 0){ if(core.units.begin()->peffect == 0) {
if(cait->opinfos.count(0x200)) { if(cait->opinfos.count(0x200)) {
if(core.spsummon_state_count_tmp[cait->triggering_player] == core.spsummon_state_count[cait->triggering_player]) if(core.spsummon_state_count_tmp[cait->triggering_player] == core.spsummon_state_count[cait->triggering_player])
set_spsummon_counter(cait->triggering_player); set_spsummon_counter(cait->triggering_player);
...@@ -4723,22 +4726,27 @@ int32 field::solve_chain(uint16 step, uint32 skip_new) { ...@@ -4723,22 +4726,27 @@ int32 field::solve_chain(uint16 step, uint32 skip_new) {
auto& optarget = cait->opinfos[0x200]; auto& optarget = cait->opinfos[0x200];
if(optarget.op_cards) { if(optarget.op_cards) {
if(optarget.op_player == PLAYER_ALL) { if(optarget.op_player == PLAYER_ALL) {
auto spcard = optarget.op_cards->container.begin(); uint32 sumplayer = optarget.op_param;
uint32 plr = optarget.op_param; if(core.global_flag & GLOBALFLAG_SPSUMMON_ONCE) {
if((core.global_flag & GLOBALFLAG_SPSUMMON_ONCE) && (*spcard)->spsummon_code) { auto opit = optarget.op_cards->container.begin();
core.spsummon_once_map[plr][(*spcard)->spsummon_code]++; if((*opit)->spsummon_code)
++spcard; core.spsummon_once_map[sumplayer][(*opit)->spsummon_code]++;
core.spsummon_once_map[1 - plr][(*spcard)->spsummon_code]++; ++opit;
if((*opit)->spsummon_code)
core.spsummon_once_map[1 - sumplayer][(*opit)->spsummon_code]++;
} }
spcard = optarget.op_cards->container.begin(); auto opit = optarget.op_cards->container.begin();
check_card_counter(*spcard, 3, plr); check_card_counter(*opit, 3, sumplayer);
++spcard; ++opit;
check_card_counter(*spcard, 3, 1 - plr); check_card_counter(*opit, 3, 1 - sumplayer);
} else { } else {
for(auto spcard = optarget.op_cards->container.begin(); spcard != optarget.op_cards->container.end(); ++spcard) { uint32 sumplayer = cait.triggering_player;
if((core.global_flag & GLOBALFLAG_SPSUMMON_ONCE) && (*spcard)->spsummon_code) if(optarget.op_player == 1)
core.spsummon_once_map[cait->triggering_player][(*spcard)->spsummon_code]++; sumplayer = 1 - sumplayer;
check_card_counter(*spcard, 3, cait->triggering_player); for(auto opit = optarget.op_cards->container.begin(); opit != optarget.op_cards->container.end(); ++opit) {
if((core.global_flag & GLOBALFLAG_SPSUMMON_ONCE) && (*opit)->spsummon_code)
core.spsummon_once_map[sumplayer][(*opit)->spsummon_code]++;
check_card_counter(*opit, 3, sumplayer);
} }
} }
} }
......
...@@ -42,6 +42,7 @@ function c12525049.sptg(e,tp,eg,ep,ev,re,r,rp,chk) ...@@ -42,6 +42,7 @@ function c12525049.sptg(e,tp,eg,ep,ev,re,r,rp,chk)
Duel.SetOperationInfo(0,CATEGORY_SPECIAL_SUMMON,nil,1,tp,LOCATION_DECK) Duel.SetOperationInfo(0,CATEGORY_SPECIAL_SUMMON,nil,1,tp,LOCATION_DECK)
end end
function c12525049.spop(e,tp,eg,ep,ev,re,r,rp) function c12525049.spop(e,tp,eg,ep,ev,re,r,rp)
if not e:GetHandler():IsRelateToEffect(e) then return end
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,c12525049.spfilter,tp,LOCATION_DECK,0,1,1,nil,e,tp) local g=Duel.SelectMatchingCard(tp,c12525049.spfilter,tp,LOCATION_DECK,0,1,1,nil,e,tp)
......
...@@ -15,7 +15,7 @@ function c23516703.initial_effect(c) ...@@ -15,7 +15,7 @@ function c23516703.initial_effect(c)
e2:SetTarget(c23516703.limittg) e2:SetTarget(c23516703.limittg)
c:RegisterEffect(e2) c:RegisterEffect(e2)
local e3=e2:Clone() local e3=e2:Clone()
e3:SetCode(EFFECT_CANNOT_FLIPSUMMON) e3:SetCode(EFFECT_CANNOT_FLIP_SUMMON)
c:RegisterEffect(e3) c:RegisterEffect(e3)
local e4=e2:Clone() local e4=e2:Clone()
e4:SetCode(EFFECT_CANNOT_SPECIAL_SUMMON) e4:SetCode(EFFECT_CANNOT_SPECIAL_SUMMON)
......
...@@ -17,7 +17,7 @@ end ...@@ -17,7 +17,7 @@ end
c55067058.xyz_number=19 c55067058.xyz_number=19
function c55067058.rcon(e,tp,eg,ep,ev,re,r,rp) function c55067058.rcon(e,tp,eg,ep,ev,re,r,rp)
return bit.band(r,REASON_COST)~=0 and re:IsHasType(0x7e0) and re:IsActiveType(TYPE_XYZ) return bit.band(r,REASON_COST)~=0 and re:IsHasType(0x7e0) and re:IsActiveType(TYPE_XYZ)
and e:GetHandler():RemoveOverlayCard(tp,1,1,REASON_EFFECT) and e:GetHandler():CheckRemoveOverlayCard(tp,1,REASON_EFFECT)
and ep==e:GetOwnerPlayer() and re:GetHandler():GetOverlayCount()>=ev-1 and ep==e:GetOwnerPlayer() and re:GetHandler():GetOverlayCount()>=ev-1
end end
function c55067058.rop(e,tp,eg,ep,ev,re,r,rp) function c55067058.rop(e,tp,eg,ep,ev,re,r,rp)
......
...@@ -20,25 +20,23 @@ function c57728570.cost(e,tp,eg,ep,ev,re,r,rp,chk) ...@@ -20,25 +20,23 @@ function c57728570.cost(e,tp,eg,ep,ev,re,r,rp,chk)
Duel.Release(g,REASON_COST) Duel.Release(g,REASON_COST)
end end
function c57728570.filter(c) function c57728570.filter(c)
return c:IsType(TYPE_MONSTER) and c:IsAttackAbove(1500) and c:IsDestructable() return c:IsAttackAbove(1500) and c:IsDestructable()
end end
function c57728570.hgfilter(c) function c57728570.hgfilter(c)
return not c:IsPublic() or c57728570.filter(c) return not c:IsPublic() or c57728570.filter(c)
end end
function c57728570.fgfilter(c) function c57728570.fgfilter(c)
return not c:IsFaceup() or c57728570.filter(c) return c:IsFacedown() or c57728570.filter(c)
end end
function c57728570.tgfilter(c) function c57728570.tgfilter(c)
return ((c:IsLocation(LOCATION_HAND) and c:IsPublic()) or (c:IsLocation(LOCATION_HAND) and c:IsFaceup())) and c57728570.filter(c) return ((c:IsLocation(LOCATION_HAND) and c:IsPublic()) or (c:IsLocation(LOCATION_MZONE) and c:IsFaceup())) and c57728570.filter(c)
end end
function c57728570.target(e,tp,eg,ep,ev,re,r,rp,chk) function c57728570.target(e,tp,eg,ep,ev,re,r,rp,chk)
local ct1=Duel.GetFieldGroup(tp,0,LOCATION_HAND):FilterCount(c57728570.hgfilter,nil) if chk==0 then return Duel.IsExistingMatchingCard(c57728570.hgfilter,tp,0,LOCATION_HAND,1,nil)
local ct2=Duel.GetFieldGroup(tp,0,LOCATION_MZONE):FilterCount(c57728570.fgfilter,nil) or Duel.IsExistingMatchingCard(c57728570.fgfilter,tp,0,LOCATION_MZONE,1,nil) end
if chk==0 then return ct1+ct2>0 end
local g=Duel.GetMatchingGroup(c57728570.tgfilter,tp,0,LOCATION_MZONE+LOCATION_HAND,nil) local g=Duel.GetMatchingGroup(c57728570.tgfilter,tp,0,LOCATION_MZONE+LOCATION_HAND,nil)
Duel.SetOperationInfo(0,CATEGORY_DESTROY,g,g:GetCount(),0,0) Duel.SetOperationInfo(0,CATEGORY_DESTROY,g,g:GetCount(),0,0)
end end
function c57728570.activate(e,tp,eg,ep,ev,re,r,rp) function c57728570.activate(e,tp,eg,ep,ev,re,r,rp)
local conf=Duel.GetFieldGroup(tp,0,LOCATION_MZONE+LOCATION_HAND) local conf=Duel.GetFieldGroup(tp,0,LOCATION_MZONE+LOCATION_HAND)
local ct=0 local ct=0
......
...@@ -33,8 +33,14 @@ function c58551308.sptg(e,tp,eg,ep,ev,re,r,rp,chk,chkc) ...@@ -33,8 +33,14 @@ function c58551308.sptg(e,tp,eg,ep,ev,re,r,rp,chk,chkc)
local g1=Duel.SelectTarget(tp,c58551308.filter,tp,LOCATION_GRAVE,0,1,1,e:GetHandler(),e,tp) local g1=Duel.SelectTarget(tp,c58551308.filter,tp,LOCATION_GRAVE,0,1,1,e:GetHandler(),e,tp)
Duel.Hint(HINT_SELECTMSG,1-tp,HINTMSG_SPSUMMON) Duel.Hint(HINT_SELECTMSG,1-tp,HINTMSG_SPSUMMON)
local g2=Duel.SelectTarget(1-tp,c58551308.filter,1-tp,LOCATION_GRAVE,0,1,1,e:GetHandler(),e,1-tp) local g2=Duel.SelectTarget(1-tp,c58551308.filter,1-tp,LOCATION_GRAVE,0,1,1,e:GetHandler(),e,1-tp)
g1:Merge(g2) if g1:GetCount()>0 and g2:GetCount()>0 then
Duel.SetOperationInfo(0,CATEGORY_SPECIAL_SUMMON,g1,g1:GetCount(),PLAYER_ALL,g1:GetFirst():GetOwner()) g1:Merge(g2)
Duel.SetOperationInfo(0,CATEGORY_SPECIAL_SUMMON,g1,2,PLAYER_ALL,g1:GetFirst():GetOwner())
elseif g1:GetCount()>0 then
Duel.SetOperationInfo(0,CATEGORY_SPECIAL_SUMMON,g1,1,0,0)
elseif g2:GetCount()>0 then
Duel.SetOperationInfo(0,CATEGORY_SPECIAL_SUMMON,g2,1,1,0)
end
end end
function c58551308.spop(e,tp,eg,ep,ev,re,r,rp) function c58551308.spop(e,tp,eg,ep,ev,re,r,rp)
local g=Duel.GetChainInfo(0,CHAININFO_TARGET_CARDS) local g=Duel.GetChainInfo(0,CHAININFO_TARGET_CARDS)
......
...@@ -50,7 +50,7 @@ function c74892653.target(e,tp,eg,ep,ev,re,r,rp,chk) ...@@ -50,7 +50,7 @@ function c74892653.target(e,tp,eg,ep,ev,re,r,rp,chk)
Duel.SetOperationInfo(0,CATEGORY_DISABLE_SUMMON,eg,eg:GetCount(),0,0) Duel.SetOperationInfo(0,CATEGORY_DISABLE_SUMMON,eg,eg:GetCount(),0,0)
Duel.SetOperationInfo(0,CATEGORY_DESTROY,eg,eg:GetCount(),0,0) Duel.SetOperationInfo(0,CATEGORY_DESTROY,eg,eg:GetCount(),0,0)
end end
function c74892653.operation(e,tp,eg,ep,ev,re,r,rp,chk) function c74892653.operation(e,tp,eg,ep,ev,re,r,rp)
Duel.NegateSummon(eg) Duel.NegateSummon(eg)
Duel.Destroy(eg,REASON_EFFECT) Duel.Destroy(eg,REASON_EFFECT)
e:GetHandler():RegisterFlagEffect(74892653,RESET_EVENT+0x1fe0000+RESET_PHASE+RESET_END,0,1) e:GetHandler():RegisterFlagEffect(74892653,RESET_EVENT+0x1fe0000+RESET_PHASE+RESET_END,0,1)
...@@ -72,7 +72,8 @@ function c74892653.sccon(e,tp,eg,ep,ev,re,r,rp) ...@@ -72,7 +72,8 @@ function c74892653.sccon(e,tp,eg,ep,ev,re,r,rp)
and c:IsPreviousPosition(POS_FACEUP) and c:IsPreviousPosition(POS_FACEUP)
end end
function c74892653.filter(c,e,tp) function c74892653.filter(c,e,tp)
return c:IsSetCard(0x66) and c:IsLevelBelow(8) and c:IsCanBeSpecialSummoned(e,SUMMON_TYPE_SYNCHRO,tp,false,false) return c:IsSetCard(0x66) and c:IsLevelBelow(8) and c:IsType(TYPE_SYNCHRO)
and c:IsCanBeSpecialSummoned(e,SUMMON_TYPE_SYNCHRO,tp,false,false)
end end
function c74892653.sctg(e,tp,eg,ep,ev,re,r,rp,chk) function c74892653.sctg(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
......
...@@ -23,7 +23,7 @@ function c86466163.operation(e,tp,eg,ep,ev,re,r,rp) ...@@ -23,7 +23,7 @@ function c86466163.operation(e,tp,eg,ep,ev,re,r,rp)
e1:SetCode(EFFECT_XYZ_LEVEL) e1:SetCode(EFFECT_XYZ_LEVEL)
e1:SetProperty(EFFECT_FLAG_IGNORE_IMMUNE) e1:SetProperty(EFFECT_FLAG_IGNORE_IMMUNE)
e1:SetTargetRange(LOCATION_MZONE,0) e1:SetTargetRange(LOCATION_MZONE,0)
e1:SetTargeet(c86466163.xyztg) e1:SetTarget(c86466163.xyztg)
e1:SetValue(c86466163.xyzlv) e1:SetValue(c86466163.xyzlv)
e1:SetReset(RESET_PHASE+RESET_END) e1:SetReset(RESET_PHASE+RESET_END)
Duel.RegisterEffect(e1,tp) Duel.RegisterEffect(e1,tp)
......
...@@ -44,10 +44,9 @@ function c8809344.rkop(e,tp,eg,ep,ev,re,r,rp) ...@@ -44,10 +44,9 @@ function c8809344.rkop(e,tp,eg,ep,ev,re,r,rp)
end end
end end
function c8809344.condition(e,tp,eg,ep,ev,re,r,rp) function c8809344.condition(e,tp,eg,ep,ev,re,r,rp)
return e:GetHandler():IsType(TYPE_XYZ) and e:GetOverlayGroup():GetCount()>0 return e:GetHandler():IsType(TYPE_XYZ) and e:GetHandler():GetOverlayCount()>0
end end
function c8809344.target(e,tp,eg,ep,ev,re,r,rp,chk,chkc) function c8809344.target(e,tp,eg,ep,ev,re,r,rp,chk,chkc)
local c=e:GetHandler()
if chkc then return chkc:IsLocation(LOCATION_GRAVE) and chkc:IsControler(tp) and chkc:IsType(TYPE_MONSTER) end if chkc then return chkc:IsLocation(LOCATION_GRAVE) and chkc:IsControler(tp) and chkc:IsType(TYPE_MONSTER) end
if chk==0 then return Duel.IsExistingTarget(Card.IsType,tp,LOCATION_GRAVE,0,1,nil,TYPE_MONSTER) end if chk==0 then return Duel.IsExistingTarget(Card.IsType,tp,LOCATION_GRAVE,0,1,nil,TYPE_MONSTER) end
Duel.Hint(HINT_SELECTMSG,tp,HINTMSG_TARGET) Duel.Hint(HINT_SELECTMSG,tp,HINTMSG_TARGET)
......
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