pre cw with probe and a bunch script to read game behavior

This commit is contained in:
CAtlas0784 committed 2026-10-21 20:40:13 +07:00
1 parent 5120219ae2
commit da8a32f60d
310 files changed
+219693 -872

No files matched your search

@@ -0,0 +1,30 @@
-- Inspect only the named Peak module and configuration loader; no state writes.
do
local s=_G.__gacPeakCycleSchema1 or {phase=0,index=0};_G.__gacPeakCycleSchema1=s
local function log(v)CS.UnityEngine.Debug.Log('[GAC_PEAK_CYCLE_SCHEMA] '..tostring(v))end
if s.phase<3 then
local ok,err=pcall(function()
local flags=CS.System.Enum.ToObject(typeof(CS.System.Reflection.BindingFlags),60)
if s.phase==0 then
local m=CS.RPG.Client.GlobalVars.s_ModuleManager.ChallengePeakModule
s.module=m;s.fields=m:GetType():GetFields(flags);log('MODULE '..tostring(m:GetType()));s.phase=1
end
if s.phase==1 then
for i=s.index,math.min(s.index+15,s.fields.Length-1)do
local f=s.fields[i];log('FIELD '..f.Name..' '..tostring(f.FieldType))
if not f.IsStatic and (f.Name:lower():find('cycle') or f.Name:lower():find('settle') or f.Name:lower():find('result')) then
local good,v=pcall(function()return f:GetValue(s.module)end);if good then log('VALUE '..f.Name..' '..tostring(v))end
end
end
s.index=s.index+16;if s.index>=s.fields.Length then s.phase=2;s.index=0;s.methods=typeof(CS.RPG.GameCore.GameCoreConfigLoader):GetMethods(flags)end
elseif s.phase==2 then
for i=s.index,math.min(s.index+127,s.methods.Length-1)do
local m=s.methods[i];if m.Name:find('ChallengePeak',1,true)then log('LOADER '..tostring(m))end
end
s.index=s.index+128;if s.index>=s.methods.Length then s.phase=3;log('END')end
end
end)
if not ok then s.phase=3;log('ERROR '..tostring(err))end
end
end
@@ -0,0 +1,35 @@
do
local s=_G.__gacPeakNativeData1 or {phase=1,index=0};_G.__gacPeakNativeData1=s
local function log(v)CS.UnityEngine.Debug.Log('[GAC_PEAK_NATIVE_DATA] '..tostring(v))end
if s.phase<=3 then
local ok,err=pcall(function()
local flags=CS.System.Enum.ToObject(typeof(CS.System.Reflection.BindingFlags),60)
if s.phase==1 then
local obj=CS.RPG.Client.GlobalVars.s_ModuleManager.BattleModule.LastBattleStatistic
local methods=obj:GetType():GetMethods(flags)
for i=s.index,math.min(s.index+31,methods.Length-1)do log('STATS_METHOD '..tostring(methods[i]))end
s.index=s.index+32;if s.index>=methods.Length then s.phase=2;s.index=0 end
elseif s.phase==2 then
if not s.obj then
s.obj=CS.RPG.Client.GlobalVars.s_ModuleManager.ChallengePeakModule:GetChallengePeakBoss(104)
s.type=s.obj:GetType();s.fields=s.type:GetFields(flags);log('PEAK_TYPE '..tostring(s.type))
end
for i=s.index,math.min(s.index+15,s.fields.Length-1)do
local f=s.fields[i];log('PEAK_FIELD '..f.Name..' '..tostring(f.FieldType))
if not f.IsStatic and (f.Name:lower():find('target')or f.FieldType.IsPrimitive)then
local good,v=pcall(function()return f:GetValue(s.obj)end);if good then log('PEAK_VALUE '..f.Name..' '..tostring(v))end
end
end
s.index=s.index+16;if s.index>=s.fields.Length then
if s.type.BaseType and s.type.BaseType.Name=='ChallengePeak' then s.type=s.type.BaseType;s.fields=s.type:GetFields(flags);s.index=0;log('PEAK_BASE '..tostring(s.type))else s.phase=3;s.index=0 end
end
else
local t=typeof(CS.RPG.GameCore.ChallengePeakTargetConfigRow)
local fields=t:GetFields(flags);for i=0,math.min(fields.Length-1,23)do log('TARGET_FIELD '..fields[i].Name..' '..tostring(fields[i].FieldType))end
s.phase=4;log('END')
end
end)
if not ok then s.phase=4;log('ERROR '..tostring(err))end
end
end
@@ -0,0 +1,17 @@
do
if not _G.__gacPeakTargetRows1 then
_G.__gacPeakTargetRows1=true
local function log(v)CS.UnityEngine.Debug.Log('[GAC_PEAK_TARGET_ROWS] '..tostring(v))end
local ok,err=pcall(function()
local ids={3000,3001,3002,3003,3004,3005,3007}
for _,id in ipairs(ids)do
local row=CS.RPG.GameCore.BattleTargetExcelTable.dataDict[id]
if row==nil then error('Missing BattleTarget '..id)end
log('ROW '..CS.Newtonsoft.Json.JsonConvert.SerializeObject(row))
end
log('END')
end)
if not ok then log('ERROR '..tostring(err))end
end
end
@@ -0,0 +1,24 @@
do
if not _G.__gacPeakTargetsExport1 then
_G.__gacPeakTargetsExport1=true
local function log(v)CS.UnityEngine.Debug.Log('[GAC_PEAK_TARGETS] '..tostring(v))end
local ok,err=pcall(function()
local flags=CS.System.Enum.ToObject(typeof(CS.System.Reflection.BindingFlags),60)
local obj=CS.RPG.Client.GlobalVars.s_ModuleManager.ChallengePeakModule:GetChallengePeakBoss(104)
for _,name in ipairs({'_Meta','_BossMeta'})do
local f=obj:GetType():GetField(name,flags);if f then log('META '..name..' '..CS.Newtonsoft.Json.JsonConvert.SerializeObject(f:GetValue(obj)))end
end
local targets=obj:GetType():GetField('_Targets',flags):GetValue(obj)
log('COUNT '..targets.Count)
for i=0,math.min(targets.Count-1,15)do
local target=targets[i];local fields=target:GetType():GetFields(flags)
for j=0,fields.Length-1 do
local f=fields[j];log('FIELD '..f.Name..' '..tostring(f.FieldType))
if f.Name:find('Meta')then log('ROW '..CS.Newtonsoft.Json.JsonConvert.SerializeObject(f:GetValue(target)))end
end
end
end)
if not ok then log('ERROR '..tostring(err))end
end
end