Skip to main content
New Participant
September 11, 2015
Answered

Why does moving a bone symbol with .x = newx only moves the root bitmap ??

  • September 11, 2015
  • 2 replies
  • 348 views

Hi !

I've started using bones to animate a toon like character with a very simple armature.

This toon was created inside a MovieClip Symbol, which I can instantiate in my scene etc.

I can call start/stopDrag() and everything works fine.

But, when I try to move it by program (once the drag is finished, I need to "snap" it or move

it myself) the only thing that moves is the torso, which is the root bone's bitmap.

I do something like :

myToon.x = newx;

myToon.y = newy;

I tried using a transform matrix but I get the same result...

I don't understand what is happening there. Should I inject a motionTween on the root bone ?

here's what it looks like :

my toon Symbol with armature :

I imported a bitmap, lasso'd each part (why no rectangular selection tool ? beats me) and converted them to Symbols. Then I built the armature.

Using it as a symbol works fine with things like adding to the scene, dragging etc.

But as soon as I want to move it myself by program, this happens :

thanks for your help !

(PS moved from general to AS3).

This topic has been closed for replies.
Correct answer Nico___

I fixed it !

In my callback, I was using e.target, I switched to e.currentTarget, and now it works fine !!

Marking as fixed, and I'll leave this here in case it can help someone later on...

2 replies

Nico___AuthorCorrect answer
New Participant
September 11, 2015

I fixed it !

In my callback, I was using e.target, I switched to e.currentTarget, and now it works fine !!

Marking as fixed, and I'll leave this here in case it can help someone later on...

Nico___Author
New Participant
September 11, 2015

I may have a hint on what is wrong, but I still don't understand why.

When I trace what is selected when I drag my toon (I have a mouseDown and mouseUp callback on it),

I sometimes get my symbol's class, or MovieClip.

I tried adding a rectangle "mask" around it, so that one could click in the empty spaces inside it, and now my symbol traces as "mysymbol" instead of MovieClip more often.

More specifically, I drew a rectangle around it, and I didn't transform it into a Symbol.

When I drag the toon by clicking in this rectangle, I see [object NBBonom], but when I click on the bone animation itself I get [object MovieClip].

when the object is NBBonom, the translation works fine.

I tried having the rectangle in front of the bones, but it remains behind, the menu is greyed, I can't put the shape in front. (I could have lived with a transparent rect in front...)

*feeling lost*