sobota, 24 maja 2014

Background animations and objects displaying



I had a lot of school work this week, so my progress is smaller then I hope. I’m not proud of it but I’m going to work harder in upcoming week.

I was working on background animations displaying. I manage to load and display proper first frames of animations for each location. At the beginning I thought that I will be able to use same way of loading that is used for objects loading (like for shovel in first location). Sadly, there are more complications with them.

I was trying to understand how animations for Prince are stored. For each location we have anim.lst file that contains information about all animations of loaded room: special animations of hero (like hero with shovel for first room), background animations (like owl or bats in loc no. 1) and normal animations (like wizard Arivald). I had to implement InstallBackAnimations and InstallSingleBackAnim functions to find and load only background animations. These functions allow to find their proper numbers in anim.lst and load data for them.

But there are some background animations that has more then one type / sub-animation (like owl in first location – there are animations of her blinking eyes, waving her wings, etc). I decided to store main info (BAS structure) and array of all sub-animations (Anim) for one background animation in one structure (BackgroundAnim) and then create array of these structures (backAnimList) that contains all of them, but I’m not 100% sure if it’s the best idea. Some of background animations can change into normal animations (like gravedigger in first location) and that will be important too.
 
I’m still working on finding which sub-animation should be loaded in specific moment - it’s calculated in ShowBackAnims function.

Background animations - location no. 1

Background animations - location no. 3

Background animations - location no. 10

Brak komentarzy:

Prześlij komentarz