Files

33 lines
1.9 KiB
Lua
Raw Permalink Normal View History

2026-10-28 18:54:43 +07:00
-- Metadata only on two established types. Parameter names are current protocol
-- candidates: finding a consumer does not by itself establish request pairing.
-- Keep outside scripts/. No assembly scan, packet sends, hooks or state writes.
do local function capture()
local s=_G.__gacCwResponseConsumers1 or {target=1,index=0,beats=0};_G.__gacCwResponseConsumers1=s
if s.done then return end
s.beats=s.beats+1;if s.beats>100 then s.done=true;return end
local flags=CS.System.Enum.ToObject(typeof(CS.System.Reflection.BindingFlags),60)
local manager=CS.RPG.Client.GlobalVars.s_GamePhaseManager
local f=manager and manager:GetType():GetField('_CurrentPhase',flags)
local phase=f and f:GetValue(manager)
if not phase or typeof(CS.RPG.Client.BattleGamePhase):IsInstanceOfType(phase)then return end
local log=function(v)CS.UnityEngine.Debug.Log('[GAC_CW_RESPONSE_CONSUMER] '..tostring(v))end
if not s.methods then
if s.target==1 then s.t=typeof(CS.RPG.Client.GridFightModule)
elseif s.target==2 then s.t=typeof(CS.RPG.Client.NetworkManager)
else s.done=true;log('END');return end
s.methods=s.t:GetMethods(flags);s.index=0
log('TYPE '..s.t.FullName..' count='..s.methods.Length)
end
local start=CS.UnityEngine.Time.realtimeSinceStartup
for n=1,32 do
if s.index>=s.methods.Length then s.methods=nil;s.t=nil;s.target=s.target+1;return end
local m=s.methods[s.index];s.index=s.index+1
if m.DeclaringType==s.t then
local signature=tostring(m)
if signature:find('PNHDGCBLPGD',1,true)or signature:find('GDHFMHKFEAL',1,true)or signature:find('GridFightEnterBonfireScRsp',1,true)then
log('METHOD '..signature..' HANDLE '..tostring(m.MethodHandle.Value))
end
end
if CS.UnityEngine.Time.realtimeSinceStartup-start>0.002 then return end
end
end local ok,e=pcall(capture);if not ok then _G.__gacCwResponseConsumers1={done=true};CS.UnityEngine.Debug.Log('[GAC_CW_RESPONSE_CONSUMER] ERROR '..tostring(e))end end