Skip to content

Duel.SwapDeckAndGrave ​

Signature ​

lua
Duel.SwapDeckAndGrave(int player) -> void

Description ​

For Exchange of the Spirit-style effects, swaps player's Deck and Graveyard.

Parameters ​

  • player int

Source ​

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

Used By ​

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

  • Detected in 1 indexed script(s).
  • Search this function in the Script Explorer with Duel.SwapDeckAndGrave.
CardIDScriptDetected Calls
Exchange of the Spirit17484499Scripts/c17484499.lua2

Script Examples ​

Exchange of the Spirit (17484499) ​

Source: Scripts/c17484499.lua

lua
	local g=Duel.GetFieldGroup(tp,LOCATION_GRAVE,LOCATION_GRAVE)
	if aux.NecroValleyNegateCheck(g) then return end
	Duel.SwapDeckAndGrave(tp)
	Duel.SwapDeckAndGrave(1-tp)
end