Skip to content

Voidalfr Star Mayfly ​

  • Card ID: 120300034
  • Format: Rush Duel
  • Script: Rush/Scripts/c120300034.lua

Stats ​

FieldValue
Type0x61
ATK3000
DEF2400
Level/Rank/Link0x9
Race0x40000000
Attribute0x2
Category0x310410

Card Text ​

text
"Voidalfr Heavenstar" + 1 WATER Attribute monster	
[REQUIREMENT]	
During your Main Phase that you Fusion Summoned this card, shuffle 3 Galaxy Type monsters from your Graveyard into the Deck, including a WATER Attribute monster.	
[EFFECT]	
Return up to 3 face-up Level 8 or lower monsters and/or face-down monsters from your opponent's field to the owner's hand. This turn, you can only attack with 1 monster.

Detected API Calls ​

Script ​

lua
local cm,m=GetID()
local list={120300006}
cm.name="虚空精灵·星宇蜉蝣"
function cm.initial_effect(c)
	RD.AddCodeList(c,list)
	--Fusion Material
	RD.AddFusionProcedure(c,list[1],cm.matfilter)
	--To Hand
	local e1=Effect.CreateEffect(c)
	e1:SetDescription(aux.Stringid(m,0))
	e1:SetCategory(CATEGORY_TOHAND)
	e1:SetType(EFFECT_TYPE_IGNITION)
	e1:SetRange(LOCATION_MZONE)
	e1:SetCondition(cm.condition)
	e1:SetCost(cm.cost)
	e1:SetTarget(cm.target)
	e1:SetOperation(cm.operation)
	c:RegisterEffect(e1)
end
--Fusion Material
cm.unspecified_funsion=true
function cm.matfilter(c,fc,sub)
	return c:IsFusionAttribute(ATTRIBUTE_WATER)
end
--To Hand
function cm.costfilter(c)
	return c:IsRace(RACE_GALAXY) and c:IsAbleToDeckOrExtraAsCost()
end
function cm.filter(c)
	return ((c:IsFaceup() and c:IsLevelBelow(8)) or c:IsFacedown())
		and c:IsAbleToHand()
end
function cm.check(g)
	return g:IsExists(Card.IsAttribute,1,nil,ATTRIBUTE_WATER)
end
function cm.condition(e,tp,eg,ep,ev,re,r,rp)
	return RD.IsSpecialSummonMainPhase(e:GetHandler(),SUMMON_TYPE_FUSION)
end
cm.cost=RD.CostSendGraveSubToDeck(cm.costfilter,cm.check,3,3)
function cm.target(e,tp,eg,ep,ev,re,r,rp,chk)
	if chk==0 then return Duel.IsExistingMatchingCard(cm.filter,tp,0,LOCATION_MZONE,1,nil) end
	local g=Duel.GetMatchingGroup(cm.filter,tp,0,LOCATION_MZONE,nil)
	Duel.SetOperationInfo(0,CATEGORY_TOHAND,g,1,0,0)
end
function cm.operation(e,tp,eg,ep,ev,re,r,rp)
	RD.SelectAndDoAction(HINTMSG_RTOHAND,cm.filter,tp,0,LOCATION_MZONE,1,3,nil,function(g)
		RD.SendToHandAndExists(g,e,tp,REASON_EFFECT)
	end)
	if Duel.GetFlagEffect(tp,m)~=0 then return end
	RD.CreateHintEffect(e,aux.Stringid(m,1),tp,1,0,RESET_PHASE+PHASE_END)
	RD.CreateOnlySoleAttackEffect(e,20300034,tp,LOCATION_MZONE,0,RESET_PHASE+PHASE_END)
	Duel.RegisterFlagEffect(tp,m,RESET_PHASE+PHASE_END,0,1)
end