name: Schuberta
card_text: 2 "Melodious" monsters
  Once while face-up on the field (Quick Effect): You can target up to 3 cards in any GY(s); banish them, and if you do, this card gains 200 ATK for each.
external_ids: local SETCARD_ID_0 = 0x9b --Melodious
  
lua: local SETCARD_ID_0 = 0x9b --Melodious
  local s, id, o = GetID()
  function s.initial_effect(c)
  	--fusion material
  	c:EnableReviveLimit()
  	aux.AddFusionProcFunRep(c, aux.FilterBoolFunction(Card.IsFusionSetCard, SETCARD_ID_0), 2, true)
  	--remove
  	local e1 = Effect.CreateEffect(c)
  	e1:SetCategory(CATEGORY_REMOVE + CATEGORY_ATKCHANGE)
  	e1:SetType(EFFECT_TYPE_QUICK_O)
  	e1:SetCode(EVENT_FREE_CHAIN)
  	e1:SetProperty(EFFECT_FLAG_CARD_TARGET + EFFECT_FLAG_DAMAGE_STEP + EFFECT_FLAG_NO_TURN_RESET)
  	e1:SetRange(LOCATION_MZONE)
  	e1:SetHintTiming(TIMING_DAMAGE_STEP)
  	e1:SetCountLimit(1)
  	e1:SetCondition(aux.dscon)
  	e1:SetTarget(s.target)
  	e1:SetOperation(s.operation)
  	c:RegisterEffect(e1)
  end
  function s.target(e, tp, eg, ep, ev, re, r, rp, chk, chkc)
  	if chkc then
  		return chkc:IsLocation(LOCATION_GRAVE) and chkc:IsAbleToRemove()
  	end
  	if chk == 0 then
  		return Duel.IsExistingTarget(Card.IsAbleToRemove, tp, LOCATION_GRAVE, LOCATION_GRAVE, 1, nil)
  	end
  	Duel.Hint(HINT_SELECTMSG, tp, HINTMSG_REMOVE)
  	local g = Duel.SelectTarget(tp, Card.IsAbleToRemove, tp, LOCATION_GRAVE, LOCATION_GRAVE, 1, 3, nil)
  	Duel.SetOperationInfo(0, CATEGORY_REMOVE, g, g:GetCount(), PLAYER_ALL, LOCATION_GRAVE)
  end
  function s.operation(e, tp, eg, ep, ev, re, r, rp)
  	local g = Duel.GetChainInfo(0, CHAININFO_TARGET_CARDS):Filter(Card.IsRelateToEffect, nil, e)
  	local ct = Duel.Remove(g, POS_FACEUP, REASON_EFFECT)
  	local c = e:GetHandler()
  	if ct > 0 and c:IsFaceup() and c:IsRelateToEffect(e) then
  		local e1 = Effect.CreateEffect(c)
  		e1:SetType(EFFECT_TYPE_SINGLE)
  		e1:SetCode(EFFECT_UPDATE_ATTACK)
  		e1:SetReset(RESET_EVENT + RESETS_STANDARD + RESET_DISABLE)
  		e1:SetValue(ct * 200)
  		c:RegisterEffect(e1)
  	end
  end
  
  
source_text: Schuberta
  2 "Melodious" monsters
  Once while face-up on the field (Quick Effect): You can target up to 3 cards in any GY(s); banish them, and if you do, this card gains 200 ATK for each.
target_text: -- Schuberta
  local SETCARD_ID_0 = 0x9b --Melodious
  local s, id, o = GetID()
  function s.initial_effect(c)
  	--fusion material
  	c:EnableReviveLimit()
  	aux.AddFusionProcFunRep(c, aux.FilterBoolFunction(Card.IsFusionSetCard, SETCARD_ID_0), 2, true)
  	--remove
  	local e1 = Effect.CreateEffect(c)
  	e1:SetCategory(CATEGORY_REMOVE + CATEGORY_ATKCHANGE)
  	e1:SetType(EFFECT_TYPE_QUICK_O)
  	e1:SetCode(EVENT_FREE_CHAIN)
  	e1:SetProperty(EFFECT_FLAG_CARD_TARGET + EFFECT_FLAG_DAMAGE_STEP + EFFECT_FLAG_NO_TURN_RESET)
  	e1:SetRange(LOCATION_MZONE)
  	e1:SetHintTiming(TIMING_DAMAGE_STEP)
  	e1:SetCountLimit(1)
  	e1:SetCondition(aux.dscon)
  	e1:SetTarget(s.target)
  	e1:SetOperation(s.operation)
  	c:RegisterEffect(e1)
  end
  function s.target(e, tp, eg, ep, ev, re, r, rp, chk, chkc)
  	if chkc then
  		return chkc:IsLocation(LOCATION_GRAVE) and chkc:IsAbleToRemove()
  	end
  	if chk == 0 then
  		return Duel.IsExistingTarget(Card.IsAbleToRemove, tp, LOCATION_GRAVE, LOCATION_GRAVE, 1, nil)
  	end
  	Duel.Hint(HINT_SELECTMSG, tp, HINTMSG_REMOVE)
  	local g = Duel.SelectTarget(tp, Card.IsAbleToRemove, tp, LOCATION_GRAVE, LOCATION_GRAVE, 1, 3, nil)
  	Duel.SetOperationInfo(0, CATEGORY_REMOVE, g, g:GetCount(), PLAYER_ALL, LOCATION_GRAVE)
  end
  function s.operation(e, tp, eg, ep, ev, re, r, rp)
  	local g = Duel.GetChainInfo(0, CHAININFO_TARGET_CARDS):Filter(Card.IsRelateToEffect, nil, e)
  	local ct = Duel.Remove(g, POS_FACEUP, REASON_EFFECT)
  	local c = e:GetHandler()
  	if ct > 0 and c:IsFaceup() and c:IsRelateToEffect(e) then
  		local e1 = Effect.CreateEffect(c)
  		e1:SetType(EFFECT_TYPE_SINGLE)
  		e1:SetCode(EFFECT_UPDATE_ATTACK)
  		e1:SetReset(RESET_EVENT + RESETS_STANDARD + RESET_DISABLE)
  		e1:SetValue(ct * 200)
  		c:RegisterEffect(e1)
  	end
  end
  
  