RushDuel.Draw
Alias: RD.Draw. Requires the matching Rush Duel Lua bootstrap.
Signature
lua
RushDuel.Draw([int player], [int count]) -> intDescription
Draws with REASON_EFFECT using the supplied player/count, or the current chain's target player/parameter when arguments are omitted. Pair RD.TargetDraw(tp, count) in targeting with RD.Draw() in resolution.
Parameters
playerint(optional): Player; defaults to CHAININFO_TARGET_PLAYER.countint(optional): Count; defaults to CHAININFO_TARGET_PARAM.
Returns
int: Result returned by Duel.Draw.
Source
Rush/Utilities/RDTarget.lua:34
lua
function RushDuel.Draw(player, count)
local p, d = Duel.GetChainInfo(0, CHAININFO_TARGET_PLAYER, CHAININFO_TARGET_PARAM)
return Duel.Draw(player or p, count or d, REASON_EFFECT)
endGuided Examples
Learn how to use this function in context:
Used By
Generated from the local Rush/Scripts/ folder and rush_cards.cdb.
- Detected in 150 indexed script(s).
- Search this function in the Script Explorer with
RushDuel.Draw.
Script Examples
Elemental Circulation (120263030)
Source: Rush/Scripts/c120263030.lua
lua
end
function cm.activate(e,tp,eg,ep,ev,re,r,rp)
if RD.Draw()~=0 then
RD.SelectAndDoAction(HINTMSG_TOGRAVE,Card.IsAbleToGrave,tp,LOCATION_HAND,0,1,1,nil,function(g)
Duel.BreakEffect()Ember the Ultra Assistant (120283035)
Source: Rush/Scripts/c120283035.lua
lua
end
function cm.operation(e,tp,eg,ep,ev,re,r,rp)
if RD.Draw()~=0 and Duel.IsExistingMatchingCard(cm.exfilter,tp,LOCATION_GRAVE,0,1,nil) then
local sg,og=RD.SendDeckTopToGraveAndCanSelect(tp,2,aux.Stringid(m,1),HINTMSG_ATOHAND,aux.NecroValleyFilter(cm.thfilter),1,1)
if sg:GetCount()>0 thenNobody Phantom Thief (120244060)
Source: Rush/Scripts/c120244060.lua
lua
end
function cm.activate(e,tp,eg,ep,ev,re,r,rp)
if RD.Draw()~=0 then
RD.SelectAndDoAction(HINTMSG_TOGRAVE,cm.filter,tp,LOCATION_HAND,0,1,99,nil,function(g)
Duel.BreakEffect()