Advertisement
Not a member of Pastebin yet?
Sign Up,
it unlocks many cool features!
- {$CLEO}
- goto @start
- 0662: printstring "Code written by fastman92"
- :start
- 0A8D: 0@ = read_memory 0x40122D size 4 virtual_protect false // CModelInfo::ms_modelInfoPtrs
- 0A8D: 1@ = read_memory 0x407106 size 4 virtual_protect false // _countof(CModelInfo::ms_modelInfoPtrs) / base ID of TXD files
- 0A8D: 2@ = read_memory 0x4C67A1 size 4 virtual_protect false // &IDE_peds_store
- 0A8D: 3@ = read_memory 2@ size 4 virtual_protect false // IDE_peds_store.count
- /////////////////////////////////////////////////////////
- // Get address to beginning of CStore<CPedModelInfo>.array
- 0A8E: 4@ = 2@ + 4 // int ; offset of CStore.array
- // Get address to end of CStore<CPedModelInfo>.array
- 0A90: 5@ = 3@ * 0x44 // int ; sizeof(CPedModelInfo)
- 005A: 5@ += 4@ // (int)
- // Copy address of CModelInfo::ms_modelInfoPtrs to different variable that will be overwritten.
- 0085: 6@ = 0@ // (int)
- // model ID
- 7@ = 0
- // Loop over CModelInfo::ms_modelInfoPtrs
- while 001D: 1@ > 7@ // (int)
- 0A8D: 8@ = read_memory 6@ size 4 virtual_protect false // read CBaseModelInfo*
- if and
- 002D: 8@ >= 4@ // (int) ; pointer >= beginning of CStore<CPedModelInfo>.array
- 001D: 5@ > 8@ // (int) ; end of CStore<CPedModelInfo>.array > pointer
- then
- wait 200
- while 8AB0: not key_pressed 48
- wait 0
- 0AD1: show_formatted_text_highpriority "Found ped ID: %d Press 0 to continue." time 2000 7@
- end
- end
- 6@ += 4 // CBaseModelInfo** modelInfoPtr
- 7@ += 1 // model ID
- end
- wait 200
- while 8AB0: not key_pressed 48
- wait 0
- 0AD1: show_formatted_text_highpriority "FindPedIDs finished! Press 0 to exit the script" time 2000
- end
- 0A93: end_custom_thread
Advertisement
Add Comment
Please, Sign In to add comment
Advertisement