Skip to content

Auxiliary.GetAttributeCount ​

Signature ​

lua
Auxiliary.GetAttributeCount(Group g) -> void

Description ​

Returns how many different Attributes are represented among the cards in g; an empty group returns 0.

Parameters ​

  • g Group

Source ​

  • Utilities/utility.lua:587

Used By ​

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

  • Detected in 9 indexed script(s).
  • Search this function in the Script Explorer with Auxiliary.GetAttributeCount.
CardIDScriptDetected Calls
Elemental HERO Sunrise22908820Scripts/c22908820.lua1
Possessed Partnerships65046521Scripts/c65046521.lua1
Charmer Quartet in Bloom27519978Scripts/c27519978.lua1
Ancient Warriors Saga - Borrowing of Arrows33609093Scripts/c33609093.lua1
Pressured Planet Wraitsoth71832012Scripts/c71832012.lua1
Elemental HERO Shining Neos Wingman56733747Scripts/c56733747.lua1
Ancient Warriors Saga - Sun-Liu Alliance58116537Scripts/c58116537.lua1
Dark Doriado62312469Scripts/c62312469.lua1
Awakening of the Possessed62256492Scripts/c62256492.lua1

Script Examples ​

Elemental HERO Sunrise (22908820) ​

Source: Scripts/c22908820.lua

lua
function c22908820.val(e,c)
	local g=Duel.GetMatchingGroup(c22908820.atkfilter,e:GetHandlerPlayer(),LOCATION_MZONE,0,nil)
	return aux.GetAttributeCount(g)*200
end
function c22908820.descon(e,tp,eg,ep,ev,re,r,rp)

Possessed Partnerships (65046521) ​

Source: Scripts/c65046521.lua

lua
	local mg=Duel.GetMatchingGroup(Card.IsFaceup,tp,LOCATION_MZONE,0,nil)
	local g=Duel.GetMatchingGroup(Card.IsFaceup,tp,LOCATION_ONFIELD,LOCATION_ONFIELD,aux.ExceptThisCard(e))
	if aux.GetAttributeCount(mg)>=2 and g:GetCount()>0 and Duel.SelectYesNo(tp,aux.Stringid(65046521,1)) then
		Duel.BreakEffect()
		Duel.Hint(HINT_SELECTMSG,tp,HINTMSG_DESTROY)

Charmer Quartet in Bloom (27519978) ​

Source: Scripts/c27519978.lua

lua
function s.atkval(e,c)
	local g=Duel.GetMatchingGroup(s.atkfilter,e:GetHandlerPlayer(),LOCATION_MZONE,LOCATION_MZONE,nil)
	return aux.GetAttributeCount(g)*300
end
function s.spcon(e,tp,eg,ep,ev,re,r,rp)