Code:
How to get the GetCSWpnData Index:
string search: "Inaccuracy =\t%f\tSpread =\t%f\tSpreadDistance =\t%f\tPlayer Velocity =\t%f\n" and xref it
Note: v2 = vtable
.text:105EEDB3 68 88 D7 B8 10 push offset aInaccuracyFSpr ; "Inaccuracy =\t%f\tSpread =\t%f\tSpreadD"...
.text:105EEDB8 FF 15 B0 52 A5 10 call ds:Msg
.text:105EEDBE 83 C4 24 add esp, 24h
.text:105EEDC1 ; 338: sub_1018C340(v2);
.text:105EEDC1
.text:105EEDC1 loc_105EEDC1: ; CODE XREF: sub_105EE840+510↑j
.text:105EEDC1 ; sub_105EE840+538↑j
.text:105EEDC1 8B CE mov ecx, esi
.text:105EEDC3 E8 78 D5 B9 FF call sub_1018C340
.text:105EEDC8 ; 339: v151 = *(_DWORD *)((*(int (__thiscall **)(float *))(*(_DWORD *)v2 + 1816))(v2) + 300);
.text:105EEDC8 8B 06 mov eax, [esi]
.text:105EEDCA 8B CE mov ecx, esi
.text:105EEDCC 8B 80 18 07 00 00 mov eax, [eax+718h] <--- this ( divided by 4 = vtable index)
.text:105EEDD2 FF D0 call eax
.text:105EEDD4 ; 340: if ( ((int (__thiscall *)(void ***))off_10D0B228[13])(&off_10D0B228) )
.text:105EEDD4 B9 28 B2 D0 10 mov ecx, offset off_10D0B228
.text:105EEDD9 8B 80 2C 01 00 00 mov eax, [eax+12Ch]
.text:105EEDDF 89 44 24 60 mov [esp+80h+var_20], eax
.text:105EEDE3 A1 28 B2 D0 10 mov eax, off_10D0B228
.text:105EEDE8 8B 40 34 mov eax, [eax+34h]
.text:105EEDEB FF D0 call eax
.text:105EEDED 85 C0 test eax, eax
.text:105EEDEF 74 1B jz short loc_105EEE0C
.text:105EEDF1 ; 342: sub_1018C340(v2);
.text:105EEDF1 8B CE mov ecx, esi
.text:105EEDF3 E8 48 D5 B9 FF call sub_1018C340
.text:105EEDF8 ; 343: v19 = *(_DWORD *)((*(int (__thiscall **)(float *))(*(_DWORD *)v2 + 1816))(v2) + 296);
.text:105EEDF8 8B 06 mov eax, [esi]
.text:105EEDFA 8B CE mov ecx, esi
.text:105EEDFC 8B 80 18 07 00 00 mov eax, [eax+718h] <--- or this ( divided by 4 = vtable index)
.text:105EEE02 FF D0 call eax
.text:105EEE04 8B 80 28 01 00 00 mov eax, [eax+128h]
.text:105EEE0A EB 05 jmp short loc_105EEE11