Ledger Nano X - The secure hardware wallet
SHARE
TWEET

Untitled

a guest Oct 5th, 2015 301 Never
Not a member of Pastebin yet? Sign Up, it unlocks many cool features!
  1. # WAVEBK11
  2. #   Spider Man 2 (Xbox)
  3. # script for QuickBMS http://quickbms.aluigi.org
  4.  
  5. math ADD_RIFF_HEADER = 0
  6.  
  7. idstring "WAVEBK"
  8. goto 0x20
  9. get NAME string
  10. goto 0x40
  11. get FILES long
  12. get INFO_OFF long
  13. goto 0x50
  14. get DUMMY_SIZE long
  15. get DUMMY_OFF long
  16. goto 0x60
  17. get NAMES_SIZE long
  18. get NAMES_OFF long
  19.  
  20. #log MEMORY_FILE3 NAMES_OFF NAMES_SIZE
  21.  
  22. goto INFO_OFF
  23. for i = 0 < FILES
  24.     get NAME_OFF long
  25.     get DUMMY2 long
  26.     get SIZE long
  27.     get DUMMY4 long
  28.     get DUMMY5 long
  29.     get DUMMY6 long
  30.     get DUMMY7 long # -1
  31.     get OFFSET long
  32.     get FREQUENCY long
  33.     get ZERO long
  34.  
  35. #    goto NAME_OFF MEMORY_FILE3
  36. #    get NAME string MEMORY_FILE3
  37.  
  38.     if ADD_RIFF_HEADER == 0
  39.         string NAME p= "%d_%d.raw" i FREQUENCY
  40.         log NAME OFFSET SIZE
  41.     else
  42.         string NAME += ".wav"
  43.         math CHANNELS = 2
  44.         callfunction TOIMAWAV 1
  45.     endif
  46.  
  47. next i
  48.  
  49. startfunction TOIMAWAV
  50.     set MEMORY_FILE binary "\x52\x49\x46\x46\x00\x00\x00\x00\x57\x41\x56\x45\x66\x6d\x74\x20\x14\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x02\x00\x40\x00\x64\x61\x74\x61\x00\x00\x00\x00"
  51.  
  52.     math BITS = 4
  53.     set RIFFSIZE long SIZE
  54.     math RIFFSIZE += 36
  55.     set BLOCKALIGN long BITS
  56.     xmath BLOCKALIGN "36 * CHANNELS"
  57.     xmath AVGBYTES "(689 * BLOCKALIGN) + 4"
  58.  
  59.     putvarchr MEMORY_FILE 4 RIFFSIZE long
  60.     putvarchr MEMORY_FILE 20 0x0069 short     # wFormatTag (use 0x11 for IMA ADPCM)
  61.     putvarchr MEMORY_FILE 22 CHANNELS short   # wChannels
  62.     putvarchr MEMORY_FILE 24 FREQUENCY long   # dwSamplesPerSec
  63.     putvarchr MEMORY_FILE 28 AVGBYTES long    # dwAvgBytesPerSec
  64.     putvarchr MEMORY_FILE 32 BLOCKALIGN short # wBlockAlign
  65.     putvarchr MEMORY_FILE 34 BITS short       # wBitsPerSample
  66.  
  67.     get MEMORY_FILE_SIZE asize MEMORY_FILE
  68.     xmath TMP "MEMORY_FILE_SIZE - 4"
  69.     putvarchr MEMORY_FILE TMP SIZE long
  70.     log MEMORY_FILE2 0 MEMORY_FILE_SIZE MEMORY_FILE
  71.     append
  72.     log MEMORY_FILE2 OFFSET SIZE
  73.     append
  74.     get RIFF_SIZE asize MEMORY_FILE2
  75.     log NAME 0 RIFF_SIZE MEMORY_FILE2
  76. endfunction
RAW Paste Data
We use cookies for various purposes including analytics. By continuing to use Pastebin, you agree to our use of cookies as described in the Cookies Policy. OK, I Understand
Top