File tree Expand file tree Collapse file tree 1 file changed +0
-9
lines changed Expand file tree Collapse file tree 1 file changed +0
-9
lines changed Original file line number Diff line number Diff line change @@ -73,15 +73,6 @@ def extract_pac_buffer(buffer: bytes, extension: str) -> list[File]:
73
73
file_name = buffer [row_index - 16 : row_index ].decode ("utf-8" , errors = "ignore" ).replace ("\x00 " , "" )
74
74
file_offset = int .from_bytes (buffer [row_index + 8 : row_index + 12 ], byteorder = "big" )
75
75
file_size = int .from_bytes (buffer [row_index + 4 : row_index + 8 ], byteorder = "big" )
76
- # Size is calculated this way: (next_file.offset - current_file.offset)
77
- # However, if this is the last file, then: (pac_file.size - current_file.offset)
78
- # file_size = 0
79
- # if i == (files_count * 2): # Last file
80
- # file_size = len(buffer) - file_offset
81
- # else:
82
- # next_file_offset = int.from_bytes(buffer[row_index + 0x20 + 8: row_index + 0x20 + 12], byteorder="big")
83
- # file_size = next_file_offset - file_offset
84
-
85
76
data = buffer [file_offset : file_offset + file_size ]
86
77
87
78
if extension == "hkx" :
You can’t perform that action at this time.
0 commit comments