28 lines
1.4 KiB
Lua
28 lines
1.4 KiB
Lua
-- Named CW entry/sync targets only; metadata, no invocation or patching.
|
|||
|
|
do
|
||
|
|
if _G.__gacCwEntrySyncHandles20261020 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
|
||
|
|
_G.__gacCwEntrySyncHandles20261020=true
|
||
|
|
local log=function(v)CS.UnityEngine.Debug.Log('[GAC_CW_ENTRY_SYNC_HANDLE] '..tostring(v))end
|
||
|
|
local ok,err=pcall(function()
|
||
|
|
local a=typeof(CS.RPG.Client.GridFightModule).Assembly
|
||
|
|
local targets={
|
||
|
|
{'RPG.Client.GridFightModule','_OnGridFightGetDataScRsp'},
|
||
|
|
{'RPG.Client.GridFightModule','_SyncCurGame'},
|
||
|
|
{'RPG.Client.GridFightGameSession','Sync'},
|
||
|
|
{'RPG.Client.GridFightGameSession','_SyncInternal'},
|
||
|
|
{'RPG.Client.GridFightModule','_OnGridFightSyncUpdateResultScNotify'},
|
||
|
|
{'RPG.Client.GridFightRoleShop','Sync'},
|
||
|
|
{'RPG.Client.GridFightModule','_RecoverOldSession'}
|
||
|
|
}
|
||
|
|
for _,item in ipairs(targets)do
|
||
|
|
local t=a:GetType(item[1]);local m=t and t:GetMethod(item[2],flags)
|
||
|
|
if m then log(item[1]..' '..item[2]..' '..tostring(m.MethodHandle.Value)..' '..tostring(m))else log('MISSING '..item[1]..' '..item[2])end
|
||
|
|
end
|
||
|
|
log('END')
|
||
|
|
end)
|
||
|
|
if not ok then log('ERROR '..tostring(err))end
|
||
|
|
end
|