The recovered system: fire channels = LBE4ControlsManager buttonGroups (0x40/0x45/0x46/0x47); default groups = the per-mech type-6 controls-map resource in BTL4.RES, installed by the T0 CreateStreamedMappings the port already called -- it needed only the TriggerState attribute (id 0x13 PINNED to the binary value; fireImpulse@0x31C is the binary's TriggerState) and an input feed. Keyboard/harness now push press/release edges into the button groups; the gBT*Trigger bypasses, per-type keyboard split and 1,0 pulse hack are retired -- weapons sharing a button fire TOGETHER (madcat Trigger = 4 weapons). Myomers @4b9550/@4b95b8 misattribution corrected (they are MechWeapon ConfigureMappables/ChooseButton). Verified 2-node: kill through the authentic chain (12 hits vs ~36 pre-groups). Config-mode session (regrouping UI) = the remaining stage, KB-scoped. Co-Authored-By: Claude Fable 5 <noreply@anthropic.com>
32 lines
1.5 KiB
Python
32 lines
1.5 KiB
Python
import struct, numpy as np
|
|
data=open("content/VIDEO/GEO/BLX_COP.BGF","rb").read()
|
|
uvs=[]; zs=[]
|
|
def parse(p,end):
|
|
while p+3<=end:
|
|
tw=struct.unpack_from("<H",data,p)[0]; p+=2
|
|
cid=tw&0x2fff; lw=4 if(tw&0x8000)else(2 if(tw&0x4000)else 1)
|
|
if p+lw>end:return
|
|
ln=data[p] if lw==1 else(struct.unpack_from("<H",data,p)[0] if lw==2 else struct.unpack_from("<I",data,p)[0])
|
|
p+=lw
|
|
if p+ln>end:return
|
|
if cid==0x88: # XYZ_UV stride 20: xyz(12)+uv(8)
|
|
for i in range(ln//20):
|
|
o=p+i*20; x,y,z=struct.unpack_from("<fff",data,o); u,v=struct.unpack_from("<ff",data,o+12)
|
|
uvs.append((u,v)); zs.append((x,y,z))
|
|
if cid in {0x3,0x70,0x40,0x41,0x42,0x46,0x48,0x10,0x20,0x30}: parse(p,p+ln)
|
|
p+=ln
|
|
if cid==0x5:break
|
|
parse(8,len(data))
|
|
UV=np.array(uvs); P=np.array(zs)
|
|
print("verts",len(UV))
|
|
print("U range [%.3f, %.3f] V range [%.3f, %.3f]"%(UV[:,0].min(),UV[:,0].max(),UV[:,1].min(),UV[:,1].max()))
|
|
print("U unique(sample):",np.unique(UV[:,0].round(2))[:12])
|
|
print("V unique(sample):",np.unique(UV[:,1].round(2))[:12])
|
|
# do UVs correlate with position (a gradient) or look like real texture coords?
|
|
print("first 12 (u,v | x,y,z):")
|
|
for i in range(min(12,len(UV))):
|
|
print(" (%.3f,%.3f | %.2f,%.2f,%.2f)"%(UV[i,0],UV[i,1],P[i,0],P[i,1],P[i,2]))
|
|
# histogram of V (if bimodal -> windows vs struts)
|
|
h,edges=np.histogram(UV[:,1],bins=8)
|
|
print("V histogram:",h.tolist(),"edges",[round(e,2) for e in edges])
|