Skip to content

Card.GetEquipTarget ​

Signature ​

lua
Card.GetEquipTarget(Card c) -> Card|nil

Description ​

Returns the card that c is currently equipped to, or nil if c has no equip target. Use this while the Equip Card is still equipped. After it leaves the relationship, use Card.GetPreviousEquipTarget for leave-field triggers.

How To Use It ​

Use this while the card is currently equipped and you need the monster it is equipped to.

lua
local ec=e:GetHandler():GetEquipTarget()
if ec and ec:IsFaceup() then
    -- use the equipped monster
end

After the Equip Card leaves the field, this relationship is gone. Use Card.GetPreviousEquipTarget in leave-field or sent-to-GY triggers.

Parameters ​

  • c Card

Returns ​

  • Card|nil

Source ​

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

Guided Examples ​

Learn how to use this function in context:

Used By ​

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

  • Detected in 150 indexed script(s).
  • Search this function in the Script Explorer with Card.GetEquipTarget.
CardIDScriptDetected Calls
Spirit Illusion71939275Scripts/c71939275.lua5
Converging Wishes20007374Scripts/c20007374.lua3
Camelot, Realm of Noble Knights and Noble Arms15635751Scripts/c15635751.lua1
Fiendsmith Kyrie26434972Scripts/c26434972.lua1
Red-Eyes Slash Dragon21140872Scripts/c21140872.lua1
Clown Crew Malabarisme83232904Scripts/c83232904.lua1
Horn of Olifant55749927Scripts/c55749927.lua1
Amaze Attraction Wonder Wheel93473606Scripts/c93473606.lua5
Nephe Shaddoll Fusion60226558Scripts/c60226558.lua2
Dragunity Arma Gram53184342Scripts/c53184342.lua1
Master Spirit Tech Force - Pendulum Ruler68508433Scripts/c68508433.lua1
Amaze Attraction Thrill Train36591747Scripts/c36591747.lua7
Shichi-Go-San11035075Scripts/c11035075.lua5
Salamandra Fusion9102835Scripts/c9102835.lua3
Immortal Phoenix Gearfried22091647Scripts/c22091647.lua1
Gergonne's End59490397Scripts/c59490397.lua4
Tragic Twin Twined Jewels81143465Scripts/c81143465.lua3
Commander Souza, Swordmaster72867001Scripts/c72867001.lua1
Meklord Emperor Granel4545683Scripts/c4545683.lua1
Plunder Patroll Parrrty43004235Scripts/c43004235.lua1
Tailwind of Gusto1187243Scripts/c1187243.lua4
Marincess Wonder Heart94207108Scripts/c94207108.lua1
ZS - Ouroboros Sage32281491Scripts/c32281491.lua2
Super Strident Blaze81193865Scripts/c81193865.lua5
...and 126 more

Script Examples ​

Spirit Illusion (71939275) ​

Source: Scripts/c71939275.lua

lua
end
function s.fcon(e,tp,eg,ep,ev,re,r,rp)
	return e:GetHandler():GetEquipTarget()
end
function s.filter1(c,e)

Converging Wishes (20007374) ​

Source: Scripts/c20007374.lua

lua
end
function c20007374.cacon(e,tp,eg,ep,ev,re,r,rp)
	local ec=e:GetHandler():GetEquipTarget()
	return ec and eg:IsContains(ec)
end

Camelot, Realm of Noble Knights and Noble Arms (15635751) ​

Source: Scripts/c15635751.lua

lua
end
function s.dfilter(c,e)
	return c:GetEquipTarget() and c:IsDestructable(e) and not c:IsStatus(STATUS_DESTROY_CONFIRMED)
end
function s.reptg(e,tp,eg,ep,ev,re,r,rp,chk)