You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
When a level is built, for each armature in the level (@anim level object), data is generated for all of its animations.
For example, in build/assets/test_chambers/test_chamber_09_geo.c, the exit_piston armature has an array of SKAnimationClips named test_chamber_09_test_chamber_09_exit_piston_clips. In this array there is an entry for its piston_move_down animation, which contains a pointer to the actual frame data stored in build/assets/test_chambers/test_chamber_09_anim.c.
However, the exit_piston clips array also contains entries for the pit_0_down and pit_1_down animations, which are only used by the pit_0 and pit_1 armatures:
and there are copies of the animation data in the _anim.c file. This is not limited to chamber 14. This duplicated data is unused and bloats the ROM size. It is not very impactful now, but could be for future levels with more large/complex animations (such as in chamber 15; #39). In general it is also just good practice to avoid waste like this.
Interestingly, animations for Blender armatures (such stairs_ascend and stairs_descend in chamber 14) do not get duplicated. This could mean the problem stems from the way animations are defined in the .blend files.
Steps to reproduce the behavior:
Build the game
Open the _geo.c and _anim.c files for a level which contains animations (such as chamber 14)
Observe the duplication described above
The text was updated successfully, but these errors were encountered:
Version of the game
Latest (f35bf3d)
Original Hardware or Emulator?
N/A
What is the bug?
When a level is built, for each armature in the level (
@anim
level object), data is generated for all of its animations.For example, in
build/assets/test_chambers/test_chamber_09_geo.c
, theexit_piston
armature has an array ofSKAnimationClip
s namedtest_chamber_09_test_chamber_09_exit_piston_clips
. In this array there is an entry for itspiston_move_down
animation, which contains a pointer to the actual frame data stored inbuild/assets/test_chambers/test_chamber_09_anim.c
.However, the
exit_piston
clips array also contains entries for thepit_0_down
andpit_1_down
animations, which are only used by thepit_0
andpit_1
armatures:and there are copies of the animation data in the
_anim.c
file. This is not limited to chamber 14. This duplicated data is unused and bloats the ROM size. It is not very impactful now, but could be for future levels with more large/complex animations (such as in chamber 15; #39). In general it is also just good practice to avoid waste like this.Interestingly, animations for Blender armatures (such
stairs_ascend
andstairs_descend
in chamber 14) do not get duplicated. This could mean the problem stems from the way animations are defined in the.blend
files.Steps to reproduce the behavior:
_geo.c
and_anim.c
files for a level which contains animations (such as chamber 14)The text was updated successfully, but these errors were encountered: