Skip to content

Duel.SelectDisableField ​

Signature ​

lua
Duel.SelectDisableField(int player, int count, int location1, int location2, int filter) -> int

Description ​

Lets player select count available field zones from the requested own-side and opponent-side locations, then returns the selected zone bitmask. location1 applies to player's field and location2 applies to the opponent's field. The core clamps count to the available number of zones and returns no value if no zone can be selected. The returned mask uses player-relative bits: own Monster Zone seq, own Spell & Trap Zone seq+8, opponent Monster Zone seq+16, and opponent Spell & Trap Zone seq+24.

Parameters ​

  • player int - Player who selects zones and whose viewpoint defines the returned mask.
  • count int - Number of zones to select. The core reduces this to the number of available zones if needed.
  • location1 int - Selectable locations on player's field, usually LOCATION_MZONE and/or LOCATION_SZONE.
  • location2 int - Selectable locations on the opponent's field, usually LOCATION_MZONE and/or LOCATION_SZONE.
  • filter int - Player-relative mask of zones that cannot be selected.

Returns ​

  • int - Selected zone bitmask, or no return value if no zone can be selected.

Source ​

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

Guided Examples ​

Learn how to use this function in context:

Used By ​

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

  • Detected in 50 indexed script(s).
  • Search this function in the Script Explorer with Duel.SelectDisableField.
CardIDScriptDetected Calls
Vaylantz Genesis Grand Duke76075139Scripts/c76075139.lua1
Arktos XII - Chronochasm Vaylantz50687050Scripts/c50687050.lua1
Mamonaka the Vaylantz United40680521Scripts/c40680521.lua1
S-Force Justify35334193Scripts/c35334193.lua1
Sprind the Irondash Dragon1906812Scripts/c1906812.lua1
Parallel Panzer93394164Scripts/c93394164.lua2
R.B. VALCan Booster6821579Scripts/c6821579.lua1
Dark Infant @Ignister74567889Scripts/c74567889.lua1
Seismic Shockwave79569173Scripts/c79569173.lua1
S-Force World Sorting11642993Scripts/c11642993.lua1
Kashtira Shangri-Ira73542331Scripts/c73542331.lua1
Elfnotes: Aristeia of Trust50590801Scripts/c50590801.lua1
Crusadia Spatha39528955Scripts/c39528955.lua1
Codebreaker Virus Swordsman84121193Scripts/c84121193.lua1
S-Force Mystify4611341Scripts/c4611341.lua2
Boompoline!!14839621Scripts/c14839621.lua1
S-Force Specimen82977464Scripts/c82977464.lua1
Spring60600821Scripts/c60600821.lua1
Procession of the Tea Jar12612470Scripts/c12612470.lua1
Aeropixthree83094004Scripts/c83094004.lua1
World Legacy Guardragon87571563Scripts/c87571563.lua1
Goldilocks the Battle Landscaper24521754Scripts/c24521754.lua1
Appliancer Electrilyrical World3875465Scripts/c3875465.lua1
Gouki The Solid Ogre22510667Scripts/c22510667.lua1
...and 26 more

Script Examples ​

Vaylantz Genesis Grand Duke (76075139) ​

Source: Scripts/c76075139.lua

lua
			if flag==0 then return end
			Duel.Hint(HINT_SELECTMSG,tp,HINTMSG_TOZONE)
			local s=Duel.SelectDisableField(tp,1,LOCATION_MZONE,0,~flag)
			local nseq=math.log(s,2)
			Duel.MoveSequence(sc,nseq)

Arktos XII - Chronochasm Vaylantz (50687050) ​

Source: Scripts/c50687050.lua

lua
			if flag==0 then return end
			Duel.Hint(HINT_SELECTMSG,tp,HINTMSG_TOZONE)
			local s=Duel.SelectDisableField(tp,1,LOCATION_MZONE,0,~flag)
			local nseq=math.log(s,2)
			Duel.HintSelection(sg)

Mamonaka the Vaylantz United (40680521) ​

Source: Scripts/c40680521.lua

lua
			if flag==0 then return end
			Duel.Hint(HINT_SELECTMSG,tp,HINTMSG_TOZONE)
			local s=Duel.SelectDisableField(tp,1,LOCATION_MZONE,0,~flag)
			local nseq=math.log(s,2)
			Duel.MoveSequence(sc,nseq)