Skip to main content
Participant
June 24, 2009
Question

how to read movieClip container variables by attachmovie

  • June 24, 2009
  • 1 reply
  • 543 views
I used a movieClip to store the attach movieclip, but How to get back the variable from that movieClip container,

such as a I set a array in the exiting movieClip

var m_click:Array = new Array();
for (var f=0; f<=this[mc_name+"_qty"]._totalframes-1; f++)
{ m_click = 0; }

I want the attached movieClip "y_qty" with a button inside to get the m_click for changing each m_click[0]..m_click[1]..value, how to do it?

Thanks
This topic has been closed for replies.

1 reply

Ned Murphy
Legend
June 24, 2009

Your question is not very clear (to me).  Can you show the code you are using to load the movieclip into the container, and explain what you are trying to extract from where in that combination of objects?

Participant
June 25, 2009

As I want to build a supermarket interface with number of 2x3 or 2x2 cells in every shelf,

I prepare at least more than 6 items in 1 mc for attachmovie randomly in each cell.

On the other hand, I need to attachmovie of  the selected items in a shopping cart list with quantity information, and

removed it in cart list when click until tthe quantity is zero.

So, I added a button inside the attachmovie to count and store the times on each frame click and currentframe no with items id in array.

Now is much trouble to store array item_id without repeat, if repeat, add to item_qty++