Commit 57a24aa2 authored by salix5's avatar salix5

Merge pull request #1282 from DailyShana/patch-5

fix
parents 50f98b51 bb26cce4
......@@ -43,7 +43,10 @@ function c30100551.drop(e,tp,eg,ep,ev,re,r,rp)
Duel.DiscardDeck(p,d,REASON_EFFECT)
local g=Duel.GetOperatedGroup()
local ct=g:FilterCount(c30100551.cfilter,nil)
Duel.Draw(tp,ct,REASON_EFFECT)
if ct>0 then
Duel.BreakEffect()
Duel.Draw(tp,ct,REASON_EFFECT)
end
end
function c30100551.descon(e,tp,eg,ep,ev,re,r,rp)
return rp~=tp and e:GetHandler():IsReason(REASON_BATTLE+REASON_EFFECT)
......@@ -55,6 +58,7 @@ function c30100551.desop(e,tp,eg,ep,ev,re,r,rp)
local ct=g:FilterCount(c30100551.cfilter,nil)
local dg=Duel.GetMatchingGroup(Card.IsDestructable,tp,LOCATION_ONFIELD,LOCATION_ONFIELD,nil)
if ct~=0 and dg:GetCount()>0 and Duel.SelectYesNo(tp,aux.Stringid(30100551,0)) then
Duel.BreakEffect()
Duel.Hint(HINT_SELECTMSG,tp,HINTMSG_DESTROY)
local sdg=dg:Select(tp,1,ct,nil)
Duel.Destroy(sdg,REASON_EFFECT)
......
......@@ -48,9 +48,11 @@ function c30500113.activate(e,tp,eg,ep,ev,re,r,rp)
end
end
function c30500113.cfilter2(c,tp)
return c:IsSetCard(0xba) and c:IsReason(REASON_EFFECT) and c:GetPreviousControler()==tp
return c:IsSetCard(0xba) and c:IsReason(REASON_EFFECT)
and c:GetPreviousControler()==tp and c:IsPreviousPosition(POS_FACEUP)
end
function c30500113.thcon(e,tp,eg,ep,ev,re,r,rp)
if eg:IsContains(e:GetHandler()) then return false end
return eg:IsExists(c30500113.cfilter2,1,nil,tp)
end
function c30500113.thcost(e,tp,eg,ep,ev,re,r,rp,chk)
......
......@@ -11,7 +11,7 @@ function c30922149.initial_effect(c)
c:RegisterEffect(e1)
end
function c30922149.target(e,tp,eg,ep,ev,re,r,rp,chk)
if chk==0 then return Duel.IsPlayerCanDraw(1-tp) end
if chk==0 then return Duel.IsPlayerCanDraw(1-tp,1) end
Duel.SetTargetPlayer(1-tp)
Duel.SetOperationInfo(0,CATEGORY_DRAW,nil,0,1-tp,1)
end
......
......@@ -49,7 +49,9 @@ function c3105404.cfilter(c)
return c:IsSetCard(0x1047) and c:IsAbleToGraveAsCost()
end
function c3105404.thcost(e,tp,eg,ep,ev,re,r,rp,chk)
if chk==0 then return Duel.IsExistingMatchingCard(c3105404.cfilter,tp,LOCATION_HAND,0,1,nil) end
if chk==0 then return e:GetHandler():GetFlagEffect(3105404)==0
and Duel.IsExistingMatchingCard(c3105404.cfilter,tp,LOCATION_HAND,0,1,nil) end
e:GetHandler():RegisterFlagEffect(3105404,RESET_CHAIN,0,1)
Duel.DiscardHand(tp,c3105404.cfilter,1,1,REASON_COST,nil)
end
function c3105404.thtg(e,tp,eg,ep,ev,re,r,rp,chk)
......
......@@ -18,27 +18,27 @@ function c54250060.initial_effect(c)
e3:SetCode(EFFECT_UPDATE_DEFENCE)
c:RegisterEffect(e3)
--spsummon
local e3=Effect.CreateEffect(c)
e3:SetDescription(aux.Stringid(54250060,0))
e3:SetCategory(CATEGORY_SPECIAL_SUMMON)
e3:SetType(EFFECT_TYPE_IGNITION)
e3:SetRange(LOCATION_FZONE)
e3:SetCountLimit(1)
e3:SetCost(c54250060.spcost)
e3:SetTarget(c54250060.sptg)
e3:SetOperation(c54250060.spop)
c:RegisterEffect(e3)
--to hand
local e4=Effect.CreateEffect(c)
e4:SetDescription(aux.Stringid(54250060,1))
e4:SetCategory(CATEGORY_TOHAND+CATEGORY_SEARCH)
e4:SetDescription(aux.Stringid(54250060,0))
e4:SetCategory(CATEGORY_SPECIAL_SUMMON)
e4:SetType(EFFECT_TYPE_IGNITION)
e4:SetRange(LOCATION_FZONE)
e4:SetCountLimit(1)
e4:SetCost(c54250060.thcost)
e4:SetTarget(c54250060.thtg)
e4:SetOperation(c54250060.thop)
e4:SetCost(c54250060.spcost)
e4:SetTarget(c54250060.sptg)
e4:SetOperation(c54250060.spop)
c:RegisterEffect(e4)
--to hand
local e5=Effect.CreateEffect(c)
e5:SetDescription(aux.Stringid(54250060,1))
e5:SetCategory(CATEGORY_TOHAND+CATEGORY_SEARCH)
e5:SetType(EFFECT_TYPE_IGNITION)
e5:SetRange(LOCATION_FZONE)
e5:SetCountLimit(1)
e5:SetCost(c54250060.thcost)
e5:SetTarget(c54250060.thtg)
e5:SetOperation(c54250060.thop)
c:RegisterEffect(e5)
end
function c54250060.atktg(e,c)
return c:IsRace(RACE_DRAGON+RACE_WARRIOR+RACE_SPELLCASTER)
......
......@@ -49,7 +49,7 @@ function c67616300.initial_effect(c)
e6:SetCategory(CATEGORY_RECOVER)
e6:SetType(EFFECT_TYPE_IGNITION)
e6:SetRange(LOCATION_FZONE)
e6:SetProperty(EFFECT_FLAG_BOTH_SIDE)
e6:SetProperty(EFFECT_FLAG_BOTH_SIDE+EFFECT_FLAG_PLAYER_TARGET)
e6:SetCountLimit(1,EFFECT_COUNT_CODE_SINGLE)
e6:SetCost(c67616300.effcost)
e6:SetTarget(c67616300.rectg)
......
......@@ -12,7 +12,8 @@ function c93983867.initial_effect(c)
c:RegisterEffect(e1)
end
function c93983867.cfilter(c,tp)
return c:IsSetCard(0xc6) and c:IsReason(REASON_DESTROY) and c:IsPreviousLocation(LOCATION_MZONE) and c:GetPreviousControler()==tp
return c:IsSetCard(0xc6) and c:IsReason(REASON_DESTROY) and c:IsPreviousPosition(POS_FACEUP)
and c:IsPreviousLocation(LOCATION_MZONE) and c:GetPreviousControler()==tp
end
function c93983867.condition(e,tp,eg,ep,ev,re,r,rp)
return eg:IsExists(c93983867.cfilter,1,nil,tp)
......
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