Exit
  • Global community
    • Language:
      • Deutsch
      • English
      • Español
      • Français
      • Português
  • 日本語コミュニティ
  • 한국 커뮤니티
0

Set Order of Layers for Each Frame

Explorer ,
Apr 22, 2023 Apr 22, 2023

Hello Friends! Hope all is well.
I apologize in advance if my termanology isnt great, as I am still learning the Adobe Ecosystem.
I am creating a Top down Walking Animation for a simple Chibi Like Character.
When The Character takes a step forward with say his right foot&leg, I'd like to set it so that the "right foot&Leg" Layer is behind the "Left foot&leg" Layer. 
But then when the character takes a step forward with the left foot&Leg, I'd like to set it so that the "Left foot&Leg" Layer is behind the "Right foot&leg" Layer.
Hopefully that makes sense. I really appreciate the help! Hopefully this is a feature.

Thanks!

1.0K
Translate
Report
Community guidelines
Be kind and respectful, give credit to the original source of content, and search for duplicates before posting. Learn more
community guidelines
Community Expert ,
Apr 22, 2023 Apr 22, 2023

you can't change layer/symbol depth unless you use code.

 

you can use different parts of a timeline/keyframes  to change the layers used by your symbols.

Translate
Report
Community guidelines
Be kind and respectful, give credit to the original source of content, and search for duplicates before posting. Learn more
community guidelines
Explorer ,
Apr 22, 2023 Apr 22, 2023

Hello,

I appreciate the response.

Do you mind alaborating a bit on this?
I'm definetly willing to look into actionscript. Do you by chance know where to start regarding this?
Also, I'm having issues understand your second statement if you dont mind going into that further.
Thanks in advance 🙂

Translate
Report
Community guidelines
Be kind and respectful, give credit to the original source of content, and search for duplicates before posting. Learn more
community guidelines
Explorer ,
Apr 22, 2023 Apr 22, 2023

NOTE: I am fimiliar with what keyframes, symbols, and the timeline are; as this is what I'm currently using to creating the animation.

Translate
Report
Community guidelines
Be kind and respectful, give credit to the original source of content, and search for duplicates before posting. Learn more
community guidelines
Community Expert ,
Apr 22, 2023 Apr 22, 2023

it might be easier for (esp novice) users to use the timeline to reorder onstage objects.

 

but it's easier to explain how to reorder symbols using code.

 

to use code, just use addChild() several times. any symbol added after another appears above the other.

Translate
Report
Community guidelines
Be kind and respectful, give credit to the original source of content, and search for duplicates before posting. Learn more
community guidelines
Explorer ,
Apr 22, 2023 Apr 22, 2023

Awesome, thanks a ton I appreciate the help!

Translate
Report
Community guidelines
Be kind and respectful, give credit to the original source of content, and search for duplicates before posting. Learn more
community guidelines
Community Expert ,
Apr 22, 2023 Apr 22, 2023

you're welcome.

Translate
Report
Community guidelines
Be kind and respectful, give credit to the original source of content, and search for duplicates before posting. Learn more
community guidelines
Contributor ,
Apr 24, 2023 Apr 24, 2023

This is very interesting, what would the code look like?


____
2D vector animator since 2000 & PhD
Translate
Report
Community guidelines
Be kind and respectful, give credit to the original source of content, and search for duplicates before posting. Learn more
community guidelines
Valorous Hero ,
Apr 24, 2023 Apr 24, 2023

@sergiopop75  🙂 🙂 🙂

 

Nick - Character Designer and Animator, Flash user since 1998
Member of the Flanimate Power Tools team - extensions for character animation
Translate
Report
Community guidelines
Be kind and respectful, give credit to the original source of content, and search for duplicates before posting. Learn more
community guidelines
Community Expert ,
Apr 24, 2023 Apr 24, 2023

@sergiopop75 

 

as3 or html5?

Translate
Report
Community guidelines
Be kind and respectful, give credit to the original source of content, and search for duplicates before posting. Learn more
community guidelines
Contributor ,
Apr 24, 2023 Apr 24, 2023

as3


____
2D vector animator since 2000 & PhD
Translate
Report
Community guidelines
Be kind and respectful, give credit to the original source of content, and search for duplicates before posting. Learn more
community guidelines
Community Expert ,
Apr 24, 2023 Apr 24, 2023
LATEST

// create an array of the character body parts

var cParts = [body, leftarm, rightarm, leftleg, rightleg];

 

// call orderF and pass an array specifying the depth (less is below) of each body part

orderF([0,3,1,2,4]);  // body at bottom, rightarm above body, then leftleg, then leftarm, rightleg on top


function orderF(a:Array):void{
for(var i:int = 0;i<a.length;i++){
addChild(cParts[a.indexOf(i)]);
}
}

 

this can easily be adapted to include a parent paramenter if there are other movieclips whose parts need ordering by code.

Translate
Report
Community guidelines
Be kind and respectful, give credit to the original source of content, and search for duplicates before posting. Learn more
community guidelines