Skip to content

Card.CopyEffect ​

Signature ​

lua
Card.CopyEffect(Card c, int code, int reset, [int count]) -> int

Description ​

Copies the initial_effect of card code onto c and returns the generated copy id, or -1 if code belongs to a Normal Monster. reset defaults to RESETS_STANDARD when 0. count defaults to 1; phase resets without a turn side are normalized to both players' turns. If c is a non-Effect Monster, the core also adds TYPE_EFFECT for the same reset.

Parameters ​

  • c Card
  • code int
  • reset int
  • count int optional - default: 1

Returns ​

  • int

Source ​

  • D:\Programs\GitHub\ygopro-core\libcard.cpp:3621

Used By ​

Generated from the local Scripts/ folder and cards.cdb.

  • Detected in 25 indexed script(s).
  • Search this function in the Script Explorer with Card.CopyEffect.
CardIDScriptDetected Calls
Starving Venemy Dragon93729065Scripts/c93729065.lua1
Windwitch - Crystal Bell25793414Scripts/c25793414.lua1
Emperor Charles the Great97864322Scripts/c97864322.lua1
Odd-Eyes Venom Dragon45014450Scripts/c45014450.lua1
Masterflare Hyperion63101468Scripts/c63101468.lua1
Raidraptor - Rising Rebellion Falcon71222868Scripts/c71222868.lua1
Starving Venom Fusion Dragon41209827Scripts/c41209827.lua1
Blackwing - Aurora the Northern Lights4068622Scripts/c4068622.lua1
Hundred Eyes Dragon95453143Scripts/c95453143.lua1
Supreme King Dragon Starving Venom43387895Scripts/c43387895.lua1
Dragon Knight Draco-Equiste14017402Scripts/c14017402.lua1
Number 8: Heraldic King Genom-Heritage47387961Scripts/c47387961.lua1
CXyz Barian Hope67926903Scripts/c67926903.lua1
Symphonic Warrior Synthess49919798Scripts/c49919798.lua1
Elemental HERO Divine Neos31111109Scripts/c31111109.lua1
The Tyrant Neptune88071625Scripts/c88071625.lua1
Phantom of Chaos30312361Scripts/c30312361.lua1
Number C69: Heraldry Crest of Horror11522979Scripts/c11522979.lua1
Gem-Knight Master Diamond39512984Scripts/c39512984.lua1
Neo-Spacian Dark Panther43237273Scripts/c43237273.lua1
Legendary Knight Hermos84565800Scripts/c84565800.lua1
Number 69: Heraldry Crest2407234Scripts/c2407234.lua1
Pseudo Space77584012Scripts/c77584012.lua1
Infernoid Decatron58446973Scripts/c58446973.lua1
...and 1 more

Script Examples ​

Starving Venemy Dragon (93729065) ​

Source: Scripts/c93729065.lua

lua
		c:RegisterEffect(e1)
		if not tc:IsType(TYPE_TRAPMONSTER) then
			cid=c:CopyEffect(tc:GetOriginalCode(),RESET_EVENT+RESETS_STANDARD+RESET_PHASE+PHASE_END,1)
		end
		local e2=Effect.CreateEffect(c)

Windwitch - Crystal Bell (25793414) ​

Source: Scripts/c25793414.lua

lua
		c:RegisterEffect(e1)
		if not tc:IsType(TYPE_TRAPMONSTER) then
			cid=c:CopyEffect(code,RESET_EVENT+RESETS_STANDARD+RESET_PHASE+PHASE_END,1)
		end
		local e2=Effect.CreateEffect(c)

Emperor Charles the Great (97864322) ​

Source: Scripts/c97864322.lua

lua
		c:RegisterEffect(e1)
		if tc:GetOriginalType()&TYPE_EFFECT==TYPE_EFFECT then
			c:CopyEffect(code,RESET_EVENT+RESETS_STANDARD)
		end
		if Duel.GetLocationCount(tp,LOCATION_SZONE)>0 and tc:CheckUniqueOnField(tp) and not tc:IsForbidden() then