Commit fd159a49 authored by mercury233's avatar mercury233

fix

parent 138ce587
......@@ -145,7 +145,8 @@ function c101009011.thop(e,tp,eg,ep,ev,re,r,rp)
end
end
function c101009011.cfilter(c,tp)
return c:IsPreviousLocation(LOCATION_ONFIELD) and c:IsReason(REASON_EFFECT) and c:GetReasonPlayer()==tp
return c:IsPreviousLocation(LOCATION_ONFIELD) and c:IsLocation(LOCATION_HAND+LOCATION_DECK)
and c:IsReason(REASON_EFFECT) and c:GetReasonPlayer()==tp
end
function c101009011.atkcon(e,tp,eg,ep,ev,re,r,rp)
return eg:IsExists(c101009011.cfilter,1,e:GetHandler(),tp)
......
......@@ -39,7 +39,7 @@ function c101009022.initial_effect(c)
c:RegisterEffect(e3)
end
function c101009022.cfilter(c,tp)
return c:GetSummonPlayer()==tp and c:IsAttribute(ATTRIBUTE_DARK+ATTRIBUTE_WIND)
return c:GetSummonPlayer()==tp and c:IsSummonType(SUMMON_TYPE_ADVANCE) and c:IsAttribute(ATTRIBUTE_DARK+ATTRIBUTE_WIND)
end
function c101009022.spcon(e,tp,eg,ep,ev,re,r,rp)
return eg:IsExists(c101009022.cfilter,1,nil,tp)
......
......@@ -32,8 +32,9 @@ function c101009037.lvtg(e,tp,eg,ep,ev,re,r,rp,chk,chkc)
if chk==0 then return Duel.IsExistingTarget(c101009037.lvfilter1,tp,LOCATION_MZONE,0,1,nil,tp) end
local g=Duel.GetMatchingGroup(c101009037.lvfilter1,tp,LOCATION_MZONE,0,nil,tp)
local mg,lv=g:GetMinGroup(Card.GetLevel)
local alv=1
if lv>2 then alv=Duel.AnnounceLevel(tp,1,lv-1) end
local alv=0
if lv>2 then alv=Duel.AnnounceLevel(tp,1,math.min(lv-1,6))
else alv=Duel.AnnounceLevel(tp,1,1) end
Duel.Hint(HINT_SELECTMSG,tp,aux.Stringid(101009037,1))
local g1=Duel.SelectTarget(tp,c101009037.lvfilter3,tp,LOCATION_MZONE,0,1,1,nil,tp,alv)
Duel.Hint(HINT_SELECTMSG,tp,aux.Stringid(101009037,2))
......
......@@ -26,7 +26,7 @@ function c101009048.initial_effect(c)
c:RegisterEffect(e2)
end
function c101009048.lcheck(g,lc)
return g:GetClassCount(Card.GetCode)==g:GetCount()
return g:GetClassCount(Card.GetLinkCode)==g:GetCount()
end
function c101009048.valop(e,tp,eg,ep,ev,re,r,rp)
local c=e:GetHandler()
......@@ -40,14 +40,12 @@ function c101009048.valop(e,tp,eg,ep,ev,re,r,rp)
end
function c101009048.condition(e,tp,eg,ep,ev,re,r,rp)
return ep==1-tp and re:IsActiveType(TYPE_MONSTER) and Duel.IsChainNegatable(ev)
and not e:GetHandler():IsStatus(STATUS_CHAINING+STATUS_BATTLE_DESTROYED)
and not e:GetHandler():IsStatus(STATUS_BATTLE_DESTROYED)
end
function c101009048.target(e,tp,eg,ep,ev,re,r,rp,chk)
local c=e:GetHandler()
if chk==0 then return c:IsAttackAbove(800) and c:GetFlagEffect(101009048)==0 end
if c:IsHasEffect(EFFECT_REVERSE_UPDATE) then
c:RegisterFlagEffect(101009048,RESET_EVENT+RESETS_STANDARD+RESET_PHASE+PHASE_END,0,1)
end
c:RegisterFlagEffect(101009048,RESET_CHAIN,0,1)
Duel.SetOperationInfo(0,CATEGORY_NEGATE,eg,1,0,0)
end
function c101009048.operation(e,tp,eg,ep,ev,re,r,rp)
......@@ -63,5 +61,7 @@ function c101009048.operation(e,tp,eg,ep,ev,re,r,rp)
e1:SetReset(RESET_EVENT+RESETS_STANDARD+RESET_DISABLE)
e1:SetValue(-800)
c:RegisterEffect(e1)
Duel.NegateActivation(ev)
if not c:IsHasEffect(EFFECT_REVERSE_UPDATE) then
Duel.NegateActivation(ev)
end
end
......@@ -37,6 +37,7 @@ function c101009064.filter(c,lp)
return c:IsFaceup() and c:IsAttackBelow(lp) and c:GetFlagEffect(101009064)==0
end
function c101009064.target(e,tp,eg,ep,ev,re,r,rp,chk,chkc)
local lp=Duel.GetLP(tp)
if chkc then return chkc:IsLocation(LOCATION_MZONE) and chkc:IsControler(tp) and c101009064.filter(chkc,lp) end
if chk==0 then return Duel.IsExistingTarget(c101009064.filter,tp,LOCATION_MZONE,0,1,nil,lp) end
Duel.Hint(HINT_SELECTMSG,tp,HINTMSG_FACEUP)
......
......@@ -79,7 +79,7 @@ function c101009073.thop(e,tp,eg,ep,ev,re,r,rp)
local g=Duel.GetMatchingGroup(Card.IsAbleToHand,tp,LOCATION_ONFIELD,LOCATION_ONFIELD,nil)
if g:GetCount()>0 and Duel.SendtoHand(g,nil,REASON_EFFECT)~=0 then
local ct=Duel.GetOperatedGroup():FilterCount(Card.IsLocation,nil,LOCATION_HAND)
local val=Duel.Damage(tp,ct,REASON_EFFECT)
local val=Duel.Damage(tp,ct*500,REASON_EFFECT)
if val>0 and Duel.GetLP(tp)>0 then
Duel.BreakEffect()
Duel.Damage(1-tp,val,REASON_EFFECT)
......
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