name: Tainted
card_text: If this Attack Position card is changed to face-up Defense Position: Shuffle your Deck.
lua: local s, id, o = GetID()
  function s.initial_effect(c)
  	--shuffle
  	local e1 = Effect.CreateEffect(c)
  	e1:SetDescription(aux.Stringid(id, 0))
  	e1:SetType(EFFECT_TYPE_SINGLE + EFFECT_TYPE_TRIGGER_F)
  	e1:SetCode(EVENT_CHANGE_POS)
  	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():IsPreviousPosition(POS_ATTACK) and e:GetHandler():IsPosition(POS_DEFENSE)
  end
  function s.operation(e, tp, eg, ep, ev, re, r, rp)
  	Duel.ShuffleDeck(tp)
  end
  
  
source_text: Tainted
  If this Attack Position card is changed to face-up Defense Position: Shuffle your Deck.
target_text: -- Tainted
  local s, id, o = GetID()
  function s.initial_effect(c)
  	--shuffle
  	local e1 = Effect.CreateEffect(c)
  	e1:SetDescription(aux.Stringid(id, 0))
  	e1:SetType(EFFECT_TYPE_SINGLE + EFFECT_TYPE_TRIGGER_F)
  	e1:SetCode(EVENT_CHANGE_POS)
  	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():IsPreviousPosition(POS_ATTACK) and e:GetHandler():IsPosition(POS_DEFENSE)
  end
  function s.operation(e, tp, eg, ep, ev, re, r, rp)
  	Duel.ShuffleDeck(tp)
  end
  
  