Commit 1ac1f1b0 authored by Huangnan's avatar Huangnan

thbmlfix

parent 2f701ce3
......@@ -112,25 +112,23 @@ function c1008002.thcost(e,tp,eg,ep,ev,re,r,rp,chk)
if chk==0 then return e:GetHandler():IsReleasable() end
Duel.Release(e:GetHandler(),REASON_COST)
end
function c1008002.penfilter(c,tp)
return c:IsSetCard(0x320e) and c:IsType(TYPE_PENDULUM) and not c:IsForbidden()
function c1008002.penfilter(c)
return c:IsSetCard(0x320e) and c:IsType(TYPE_PENDULUM) and not c:IsForbidden()
end
function c1008002.thtg(e,tp,eg,ep,ev,re,r,rp,chk)
local a1=(Duel.GetFieldCard(tp,LOCATION_SZONE,6))
local a2=(Duel.GetFieldCard(tp,LOCATION_SZONE,7))
if chk==0 then return Duel.IsExistingMatchingCard(c1008002.penfilter,tp,LOCATION_DECK,0,1,nil,tp)
and not (a1 and a2) end
function c1008002.thtg(e,tp,eg,ep,ev,re,r,rp,chk)
if chk==0 then return (Duel.CheckLocation(tp,LOCATION_PZONE,0) or Duel.CheckLocation(tp,LOCATION_PZONE,1))
and Duel.IsExistingMatchingCard(c1008002.penfilter,tp,LOCATION_DECK,0,1,nil) end
end
function c1008002.thop(e,tp,eg,ep,ev,re,r,rp)
Duel.Hint(HINT_MUSIC,0,aux.Stringid(1008002,4))
Duel.Hint(HINT_SELECTMSG,tp,aux.Stringid(1008002,2))
local tc=Duel.SelectMatchingCard(tp,c1008002.penfilter,tp,LOCATION_DECK,0,1,1,nil,tp):GetFirst()
if tc then
local fc1=Duel.GetFieldCard(tp,LOCATION_SZONE,6)
local fc2=Duel.GetFieldCard(tp,LOCATION_SZONE,7)
if fc1 and fc2 then return end
Duel.MoveToField(tc,tp,tp,LOCATION_SZONE,POS_FACEUP,true)
end
local c=e:GetHandler()
if not c:IsRelateToEffect(e) then return end
if not (Duel.CheckLocation(tp,LOCATION_PZONE,0) or Duel.CheckLocation(tp,LOCATION_PZONE,1)) then return end
Duel.Hint(HINT_SELECTMSG,tp,HINTMSG_TOFIELD)
local g=Duel.SelectMatchingCard(tp,c47598941.filter,tp,LOCATION_DECK,0,1,1,nil)
local tc=g:GetFirst()
if tc then
Duel.MoveToField(tc,tp,tp,LOCATION_PZONE,POS_FACEUP,true)
end
end
function c1008002.voidfilter(c)
return c:IsSetCard(0x320e) and c:IsFaceup()
......@@ -217,4 +215,4 @@ function c1008002.rmop(e,tp,eg,ep,ev,re,r,rp)
if tc:IsRelateToEffect(e) then
Duel.Remove(tc,POS_FACEUP,REASON_EFFECT)
end
end
\ No newline at end of file
end
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