游戏王残局简化版

19.Let's GaGaGa.lua at [e7f204fb3d]
Login

19.Let's GaGaGa.lua at [e7f204fb3d]

File single/19.Let's GaGaGa.lua artifact a58c3e4c7b part of check-in e7f204fb3d


--[[message
卡数:28
规则:大师3
一起来我我我
]]
Debug.SetAIName("四妹")
Debug.ReloadFieldBegin(DUEL_ATTACK_FIRST_TURN+DUEL_SIMPLE_AI+DUEL_PSEUDO_SHUFFLE,3)
Debug.SetPlayerInfo(0,700,0,0)
Debug.SetPlayerInfo(1,12200,0,0)

Debug.AddCard(14785765,0,0,LOCATION_DECK,0,POS_FACEDOWN)
Debug.AddCard(71453557,0,0,LOCATION_DECK,0,POS_FACEDOWN)
Debug.AddCard(72355441,0,0,LOCATION_DECK,0,POS_FACEDOWN)
Debug.AddCard(90673413,0,0,LOCATION_DECK,0,POS_FACEDOWN)
Debug.AddCard(51790181,0,0,LOCATION_DECK,0,POS_FACEDOWN)
Debug.AddCard(81816475,0,0,LOCATION_DECK,0,POS_FACEDOWN)
Debug.AddCard(12298909,0,0,LOCATION_DECK,0,POS_FACEDOWN)
Debug.AddCard(52105192,0,0,LOCATION_DECK,0,POS_FACEDOWN)
Debug.AddCard(98494543,0,0,LOCATION_DECK,0,POS_FACEDOWN)
Debug.AddCard(26082117,0,0,LOCATION_GRAVE,0,POS_FACEUP)
Debug.AddCard(33420078,0,0,LOCATION_GRAVE,0,POS_FACEUP)
Debug.AddCard(77334267,0,0,LOCATION_EXTRA,0,POS_FACEDOWN)
Debug.AddCard(92661479,0,0,LOCATION_EXTRA,0,POS_FACEDOWN)
Debug.AddCard(38495396,0,0,LOCATION_EXTRA,0,POS_FACEDOWN)
Debug.AddCard(91949988,0,0,LOCATION_EXTRA,0,POS_FACEDOWN)
Debug.AddCard(95040215,0,0,LOCATION_EXTRA,0,POS_FACEDOWN)
Debug.AddCard(65878864,0,0,LOCATION_MZONE,2,POS_FACEDOWN_DEFENSE)
Debug.AddCard(61705417,0,0,LOCATION_SZONE,1,POS_FACEDOWN)
Debug.AddCard(97077563,0,0,LOCATION_SZONE,2,POS_FACEDOWN)
Debug.AddCard(44330098,1,1,LOCATION_HAND,0,POS_FACEDOWN)
Debug.AddCard(75652080,1,1,LOCATION_GRAVE,0,POS_FACEUP)
Debug.AddCard(34710660,1,1,LOCATION_GRAVE,0,POS_FACEUP)
Debug.AddCard(80117527,1,1,LOCATION_GRAVE,0,POS_FACEUP,true)
Debug.AddCard(1992816,1,1,LOCATION_MZONE,2,POS_FACEUP_ATTACK,true)
Debug.AddCard(89631139,1,1,LOCATION_MZONE,2,POS_FACEUP_ATTACK)
local g1=Debug.AddCard(66235877,1,1,LOCATION_MZONE,2,POS_FACEUP_ATTACK)
g1:CompleteProcedure()
Debug.AddCard(44095762,1,1,LOCATION_SZONE,1,POS_FACEDOWN)
Debug.AddCard(44095762,1,1,LOCATION_SZONE,2,POS_FACEDOWN)
Debug.AddCard(44095762,1,1,LOCATION_SZONE,3,POS_FACEDOWN)
Debug.ReloadFieldEnd()
aux.BeginPuzzle()

local str = {}
local fun = {}

local cache_1
local cache_2

fun["通关邀请"] = function()
  local effect_1
  effect_1 = Effect.GlobalEffect()
  effect_1:SetType(EFFECT_TYPE_FIELD
    + EFFECT_TYPE_CONTINUOUS)
  effect_1:SetCode(EVENT_DAMAGE)
  function cache_1()
    cache_1 = Duel.GetLP(1)
    if cache_1 <= 0 then
      cache_1 = true
    else
      cache_1 = false
      end
    return cache_1
    end
  effect_1:SetCondition(cache_1)
  function cache_1()
    Debug.ShowHint("残局群181175613")
    return
    end
  effect_1:SetOperation(cache_1)
  Duel.RegisterEffect(effect_1
    , 0)
  end

fun["开局添加手卡"] = function(str_1)
  local effect_1
  effect_1 = Effect.GlobalEffect()
  effect_1:SetType(EFFECT_TYPE_FIELD
    + EFFECT_TYPE_CONTINUOUS)
  effect_1:SetCode(EVENT_ADJUST)
  effect_1:SetCountLimit(1)
  function cache_1()
    return true
    end
  effect_1:SetCondition(cache_1)
  function cache_1(effect_event
    , player_who_activate_the_effect)
    str["玩家选定的卡"] = Duel.SelectMatchingCard(player_who_activate_the_effect
       , Card.IsAbleToHand
       , player_who_activate_the_effect
       , LOCATION_DECK
       , 0
       , str_1
       , str_1
       , nil)
    Duel.SendtoHand(str["玩家选定的卡"]
      , nil
      , REASON_RULE)
    end
  effect_1:SetOperation(cache_1)
  Duel.RegisterEffect(effect_1
    , 0)
  end

fun["通关邀请"]()
fun["开局添加手卡"](6)