diff options
Diffstat (limited to 'bck_funcs.py')
-rw-r--r-- | bck_funcs.py | 11 |
1 files changed, 4 insertions, 7 deletions
diff --git a/bck_funcs.py b/bck_funcs.py index 8e2d6bb..e8482f8 100644 --- a/bck_funcs.py +++ b/bck_funcs.py @@ -7,9 +7,9 @@ from . import smg_common # what this file will do is the following: # pre_read_bck_file() takes the first look into the BCK and it checks if a BCK is correct. -# On the way it assigns important variables to the final bck_raw_info (smg_bck class). -# If the file is correct, then read_bck_file() will assign the remaining variables, if any -# and return the respective structure (a copy of it, not the reference). +# On the way it assigns all the variables to bck_raw_info (smg_bck_raw struct). +# If the file is correct, then read_bck_file() will assign the actually useful variables +# to a smg_bck_anim structure and return that structure # # in case of any error pre_read_bck_file() returns a string that can # be read by a human to identify what it is wrong with the BCK file @@ -299,7 +299,6 @@ def pre_read_bck_file(filepath): # holder for variables bck_raw_info = smg_bck_raw(); - ######## # header # magic @@ -340,7 +339,6 @@ def pre_read_bck_file(filepath): if (bck_raw_info.header.unknown1[i] != 0xFF): return bck_raw_error_str + "unknown 1" - ############## # ank1 section # magic @@ -396,7 +394,6 @@ def pre_read_bck_file(filepath): + (bck_raw_info.ank1.transl_arr_length * 4) > bck_raw_info.ank1.size): return bck_raw_error_str + "ank1 translation array offset" - ######################################################################## # refer to the offsets to read the animation data always (SMG does this) # bone animation data @@ -783,7 +780,7 @@ def write_smg_bck_raw(raw, filepath, endian_ch): f.write(pad.string_fill(32, raw.ank1.scale_arr_offset + (raw.ank1.scale_arr_length * 4))) # rotation array for i in range(raw.ank1.rot_arr_length): - # check if the slope surpaces max representation container + # check if the slope is larger in magnitude than the max representation container # (truncate the value to the max representation) value = int(raw.ank1.rot_arr[i]) if (value > 0x7FFF): |