ZenHAX

Free Game Research Forum | Official QuickBMS support | twitter @zenhax | SSL HTTPS://zenhax.com
It is currently Mon Jun 21, 2021 1:31 am

All times are UTC




Post new topic  Reply to topic  [ 2 posts ] 
Author Message
 Post subject: FindLoc MEMORY_FILE
PostPosted: Mon Jun 07, 2021 2:21 pm 

Joined: Sat May 02, 2020 12:46 pm
Posts: 10
Hi guys,

Regarding FindLoc, I'd love to ask how to pass a dynamic byte array stored in MEMORY_FILE to a variable:

The idea would be on a loop, to log each binary array into a MEMORY_FILE, after each line is logged, start a second loop to scan for duplicates.

I've thought about findLoc current line array from the beginning of file until current line but unable to pass it into a variable.


Top
   
 Post subject: Re: FindLoc MEMORY_FILE
PostPosted: Mon Jun 14, 2021 9:14 am 
Site Admin
User avatar

Joined: Wed Jul 30, 2014 9:32 pm
Posts: 12296
Unfortunately I don't have a solution for handling arrays.
Sometimes I have formats that use a "combo" of hashes and filenames that obviously require a long operation like search the hash and replace with the filename.

The only work-around I found was to store hashes as binary or hex sequence (after all it has a fixed size) and filenames followed by a dividing character (like ';') in a memory file.
Not sure if that's what you want but an example script is http://aluigi.org/bms/new_sword_legends.bms

Even if in my tests the script was very fast, it looks like it's still very slow with about 300'000 filenames:
https://www.zenhax.com/viewtopic.php?p=64017#p64017


Top
   
Display posts from previous:  Sort by  
Post new topic  Reply to topic  [ 2 posts ] 

All times are UTC


You cannot post new topics in this forum
You cannot reply to topics in this forum
You cannot edit your posts in this forum
You cannot delete your posts in this forum
You cannot post attachments in this forum

Search for:
Powered by phpBB® Forum Software © phpBB Limited