In a small team, one might have a programmer and a graphic designer.
Let's say the programmer writes up all the logic involving a sprite called Cat. Currently, Cat contains only the 'Walking' animation.
A few months later, the graphic designer sends the programmer an updated Cat object, which contains a 'Walking', 'Running', 'Meowing', 'Purring', and 'Jumping' animation.
What is the most efficient way for the programmer to go about updating Cat's animations, while preserving the instance variables and events of Cat?
My initial thought was to re-save the Construct project to use a directory instead of a single file, and then replace the Cat's animation folder. Would this be the correct way of doing it, or could it potentially create problems?
Thanks for your help!
Develop games in your browser. Powerful, performant & highly capable.
I've settled on replacing the Animations folder and replacing the <animation-folder> node in the .caproj. Looks to me like there would be no problems with this approach, except accidentally corrupting the project somehow. I'll just backup my project before doing the change.
If anybody knows of a cleaner way to replace an object's animations, let me know.
Honestly, what you'll want to use are basically variable dimensions in your events. So if your Cat idle animation is 32 pixels wide, instead of putting in your events "Cat is 32 pixels from the left side of the screen" instead you would do "Cat is Cat.Width from the left side of the screen". Little things like that. Then you can import the new animations and frames like normal without worrying about breaking your programming.
That was just a basic example, but it'd probably be good practice to leave just about all your numbers variable rather than hardcoded and static.