Say you have about 356 movie clips

And they represent parts of a character that can be customized by a player at any given time. For example, the character’s pants can be changed at any time, so you have eight options for pants, and each pants option has eight movie clips (one for each leg position, the positions being face up/down/left/right and walk up/down/left/right). So you have these groups of clips for the legs, for the arms, the torso, the feet, etc, and they total up to 356 separate clips.

Right now, I have these clips placed on different frames inside of parent clips that are controlled by goto’s and stops depending on what the player chooses to wear. So, if the player chooses jeans, the corresponding clip (depending on what position the character is in, “face down”, “walk left”, etc) will go to and display the “jeans” frame.

Needless to say, this makes one gigantic clusterf–k of a character movie clip. I counted today, and it is composed of approximately 356 separate clips, I did this because at the time it was the only way I could think to have any and all possible options for outfits ready to go at any given time at the press of a button.

It’s actually working perfectly. BUT, when any other clips are put into play at the same time, the whole thing is bogged down. So here is what I am considering doing…

What if, the base character movie clip, rather than containing all those separate option clips at once all the time, was just composed of “anchor” clips for each changeable part? Meaning, a “torso anchor”, an “arms anchor”, etc for each part that can be customized on the fly. I would then modify the code on the buttons in the clothing selection screen to attach/remove clips from the library dynamically. When you change your pants, the game will remove the current clip attached to the “legs anchor” and attach the new choice’s clip from the library. Same for all the other parts.

Some questions:

  • Does Flash always load all clips that are contained within my base character clip, whether they are being displayed or not? Like, if the character is walking left, wearing jeans and a tee shirt, is Flash still working to keep all those other clothing options and character positions ready and loaded even though they aren’t being displayed?

  • Will having 356 different movie clips in the library that are pulled and attached and removed dynamically by the player take a huge toll on the game’s performance speed? Or is that really not that big a deal? Keep in mind, that’s just for the character. There will be an unforseen amount of other movie clips stored in the library for other aspects of the game that I haven’t gotten to yet.

  • In a nutshell, is my new idea worth trying, or is it really no better than what I’m doing right now? If you’re wondering why the number of clips is so high, it’s because in addition to having a bunch of clothing options for each part of the character, you can also choose your mood, which modifies the position of the arms accordingly and therefore creates a whole bunch of new clips (as there needs to be one for each mood, in each standing/walking position, and for each clothing option).

:snooze: