Skip to content

Duel.AnnounceCard ​

Signature ​

lua
Duel.AnnounceCard(int player, [int opcode1], [... int]) -> int

Description ​

Lets player declare a card code matching the optional opcode/filter expression and returns the selected code.

Parameters ​

  • player int
  • opcode1 int optional
  • ... int optional

Returns ​

  • int

Source ​

  • D:\Programs\GitHub\ygopro-core\libduel.cpp:5032

Guided Examples ​

Learn how to use this function in context:

Used By ​

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

  • Detected in 32 indexed script(s).
  • Search this function in the Script Explorer with Duel.AnnounceCard.
CardIDScriptDetected Calls
Ma'at18631392Scripts/c18631392.lua3
Mind Scan34298391Scripts/c34298391.lua2
Gravekeeper's Trap98715423Scripts/c98715423.lua1
Primite Roar92501449Scripts/c92501449.lua1
Primite Howl41488249Scripts/c41488249.lua1
Primite Lordly Lode56506740Scripts/c56506740.lua1
Artmage Academic Arcane Arts Acropolis74733322Scripts/c74733322.lua1
Forge a New Future27104921Scripts/c27104921.lua1
Akashic Magician28776350Scripts/c28776350.lua1
Alsei, the Sylvan High Protector10406322Scripts/c10406322.lua1
Exosister Carpedivem30802207Scripts/c30802207.lua1
Gunkan Suship Catch-of-the-Day83008724Scripts/c83008724.lua1
Ancient Gear Gadget18486927Scripts/c18486927.lua1
The Suppression Pluto24413299Scripts/c24413299.lua1
Engraver of the Mark50078320Scripts/c50078320.lua2
Goddess Urd's Verdict91969909Scripts/c91969909.lua1
Crossout Designator65681983Scripts/c65681983.lua1
The True Name39913299Scripts/c39913299.lua1
Dirge of the Lost Dragon40971261Scripts/c40971261.lua1
Lullaby of Obedience39238953Scripts/c39238953.lua1
Archfiend's Oath22796548Scripts/c22796548.lua1
Question38723936Scripts/c38723936.lua1
The Black Goat Laughs49299410Scripts/c49299410.lua1
Cloak and Dagger8323633Scripts/c8323633.lua1
...and 8 more

Script Examples ​

Ma'at (18631392) ​

Source: Scripts/c18631392.lua

lua
	getmetatable(e:GetHandler()).announce_filter={TYPE_FUSION+TYPE_SYNCHRO+TYPE_XYZ+TYPE_LINK,OPCODE_ISTYPE,OPCODE_NOT}
	Duel.Hint(HINT_SELECTMSG,tp,HINTMSG_CODE)
	local ac1=Duel.AnnounceCard(tp,table.unpack(getmetatable(e:GetHandler()).announce_filter))
	Duel.Hint(HINT_SELECTMSG,tp,HINTMSG_CODE)
	local ac2=Duel.AnnounceCard(tp,table.unpack(getmetatable(e:GetHandler()).announce_filter))

Mind Scan (34298391) ​

Source: Scripts/c34298391.lua

lua
		table.insert(afilter,OPCODE_NOT)
		ag:Clear()
		local ac=Duel.AnnounceCard(tp,table.unpack(afilter))
		Duel.SetTargetParam(ac)
		Duel.SetOperationInfo(0,CATEGORY_ANNOUNCE,nil,0,tp,0)

Gravekeeper's Trap (98715423) ​

Source: Scripts/c98715423.lua

lua
	Duel.Hint(HINT_SELECTMSG,tp,HINTMSG_CODE)
	getmetatable(e:GetHandler()).announce_filter={TYPE_FUSION+TYPE_SYNCHRO+TYPE_XYZ+TYPE_LINK,OPCODE_ISTYPE,OPCODE_NOT}
	local ac=Duel.AnnounceCard(tp,table.unpack(getmetatable(e:GetHandler()).announce_filter))
	Duel.SetTargetParam(ac)
	Duel.SetOperationInfo(0,CATEGORY_ANNOUNCE,nil,0,tp,0)