name: Snow
card_text: When this card is destroyed by battle or by a card effect and sent to the Graveyard: Place 1 Ice Counter on each face-up monster on the field.
external_ids: local COUNTER_ID_0 = 0x1015 --Ice
  
lua: local COUNTER_ID_0 = 0x1015 --Ice
  local s, id, o = GetID()
  function s.initial_effect(c)
  	--special summon
  	local e1 = Effect.CreateEffect(c)
  	e1:SetDescription(aux.Stringid(id, 0))
  	e1:SetType(EFFECT_TYPE_SINGLE + EFFECT_TYPE_TRIGGER_F)
  	e1:SetCode(EVENT_TO_GRAVE)
  	e1:SetCondition(s.condition)
  	e1:SetOperation(s.operation)
  	c:RegisterEffect(e1)
  end
  function s.condition(e, tp, eg, ep, ev, re, r, rp)
  	return e:GetHandler():IsReason(REASON_DESTROY)
  end
  function s.operation(e, tp, eg, ep, ev, re, r, rp)
  	local g = Duel.GetMatchingGroup(Card.IsCanAddCounter, tp, LOCATION_MZONE, LOCATION_MZONE, nil, 0x1015, 1)
  	local tc = g:GetFirst()
  	while tc do
  		tc:AddCounter(COUNTER_ID_0, 1, REASON_EFFECT)
  		tc = g:GetNext()
  	end
  end
  
  
source_text: Snow
  When this card is destroyed by battle or by a card effect and sent to the Graveyard: Place 1 Ice Counter on each face-up monster on the field.
target_text: -- Snow
  local COUNTER_ID_0 = 0x1015 --Ice
  local s, id, o = GetID()
  function s.initial_effect(c)
  	--special summon
  	local e1 = Effect.CreateEffect(c)
  	e1:SetDescription(aux.Stringid(id, 0))
  	e1:SetType(EFFECT_TYPE_SINGLE + EFFECT_TYPE_TRIGGER_F)
  	e1:SetCode(EVENT_TO_GRAVE)
  	e1:SetCondition(s.condition)
  	e1:SetOperation(s.operation)
  	c:RegisterEffect(e1)
  end
  function s.condition(e, tp, eg, ep, ev, re, r, rp)
  	return e:GetHandler():IsReason(REASON_DESTROY)
  end
  function s.operation(e, tp, eg, ep, ev, re, r, rp)
  	local g = Duel.GetMatchingGroup(Card.IsCanAddCounter, tp, LOCATION_MZONE, LOCATION_MZONE, nil, 0x1015, 1)
  	local tc = g:GetFirst()
  	while tc do
  		tc:AddCounter(COUNTER_ID_0, 1, REASON_EFFECT)
  		tc = g:GetNext()
  	end
  end
  
  