Number
2 Level 1 monsters
Once per turn (Quick Effect): You can detach 1 material from this card; your opponent randomly chooses 1 card in your Extra Deck, and if it is a "Number" monster that has a number between "1" and "99" in its name, Special Summon it by using this face-up card you control as material, but banish that monster during the End Phase, also you cannot Special Summon for the rest of this turn. (This is treated as an Xyz Summon. Transfer its materials to the Summoned monster.)
local SETCARD_ID_0 = 0x48 --Number

local SETCARD_ID_0 = 0x48 --Number
local s, id, o = GetID()
function s.initial_effect(c)
	--xyz summon
	aux.AddXyzProcedure(c, nil, 1, 2)
	c:EnableReviveLimit()
	--spsummon
	local e1 = Effect.CreateEffect(c)
	e1:SetDescription(aux.Stringid(id, 0))
	e1:SetCategory(CATEGORY_SPECIAL_SUMMON)
	e1:SetType(EFFECT_TYPE_QUICK_O)
	e1:SetCode(EVENT_FREE_CHAIN)
	e1:SetRange(LOCATION_MZONE)
	e1:SetCountLimit(1)
	e1:SetCost(s.cost)
	e1:SetTarget(s.sptg)
	e1:SetOperation(s.spop)
	c:RegisterEffect(e1)
end
aux.xyz_number[id] = 78
function s.cost(e, tp, eg, ep, ev, re, r, rp, chk)
	if chk == 0 then
		return e:GetHandler():CheckRemoveOverlayCard(tp, 1, REASON_COST)
	end
	e:GetHandler():RemoveOverlayCard(tp, 1, 1, REASON_COST)
end
function s.filter(c, e, tp, mc)
	local no = aux.GetXyzNumber(c)
	return no
		and no >= 1
		and no <= 99
		and c:IsSetCard(SETCARD_ID_0)
		and mc:IsCanBeXyzMaterial(c)
		and c:IsCanBeSpecialSummoned(e, SUMMON_TYPE_XYZ, tp, false, false)
		and Duel.GetLocationCountFromEx(tp, tp, mc, c) > 0
end
function s.sptg(e, tp, eg, ep, ev, re, r, rp, chk)
	if chk == 0 then
		return aux.MustMaterialCheck(e:GetHandler(), tp, EFFECT_MUST_BE_XMATERIAL) and Duel.IsExistingMatchingCard(s.filter, tp, LOCATION_EXTRA, 0, 1, nil, e, tp, e:GetHandler())
	end
	Duel.SetOperationInfo(0, CATEGORY_SPECIAL_SUMMON, nil, 1, tp, LOCATION_EXTRA)
end
function s.spop(e, tp, eg, ep, ev, re, r, rp)
	local c = e:GetHandler()
	local g = Duel.GetFieldGroup(tp, LOCATION_EXTRA, 0)
	if g:GetCount() > 0 and aux.MustMaterialCheck(c, tp, EFFECT_MUST_BE_XMATERIAL) and c:IsFaceup() and c:IsRelateToEffect(e) and c:IsControler(tp) and not c:IsImmuneToEffect(e) then
		Duel.ShuffleExtra(tp)
		local tg = g:RandomSelect(1 - tp, 1)
		Duel.ConfirmCards(1 - tp, tg)
		if tg:IsExists(s.filter, 1, nil, e, tp, c) then
			local tc = tg:GetFirst()
			local mg = c:GetOverlayGroup()
			if mg:GetCount() ~= 0 then
				Duel.Overlay(tc, mg)
			end
			tc:SetMaterial(Group.FromCards(c))
			Duel.Overlay(tc, Group.FromCards(c))
			Duel.SpecialSummon(tc, SUMMON_TYPE_XYZ, tp, tp, false, false, POS_FACEUP)
			local fid = c:GetFieldID()
			tc:RegisterFlagEffect(id, RESET_EVENT + RESETS_STANDARD, 0, 1, fid)
			tc:CompleteProcedure()
			local e1 = Effect.CreateEffect(c)
			e1:SetType(EFFECT_TYPE_FIELD + EFFECT_TYPE_CONTINUOUS)
			e1:SetProperty(EFFECT_FLAG_IGNORE_IMMUNE)
			e1:SetCode(EVENT_PHASE + PHASE_END)
			e1:SetCountLimit(1)
			e1:SetLabel(fid)
			e1:SetLabelObject(tc)
			e1:SetCondition(s.rmcon)
			e1:SetOperation(s.rmop)
			Duel.RegisterEffect(e1, tp)
		end
	end
	local e2 = Effect.CreateEffect(c)
	e2:SetType(EFFECT_TYPE_FIELD)
	e2:SetProperty(EFFECT_FLAG_PLAYER_TARGET)
	e2:SetCode(EFFECT_CANNOT_SPECIAL_SUMMON)
	e2:SetReset(RESET_PHASE + PHASE_END)
	e2:SetTargetRange(1, 0)
	Duel.RegisterEffect(e2, tp)
end
function s.rmcon(e, tp, eg, ep, ev, re, r, rp)
	if e:GetLabelObject():GetFlagEffectLabel(id) ~= e:GetLabel() then
		e:Reset()
		return false
	else
		return true
	end
end
function s.rmop(e, tp, eg, ep, ev, re, r, rp)
	local tc = e:GetLabelObject()
	Duel.Remove(tc, POS_FACEUP, REASON_EFFECT)
end


Number
2 Level 1 monsters
Once per turn (Quick Effect): You can detach 1 material from this card; your opponent randomly chooses 1 card in your Extra Deck, and if it is a "Number" monster that has a number between "1" and "99" in its name, Special Summon it by using this face-up card you control as material, but banish that monster during the End Phase, also you cannot Special Summon for the rest of this turn. (This is treated as an Xyz Summon. Transfer its materials to the Summoned monster.)
-- Number
local SETCARD_ID_0 = 0x48 --Number
local s, id, o = GetID()
function s.initial_effect(c)
	--xyz summon
	aux.AddXyzProcedure(c, nil, 1, 2)
	c:EnableReviveLimit()
	--spsummon
	local e1 = Effect.CreateEffect(c)
	e1:SetDescription(aux.Stringid(id, 0))
	e1:SetCategory(CATEGORY_SPECIAL_SUMMON)
	e1:SetType(EFFECT_TYPE_QUICK_O)
	e1:SetCode(EVENT_FREE_CHAIN)
	e1:SetRange(LOCATION_MZONE)
	e1:SetCountLimit(1)
	e1:SetCost(s.cost)
	e1:SetTarget(s.sptg)
	e1:SetOperation(s.spop)
	c:RegisterEffect(e1)
end
aux.xyz_number[id] = 78
function s.cost(e, tp, eg, ep, ev, re, r, rp, chk)
	if chk == 0 then
		return e:GetHandler():CheckRemoveOverlayCard(tp, 1, REASON_COST)
	end
	e:GetHandler():RemoveOverlayCard(tp, 1, 1, REASON_COST)
end
function s.filter(c, e, tp, mc)
	local no = aux.GetXyzNumber(c)
	return no
		and no >= 1
		and no <= 99
		and c:IsSetCard(SETCARD_ID_0)
		and mc:IsCanBeXyzMaterial(c)
		and c:IsCanBeSpecialSummoned(e, SUMMON_TYPE_XYZ, tp, false, false)
		and Duel.GetLocationCountFromEx(tp, tp, mc, c) > 0
end
function s.sptg(e, tp, eg, ep, ev, re, r, rp, chk)
	if chk == 0 then
		return aux.MustMaterialCheck(e:GetHandler(), tp, EFFECT_MUST_BE_XMATERIAL) and Duel.IsExistingMatchingCard(s.filter, tp, LOCATION_EXTRA, 0, 1, nil, e, tp, e:GetHandler())
	end
	Duel.SetOperationInfo(0, CATEGORY_SPECIAL_SUMMON, nil, 1, tp, LOCATION_EXTRA)
end
function s.spop(e, tp, eg, ep, ev, re, r, rp)
	local c = e:GetHandler()
	local g = Duel.GetFieldGroup(tp, LOCATION_EXTRA, 0)
	if g:GetCount() > 0 and aux.MustMaterialCheck(c, tp, EFFECT_MUST_BE_XMATERIAL) and c:IsFaceup() and c:IsRelateToEffect(e) and c:IsControler(tp) and not c:IsImmuneToEffect(e) then
		Duel.ShuffleExtra(tp)
		local tg = g:RandomSelect(1 - tp, 1)
		Duel.ConfirmCards(1 - tp, tg)
		if tg:IsExists(s.filter, 1, nil, e, tp, c) then
			local tc = tg:GetFirst()
			local mg = c:GetOverlayGroup()
			if mg:GetCount() ~= 0 then
				Duel.Overlay(tc, mg)
			end
			tc:SetMaterial(Group.FromCards(c))
			Duel.Overlay(tc, Group.FromCards(c))
			Duel.SpecialSummon(tc, SUMMON_TYPE_XYZ, tp, tp, false, false, POS_FACEUP)
			local fid = c:GetFieldID()
			tc:RegisterFlagEffect(id, RESET_EVENT + RESETS_STANDARD, 0, 1, fid)
			tc:CompleteProcedure()
			local e1 = Effect.CreateEffect(c)
			e1:SetType(EFFECT_TYPE_FIELD + EFFECT_TYPE_CONTINUOUS)
			e1:SetProperty(EFFECT_FLAG_IGNORE_IMMUNE)
			e1:SetCode(EVENT_PHASE + PHASE_END)
			e1:SetCountLimit(1)
			e1:SetLabel(fid)
			e1:SetLabelObject(tc)
			e1:SetCondition(s.rmcon)
			e1:SetOperation(s.rmop)
			Duel.RegisterEffect(e1, tp)
		end
	end
	local e2 = Effect.CreateEffect(c)
	e2:SetType(EFFECT_TYPE_FIELD)
	e2:SetProperty(EFFECT_FLAG_PLAYER_TARGET)
	e2:SetCode(EFFECT_CANNOT_SPECIAL_SUMMON)
	e2:SetReset(RESET_PHASE + PHASE_END)
	e2:SetTargetRange(1, 0)
	Duel.RegisterEffect(e2, tp)
end
function s.rmcon(e, tp, eg, ep, ev, re, r, rp)
	if e:GetLabelObject():GetFlagEffectLabel(id) ~= e:GetLabel() then
		e:Reset()
		return false
	else
		return true
	end
end
function s.rmop(e, tp, eg, ep, ev, re, r, rp)
	local tc = e:GetLabelObject()
	Duel.Remove(tc, POS_FACEUP, REASON_EFFECT)
end

