local helper = CS.Lens.Tools.RuntimeDebug.RuntimeDebugActionHelper
local lockstepManager = CS.Lens.Gameplay.Battle.Logic.LockStepManager
local rePlayManager = CS.Lens.Gameplay.Battle.Logic.RePlayManager
local debugActions = require("debug.debugActions")
if IS_DEV_BUILD then
  helper.SetTouchToggleActive(Unity.Application.isEditor or Unity.Application.isMobilePlatform)
else
  helper.SetTouchToggleActive(false)
end
helper.RegisterButton("Application", "Resources.UnloadUnusedAssets", function()
  CS.Lens.Framework.AzurAssets.UnloadAllPackagesUnusedAssets(true)
end, true, "Resources.UnloadUnusedAssets")
helper.RegisterButton("Application", "\232\181\132\230\186\144\233\135\138\230\148\190\230\181\139\232\175\149", function()
  CS.Lens.Framework.AzurAssets.Test11()
end, true, "Resources.UnloadUnusedAssets")
helper.RegisterButton("Application", "GC.Collect(Mono+Lua)", function()
  CS.System.GC.Collect()
  collectgarbage("collect")
end, true, "GC.Collect(Mono+Lua)")
helper.RegisterToggle("Application", "Unity Logger", function()
  return CS.UnityEngine.Debug.unityLogger.logEnabled
end, function(isOn)
  CS.UnityEngine.Debug.unityLogger.logEnabled = isOn
end, false, "Enable/Disable Unity Logger")
helper.RegisterButton("GM Tools", "\233\135\141\230\150\176\230\179\168\229\134\140\229\145\189\228\187\164", function()
  helper.UnregisterByGroup("GM Tools")
  package.loaded["debug.registerRuntimeDebugActions"] = pcall(load("debug.registerRuntimeDebugActions"))
  package.loaded["debug.debugActions"] = pcall(load("debug.debugActions"))
  printf("RuntimeDebugActionHelper", "lua gm\232\132\154\230\156\172\233\135\141\231\189\174")
  require("debug.registerRuntimeDebugActions")
end)
helper.RegisterButton("GM Tools", "Smart GC", function()
  CS.Azur.Gameplay.Core.SmartGC.Instance:Collect(true)
end)
helper.RegisterButton("GM Tools", "\230\137\147\229\188\128\229\164\150\230\140\130", function()
  local msg = {
    command = "DEEPFINISHALLGUIDETASK",
    args = {}
  }
  L_Net:sendMessage(MsgGenCode.CSProtoGMCommand, msg, nil)
  local msg = {
    command = "UNLOCKPOS",
    args = {}
  }
  L_Net:sendMessage(MsgGenCode.CSProtoGMCommand, msg, nil)
  local msg = {
    command = "SUPERCMD",
    args = {"7"}
  }
  L_Net:sendMessage(MsgGenCode.CSProtoGMCommand, msg, function()
    debugActions.SendGMCommand("ALLPETLV " .. tostring(100))
  end)
  local msg = {
    command = "SUPERCMD",
    args = {"1"}
  }
  L_Net:sendMessage(MsgGenCode.CSProtoGMCommand, msg, function()
    debugActions.SendGMCommand("HEROLV " .. tostring(100))
  end)
end)
helper.RegisterButton("GM Tools", "\230\136\152\230\150\151\230\168\161\230\139\159\229\153\168(\228\187\133\230\160\135\233\162\152\231\149\140\233\157\162\232\191\155\229\133\165)", function()
  CS.Azur.Gameplay.AzurEntry.instance:StartGame(function()
    AzurWorld.proxyCenter:ToSimulate(99997, CS.Azur.Gameplay.Flows.ESimulateType.BattleSimulate)
  end)
end, true, "\233\157\158\230\160\135\233\162\152\231\149\140\233\157\162\232\191\155\229\133\165\228\184\141\229\134\141\231\187\180\230\138\164\239\188\140\230\158\129\229\164\167\230\166\130\231\142\135\230\138\165\233\148\153")
helper.RegisterButton("GM Tools", "\228\187\152\232\180\185\230\181\139\232\175\149", function()
  local data = {productId = 1001, times = 1}
  L_MoneyShopStore:req_purchaseCashItem(data, function(result)
    if result then
      L_FlyMsgManager:showNormalMsg(L_WordsTpl:getValue("notice_buySuccess"))
    else
      L_FlyMsgManager:showNormalMsg(L_WordsTpl:getValue("notice_buyFail"))
    end
  end)
end, true, "\228\187\152\232\180\185\230\181\139\232\175\149")
helper.RegisterInput("GM Tools", "GM\229\145\189\228\187\164", function(inputStr)
  debugActions.SendGMCommand(inputStr)
end, true, "\229\144\145\229\144\142\231\171\175\229\143\145\233\128\129GM\229\145\189\228\187\164")
helper.RegisterInput("GM Tools", "\229\136\135\230\141\162\229\156\186\230\153\175", function(inputStr)
  AzurWorld.proxyCenter:RequestTransfer(tonumber(inputStr))
end, true, "\228\188\160\233\128\129\229\136\176\230\140\135\229\174\154\229\156\186\230\153\175")
helper.RegisterInput("GM Tools", "\232\191\155\229\133\165\229\137\175\230\156\172", function(inputStr)
  local nums = string.split(inputStr, " ")
  local data = {
    group_id = tonumber(nums[1]),
    difficulty = tonumber(nums[2])
  }
  L_Net:sendMessage(MsgGenCode.CSProtoCampaignCreate, data, function(rspData, errorCode)
  end)
end, true, "\228\188\160\233\128\129\229\136\176\230\140\135\229\174\154\229\137\175\230\156\172\239\188\154\229\137\175\230\156\172\231\187\132id \233\154\190\229\186\166")
helper.RegisterInput("GM Tools", "\232\191\155\229\133\165\230\149\153\229\173\166\229\133\179\229\141\161", function(inputStr)
  L_EntrustStore:req_CSProtoTeachStart(tonumber(inputStr))
end, true, "\228\188\160\233\128\129\229\136\176\230\140\135\229\174\154\230\149\153\229\173\166\229\133\179\229\141\161\239\188\154trainTask\232\161\168id")
helper.RegisterButton("GM Tools", "\231\190\142\230\156\175\230\181\139\232\175\149\232\176\131\229\143\130", function()
  L_UI:open("pageArtGM")
end)
helper.RegisterInput("GM Tools", "\232\191\155\229\133\165\229\165\135\230\179\162\229\175\185\230\136\152\230\181\139\232\175\149\232\175\149\231\148\168\229\165\135\230\179\162", function(inputStr)
  local nums = string.split(inputStr, " ")
  local levelId = tonumber(nums[1])
  if math.isEmpty(levelId) then
    return
  end
  L_KiBoDuelManager:openTestKiBoDuel(levelId)
end, true, "\232\191\155\229\133\165\229\165\135\230\179\162\229\175\185\230\136\152\230\181\139\232\175\149\232\175\149\231\148\168\229\165\135\230\179\162\239\188\154\229\137\175\230\156\172id")
helper.RegisterInput("GM Tools", "\231\155\184\230\156\186\230\138\150\229\138\168", function(inputStr)
  C_CameraManager.SetLookAtFollowLerpSpeed(tonumber(inputStr))
end, true, "\231\155\184\230\156\186\230\138\150\229\138\168\229\143\130\230\149\176\232\174\190\231\189\174")
helper.RegisterToggle("GM Tools", "\231\155\184\230\156\186\229\177\143\232\148\189\230\128\187\229\188\128\229\133\179", function(isShow)
  return C_CameraManager.lookAtCameraIgnore
end, function(isShow)
  C_CameraManager.lookAtCameraIgnore = isShow
end)
helper.RegisterToggle("GM Tools", "\231\155\184\230\156\186\229\177\143\232\148\189-\229\177\143\232\148\189\230\143\146\228\187\182\229\155\158\230\173\163", function(isShow)
  return C_CameraManager.huizhengIgnore
end, function(isShow)
  C_CameraManager.huizhengIgnore = isShow
end)
helper.RegisterToggle("GM Tools", "\231\155\184\230\156\186\229\177\143\232\148\189-\229\177\143\232\148\189\228\186\186\231\137\169timeline", function(isShow)
  return C_CameraManager.herotimelineIgnore
end, function(isShow)
  C_CameraManager.herotimelineIgnore = isShow
end)
helper.RegisterToggle("GM Tools", "\231\155\184\230\156\186\229\177\143\232\148\189-\229\177\143\232\148\189\229\174\160\231\137\169timeline", function(isShow)
  return C_CameraManager.pettimelineIgnore
end, function(isShow)
  C_CameraManager.pettimelineIgnore = isShow
end)
helper.RegisterToggle("GM Tools", "\231\155\184\230\156\186\229\177\143\232\148\189-\229\177\143\232\148\189\229\136\135\228\186\186fov\228\184\142\232\167\134\232\183\157", function(isShow)
  return C_CameraManager.switchFovTimelineIgnore
end, function(isShow)
  C_CameraManager.switchFovTimelineIgnore = isShow
end)
helper.RegisterToggle("GM Tools", "\231\155\184\230\156\186\229\177\143\232\148\189-\229\177\143\232\148\189\228\186\186\231\137\169\230\140\135\230\140\165\233\149\156\229\164\180", function(isShow)
  return C_CameraManager.petZhihuiIgnore
end, function(isShow)
  C_CameraManager.petZhihuiIgnore = isShow
end)
helper.RegisterToggle("GM Tools", "\231\155\184\230\156\186\229\177\143\232\148\189-break\233\149\156\229\164\180", function(isShow)
  return C_CameraManager.breakIgnore
end, function(isShow)
  C_CameraManager.breakIgnore = isShow
end)
local C_BevPlatform = CS.Lens.Framework.Utility.BehaviorOnPlatform
helper.RegisterToggle("GM Tools", "PC/Mobile UI\233\128\130\233\133\141", function(isShow)
  return C_BevPlatform.platformInt == 1
end, function(isShow)
  C_BevPlatform.platformInt = isShow and 1 or 2
  L_UI:setRefResolution(isShow and {x = 2400, y = 1350} or {x = 1920, y = 1080})
end)
helper.RegisterToggle("GM Tools", "\231\155\184\230\156\186\229\177\143\232\148\189-\229\177\143\232\148\189\229\133\168\229\177\128\231\155\184\230\156\186\229\155\158\230\173\163", function(isShow)
  return C_CameraManager.resetIgnore
end, function(isShow)
  C_CameraManager.resetIgnore = isShow
end)
helper.RegisterToggle("GM Tools", "\230\152\175\229\144\166\230\152\190\231\164\186Log\230\151\165\229\191\151", function(isShow)
  return debugActions.isShowLogConsole
end, function(isShow)
  debugActions.isShowLogConsole = debugActions.showlogConsole(isShow)
end)
debugActions.showLogConsole(debugActions.isShowLogConsole)
helper.RegisterToggle("GM Tools", "\232\174\190\231\189\174\229\189\147\229\137\141\232\174\190\229\164\135", function(isShow)
  return L_DeviceTpl:getIsPc()
end, function(isShow)
  if isShow then
    L_DeviceTpl.data.equipment = L_Const.equipment.pc
    L_DeviceTpl.data.platform = L_Const.platform.editor
  else
    L_DeviceTpl.data.equipment = L_Const.equipment.mobile
    L_DeviceTpl.data.platform = L_Const.platform.android
  end
  L_SettingStore:injectAdapter()
  L_SettingStore:call(L_SettingStore.event.refreshEquipment)
end)
helper.RegisterInput("GM Tools", "\229\136\183\230\150\176\233\154\143\230\156\186\228\187\187\229\138\161\230\181\139\232\175\149", function(inputStr)
  C_TaskManager.GMRefreshRandomTask(inputStr, true)
end, true, "\228\187\187\229\138\161id")
helper.RegisterInput("GM Tools", "\229\142\187\233\153\164\233\154\143\230\156\186\228\187\187\229\138\161\230\181\139\232\175\149", function(inputStr)
  C_TaskManager.GMRefreshRandomTask(inputStr, false)
end, true, "\228\187\187\229\138\161id")
helper.RegisterToggle("GM Tools", "\229\188\128\229\133\179\231\129\175\229\133\137", function(isShow)
  return debugActions.isLightOpen
end, function(isShow)
  debugActions.changeLightObjShow("Light", isShow)
  debugActions.isLightOpen = isShow
end)
helper.RegisterToggle("GM Tools", "\229\188\128\229\133\179\230\168\161\229\158\139", function(isShow)
  return debugActions.isModelOpen
end, function(isShow)
  debugActions.changeModelObjShow("Model", isShow)
  debugActions.isModelOpen = isShow
end)
helper.RegisterToggle("GM Tools", "\229\188\128\229\133\179\231\137\185\230\149\136", function(isShow)
  return debugActions.isEffectOpen
end, function(isShow)
  debugActions.changeEffectObjShow("Effect", isShow)
  debugActions.isEffectOpen = isShow
end)
helper.RegisterToggle("GM Tools", "\230\150\176\230\137\139\229\188\149\229\175\188", function(isShow)
  if not G_Launcher.gameplayRequired then
    return false
  end
  return L_GuideManager:canStartGuide()
end, function(isShow)
  L_GuideManager:setGuideActive(isShow)
  if isShow then
    L_GuideManager:startAllGuide()
  else
    L_GuideManager:stopAllGuide()
  end
end)
helper.RegisterToggle("GM Tools", "\230\142\167\229\136\182\230\137\128\230\156\137UI\230\152\190\231\164\186\233\154\144\232\151\143", function(isShow)
  return debugActions.isUIOpen
end, function(isShow)
  debugActions.isUIOpen = isShow
  L_UI:controlUIRootShowState(debugActions.isUIOpen)
  if not isShow then
    helper.SetTouchToggleActive(false)
  elseif IS_DEV_BUILD then
    helper.SetTouchToggleActive(Unity.Application.isEditor or Unity.Application.isMobilePlatform)
  end
  C_BattleUIManager.GMSetUIShowState(debugActions.isUIOpen)
end)
helper.RegisterToggle("GM Tools", "\230\142\167\229\136\182\228\188\164\229\174\179\232\183\179\229\173\151\230\152\190\231\164\186\233\154\144\232\151\143", function(isShow)
  return debugActions.isDamageText
end, function(isShow)
  debugActions.isDamageText = isShow
  C_BattleUIManager.SetDamageTextState(debugActions.isDamageText)
end)
helper.RegisterInput("GM Tools", "\232\176\131\232\175\149\230\150\176\230\137\139\229\188\149\229\175\188", function(inputStr)
  L_GuideManager:debugGuide(tonumber(inputStr))
end, true, "")
helper.RegisterInput("GM Tools", "\232\176\131\232\175\149\229\165\135\230\179\162\229\175\185\230\136\152", function(inputStr)
  L_UI:open("pagePetPrepareDuel", {
    levelId = tonumber(inputStr)
  })
end, true, "")
helper.RegisterInput("GM Tools", "\232\176\131\232\175\149\229\165\135\230\179\162\229\175\185\230\136\152\232\174\173\231\187\131\229\133\179\229\141\161", function(inputStr)
  local levelId = tonumber(inputStr)
  L_PetDuelStore:setCurChallengeLevelId(levelId)
  C_KiBoDuelLuaWrapper.SetCurrentLevel(levelId)
  L_PetDuelStore:req_CSProtoKiboDuelStart(levelId)
end, true, "")
helper.RegisterInput("GM Tools", "\232\176\131\232\175\149\232\142\183\229\190\151\232\139\177\233\155\132", function(inputStr)
  L_UI:open("pageGetHero", {
    configId = tonumber(inputStr)
  })
end, true, "")
helper.RegisterInput("GM Tools", "\230\163\128\230\159\165\229\188\149\229\175\188\231\138\182\230\128\129", function(inputStr)
  if string.isEmpty(inputStr) then
    return
  end
  local guidId = tonumber(inputStr)
  if L_GuideManager:isGuideOnRunning(guidId) then
    L_FlyMsgManager:showNormalMsg(inputStr .. L_WordsTpl:getValue("notice_guide"))
    return
  end
  if L_GuideStore:isGuideComplete(guidId) then
    L_FlyMsgManager:showNormalMsg(inputStr .. L_WordsTpl:getValue("notice_finished"))
    return
  end
  L_FlyMsgManager:showNormalMsg(inputStr .. L_WordsTpl:getValue("notice_notrigger"))
end, true, "")
helper.RegisterButton("GM Tools", "\230\168\161\230\139\159\230\149\176\230\141\174\230\155\180\230\150\176\229\155\158\229\136\176\229\136\157\229\167\139UI", function(inputStr)
  L_GuideManager:stopAllGuide()
  L_UI:backToRoot()
  L_GuideManager:restartAllGuide()
end, true, "")
helper.RegisterButton("GM Tools", "\230\151\182\233\151\180\229\190\170\231\142\175", function()
  L_UI:open("pageTimeLoop")
end, true, "\230\151\182\233\151\180\229\190\170\231\142\175")
helper.RegisterInput("GM Tools", "\230\137\147\229\188\128\230\140\135\229\174\154UI\231\149\140\233\157\162", function(inputStr)
  L_UI:open(inputStr)
end, true, "\232\190\147\229\133\165UI\231\149\140\233\157\162\229\144\141\231\167\176")
helper.RegisterButton("GM Tools", "\230\137\147\229\188\128\232\174\190\231\189\174\231\149\140\233\157\162", function()
  L_UI:open("pageOption")
end, true, "\230\137\147\229\188\128\232\174\190\231\189\174\231\149\140\233\157\162")
helper.RegisterButton("GM Tools", "\229\188\128\229\144\175/\229\133\179\233\151\173\231\188\150\233\152\159HUD\232\176\131\232\175\149", function()
  L_FormationManager._isGm = not L_FormationManager._isGm
end, true)
helper.RegisterInput("GM Tools", "\228\191\174\230\148\185\230\150\173\231\186\191\230\163\128\230\181\139\230\151\182\233\151\180", function(inputStr)
  local time = tonumber(inputStr)
  if 0 < time then
    local maskPlugin = CS.Azur.Gameplay.Core.Net.NetManager.GetPlugin(C_NetChannel.Main, CS.Azur.Gameplay.Core.Net.ENetPluginType.MsgMask)
    maskPlugin.MaskTimeLimit = time
    local heartPlugin = CS.Azur.Gameplay.Core.Net.NetManager.GetPlugin(C_NetChannel.Main, CS.Azur.Gameplay.Core.Net.ENetPluginType.Heart)
    heartPlugin.HeartReceiveLimit = time
  end
end, true, "\230\150\173\231\186\191\230\163\128\230\181\139\230\151\182\233\151\180")
helper.RegisterInput("GM Tools", "\230\181\139\232\175\149\233\149\191\233\135\141\232\191\158", function(inputStr)
  local params = string.split(inputStr, " ")
  local time = tonumber(params[1])
  local showMask = params[2] == nil or tonumber(params[2]) ~= 0
  local channel = CS.Azur.Gameplay.Core.Net.NetManager.GetChannel(C_NetChannel.Main)
  channel:GM_NetReconnect(true, time, showMask)
end, true, "\233\135\141\232\191\158\229\187\182\232\191\159\230\175\171\231\167\146\230\149\176")
helper.RegisterInput("GM Tools", "\230\181\139\232\175\149\231\159\173\233\135\141\232\191\158", function(inputStr)
  local params = string.split(inputStr, " ")
  local time = tonumber(params[1])
  local showMask = params[2] == nil or tonumber(params[2]) ~= 0
  local channel = CS.Azur.Gameplay.Core.Net.NetManager.GetChannel(C_NetChannel.Main)
  channel:GM_NetReconnect(false, time, showMask)
end, true, "\233\135\141\232\191\158\229\187\182\232\191\159\230\175\171\231\167\146\230\149\176")
helper.RegisterInput("\229\137\167\230\131\133", "\230\146\173\230\148\190\229\137\167\230\131\133", function(inputStr)
  if AzurWorld.StoryMgr then
    local storyId = tonumber(inputStr)
    AzurWorld.StoryMgr:PlayStory(storyId)
  end
end, true, "\229\137\167\230\131\133id")
helper.RegisterButton("\229\137\167\230\131\133", "\231\187\147\230\157\159\229\137\167\230\131\133", function()
  if AzurWorld.StoryMgr then
    AzurWorld.StoryMgr:Stop()
  end
end, true)
helper.RegisterButton("\229\137\167\230\131\133", "\229\137\167\230\131\133\229\143\175\232\183\179", function()
  C_StoryManager.IsDebugForceCanSkip = true
end, true)
helper.RegisterButton("\229\137\167\230\131\133", "\230\129\162\229\164\141\229\137\167\230\131\133\232\183\179\232\191\135\233\133\141\231\189\174", function()
  C_StoryManager.IsDebugForceCanSkip = false
end, true)
helper.RegisterButton("\229\184\184\231\148\168GM\230\140\135\228\187\164", "\230\181\139\232\175\149\231\189\145\229\133\179\229\133\172\229\145\138", function()
  local successCall = function(self, tex)
    local pos = string.split(tex, "&")
    local data = {
      txtTitle = pos[1],
      txtContent = pos[3],
      hideCancel = true,
      hideConfirm = true
    }
    L_UI:open("pageTextNoticeWindow", data)
  end
  local failCall = function(self, key)
  end
  local announceUrl = "project-3/gateway_announce/gm_announce_show.txt"
  C_CDNManager.GetObject(announceUrl, handler(nil, successCall), handler(nil, failCall))
end, true)
helper.RegisterButton("\229\184\184\231\148\168GM\230\140\135\228\187\164", "\232\167\163\233\148\129\230\137\128\230\156\137\231\179\187\231\187\159", function()
  local msg = {
    command = "SYSALLUNLOCK",
    args = {"1"}
  }
  L_Net:sendMessage(MsgGenCode.CSProtoGMCommand, msg, nil)
end, true)
helper.RegisterButton("\229\184\184\231\148\168GM\230\140\135\228\187\164", "\228\184\128\233\148\174\229\174\140\230\136\144\230\137\128\230\156\137\229\188\149\229\175\188\228\187\187\229\138\161", function()
  local msg = {
    command = "DEEPFINISHALLGUIDETASK",
    args = {}
  }
  L_Net:sendMessage(MsgGenCode.CSProtoGMCommand, msg, nil)
end, true)
helper.RegisterButton("\229\184\184\231\148\168GM\230\140\135\228\187\164", "\230\183\187\229\138\160\230\137\128\230\156\137\232\167\146\232\137\178", function()
  local msg = {
    command = "SUPERCMD",
    args = {"1"}
  }
  L_Net:sendMessage(MsgGenCode.CSProtoGMCommand, msg, nil)
  debugActions.SendGMCommand("ADDITEM 1 111001 1 1")
end, true)
helper.RegisterButton("\229\184\184\231\148\168GM\230\140\135\228\187\164", "\230\183\187\229\138\160\230\137\128\230\156\137\230\173\166\229\153\168", function()
  local msg = {
    command = "SUPERCMD",
    args = {"2"}
  }
  L_Net:sendMessage(MsgGenCode.CSProtoGMCommand, msg, nil)
end, true)
helper.RegisterButton("\229\184\184\231\148\168GM\230\140\135\228\187\164", "\228\184\128\233\148\174\228\184\137\230\152\159\233\128\154\229\133\179\230\137\128\230\156\137\229\167\148\230\137\152\228\187\187\229\138\161", function()
  for i = 3580, 3910, 10 do
    local msg = {
      command = "deend",
      args = {
        tostring(i),
        "7"
      }
    }
    L_Net:sendMessage(MsgGenCode.CSProtoGMCommand, msg, nil)
  end
end, true)
helper.RegisterInput("GM Tools", "\232\174\190\231\189\174\229\189\147\229\137\141\230\140\145\230\136\152\229\190\151\229\167\148\230\137\152id", function(inputStr)
  L_EntrustStore:setCurChallengeEntrustId(tonumber(inputStr))
end, true, "\232\190\147\229\133\165UI\231\149\140\233\157\162\229\144\141\231\167\176")
helper.RegisterInput("GM Tools", "\229\135\143\229\176\145\228\189\147\229\138\155", function(inputStr)
  local msg = {
    command = "subStamina",
    args = {
      tostring(inputStr)
    }
  }
  L_Net:sendMessage(MsgGenCode.CSProtoGMCommand, msg, nil)
end, true, "\229\135\143\229\176\145\228\189\147\229\138\155")
helper.RegisterButton("\229\184\184\231\148\168GM\230\140\135\228\187\164", "\230\183\187\229\138\160\230\137\128\230\156\137\231\129\181\229\173\144\228\187\165\229\143\138\231\155\184\229\133\179\233\129\147\229\133\183", function()
  local msg = {
    command = "SUPERCMD",
    args = {"9"}
  }
  L_Net:sendMessage(MsgGenCode.CSProtoGMCommand, msg, nil)
  debugActions.SendGMCommand("ADDITEM 10 2 798000")
  debugActions.SendGMCommand("ADDITEM 10 10 1005")
  local total = {}
  local spiritronRankTpl = L_GameTpl:getSpiritronRankTpl()
  local tpl = spiritronRankTpl:getTplList()
  for k, v in pairs(tpl) do
    for i, j in pairs(v) do
      for m, n in pairs(j.rankUpItem) do
        if not total[n[1]] then
          total[n[1]] = n[2]
        else
          total[n[1]] = total[n[1]] + n[2]
        end
      end
    end
  end
  local newTotal = {}
  for k, v in pairs(total) do
    table.insert(newTotal, {k, v})
  end
  for i = 1, #newTotal do
    local item = newTotal[i]
    local id = item[1]
    local num = item[2]
    Timer.once(i * 0.2, function()
      debugActions.SendGMCommand("ADDITEM 3 " .. tostring(item[1]) .. " " .. tostring(item[2]))
    end)
  end
end, true)
helper.RegisterButton("\229\184\184\231\148\168GM\230\140\135\228\187\164", "\230\183\187\229\138\160\230\137\128\230\156\137\233\158\141\229\133\183", function()
  local msg = {
    command = "SUPERCMD",
    args = {"25"}
  }
  L_Net:sendMessage(MsgGenCode.CSProtoGMCommand, msg, nil)
end, true)
helper.RegisterButton("\229\184\184\231\148\168GM\230\140\135\228\187\164", "\230\183\187\229\138\160\230\137\128\230\156\137\233\129\147\229\133\183", function()
  local msg = {
    command = "SUPERCMD",
    args = {"5"}
  }
  L_Net:sendMessage(MsgGenCode.CSProtoGMCommand, msg, nil)
end, true)
helper.RegisterButton("\229\184\184\231\148\168GM\230\140\135\228\187\164", "\230\183\187\229\138\160\230\137\128\230\156\137\228\187\187\229\138\161\233\129\147\229\133\183", function()
  local msg = {
    command = "SUPERCMD",
    args = {"20"}
  }
  L_Net:sendMessage(MsgGenCode.CSProtoGMCommand, msg, nil)
end, true)
helper.RegisterButton("\229\184\184\231\148\168GM\230\140\135\228\187\164", "\230\183\187\229\138\160\230\137\128\230\156\137\229\174\160\231\137\169\232\155\139", function()
  local msg = {
    command = "SUPERCMD",
    args = {"6"}
  }
  L_Net:sendMessage(MsgGenCode.CSProtoGMCommand, msg, nil)
end, true)
helper.RegisterButton("\229\184\184\231\148\168GM\230\140\135\228\187\164", "\228\184\128\233\148\174\230\183\187\229\138\160\230\137\128\230\156\137\229\188\128\229\143\145\231\148\168\229\174\160\231\137\169", function()
  local msg = {
    command = "SUPERCMD",
    args = {"7"}
  }
  L_Net:sendMessage(MsgGenCode.CSProtoGMCommand, msg, nil)
end, true)
helper.RegisterButton("\229\184\184\231\148\168GM\230\140\135\228\187\164", "\230\183\187\229\138\160\230\137\128\230\156\137\229\143\175\231\148\168\229\174\160\231\137\169", function()
  local msg = {
    command = "SUPERCMD",
    args = {"8"}
  }
  L_Net:sendMessage(MsgGenCode.CSProtoGMCommand, msg, nil)
end, true)
helper.RegisterButton("\229\184\184\231\148\168GM\230\140\135\228\187\164", "\230\183\187\229\138\160\230\137\128\230\156\137\229\157\144\233\170\145", function()
  local msg = {
    command = "SUPERCMD",
    args = {"12"}
  }
  L_Net:sendMessage(MsgGenCode.CSProtoGMCommand, msg, nil)
end, true)
helper.RegisterButton("\229\184\184\231\148\168GM\230\140\135\228\187\164", "\230\183\187\229\138\160\230\137\128\230\156\137\232\163\133\229\164\135", function()
  local msg = {
    command = "SUPERCMD",
    args = {"15"}
  }
  L_Net:sendMessage(MsgGenCode.CSProtoGMCommand, msg, nil)
end, true)
helper.RegisterButton("\229\184\184\231\148\168GM\230\140\135\228\187\164", "\230\183\187\229\138\160\230\137\128\230\156\137\231\167\176\229\143\183", function()
  local msg = {
    command = "SUPERCMD",
    args = {"17"}
  }
  L_Net:sendMessage(MsgGenCode.CSProtoGMCommand, msg, nil)
end, true)
helper.RegisterButton("\229\184\184\231\148\168GM\230\140\135\228\187\164", "\229\184\149\231\177\179\233\128\159\233\128\146\228\184\147\231\148\168\232\183\168\229\164\169", function()
  local msg = {
    command = "CROSSDAY",
    args = {}
  }
  L_Net:sendMessage(MsgGenCode.CSProtoGMCommand, msg, nil)
end, true)
helper.RegisterButton("\229\184\184\231\148\168GM\230\140\135\228\187\164", "\233\135\145\229\184\129+999999", function()
  local msg = {
    command = "ADDITEM",
    args = {
      "10",
      "2",
      "999999"
    }
  }
  L_Net:sendMessage(MsgGenCode.CSProtoGMCommand, msg, nil)
end, true)
helper.RegisterButton("\229\184\184\231\148\168GM\230\140\135\228\187\164", "\233\146\187\231\159\179+999999", function()
  local msg = {
    command = "ADDITEM",
    args = {
      "10",
      "1",
      "999999"
    }
  }
  L_Net:sendMessage(MsgGenCode.CSProtoGMCommand, msg, nil)
end, true)
helper.RegisterButton("\229\184\184\231\148\168GM\230\140\135\228\187\164", "\232\135\170\231\132\182\231\130\185\230\149\176+999999", function()
  local msg = {
    command = "ADDITEM",
    args = {
      "10",
      "101",
      "999999"
    }
  }
  L_Net:sendMessage(MsgGenCode.CSProtoGMCommand, msg, nil)
end, true)
helper.RegisterButton("\229\184\184\231\148\168GM\230\140\135\228\187\164", "\231\142\169\229\174\182\231\187\143\233\170\140+999999", function()
  local msg = {
    command = "ADDITEM",
    args = {
      "10",
      "10",
      "999999"
    }
  }
  L_Net:sendMessage(MsgGenCode.CSProtoGMCommand, msg, nil)
end, true)
helper.RegisterInput("\229\184\184\231\148\168GM\230\140\135\228\187\164", "\231\142\169\229\174\182\231\187\143\233\170\140+n", function(inputStr)
  local msg = {
    command = "ADDITEM",
    args = {
      "10",
      "10",
      inputStr
    }
  }
  L_Net:sendMessage(MsgGenCode.CSProtoGMCommand, msg, nil)
end, true, "")
helper.RegisterButton("\229\184\184\231\148\168GM\230\140\135\228\187\164", "\229\174\160\231\137\169\232\155\139+1", function()
  local msg = {
    command = "ADDITEM",
    args = {
      "14",
      "500001",
      "1"
    }
  }
  L_Net:sendMessage(MsgGenCode.CSProtoGMCommand, msg, nil)
end, true)
helper.RegisterButton("\229\184\184\231\148\168GM\230\140\135\228\187\164", "\229\141\161\230\177\160\232\174\161\230\149\176\230\184\1330", function()
  local msg = {
    command = "GACHAPOOL",
    args = {}
  }
  L_Net:sendMessage(MsgGenCode.CSProtoGMCommand, msg, nil)
end, true)
helper.RegisterButton("\229\184\184\231\148\168GM\230\140\135\228\187\164", "\229\174\160\231\137\169+1", function()
  local msg = {
    command = "ADDITEM",
    args = {
      "5",
      "500001",
      "1"
    }
  }
  L_Net:sendMessage(MsgGenCode.CSProtoGMCommand, msg, nil)
end, true)
helper.RegisterButton("\229\184\184\231\148\168GM\230\140\135\228\187\164", "\229\136\160\233\153\164\230\137\128\230\156\137\232\163\133\229\164\135", function()
  local msg = {
    command = "CLEANBAG",
    args = {"15"}
  }
  L_Net:sendMessage(MsgGenCode.CSProtoGMCommand, msg, nil)
end, true)
helper.RegisterButton("\229\184\184\231\148\168GM\230\140\135\228\187\164", "\229\136\160\233\153\164\230\137\128\230\156\137\231\129\181\229\173\144", function()
  local msg = {
    command = "CLEANBAG",
    args = {"9"}
  }
  L_Net:sendMessage(MsgGenCode.CSProtoGMCommand, msg, nil)
end, true)
helper.RegisterButton("\229\184\184\231\148\168GM\230\140\135\228\187\164", "\229\136\160\233\153\164\230\137\128\230\156\137\230\153\174\233\128\154\233\129\147\229\133\183", function()
  local msg = {
    command = "CLEANBAG",
    args = {"3"}
  }
  L_Net:sendMessage(MsgGenCode.CSProtoGMCommand, msg, nil)
end, true)
helper.RegisterButton("\229\184\184\231\148\168GM\230\140\135\228\187\164", "\232\167\163\233\148\129\230\137\128\230\156\137\229\137\175\230\156\172", function()
  local msg = {
    command = "UNLOCKDUNGEON",
    args = {"0", "0"}
  }
  L_Net:sendMessage(MsgGenCode.CSProtoGMCommand, msg, nil)
end, true)
helper.RegisterButton("\229\184\184\231\148\168GM\230\140\135\228\187\164", "\233\135\141\231\189\174\233\146\147\233\177\188\231\130\185", function()
  local msg = {
    command = "FISHPOND",
    args = {}
  }
  L_Net:sendMessage(MsgGenCode.CSProtoGMCommand, msg, nil)
end, true)
helper.RegisterButton("\229\184\184\231\148\168GM\230\140\135\228\187\164", "\229\191\171\233\128\159\229\162\158\229\138\160\232\175\186\232\175\186100\229\165\189\230\132\159 ", function()
  local msg = {
    command = "ADDHEROFAVOREXP",
    args = {199003, 100}
  }
  L_Net:sendMessage(MsgGenCode.CSProtoGMCommand, msg, nil)
end, true)
helper.RegisterInput("\229\184\184\231\148\168GM\230\140\135\228\187\164", "\229\162\158\229\138\160\232\167\146\232\137\178\229\165\189\230\132\159 [heroId] [count]", function(inputStr)
  local msg = {
    command = "ADDHEROFAVOREXP",
    args = string.split(inputStr, " ")
  }
  L_Net:sendMessage(MsgGenCode.CSProtoGMCommand, msg, nil)
end, true, "\232\167\146\232\137\178id / \229\162\158\229\138\160\231\154\132\230\149\176\233\135\143")
helper.RegisterInput("\229\184\184\231\148\168GM\230\140\135\228\187\164", "\229\162\158\229\138\160\230\152\159\230\132\136\229\138\155 [count]", function(inputStr)
  local msg = {
    command = "CHARGEADD",
    args = string.split(inputStr, " ")
  }
  L_Net:sendMessage(MsgGenCode.CSProtoGMCommand, msg, nil)
end, true, "\229\162\158\229\138\160\229\164\154\229\176\145\230\152\159\230\132\136\229\138\155")
helper.RegisterInput("\229\184\184\231\148\168GM\230\140\135\228\187\164", "\229\135\143\229\176\145\230\152\159\230\132\136\229\138\155 [count]", function(inputStr)
  local msg = {
    command = "CHARGEREDUCE",
    args = string.split(inputStr, " ")
  }
  L_Net:sendMessage(MsgGenCode.CSProtoGMCommand, msg, nil)
end, true, "\229\135\143\229\176\145\229\164\154\229\176\145\230\152\159\230\132\136\229\138\155")
helper.RegisterButton("\229\184\184\231\148\168GM\230\140\135\228\187\164", "\230\184\133\231\169\186\230\152\159\230\132\136\229\138\155", function()
  local msg = {
    command = "CHARGECLEAR",
    args = {}
  }
  L_Net:sendMessage(MsgGenCode.CSProtoGMCommand, msg, nil)
end, true)
helper.RegisterButton("\229\184\184\231\148\168GM\230\140\135\228\187\164", "\228\184\128\233\148\174\229\143\145\233\130\174\228\187\182", function()
  local msg = {
    command = "AllMAIL",
    args = {}
  }
  L_Net:sendMessage(MsgGenCode.CSProtoGMCommand, msg, nil)
end, true)
helper.RegisterButton("\229\184\184\231\148\168GM\230\140\135\228\187\164", "\228\184\128\233\148\174\229\136\160\233\153\164\230\137\128\230\156\137\233\130\174\228\187\182", function()
  local msg = {
    command = "DelAllMAIL",
    args = {}
  }
  L_Net:sendMessage(MsgGenCode.CSProtoGMCommand, msg, nil)
  L_MailStore.data.mailData = {}
end, true)
helper.RegisterInput("\229\184\184\231\148\168GM\230\140\135\228\187\164", "\228\188\160\233\128\129\229\136\176\230\140\135\229\174\154\229\157\144\230\160\135[X,Y,Z]", function(inputStr)
  local numList = string.split(inputStr, ",")
  local pos = {
    x = tonumber(numList[1]),
    y = tonumber(numList[2]),
    z = tonumber(numList[3])
  }
  local rot = {
    x = 0,
    y = 0,
    z = 0
  }
  AzurWorld.transferMgr:ClientTransferStartFlow(pos, rot)
end, true, "\228\188\160\233\128\129\229\136\176\230\140\135\229\174\154\229\157\144\230\160\135[X,Y,Z] X\228\184\142Z\228\184\186\229\157\144\230\160\135\239\188\140Y\228\184\186\233\171\152\229\186\166")
helper.RegisterButton("\229\184\184\231\148\168GM\230\140\135\228\187\164", "\232\167\163\233\148\129\230\137\128\230\156\137\228\188\160\233\128\129\231\130\185", function()
  local msg = {
    command = "UNLOCKPOS",
    args = {}
  }
  L_Net:sendMessage(MsgGenCode.CSProtoGMCommand, msg, nil)
end, true)
helper.RegisterButton("\229\184\184\231\148\168GM\230\140\135\228\187\164", "\232\167\163\233\148\129\228\184\150\231\149\140\229\156\176\229\155\190\230\137\128\230\156\137\229\140\186\229\159\159", function()
  L_MapStore:setUnlockAllArea()
end, true)
helper.RegisterInput("\229\184\184\231\148\168GM\230\140\135\228\187\164", "\230\137\147\229\188\128\233\135\135\233\155\134\232\163\133\229\164\135\231\149\140\233\157\162", function(inputStr)
  local tT = tonumber(inputStr)
  L_UI:open("pageCollectionTool", {toolType = tT})
end, true)
helper.RegisterButton("PV\229\189\149\229\136\182\231\155\184\229\133\179GM\230\140\135\228\187\164", "\228\184\128\233\148\174\229\162\158\229\138\160PV\233\156\128\230\177\130\232\167\146\232\137\178\229\174\160\231\137\169\229\157\144\233\170\145", function()
  local count = 1
  Timer.once(count * 0.1, function()
    local heroList = {
      109001,
      109002,
      199003,
      107001,
      108001,
      111001,
      104001,
      101004,
      108002,
      108003,
      101006
    }
    local msg_hero = {
      cmds = {}
    }
    for i = 1, #heroList do
      local heroId = heroList[i]
      local cmd = {
        command = "ADDITEM",
        args = {
          "1",
          tostring(heroId),
          "1",
          "1"
        }
      }
      table.insert(msg_hero.cmds, cmd)
    end
    L_Net:sendMessage(MsgGenCode.CSProtoGMCommands, msg_hero, nil)
  end)
  count = count + 1
  Timer.once(count * 0.1, function()
    local petList = {
      500001,
      500004,
      500007,
      500022,
      500024,
      500025,
      500026,
      500035
    }
    local msg_pet = {
      cmds = {}
    }
    for i = 1, #petList do
      local petId = petList[i]
      local cmd = {
        command = "ADDITEM",
        args = {
          "5",
          tostring(petId),
          "1"
        }
      }
      table.insert(msg_pet.cmds, cmd)
    end
    L_Net:sendMessage(MsgGenCode.CSProtoGMCommands, msg_pet, nil)
  end)
  count = count + 1
  Timer.once(count * 0.1, function()
    local homebuildingList = {
      10011,
      10012,
      40011,
      20021,
      20041
    }
    local msg_homebuilding = {
      cmds = {}
    }
    for i = 1, #homebuildingList do
      local homebuildingId = homebuildingList[i]
      local args = {
        "13",
        tostring(homebuildingId),
        "1"
      }
      if homebuildingId == 20041 then
        args = {
          "13",
          tostring(homebuildingId),
          "20"
        }
      end
      local cmd = {command = "ADDITEM", args = args}
      table.insert(msg_homebuilding.cmds, cmd)
    end
    L_Net:sendMessage(MsgGenCode.CSProtoGMCommands, msg_homebuilding, nil)
  end)
  count = count + 1
  Timer.once(count * 0.1, function()
    local homeItemList = {
      310001,
      310002,
      310004,
      310006,
      300001,
      301002,
      350000,
      350001,
      310003,
      310005,
      304003
    }
    local msg_homeItem = {
      cmds = {}
    }
    for i = 1, #homeItemList do
      local homeItemId = homeItemList[i]
      local args = {
        "3",
        tostring(homeItemId),
        "10"
      }
      if homeItemId == 310003 or homeItemId == 310005 then
        args = {
          "3",
          tostring(homeItemId),
          "999"
        }
      end
      local cmd = {command = "ADDITEM", args = args}
      table.insert(msg_homeItem.cmds, cmd)
    end
    L_Net:sendMessage(MsgGenCode.CSProtoGMCommands, msg_homeItem, nil)
  end)
  count = count + 1
  Timer.once(count * 0.1, function()
    local msg = {
      command = "SUPERCMD",
      args = {"12"}
    }
    L_Net:sendMessage(MsgGenCode.CSProtoGMCommand, msg, nil)
  end)
  count = count + 1
  Timer.once(count * 0.1, function()
    local msg = {
      command = "HEROSTARAll",
      args = {"3"}
    }
    L_Net:sendMessage(MsgGenCode.CSProtoGMCommand, msg, nil)
  end)
end, true)
helper.RegisterButton("\229\184\184\231\148\168GM\230\140\135\228\187\164", "\230\156\141\229\138\161\229\153\168\232\135\170\230\181\139\230\142\165\229\143\1630", function()
  local msg = {
    obj_ids = {920160123},
    obj_keys = {
      {obj_id = 920160123, obj_index = 0}
    }
  }
  L_Net:sendMessage(MsgGenCode.CSProtoFightStart, msg, nil)
end, true)
helper.RegisterButton("\229\184\184\231\148\168GM\230\140\135\228\187\164", "\230\156\141\229\138\161\229\153\168\232\135\170\230\181\139\230\142\165\229\143\1631", function()
end, true)
helper.RegisterButton("\229\184\184\231\148\168GM\230\140\135\228\187\164", "\230\156\141\229\138\161\229\153\168\232\135\170\230\181\139\230\142\165\229\143\1632", function()
end, true)
helper.RegisterButton("\229\184\184\231\148\168GM\230\140\135\228\187\164", "\230\156\141\229\138\161\229\153\168\232\135\170\230\181\139\230\142\165\229\143\1633", function()
end, true)
helper.RegisterButton("\229\184\184\231\148\168GM\230\140\135\228\187\164", "\229\164\167\228\184\150\231\149\140\233\135\141\231\189\174\232\161\128\233\135\143", function()
  local msg = {
    command = "WORLD",
    args = {"HP"}
  }
  L_Net:sendMessage(MsgGenCode.CSProtoGMCommand, msg, nil)
end, true)
helper.RegisterButton("\229\184\184\231\148\168GM\230\140\135\228\187\164", "\229\164\167\228\184\150\231\149\140\233\135\141\231\189\174\231\137\169\228\187\182", function()
  local msg = {
    command = "WORLD",
    args = {"ALLOBJ"}
  }
  L_Net:sendMessage(MsgGenCode.CSProtoGMCommand, {
    command = "CLEANALLPLAY",
    args = {}
  }, nil)
  L_Net:sendMessage(MsgGenCode.CSProtoGMCommand, msg, function()
    local mapId = AzurWorld.Instance.CurWorldId
    local suc, pos = CS.Azur.Gameplay.Table.TDWorldBorthposTable.QueryAOIPos(mapId)
    AzurWorld.AOI:OnSceneEnter(mapId, pos)
    AzurWorld.service.map:PrepareWorldMapData(mapId)
    AzurWorld.WorldMapMgr:ClearUnits()
    AzurWorld.WorldMapMgr:InitWorldMapUnits()
  end)
end, true)
helper.RegisterButton("\229\184\184\231\148\168GM\230\140\135\228\187\164", "\230\151\160\230\149\140\231\137\185\229\136\171\228\185\133", function()
  if L_PlayerManager:getPlayerUnit() then
    L_PlayerManager:getPlayerUnit():getUnitData().unbelievableTime = Unity.Time.time + 100000
  end
end, true)
helper.RegisterButton("\229\184\184\231\148\168GM\230\140\135\228\187\164", "\229\136\135\230\141\162\229\185\189\231\129\181\230\168\161\229\188\143\239\188\136\231\169\186\230\160\188\229\144\145\228\184\138 ctrl\229\144\145\228\184\139\239\188\137", function()
  local playerEntity = L_PlayerManager:getMainControlEntity()
  if playerEntity then
    if playerEntity.csEntity.state:GetCurrentStateType() == C_EFsmStateType.Ghost then
      playerEntity.csEntity.state:SetTrigger("Entry")
      if L_PlayerManager:getPlayerUnit() then
        L_PlayerManager:getPlayerUnit():getUnitData().unbelievableTime = 0
      end
    else
      playerEntity.csEntity.state:SetTrigger("Ghost")
      if L_PlayerManager:getPlayerUnit() then
        L_PlayerManager:getPlayerUnit():getUnitData().unbelievableTime = Unity.Time.time + 100000
      end
    end
  end
end, true)
helper.RegisterInput("\229\184\184\231\148\168GM\230\140\135\228\187\164", "\232\174\190\231\189\174\229\185\189\231\129\181\230\168\161\229\188\143\233\128\159\229\186\166", function(inputStr)
  local playerEntity = L_PlayerManager:getMainControlEntity()
  if playerEntity then
    local speed = tonumber(inputStr)
    playerEntity.csEntity.data.characterControlProperty.maxFlySpeed = speed
  end
end, true, "\233\128\159\229\186\166")
helper.RegisterButton("\229\184\184\231\148\168GM\230\140\135\228\187\164", "\229\136\135\230\141\162\233\163\158\232\161\140\230\168\161\229\188\143", function()
  AzurWorld.mountMgr:ReqChangeMountStatus(C_WorldMapPlayerMountStatusType.WmpmstFly)
end, true)
helper.RegisterButton("\229\184\184\231\148\168GM\230\140\135\228\187\164", "\229\136\135\230\141\162\233\135\135\233\155\134\232\189\174\229\187\147", function()
end, true)
helper.RegisterButton("\229\184\184\231\148\168GM\230\140\135\228\187\164", "\230\184\133\233\153\164\233\146\147\233\177\188\228\186\139\228\187\182", function()
  local msg = {
    command = "FISHEVENTCLEAN",
    args = {}
  }
  L_Net:sendMessage(MsgGenCode.CSProtoGMCommand, msg, nil)
end, true)
helper.RegisterInput("\229\184\184\231\148\168GM\230\140\135\228\187\164", "\229\183\161\233\128\187\231\187\132\231\167\187\229\138\168", function(inputStr)
  local arr = string.split(inputStr, " ")
  if #arr < 2 then
    error("\229\143\130\230\149\176\230\160\188\229\188\143\228\184\141\229\175\185: groupId pathId [patrolType=3]")
    return
  end
  local groupId = tonumber(arr[1])
  local pathId = tonumber(arr[2])
  local patrolType = 3
  if 3 <= #arr then
    patrolType = tonumber(arr[3])
  end
  local C_GroupMoveManager = CS.Lens.Gameplay.Modules.BigWorld.GroupMoveManager
  C_GroupMoveManager.StartGroupMove(groupId, pathId, patrolType)
end, true, "\229\143\130\230\149\176 groupId pathId [patrolType=3]")
helper.RegisterButton("\229\184\184\231\148\168GM\230\140\135\228\187\164", "\230\184\133\231\169\186\230\137\128\230\156\137\231\142\169\230\179\149", function()
  local msg = {
    command = "CLEANALLPLAY",
    args = {}
  }
  L_Net:sendMessage(MsgGenCode.CSProtoGMCommand, msg, nil)
end, true)
helper.RegisterInput("GM Tools", "\230\137\147\229\188\128\232\175\180\230\152\142\231\149\140\233\157\162", function(input)
  local groupId = tonumber(input)
  local pages = L_GameTpl:getIntroductionTpl():getPages(groupId)
  if table.count(pages) > 0 then
    L_UI:open("pageCommonIntroduction", {groupId = groupId})
  end
end, true, "\229\161\171\229\133\165groupId")
helper.RegisterButton("GM Tools", "\229\137\167\230\131\133\229\175\185\232\175\157\233\162\132\232\167\136", function()
  L_UI:open("pageDialoguePreview")
end)
helper.RegisterButton("GM Tools", "\230\152\190\231\164\186HierarchyInspector\239\188\136Game\232\167\134\229\155\190\239\188\137", function()
  L_UI:open("runtimeHierarchyInspector")
end)
helper.RegisterInput("GM Tools", "\229\188\128\229\144\175RuntimeInspector\239\188\136Web\231\171\175\239\188\137", function(input)
  debugActions.startWebRuntimeInspector(tonumber(input))
end, true, "\231\149\153\231\169\186\228\189\191\231\148\168\233\187\152\232\174\164\239\188\140\230\136\150\232\190\147\229\133\165\228\189\160\230\131\179\230\140\135\229\174\154\231\154\132\231\171\175\229\143\163\229\143\183")
helper.RegisterButton("GM Tools", "\229\133\179\233\151\173RuntimeInspector\239\188\136Web\231\171\175\239\188\137", function()
  debugActions.stopWebRuntimeInspector()
end)
helper.RegisterButton("GM Tools", "Start Wwise Profiler", function()
  C_AudioManager.StartProfilerCapture()
end)
helper.RegisterButton("GM Tools", "Stop Wwise Profiler", function()
  C_AudioManager.StopProfilerCapture()
end)
helper.RegisterInput("GM Tools", "\230\155\180\230\148\185\232\175\173\232\168\128", function(inputStr)
  debugActions.setLanguage_debug(inputStr)
end, true, "\229\136\135\230\141\162\230\150\135\230\156\172\232\175\173\232\168\128 - \232\190\147\229\133\165\232\175\173\232\168\128\228\187\163\229\143\183: en|jp|kr|chs|cht")
helper.RegisterButton("GM Tools", "\232\190\147\229\135\186\230\137\128\230\156\137\229\134\133\229\173\152\228\184\173\231\154\132\233\159\179\230\149\136", function()
end)
helper.RegisterButton("GM Tools", "\230\137\147\229\188\128UWA\230\181\139\232\175\149\233\157\162\230\157\191", function()
  C_UwaLauncher.OpenUI()
end, true, "UWA\228\184\141\230\148\175\230\140\129\232\135\170\229\183\177\230\142\167\229\136\182\231\149\140\233\157\162\231\154\132\230\152\190\231\164\186\233\154\144\232\151\143")
helper.RegisterButton("GM Tools", "\229\155\158\229\136\176\229\189\147\229\137\141\231\172\172\228\184\128\228\184\170UI", function()
  L_UI:backToRoot()
end, true, "\231\148\168\230\157\165\230\181\139\232\175\149\229\188\186\229\136\182\229\155\158\229\136\176\231\172\172\228\184\128\228\184\170UI")
helper.RegisterButton("GM Tools", "\229\155\158\229\136\176\231\153\187\229\189\149\231\149\140\233\157\162", function()
  L_WorldManager:dispose()
  L_LoginManager:logoutAccount()
end, true, "\231\148\168\230\157\165\230\181\139\232\175\149\229\188\186\229\136\182\229\155\158\231\153\187\229\189\149\231\149\140\233\157\162")
helper.RegisterToggle("GM Tools", "\229\188\128\229\144\175/\233\154\144\232\151\143UI\231\149\140\233\157\162", function()
  return debugActions.getUIVisible()
end, function(isOn)
  debugActions.setUIVisible(isOn)
end, false, "\233\128\154\232\191\135\228\191\174\230\148\185UI\231\155\184\230\156\186\231\154\132CullingMask\230\157\165\230\142\167\229\136\182\230\152\190\231\164\186/\233\154\144\232\151\143UI\231\149\140\233\157\162")
helper.RegisterInput("GM Tools", "\230\137\167\232\161\140Lua\228\187\163\231\160\129", function(inputStr)
  debugActions.exeLuaScriptString(inputStr)
end, true, "\232\190\147\229\133\165\232\166\129\230\137\167\232\161\140\231\154\132lua\228\187\163\231\160\129")
helper.RegisterInput("GM Tools", "\232\191\189\232\184\170\229\156\176\229\155\190\229\175\185\232\177\161", function(inputStr)
  local worldMapTpl = L_GameTpl:getWorldMapTpl()
  local sceneId = AzurWorldInstance.CurWorldId
  local areaId = L_AreaStore:getMapAreaId()
  local tpl = worldMapTpl:getTplById(sceneId, tonumber(inputStr))
  if tpl then
    L_AzurMediator.createMapMark(areaId, worldMapTpl:getPosition(tpl))
  else
    error("\230\137\190\228\184\141\229\136\176\229\156\176\229\155\190\229\175\185\232\177\161" .. areaId .. "-" .. sceneId .. "-" .. tonumber(inputStr))
  end
end, true, "\232\190\147\229\133\165\232\166\129\232\191\189\232\184\170\231\154\132worldObjId")
helper.RegisterButton("GM Tools", "\229\188\128\229\133\179\229\141\143\232\174\174Log\230\137\147\229\141\176", function()
  local netLogOpen = Unity.PlayerPrefs.GetInt("KEY_NetLogOpen_ENABLE", 0) == 1
  if netLogOpen then
    Unity.PlayerPrefs.SetInt("KEY_NetLogOpen_ENABLE", 0)
  else
    Unity.PlayerPrefs.SetInt("KEY_NetLogOpen_ENABLE", 1)
  end
  Unity.PlayerPrefs.Save()
end, true, "\229\188\128\229\133\179\229\141\143\232\174\174\231\154\132Log\230\137\147\229\141\176")
helper.RegisterButton("\230\128\167\232\131\189\232\176\131\232\175\149", "ParticleSystem\230\149\176\233\135\143\231\187\159\232\174\161", function()
  local allPsArray = C_UnityObject.FindObjectsOfType(typeof(Unity.ParticleSystem), true)
  errorf("ParticleSystem Count: " .. tostring(allPsArray.Length))
end, true, "\229\140\133\229\144\171Inactive")
helper.RegisterButton("\229\174\182\229\155\173\231\155\184\229\133\179", "\228\184\128\233\148\174\232\128\149\229\156\176", function()
  local blockId = 1002
  local _homeTileTpl = L_GameTpl:getHomeTileTpl()
  local tpl = _homeTileTpl:getTplById(blockId)
  local cropMap = _homeTileTpl:getCropTileList(tpl)
  local baseId = 1002 * math.pow(2, 32)
  local args = {}
  for _, id in ipairs(cropMap) do
    table.insert(args, tostring(baseId + id))
  end
  local msg = {command = "HOMEFIELD", args = args}
  L_Net:sendMessage(MsgGenCode.CSProtoGMCommand, msg)
end, true)
helper.RegisterInput("\229\174\182\229\155\173\231\155\184\229\133\179", "\228\184\128\233\148\174\230\146\173\231\167\141", function(str)
  local msg = {
    command = "HOMECROP",
    args = {str}
  }
  L_Net:sendMessage(MsgGenCode.CSProtoGMCommand, msg)
end, true)
helper.RegisterButton("\229\174\182\229\155\173\231\155\184\229\133\179", "\228\184\128\233\148\174\230\136\144\231\134\159", function()
  local msg = {
    command = "HOMEHARVEST"
  }
  L_Net:sendMessage(MsgGenCode.CSProtoGMCommand, msg)
end, true)
helper.RegisterButton("\229\174\182\229\155\173\231\155\184\229\133\179", "\228\184\128\233\148\174\230\183\187\229\138\160\230\140\135\229\174\154\229\187\186\231\173\145", function()
  local msg = {
    command = "SUPERCMD",
    args = {"13"}
  }
  L_Net:sendMessage(MsgGenCode.CSProtoGMCommand, msg, nil)
end, true)
helper.RegisterInput("\229\174\182\229\155\173\231\155\184\229\133\179", "\232\167\163\233\148\129\231\167\145\230\138\128", function(inputStr)
  debugActions.SendGMCommand("UnlockTech " .. tostring(inputStr))
end, true, "\229\161\1711\230\152\175\229\183\165\228\184\154  2\230\152\175\229\134\156\228\184\154  3\230\152\175\233\135\135\233\155\134\228\184\154  4\230\152\175\231\149\156\231\137\167\228\184\154")
helper.RegisterInput("\229\174\182\229\155\173\231\155\184\229\133\179", "\230\184\133\231\169\186\229\183\178\232\167\163\233\148\129\231\167\145\230\138\128", function(inputStr)
  debugActions.SendGMCommand("LockTech " .. tostring(inputStr))
end, true, "\229\161\1711\230\152\175\229\183\165\228\184\154  2\230\152\175\229\134\156\228\184\154  3\230\152\175\233\135\135\233\155\134\228\184\154  4\230\152\175\231\149\156\231\137\167\228\184\154")
helper.RegisterInput("\229\174\182\229\155\173\231\155\184\229\133\179", "\232\174\190\231\189\174\231\167\145\230\138\128\231\173\137\231\186\167", function(inputStr)
  local techTotal = string.split(inputStr, " ")
  local techType = tonumber(techTotal[1])
  local techLv = tonumber(techTotal[2])
  debugActions.SendGMCommand("SetTechLv " .. tostring(techType) .. " " .. tostring(techLv))
end, true, "\229\143\130\230\149\1761: 1\230\152\175\229\183\165\228\184\154  2\230\152\175\229\134\156\228\184\154  3\230\152\175\233\135\135\233\155\134\228\184\154  4\230\152\175\231\149\156\231\137\167\228\184\154 \229\143\130\230\149\1762\239\188\154\229\133\183\228\189\147\231\173\137\231\186\167")
helper.RegisterInput("\229\174\182\229\155\173\231\155\184\229\133\179", "\229\138\160\231\167\145\230\138\128\231\187\143\233\170\140", function(inputStr)
  local techTotal = string.split(inputStr, " ")
  local techType = tonumber(techTotal[1])
  local techExp = tonumber(techTotal[2])
  debugActions.SendGMCommand("AddTechExp " .. tostring(techType) .. " " .. tostring(techExp))
end, true, "\229\143\130\230\149\1761: 1\230\152\175\229\183\165\228\184\154  2\230\152\175\229\134\156\228\184\154  3\230\152\175\233\135\135\233\155\134\228\184\154  4\230\152\175\231\149\156\231\137\167\228\184\154 \229\143\130\230\149\1762\239\188\154\229\133\183\228\189\147\231\187\143\233\170\140\229\128\188")
helper.RegisterInput("\229\174\182\229\155\173\231\155\184\229\133\179", "\229\138\160\231\167\145\230\138\128\231\162\142\231\137\135", function(inputStr)
  local techTotal = string.split(inputStr, " ")
  local techType = tonumber(techTotal[1])
  local techExp = tonumber(techTotal[2])
  debugActions.SendGMCommand("AddTechPoint " .. tostring(techType) .. " " .. tostring(techExp))
end, true, "\229\143\130\230\149\1761: 1\230\152\175\229\183\165\228\184\154  2\230\152\175\229\134\156\228\184\154  3\230\152\175\233\135\135\233\155\134\228\184\154  4\230\152\175\231\149\156\231\137\167\228\184\154 \229\143\130\230\149\1762\239\188\154\229\133\183\228\189\147\231\162\142\231\137\135\229\128\188")
helper.RegisterInput("\229\174\182\229\155\173\231\155\184\229\133\179", "\232\174\190\231\189\174\229\174\160\231\137\169\233\165\177\232\133\185\229\128\188", function(inputStr)
  local param = string.split(inputStr, " ")
  local petGuid = tonumber(param[1])
  local petSatiety = tonumber(param[2])
  debugActions.SendGMCommand("SETPETSATIETY " .. petGuid .. " " .. petSatiety)
end, true, "\229\143\130\230\149\1761:\229\174\160\231\137\169guid \229\143\130\230\149\1762\239\188\154\233\165\177\232\133\185\229\128\188")
helper.RegisterButton("\229\174\182\229\155\173\231\155\184\229\133\179", "\229\174\140\230\136\144\232\167\163\233\148\129\231\167\145\230\138\128\228\187\187\229\138\161", function()
  local msg = {
    command = "ADDTASK",
    args = {"99010004"}
  }
  L_Net:sendMessage(MsgGenCode.CSProtoGMCommand, msg, nil)
  local msg = {
    command = "TASKFINISH",
    args = {"99010004"}
  }
  L_Net:sendMessage(MsgGenCode.CSProtoGMCommand, msg, nil)
end, true)
helper.RegisterButton("\230\128\167\232\131\189\230\181\139\232\175\149GM", "\230\137\128\230\156\137\232\167\146\232\137\178+\229\174\160\231\137\169+\231\129\181\229\173\144+\233\129\147\229\133\183+\232\163\133\229\164\135+\232\167\146\232\137\178\231\173\137\231\186\16740\231\186\167+\229\174\182\229\155\173\229\187\186\231\173\145", function()
  local count = 1
  Timer.once(count * 0.1, function()
    local heroList = {
      109001,
      109002,
      199003,
      107001,
      108001,
      111001,
      104001,
      101004,
      108002,
      108003,
      101006
    }
    local msg_hero = {
      cmds = {}
    }
    for i = 1, #heroList do
      local heroId = heroList[i]
      local cmd = {
        command = "ADDITEM",
        args = {
          "1",
          tostring(heroId),
          "1",
          "1"
        }
      }
      table.insert(msg_hero.cmds, cmd)
    end
    L_Net:sendMessage(MsgGenCode.CSProtoGMCommands, msg_hero, nil)
  end)
  count = count + 1
  Timer.once(count * 0.1, function()
    local petList = {
      500001,
      500004,
      500007,
      500022,
      500024,
      500025,
      500026,
      500035
    }
    local msg_pet = {
      cmds = {}
    }
    for i = 1, #petList do
      local petId = petList[i]
      local cmd = {
        command = "ADDITEM",
        args = {
          "5",
          tostring(petId),
          "1"
        }
      }
      table.insert(msg_pet.cmds, cmd)
    end
    L_Net:sendMessage(MsgGenCode.CSProtoGMCommands, msg_pet, nil)
  end)
  count = count + 1
  Timer.once(count * 0.1, function()
    local homebuildingList = {
      10011,
      10012,
      40011,
      20021,
      20041
    }
    local msg_homebuilding = {
      cmds = {}
    }
    for i = 1, #homebuildingList do
      local homebuildingId = homebuildingList[i]
      local args = {
        "13",
        tostring(homebuildingId),
        "1"
      }
      if homebuildingId == 20041 then
        args = {
          "13",
          tostring(homebuildingId),
          "20"
        }
      end
      local cmd = {command = "ADDITEM", args = args}
      table.insert(msg_homebuilding.cmds, cmd)
    end
    L_Net:sendMessage(MsgGenCode.CSProtoGMCommands, msg_homebuilding, nil)
  end)
  count = count + 1
  Timer.once(count * 0.1, function()
    local homeItemList = {
      310001,
      310002,
      310004,
      310006,
      300001,
      301002,
      350000,
      350001,
      310003,
      310005,
      304003
    }
    local msg_homeItem = {
      cmds = {}
    }
    for i = 1, #homeItemList do
      local homeItemId = homeItemList[i]
      local args = {
        "3",
        tostring(homeItemId),
        "10"
      }
      if homeItemId == 310003 or homeItemId == 310005 then
        args = {
          "3",
          tostring(homeItemId),
          "999"
        }
      end
      local cmd = {command = "ADDITEM", args = args}
      table.insert(msg_homeItem.cmds, cmd)
    end
    L_Net:sendMessage(MsgGenCode.CSProtoGMCommands, msg_homeItem, nil)
  end)
  count = count + 1
  Timer.once(count * 0.1, function()
    local msg = {
      command = "SUPERCMD",
      args = {"12"}
    }
    L_Net:sendMessage(MsgGenCode.CSProtoGMCommand, msg, nil)
  end)
  count = count + 1
  Timer.once(count * 0.1, function()
    local msg = {
      command = "HEROSTARAll",
      args = {"3"}
    }
    L_Net:sendMessage(MsgGenCode.CSProtoGMCommand, msg, nil)
  end)
  count = count + 1
  Timer.once(count * 0.1, function()
    debugActions.SendGMCommand("SETACLV 30")
  end)
  local msg = {
    command = "SUPERCMD",
    args = {"15"}
  }
  L_Net:sendMessage(MsgGenCode.CSProtoGMCommand, msg, nil)
  local msg = {
    command = "SUPERCMD",
    args = {"5"}
  }
  L_Net:sendMessage(MsgGenCode.CSProtoGMCommand, msg, nil)
  local msg = {
    command = "SUPERCMD",
    args = {"9"}
  }
  L_Net:sendMessage(MsgGenCode.CSProtoGMCommand, msg, nil)
  debugActions.SendGMCommand("ADDITEM 10 2 798000")
  debugActions.SendGMCommand("ADDITEM 10 10 1005")
  local itemsTotal = {
    604001,
    601001,
    600001,
    604002,
    604003,
    604004,
    604005,
    604006,
    601002,
    600002,
    604007,
    604008,
    604009,
    604010,
    604011,
    601003,
    600003,
    604012,
    604013,
    604014,
    604015,
    601004,
    600004,
    403000,
    403001,
    403002
  }
  for k, v in ipairs(itemsTotal) do
    Timer.once(k * 0.2, function()
      debugActions.SendGMCommand("ADDITEM 3 " .. tostring(v) .. " 500")
    end)
  end
end, true)
helper.RegisterInput("\232\167\146\232\137\178\229\184\184\231\148\168GM\230\140\135\228\187\164", "\232\174\190\231\189\174\230\140\135\229\174\154\232\167\146\232\137\178\231\173\137\231\186\167[heroid] [herolv]", function(input)
  debugActions.SendGMCommand("HEROLV " .. tostring(input))
end, true, "\232\167\146\232\137\178id  \232\167\146\232\137\178lv")
helper.RegisterInput("\232\167\146\232\137\178\229\184\184\231\148\168GM\230\140\135\228\187\164", "\230\137\128\230\156\137\232\167\146\232\137\178\229\141\135\229\136\176\230\140\135\229\174\154\231\173\137\231\186\167", function(input)
  debugActions.SendGMCommand("ALLHEROLV " .. tostring(input))
end, true, "\229\166\130\230\158\156\232\166\129\229\141\135\229\136\17610\231\186\167\231\155\180\230\142\165\229\161\17110\229\141\179\229\143\175")
helper.RegisterInput("\232\167\146\232\137\178\229\184\184\231\148\168GM\230\140\135\228\187\164", "\232\174\190\231\189\174\230\140\135\229\174\154\229\174\160\231\137\169\231\173\137\231\186\167[heroid] [herolv]", function(input)
  debugActions.SendGMCommand("PETLV " .. tostring(input))
end, true, "\229\174\160\231\137\169id  \229\174\160\231\137\169lv")
helper.RegisterInput("\232\167\146\232\137\178\229\184\184\231\148\168GM\230\140\135\228\187\164", "\230\137\128\230\156\137\229\174\160\231\137\169\229\141\135\229\136\176\230\140\135\229\174\154\231\173\137\231\186\167", function(input)
  debugActions.SendGMCommand("ALLPETLV " .. tostring(input))
end, true, "\229\166\130\230\158\156\232\166\129\229\141\135\229\136\17610\231\186\167\231\155\180\230\142\165\229\161\17110\229\141\179\229\143\175")
helper.RegisterButton("\232\167\146\232\137\178\229\184\184\231\148\168GM\230\140\135\228\187\164", "\230\183\187\229\138\160\230\137\128\230\156\137\232\167\146\232\137\178", function()
  local msg = {
    command = "SUPERCMD",
    args = {"1"}
  }
  L_Net:sendMessage(MsgGenCode.CSProtoGMCommand, msg, nil)
  debugActions.SendGMCommand("ADDITEM 1 111001 1 1")
end, true)
helper.RegisterButton("\232\167\146\232\137\178\229\184\184\231\148\168GM\230\140\135\228\187\164", "\233\135\145\229\184\129+100000", function()
  local msg = {
    command = "ADDITEM",
    args = {
      "10",
      "2",
      "100000"
    }
  }
  L_Net:sendMessage(MsgGenCode.CSProtoGMCommand, msg, nil)
end, true)
helper.RegisterButton("\232\167\146\232\137\178\229\184\184\231\148\168GM\230\140\135\228\187\164", "\229\143\170\230\183\187\229\138\160\232\167\146\232\137\178\229\141\135\231\186\167\231\154\132\230\157\144\230\150\153*1000", function()
  local herolvItem = {}
  for v = 400000, 400003 do
    table.insert(herolvItem, v)
  end
  for k, v in ipairs(herolvItem) do
    Timer.once(k * 0.2, function()
      debugActions.SendGMCommand("ADDITEM 3 " .. tostring(v) .. " 1000")
    end)
  end
end, true)
helper.RegisterButton("\232\167\146\232\137\178\229\184\184\231\148\168GM\230\140\135\228\187\164", "\230\183\187\229\138\160\230\137\128\230\156\137\231\154\132\232\139\177\233\155\132\231\129\181\229\173\144", function()
  local msg = {
    command = "SUPERCMD",
    args = {"9"}
  }
  L_Net:sendMessage(MsgGenCode.CSProtoGMCommand, msg, nil)
end, true)
helper.RegisterButton("\232\167\146\232\137\178\229\184\184\231\148\168GM\230\140\135\228\187\164", "\229\143\170\230\183\187\229\138\160\231\129\181\229\173\144\229\141\135\231\186\167\231\154\132\230\157\144\230\150\153*1000", function()
  local spiritlvItem = {}
  for v = 403000, 403002 do
    table.insert(spiritlvItem, v)
  end
  for k, v in ipairs(spiritlvItem) do
    Timer.once(k * 0.2, function()
      debugActions.SendGMCommand("ADDITEM 3 " .. tostring(v) .. " 1000")
    end)
  end
end, true)
helper.RegisterButton("\232\167\146\232\137\178\229\184\184\231\148\168GM\230\140\135\228\187\164", "\229\143\170\230\183\187\229\138\160\231\129\181\229\173\144\231\170\129\231\160\180\231\154\132\230\157\144\230\150\153*500", function()
  local spiritUpItem = {}
  for v = 600001, 600004 do
    table.insert(spiritUpItem, v)
  end
  for v = 601001, 601004 do
    table.insert(spiritUpItem, v)
  end
  for v = 604001, 604015 do
    table.insert(spiritUpItem, v)
  end
  for k, v in ipairs(spiritUpItem) do
    Timer.once(k * 0.2, function()
      debugActions.SendGMCommand("ADDITEM 3 " .. tostring(v) .. " 500")
    end)
  end
end, true)
helper.RegisterInput("\232\167\146\232\137\178\229\184\184\231\148\168GM\230\140\135\228\187\164", "\229\162\158\229\138\160\230\140\135\229\174\154\232\167\146\232\137\178\230\152\159\230\158\157 [heroId] [count]", function(inputStr)
  local msg = {
    command = "HEROSTAR",
    args = string.split(inputStr, " ")
  }
  L_Net:sendMessage(MsgGenCode.CSProtoGMCommand, msg, nil)
end, true, "\232\167\146\232\137\178id / \229\162\158\229\138\160\231\154\132\230\149\176\233\135\143")
helper.RegisterInput("\232\167\146\232\137\178\229\184\184\231\148\168GM\230\140\135\228\187\164", "\229\162\158\229\138\160\230\137\128\230\156\137\232\167\146\232\137\178\230\152\159\230\158\157 [count]", function(inputStr)
  local msg = {
    command = "HEROSTARAll",
    args = string.split(inputStr, " ")
  }
  L_Net:sendMessage(MsgGenCode.CSProtoGMCommand, msg, nil)
end, true, "\229\162\158\229\138\160\229\135\160\231\186\167")
helper.RegisterButton("\232\167\146\232\137\178\229\184\184\231\148\168GM\230\140\135\228\187\164", "\230\139\137\230\187\161\230\137\128\230\156\137\232\167\146\232\137\178\230\152\159\230\158\157", function()
  local msg = {
    command = "HEROSTARAll",
    args = {"10000"}
  }
  L_Net:sendMessage(MsgGenCode.CSProtoGMCommand, msg, nil)
end, true)
helper.RegisterButton("\232\167\146\232\137\178\229\184\184\231\148\168GM\230\140\135\228\187\164", "\230\152\159\232\175\134\231\173\137\231\186\167\229\141\135\229\136\17610\231\186\167", function()
  debugActions.SendGMCommand("SETACLV 10")
end, true)
helper.RegisterButton("\232\167\146\232\137\178\229\184\184\231\148\168GM\230\140\135\228\187\164", "\230\152\159\232\175\134\231\173\137\231\186\167\229\141\135\229\136\17620\231\186\167", function()
  debugActions.SendGMCommand("SETACLV 20")
end, true)
helper.RegisterButton("\232\167\146\232\137\178\229\184\184\231\148\168GM\230\140\135\228\187\164", "\230\152\159\232\175\134\231\173\137\231\186\167\229\141\135\229\136\17630\231\186\167", function()
  debugActions.SendGMCommand("SETACLV 30")
end, true)
helper.RegisterInput("\232\167\146\232\137\178\229\184\184\231\148\168GM\230\140\135\228\187\164", "\232\174\190\231\189\174\230\152\159\232\175\134\231\173\137\231\186\167[lv]", function(input)
  debugActions.SendGMCommand("SETACLV " .. tostring(input))
end, true, "\230\152\159\232\175\134lv")
helper.RegisterInput("\232\167\146\232\137\178\229\184\184\231\148\168GM\230\140\135\228\187\164", "\229\162\158\229\138\160\232\167\146\232\137\178\229\165\189\230\132\159 [heroId] [count]", function(inputStr)
  local msg = {
    command = "ADDHEROFAVOREXP",
    args = string.split(inputStr, " ")
  }
  L_Net:sendMessage(MsgGenCode.CSProtoGMCommand, msg, nil)
end, true, "\232\167\146\232\137\178id / \229\162\158\229\138\160\231\154\132\230\149\176\233\135\143")
helper.RegisterButton("\232\167\146\232\137\178\229\184\184\231\148\168GM\230\140\135\228\187\164", "\230\137\147\229\188\128FPS\231\149\140\233\157\162", function()
  L_UI:open("pageFps")
end, true)
helper.RegisterButton("\232\167\146\232\137\178\229\184\184\231\148\168GM\230\140\135\228\187\164", "\228\184\128\233\148\174\229\162\158\229\138\160\229\149\134\229\186\151\231\155\184\229\133\179\232\180\167\229\184\129", function()
  local moneyList = {
    502000,
    502001,
    100000
  }
  for k, v in ipairs(moneyList) do
    Timer.once(k * 0.1, function()
      debugActions.SendGMCommand("ADDITEM 3 " .. tostring(v) .. " 10000")
    end)
  end
  local currencyList = {
    1,
    2,
    901,
    102
  }
  for k, v in ipairs(currencyList) do
    Timer.once(k * 0.1, function()
      debugActions.SendGMCommand("ADDITEM 10 " .. tostring(v) .. " 10000")
    end)
  end
end, true)
helper.RegisterButton("\232\167\146\232\137\178\229\184\184\231\148\168GM\230\140\135\228\187\164", "\228\184\128\233\148\174\229\162\158\229\138\160\230\138\189\229\141\161\233\129\147\229\133\183", function()
  local moneyList = {501000, 501001}
  for k, v in ipairs(moneyList) do
    Timer.once(k * 0.1, function()
      debugActions.SendGMCommand("ADDITEM 3 " .. tostring(v) .. " 10000")
    end)
  end
end, true)
helper.RegisterInput("\232\167\146\232\137\178\229\184\184\231\148\168GM\230\140\135\228\187\164", "\232\174\190\231\189\174\230\137\128\230\156\137\232\163\133\229\164\135\231\173\137\231\186\167[lv]", function(input)
  debugActions.SendGMCommand("SETALLOLV " .. tostring(input))
end, true, "\232\163\133\229\164\135LV,\232\166\129\232\174\190\231\189\1745\231\186\167\231\155\180\230\142\165\229\161\1715")
helper.RegisterButton("\232\167\146\232\137\178\229\184\184\231\148\168GM\230\140\135\228\187\164", "\232\167\163\233\148\129\230\137\128\230\156\137\230\152\159\232\132\137\230\180\187\232\183\131\229\186\166\231\173\137\231\186\167", function()
  local worldDiffcultyTpl = L_GameTpl:getWorldDifficultyTpl()
  local tpl = worldDiffcultyTpl:getTplList()
  local new_tpl = {}
  local taskId_set = {}
  for k, v in pairs(tpl) do
    if not taskId_set[v.taskId] then
      taskId_set[v.taskId] = true
      table.insert(new_tpl, v.taskId)
    end
  end
  for k, v in pairs(new_tpl) do
    if v ~= 0 then
      local msg = {
        command = "ADDTASK",
        args = {
          tostring(v)
        }
      }
      L_Net:sendMessage(MsgGenCode.CSProtoGMCommand, msg, nil)
    end
  end
  for k, v in pairs(new_tpl) do
    local msg = {
      command = "TASKFINISH",
      args = {
        tostring(v)
      }
    }
    L_Net:sendMessage(MsgGenCode.CSProtoGMCommand, msg, nil)
  end
end, true)
helper.RegisterButton("\232\167\146\232\137\178\229\184\184\231\148\168GM\230\140\135\228\187\164", "\232\167\163\233\148\129\230\137\128\230\156\137\229\165\135\230\179\162\229\175\185\230\136\152\229\133\179\229\141\161(\231\174\128\229\141\149\230\168\161\229\188\143&\229\155\176\233\154\190\230\168\161\229\188\143)", function()
  debugActions.SendGMCommand("UnlockAllKiboDuel")
end, true)
helper.RegisterButton("\229\174\160\231\137\169\229\184\184\231\148\168GM\230\140\135\228\187\164", "\230\183\187\229\138\160\230\137\128\230\156\137\229\143\175\231\148\168\229\174\160\231\137\169", function()
  local msg = {
    command = "SUPERCMD",
    args = {"8"}
  }
  L_Net:sendMessage(MsgGenCode.CSProtoGMCommand, msg, nil)
end, true)
helper.RegisterButton("\229\174\160\231\137\169\229\184\184\231\148\168GM\230\140\135\228\187\164", "\230\183\187\229\138\160\230\137\128\230\156\137\229\174\160\231\137\169\232\155\139", function()
  local msg = {
    command = "SUPERCMD",
    args = {"6"}
  }
  L_Net:sendMessage(MsgGenCode.CSProtoGMCommand, msg, nil)
end, true)
helper.RegisterInput("\229\174\160\231\137\169\229\184\184\231\148\168GM\230\140\135\228\187\164", "\229\136\160\233\153\164\229\141\149\228\184\170\229\174\160\231\137\169\232\155\139", function(input)
  local data = {
    egg_list = {
      [1] = input
    }
  }
  L_Net:sendMessage(MsgGenCode.CSProtoDelEgg, data)
end, true, "\232\190\147\229\133\165\229\174\160\231\137\169guid")
helper.RegisterButton("\229\174\160\231\137\169\229\184\184\231\148\168GM\230\140\135\228\187\164", "\229\136\160\233\153\164\230\137\128\230\156\137\229\174\160\231\137\169\232\155\139", function()
  local total = L_PetStore:getAllPetEggGuid()
  for k, v in pairs(total) do
    Timer.once(k * 0.1, function()
      local data = {
        egg_list = {
          [1] = v
        }
      }
      L_Net:sendMessage(MsgGenCode.CSProtoDelEgg, data)
    end)
  end
end, true)
helper.RegisterInput("\229\174\160\231\137\169\229\184\184\231\148\168GM\230\140\135\228\187\164", "\228\191\174\230\148\185\229\174\160\231\137\169\229\177\158\230\128\167\229\128\188", function(inputStr)
  local pettotal = string.split(inputStr, " ")
  local petguid = tonumber(pettotal[1])
  local petattrid = tonumber(pettotal[2])
  local petattr = tonumber(pettotal[3])
  debugActions.SendGMCommand("SETPETCOM " .. tostring(petguid) .. " " .. tostring(petattrid) .. " " .. tostring(petattr))
end, true, "\232\190\147\229\133\165\229\174\160\231\137\169guid \229\174\160\231\137\169\229\177\158\230\128\167 \229\177\158\230\128\167\229\128\188(pet_learningtalent.xlsx)")
helper.RegisterButton("\229\174\160\231\137\169\229\184\184\231\148\168GM\230\140\135\228\187\164", "\230\148\190\231\148\159\230\137\128\230\156\137\229\143\175\230\148\190\231\148\159\231\154\132\229\165\135\230\179\162", function()
  local petList = L_PetStore:getPetList()
  local petNewList = {}
  local petFinalList = {}
  for k, v in pairs(petList) do
    if v.work_status == 0 and v.hero_id == 0 and not petNewList[v.guid] then
      petNewList[v.guid] = v.id
    end
  end
  for k, v in pairs(petNewList) do
    local petTpl = L_GameTpl:getPetTpl()
    local tpl = petTpl:getTplById(v)
    local rename = petTpl:getIsRename(tpl)
    if rename == true then
      table.insert(petFinalList, k)
    end
  end
  if 0 < #petFinalList then
    local data = {pet_list = petFinalList}
    L_Net:sendMessage(MsgGenCode.CSProtoDelPet, data)
  else
    L_FlyMsgManager:showNormalMsg(L_WordsTpl:getValue("ui_pet_release_quick_empty"))
    return
  end
end, true)
helper.RegisterInput("\229\174\160\231\137\169\229\184\184\231\148\168GM\230\140\135\228\187\164", "\229\162\158\229\138\160\230\159\144\228\184\170\229\174\160\231\137\169\231\187\143\233\170\140\229\128\188", function(inputStr)
  local pettotal = string.split(inputStr, " ")
  local petguid = tonumber(pettotal[1])
  local petexp = tonumber(pettotal[2])
  debugActions.SendGMCommand("ADDPETEXP " .. tostring(petguid) .. " " .. tostring(petexp))
end, true, "\232\190\147\229\133\165\229\174\160\231\137\169guid \229\174\160\231\137\169\230\137\128\233\156\128\232\166\129\229\162\158\229\138\160\231\154\132\231\187\143\233\170\140\229\128\188")
helper.RegisterInput("\229\174\160\231\137\169\229\184\184\231\148\168GM\230\140\135\228\187\164", "\229\162\158\229\138\160\230\159\144\228\184\170\229\174\160\231\137\169\229\165\189\230\132\159\229\186\166", function(inputStr)
  local pettotal = string.split(inputStr, " ")
  local petguid = tonumber(pettotal[1])
  local petexp = tonumber(pettotal[2])
  debugActions.SendGMCommand("ADDPETFAVOR " .. tostring(petguid) .. " " .. tostring(petexp))
end, true, "\232\190\147\229\133\165\229\174\160\231\137\169guid \229\174\160\231\137\169\230\137\128\233\156\128\232\166\129\229\162\158\229\138\160\231\154\132\229\165\189\230\132\159\229\186\166\231\187\143\233\170\140\229\128\188")
helper.RegisterButton("\229\174\160\231\137\169\229\184\184\231\148\168GM\230\140\135\228\187\164", "\230\183\187\229\138\160\230\137\128\230\156\137\229\143\175\231\148\168\233\151\170\229\133\137\229\165\135\230\179\162", function()
  debugActions.SendGMCommand("ADDSPECPET")
end, true)
helper.RegisterButton("\229\174\160\231\137\169\229\184\184\231\148\168GM\230\140\135\228\187\164", "\230\137\147\229\141\176\229\156\176\229\155\190\228\184\138\230\137\128\230\156\137\229\165\135\231\137\185\229\165\135\230\179\162", function()
  debugActions.SendGMCommand("AllSpecialMonster")
end, true)
helper.RegisterButton("\230\136\152\230\150\151\231\155\184\229\133\179", "\231\155\180\230\142\165\233\128\128\229\135\186\230\136\152\230\150\151", function()
  local worldBattle = L_UI:getPage("pageWorldBattlePC")
  if worldBattle ~= nil then
    C_BattleManager.ForceOutBattle()
  else
    L_FlyMsgManager:showNormalMsg(L_WordsTpl:getValue("ui_onlyFight"))
  end
end, true)
helper.RegisterInput("\230\136\152\230\150\151\231\155\184\229\133\179", "\232\174\190\231\189\174\230\128\170\231\137\169\228\184\187\230\142\167", function(inputStr)
  local monsterId = tonumber(inputStr)
  if monsterId == nil then
    monsterId = 310001
  end
  local data = {tran_id = monsterId}
  L_Net:sendMessage(MsgGenCode.CSProtoTransformStart, data, function(rspData, errorCode)
  end)
end, true)
helper.RegisterButton("\230\136\152\230\150\151\231\155\184\229\133\179", "\233\128\128\229\135\186\232\174\190\231\189\174\230\128\170\231\137\169\228\184\187\230\142\167", function()
  L_Net:sendMessage(MsgGenCode.CSProtoTransformEnd, {}, function(rspData, errorCode)
  end)
end, true)
helper.RegisterButton("\230\136\152\230\150\151\231\155\184\229\133\179", "\229\188\128\229\144\175\230\136\152\230\150\151profiler", function()
  C_ProfilerTool.Open()
end, true)
helper.RegisterButton("\230\136\152\230\150\151\231\155\184\229\133\179", "\229\133\179\233\151\173\230\136\152\230\150\151profiler", function()
  C_ProfilerTool.Close()
end, true)
helper.RegisterButton("\230\180\187\232\183\131\229\186\166\228\187\187\229\138\161\231\155\184\229\133\179", "\229\174\140\230\136\144\230\175\143\230\151\165\230\180\187\232\183\131\229\186\166\230\137\128\230\156\137\228\187\187\229\138\161", function()
  local activityTpl = L_GameTpl:getActivityTpl()
  local tpl = activityTpl:getAllData(1)
  for k, v in pairs(tpl) do
    local id = v.id
    local para = v.para
    Timer.once(k * 0.1, function()
      debugActions.SendGMCommand("SETACTIVEVAL " .. tostring(id) .. " " .. tostring(para))
    end)
  end
end, true)
helper.RegisterButton("\230\180\187\232\183\131\229\186\166\228\187\187\229\138\161\231\155\184\229\133\179", "\229\174\140\230\136\144\230\175\143\229\145\168\230\180\187\232\183\131\229\186\166\230\137\128\230\156\137\228\187\187\229\138\161", function()
  local activityTpl = L_GameTpl:getActivityTpl()
  local tpl = activityTpl:getAllData(2)
  for k, v in pairs(tpl) do
    local id = v.id
    local para = v.para
    Timer.once(k * 0.1, function()
      debugActions.SendGMCommand("SETACTIVEVAL " .. tostring(id) .. " " .. tostring(para))
    end)
  end
end, true)
helper.RegisterButton("\230\139\141\231\133\167", "\232\142\183\229\143\150\230\168\161\230\157\191\229\143\130\230\149\176", function()
  if not L_PhotoManager:getMediator() then
    L_FlyMsgManager:showNormalMsg(L_WordsTpl:getValue("ui_noPhotoMode"))
    return
  end
  local id = 999999
  local type = L_Const.photoTemplateDataType.none
  L_PhotoManager:screenTemplateShot(id, true, true, function(bool, data, tex, name)
    local path = L_PhotoStore.path.tempBgSavePath .. "cellBg/" .. name
    L_FlyMsgManager:showNormalMsg(L_WordsTpl:getValue("notice_shearPlate", {
      [0] = path
    }))
    if bool then
      local data = L_PhotoManager:createPhotoWorldData(type, id, name)
      CS.UnityEngine.GUIUtility.systemCopyBuffer = data:toString()
    end
  end)
end, true)
helper.RegisterButton("\229\164\167\228\184\150\231\149\140\229\155\186\229\174\154\228\189\141\231\189\174\228\188\160\233\128\129", "\230\156\168_\232\138\177\232\139\158", function()
  debugActions.checkAndTransfer("-174 104 -310")
end, true)
helper.RegisterButton("\229\164\167\228\184\150\231\149\140\229\155\186\229\174\154\228\189\141\231\189\174\228\188\160\233\128\129", "\230\176\180_\232\174\184\230\132\191\230\177\160", function()
  debugActions.checkAndTransfer("-253.02 110.243 -320.73")
end, true)
helper.RegisterButton("\229\164\167\228\184\150\231\149\140\229\155\186\229\174\154\228\189\141\231\189\174\228\188\160\233\128\129", "\229\156\176_\231\162\142\232\163\130\229\178\169\231\159\179", function()
  debugActions.checkAndTransfer("-233.13 125.08 -442.95")
end, true)
helper.RegisterButton("\229\164\167\228\184\150\231\149\140\229\155\186\229\174\154\228\189\141\231\189\174\228\188\160\233\128\129", "\231\129\171_\231\188\160\231\187\149\231\159\179\231\162\145", function()
  debugActions.checkAndTransfer("-264.018 128.87 -490.873")
end, true)
helper.RegisterButton("\229\164\167\228\184\150\231\149\140\229\155\186\229\174\154\228\189\141\231\189\174\228\188\160\233\128\129", "\229\133\137_\231\169\186\230\180\158\231\159\179\231\162\145", function()
  debugActions.checkAndTransfer("-104.82 173.731 -755.21")
end, true)
helper.RegisterButton("\229\164\167\228\184\150\231\149\140\229\155\186\229\174\154\228\189\141\231\189\174\228\188\160\233\128\129", "\233\163\142_\232\144\189\229\143\182\229\160\134", function()
  debugActions.checkAndTransfer("-78.04 122.94 -429.35")
end, true)
helper.RegisterButton("\229\164\167\228\184\150\231\149\140\229\155\186\229\174\154\228\189\141\231\189\174\228\188\160\233\128\129", "\233\129\151\232\191\185\229\137\175\230\156\172-\230\154\151\231\132\176\229\133\189", function()
  debugActions.checkAndTransfer("-279.44 116.37 -405.13")
end, true)
helper.RegisterButton("\229\164\167\228\184\150\231\149\140\229\155\186\229\174\154\228\189\141\231\189\174\228\188\160\233\128\129", "\233\129\151\232\191\185\229\137\175\230\156\172-\230\163\174\229\189\169\231\129\181\232\157\182", function()
  debugActions.checkAndTransfer("-321.98 164.58 159.59")
end, true)
helper.RegisterButton("\229\164\167\228\184\150\231\149\140\229\155\186\229\174\154\228\189\141\231\189\174\228\188\160\233\128\129", "\233\129\151\232\191\185\229\137\175\230\156\172-\229\183\168\229\136\186\229\135\182\233\184\159", function()
  debugActions.checkAndTransfer("208.38 274.91 171.61")
end, true)
helper.RegisterButton("\229\164\167\228\184\150\231\149\140\229\155\186\229\174\154\228\189\141\231\189\174\228\188\160\233\128\129", "\233\129\151\232\191\185\229\137\175\230\156\172-\232\167\146\230\150\151\232\156\165", function()
  debugActions.checkAndTransfer("92.28 133.16 -477.74")
end, true)
helper.RegisterButton("\229\164\167\228\184\150\231\149\140\229\155\186\229\174\154\228\189\141\231\189\174\228\188\160\233\128\129", "\233\129\151\232\191\185\229\137\175\230\156\172-\233\147\129\233\172\131\233\156\184\228\184\187", function()
  debugActions.checkAndTransfer("-213.58 105.39 -363.59")
end, true)
helper.RegisterButton("\229\164\167\228\184\150\231\149\140\229\155\186\229\174\154\228\189\141\231\189\174\228\188\160\233\128\129", "\228\184\128\233\148\174\228\188\160\233\128\129\233\135\135\231\159\179\229\156\186", function()
  debugActions.checkAndTransfer("-115.11 119.62 -468.86")
end, true)
helper.RegisterButton("\229\164\167\228\184\150\231\149\140\229\155\186\229\174\154\228\189\141\231\189\174\228\188\160\233\128\129", "\228\184\128\233\148\174\228\188\160\233\128\129\233\135\135\231\159\191\229\156\186", function()
  debugActions.checkAndTransfer("-224.28 123.435 -450.91")
end, true)
helper.RegisterButton("\229\164\167\228\184\150\231\149\140\229\155\186\229\174\154\228\189\141\231\189\174\228\188\160\233\128\129", "\228\184\128\233\148\174\228\188\160\233\128\129\228\188\144\230\156\168\229\156\186", function()
  debugActions.checkAndTransfer("-223.017 138.62 -626.75")
end, true)
helper.RegisterButton("\229\164\167\228\184\150\231\149\140\229\155\186\229\174\154\228\189\141\231\189\174\228\188\160\233\128\129", "\228\184\128\233\148\174\228\188\160\233\128\129\233\146\147\233\177\188\231\130\185", function()
  debugActions.checkAndTransfer("-72.67 119.73 -478.18")
end, true)
