Commit 28b59c3b authored by songtongtong's avatar songtongtong

update lua

parent 15d4a4bb
......@@ -59,7 +59,7 @@ function cm.activate(e,tp,eg,ep,ev,re,r,rp)
e2:SetProperty(EFFECT_FLAG_PLAYER_TARGET)
e2:SetCode(EFFECT_CHANGE_DAMAGE)
e2:SetTargetRange(0,1)
e2:SetValue(HALF_DAMAGE)
e2:SetValue(cm.damval)
e2:SetReset(RESET_PHASE)
Duel.RegisterEffect(e2,tp)
local e3=Effect.CreateEffect(e:GetHandler())
......@@ -71,6 +71,9 @@ function cm.activate(e,tp,eg,ep,ev,re,r,rp)
e3:SetOperation(cm.lpop)
Duel.RegisterEffect(e3,tp)
end
function cm.damval(e,re,val,r,rp,rc)
return val/2
end
function cm.lpcon(e,tp,eg,ep,ev,re,r,rp)
return Duel.GetLP(tp)>5
end
......
......@@ -74,7 +74,7 @@ function c12008010.regop(e,tp,eg,ep,ev,re,r,rp)
end
function c12008010.spfilter(c,e,tp)
if not c:GetReasonEffect() then return false end
return c:IsFaceup() and c:IsReason(REASON_EFFECT) and c:GetReasonEffect():GetHandler():IsSetCard(0x1fb3) and c:IsCanBeSpecialSummoned(e,0,tp,false,false)
return c:IsFaceup() and c:GetReasonEffect() and c:GetReasonEffect():GetHandler():IsSetCard(0x1fb3) and c:IsCanBeSpecialSummoned(e,0,tp,false,false)
end
function c12008010.sptg(e,tp,eg,ep,ev,re,r,rp,chk)
if chk==0 then return e:GetHandler():IsCanBeSpecialSummoned(e,0,tp,false,false) and Duel.GetLocationCount(tp,LOCATION_MZONE)>1 and Duel.IsExistingMatchingCard(c12008010.spfilter,tp,LOCATION_REMOVED,LOCATION_REMOVED,1,nil,e,tp) and e:GetLabelObject() and Duel.IsPlayerCanSpecialSummonCount(tp,2) end
......
......@@ -50,7 +50,7 @@ function c12008023.spop(e,tp,eg,ep,ev,re,r,rp,mg)
Duel.SendtoDeck(td,nil,2,REASON_EFFECT)
local tt=Duel.GetOperatedGroup():GetCount()
Duel.Hint(HINT_SELECTMSG,tp,HINTMSG_ATOHAND)
local g=Duel.SelectMatchingCard(tp,c12008023.thfilter2,tp,LOCATION_DECK,0,1,tt,nil)
local g=Duel.SelectMatchingCard(tp,c12008023.thfilter2,tp,LOCATION_DECK,0,1,tt+1,nil)
if g:GetCount()>0 then
Duel.SendtoHand(g,nil,REASON_EFFECT)
Duel.ConfirmCards(1-tp,g)
......
--翁德兰 天穹之冕
function c75646701.initial_effect(c)
aux.AddCodeList(c,75646700)
--Activate
local e1=Effect.CreateEffect(c)
e1:SetType(EFFECT_TYPE_ACTIVATE)
......
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