ZenHAX

Free Game Research Forum | Official QuickBMS support | twitter @zenhax | SSL HTTPS://zenhax.com
It is currently Sun Oct 22, 2017 2:38 am

All times are UTC




Post new topic  Reply to topic  [ 3 posts ] 
Author Message
PostPosted: Sun Jul 10, 2016 11:11 am 

Joined: Sun Jul 10, 2016 11:07 am
Posts: 54
hello new member here, I've been learning to make my own script for about a week now and still a lot to learn...


I've made this noob script to extract the pack files... but my problem is the names are on hexadecimal, I was wondering how can I make it export to decimal file names for easy file arrage on windows.

Code:
endian little

for i = 0 < 5693
FindLoc FILES string "PACK" 0x0
xmath SIZEloc "FILES + 24" 
goto SIZEloc
get SIZE long
putarray 0 i FILES
putarray 1 i SIZE

string NAME p= "Package_%05x.pack" i

log NAME FILES SIZE
next i


Top
   
PostPosted: Mon Jul 11, 2016 6:51 am 
Site Admin
User avatar

Joined: Wed Jul 30, 2014 9:32 pm
Posts: 6896
'x' -> 'd':
Code:
string NAME p= "Package_%05d.pack" i

http://www.cplusplus.com/reference/cstdio/printf/


Top
   
PostPosted: Tue Jul 12, 2016 7:19 am 

Joined: Sun Jul 10, 2016 11:07 am
Posts: 54
thanks its working great now! :)


Top
   
Display posts from previous:  Sort by  
Post new topic  Reply to topic  [ 3 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