Files
GaCy-GO/tools/relic_schema_probe.lua
T

23 lines
1.3 KiB
Lua

-- Temporary targeted metadata probe. One named type per heartbeat, outside battle.
do
local names={'RelicConfigExcelTable','RelicMainAffixConfigExcelTable','RelicSubAffixConfigExcelTable','ItemConfigRelicExcelTable','EquipmentConfigExcelTable'}
local s=_G.__gacRelicSchema20261102 or {index=1}; _G.__gacRelicSchema20261102=s
if s.index>#names then return end
local flags=CS.System.Enum.ToObject(typeof(CS.System.Reflection.BindingFlags),60)
local manager=CS.RPG.Client.GlobalVars.s_GamePhaseManager
local phase=manager and typeof(CS.RPG.Client.GamePhaseManager):GetField('_CurrentPhase',flags):GetValue(manager)
if not phase or typeof(CS.RPG.Client.BattleGamePhase):IsInstanceOfType(phase) then return end
local name=names[s.index]
local ok,err=pcall(function()
local a=typeof(CS.RPG.GameCore.AvatarExcelTable).Assembly
local t=a:GetType('RPG.GameCore.'..name)
CS.UnityEngine.Debug.Log('[GAC_RELIC_SCHEMA] TYPE '..name..' '..tostring(t))
if t then
local methods=t:GetMethods(flags)
for i=0,math.min(methods.Length-1,39) do if methods[i].DeclaringType==t then CS.UnityEngine.Debug.Log('[GAC_RELIC_SCHEMA] METHOD '..tostring(methods[i])) end end
end
end)
if not ok then CS.UnityEngine.Debug.Log('[GAC_RELIC_SCHEMA] ERROR '..name..' '..tostring(err)) end
s.index=s.index+1
end