Commit 2c08fc78 authored by argon.sun's avatar argon.sun

fix

parent 0478f3b6
...@@ -1400,6 +1400,7 @@ int32 field::flip_summon(uint16 step, uint8 sumplayer, card * target) { ...@@ -1400,6 +1400,7 @@ int32 field::flip_summon(uint16 step, uint8 sumplayer, card * target) {
case 1: { case 1: {
target->previous.position = target->current.position; target->previous.position = target->current.position;
target->current.position = POS_FACEUP_ATTACK; target->current.position = POS_FACEUP_ATTACK;
target->fieldid = infos.field_id++;
core.phase_action = TRUE; core.phase_action = TRUE;
core.flipsummon_state[sumplayer] = TRUE; core.flipsummon_state[sumplayer] = TRUE;
core.flipsummoned_cards_pt[sumplayer].insert(target); core.flipsummoned_cards_pt[sumplayer].insert(target);
......
...@@ -30,7 +30,8 @@ function c21702241.initial_effect(c) ...@@ -30,7 +30,8 @@ function c21702241.initial_effect(c)
end end
function c21702241.target(e,tp,eg,ep,ev,re,r,rp,chk,chkc) function c21702241.target(e,tp,eg,ep,ev,re,r,rp,chk,chkc)
if chkc then return chkc:IsLocation(LOCATION_MZONE) and chkc:IsFaceup() end if chkc then return chkc:IsLocation(LOCATION_MZONE) and chkc:IsFaceup() end
if chk==0 then return Duel.IsExistingTarget(Card.IsFaceup,tp,LOCATION_MZONE,LOCATION_MZONE,1,nil) end if chk==0 then return not e:GetHandler():IsStatus(STATUS_CHAIINING)
and Duel.IsExistingTarget(Card.IsFaceup,tp,LOCATION_MZONE,LOCATION_MZONE,1,nil) end
Duel.Hint(HINT_SELECTMSG,tp,HINTMSG_EQUIP) Duel.Hint(HINT_SELECTMSG,tp,HINTMSG_EQUIP)
Duel.SelectTarget(tp,Card.IsFaceup,tp,LOCATION_MZONE,LOCATION_MZONE,1,1,nil) Duel.SelectTarget(tp,Card.IsFaceup,tp,LOCATION_MZONE,LOCATION_MZONE,1,1,nil)
Duel.SetOperationInfo(0,CATEGORY_EQUIP,e:GetHandler(),1,0,0) Duel.SetOperationInfo(0,CATEGORY_EQUIP,e:GetHandler(),1,0,0)
......
...@@ -10,7 +10,7 @@ function c34103656.initial_effect(c) ...@@ -10,7 +10,7 @@ function c34103656.initial_effect(c)
e2:SetType(EFFECT_TYPE_FIELD) e2:SetType(EFFECT_TYPE_FIELD)
e2:SetCode(EFFECT_UPDATE_ATTACK) e2:SetCode(EFFECT_UPDATE_ATTACK)
e2:SetRange(LOCATION_SZONE) e2:SetRange(LOCATION_SZONE)
e2:SetTarget(c34103656.lvtg) e2:SetTarget(c34103656.adtg)
e2:SetTargetRange(LOCATION_MZONE,LOCATION_MZONE) e2:SetTargetRange(LOCATION_MZONE,LOCATION_MZONE)
e2:SetValue(200) e2:SetValue(200)
c:RegisterEffect(e2) c:RegisterEffect(e2)
...@@ -26,26 +26,30 @@ function c34103656.initial_effect(c) ...@@ -26,26 +26,30 @@ function c34103656.initial_effect(c)
e3:SetOperation(c34103656.lvop) e3:SetOperation(c34103656.lvop)
c:RegisterEffect(e3) c:RegisterEffect(e3)
end end
function c34103656.lvtg(e,c) function c34103656.adtg(e,c)
return c:IsAttribute(ATTRIBUTE_WATER) return c:IsAttribute(ATTRIBUTE_WATER)
end end
function c34103656.lvtg(e,c)
return c:GetFieldID()<=e:GetLabel() and c:IsAttribute(ATTRIBUTE_WATER)
end
function c34103656.cfilter(c)
return c:IsFaceup() and c:IsAttribute(ATTRIBUTE_WATER)
end
function c34103656.lvop(e,tp,eg,ep,ev,re,r,rp) function c34103656.lvop(e,tp,eg,ep,ev,re,r,rp)
local c=e:GetHandler() local c=e:GetHandler()
if c:IsRelateToEffect(e) then if c:IsRelateToEffect(e) then
local lv=Duel.GetMatchingGroupCount(c34103656.cfilter,e:GetHandlerPlayer(),LOCATION_MZONE,0,nil)
local g=Duel.GetFieldGroup(tp,LOCATION_MZONE,0)
local g,fid=g:GetMaxGroup(Card.GetFieldID)
local e1=Effect.CreateEffect(c) local e1=Effect.CreateEffect(c)
e1:SetType(EFFECT_TYPE_FIELD) e1:SetType(EFFECT_TYPE_FIELD)
e1:SetCode(EFFECT_UPDATE_LEVEL) e1:SetCode(EFFECT_UPDATE_LEVEL)
e1:SetRange(LOCATION_SZONE) e1:SetRange(LOCATION_SZONE)
e1:SetTargetRange(LOCATION_MZONE,0) e1:SetTargetRange(LOCATION_MZONE,0)
e1:SetTarget(c34103656.lvtg) e1:SetTarget(c34103656.lvtg)
e1:SetValue(c34103656.lvval) e1:SetValue(lv)
e1:SetLabel(fid)
e1:SetReset(RESET_EVENT+0x1ff0000+RESET_PHASE+PHASE_END) e1:SetReset(RESET_EVENT+0x1ff0000+RESET_PHASE+PHASE_END)
c:RegisterEffect(e1) c:RegisterEffect(e1)
end end
end end
function c34103656.cfilter(c)
return c:IsFaceup() and c:IsAttribute(ATTRIBUTE_WATER)
end
function c34103656.lvval(e,c)
return Duel.GetMatchingGroupCount(c34103656.cfilter,e:GetHandlerPlayer(),LOCATION_MZONE,0,nil)
end
...@@ -40,10 +40,9 @@ function c34143852.atkop(e,tp,eg,ep,ev,re,r,rp) ...@@ -40,10 +40,9 @@ function c34143852.atkop(e,tp,eg,ep,ev,re,r,rp)
if c:IsRelateToEffect(e) and c:IsFaceup() then if c:IsRelateToEffect(e) and c:IsFaceup() then
local e1=Effect.CreateEffect(c) local e1=Effect.CreateEffect(c)
e1:SetType(EFFECT_TYPE_SINGLE) e1:SetType(EFFECT_TYPE_SINGLE)
e1:SetProperty(EFFECT_FLAG_CANNOT_DISABLE)
e1:SetCode(EFFECT_UPDATE_ATTACK) e1:SetCode(EFFECT_UPDATE_ATTACK)
e1:SetValue(1000) e1:SetValue(1000)
e1:SetReset(RESET_EVENT+0x1fe0000) e1:SetReset(RESET_EVENT+0x1ff0000)
c:RegisterEffect(e1) c:RegisterEffect(e1)
end end
end end
...@@ -28,7 +28,8 @@ function c37164373.filter(c) ...@@ -28,7 +28,8 @@ function c37164373.filter(c)
end end
function c37164373.target(e,tp,eg,ep,ev,re,r,rp,chk,chkc) function c37164373.target(e,tp,eg,ep,ev,re,r,rp,chk,chkc)
if chkc then return chkc:IsControler(tp) and chkc:IsLocation(LOCATION_GRAVE) and c37164373.filter(chkc) end if chkc then return chkc:IsControler(tp) and chkc:IsLocation(LOCATION_GRAVE) and c37164373.filter(chkc) end
if chk==0 then return Duel.IsExistingTarget(c37164373.filter,tp,LOCATION_GRAVE,0,1,nil) end if chk==0 then return Duel.IsExistingTarget(c37164373.filter,tp,LOCATION_GRAVE,0,1,nil)
and Duel.IsExistingMatchingCard(Card.IsAbleToDeck,tp,0,LOCATION_ONFIELD,1,nil) end
Duel.Hint(HINT_SELECTMSG,tp,HINTMSG_TODECK) Duel.Hint(HINT_SELECTMSG,tp,HINTMSG_TODECK)
local g=Duel.SelectTarget(tp,c37164373.filter,tp,LOCATION_GRAVE,0,1,2,nil) local g=Duel.SelectTarget(tp,c37164373.filter,tp,LOCATION_GRAVE,0,1,2,nil)
Duel.SetOperationInfo(0,CATEGORY_TODECK,g,g:GetCount(),0,0) Duel.SetOperationInfo(0,CATEGORY_TODECK,g,g:GetCount(),0,0)
......
...@@ -11,7 +11,7 @@ function c56514812.initial_effect(c) ...@@ -11,7 +11,7 @@ function c56514812.initial_effect(c)
c:RegisterEffect(e1) c:RegisterEffect(e1)
end end
function c56514812.target(e,tp,eg,ep,ev,re,r,rp,chk) function c56514812.target(e,tp,eg,ep,ev,re,r,rp,chk)
if chk==0 then return true end if chk==0 then return not e:GetHandler():IsStatus(STATUS_CHAIINING) end
Duel.SetOperationInfo(0,CATEGORY_HANDES,0,0,ep,1) Duel.SetOperationInfo(0,CATEGORY_HANDES,0,0,ep,1)
end end
function c56514812.operation(e,tp,eg,ep,ev,re,r,rp) function c56514812.operation(e,tp,eg,ep,ev,re,r,rp)
......
...@@ -33,6 +33,7 @@ function c60080151.activate(e,tp,eg,ep,ev,re,r,rp) ...@@ -33,6 +33,7 @@ function c60080151.activate(e,tp,eg,ep,ev,re,r,rp)
e1:SetDescription(aux.Stringid(60080151,0)) e1:SetDescription(aux.Stringid(60080151,0))
e1:SetCategory(CATEGORY_SPECIAL_SUMMON) e1:SetCategory(CATEGORY_SPECIAL_SUMMON)
e1:SetType(EFFECT_TYPE_FIELD+EFFECT_TYPE_TRIGGER_F) e1:SetType(EFFECT_TYPE_FIELD+EFFECT_TYPE_TRIGGER_F)
e1:SetCountLimit(1)
e1:SetCode(EVENT_PHASE+PHASE_END) e1:SetCode(EVENT_PHASE+PHASE_END)
e1:SetCondition(c60080151.spcon) e1:SetCondition(c60080151.spcon)
e1:SetTarget(c60080151.sptg) e1:SetTarget(c60080151.sptg)
......
...@@ -6,7 +6,6 @@ function c74530899.initial_effect(c) ...@@ -6,7 +6,6 @@ function c74530899.initial_effect(c)
e1:SetType(EFFECT_TYPE_SINGLE) e1:SetType(EFFECT_TYPE_SINGLE)
e1:SetRange(LOCATION_DECK) e1:SetRange(LOCATION_DECK)
e1:SetCode(EFFECT_SPSUMMON_CONDITION) e1:SetCode(EFFECT_SPSUMMON_CONDITION)
e1:SetValue(aux.FALSE)
c:RegisterEffect(e1) c:RegisterEffect(e1)
--summon --summon
local e2=Effect.CreateEffect(c) local e2=Effect.CreateEffect(c)
...@@ -37,7 +36,6 @@ function c74530899.initial_effect(c) ...@@ -37,7 +36,6 @@ function c74530899.initial_effect(c)
e6:SetCategory(CATEGORY_TOHAND+CATEGORY_DAMAGE) e6:SetCategory(CATEGORY_TOHAND+CATEGORY_DAMAGE)
e6:SetType(EFFECT_TYPE_FIELD+EFFECT_TYPE_TRIGGER_F) e6:SetType(EFFECT_TYPE_FIELD+EFFECT_TYPE_TRIGGER_F)
e6:SetCode(EVENT_PHASE+PHASE_BATTLE) e6:SetCode(EVENT_PHASE+PHASE_BATTLE)
e6:SetProperty(EFFECT_FLAG_REPEAT)
e6:SetCountLimit(1) e6:SetCountLimit(1)
e6:SetRange(LOCATION_MZONE) e6:SetRange(LOCATION_MZONE)
e6:SetCondition(c74530899.thcon) e6:SetCondition(c74530899.thcon)
......
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