actionscript 3 - as3 looping MC from class not adding X propertity correctly -


i have simple loop creates movieclip class in library. it's adding first part of equation x property not plus 50. however, adding +50 first item in loop. doing wrong here?

var flagbutton:movieclip;  function displayflagbuttons() {      for( var = 0; pages.length > i; i++)     {          flagbutton = new roundbutton();              // line below giving me issues in adding 50 each movieclip             flagbutton.x = (flagbutton.width * i) + 50;              // again, above code adds 50 1st item           addchild(flagbutton);     } } 

did mean :

flagbutton.x = (flagbutton.width + 50) * i;  

Comments

Popular posts from this blog

linux - Does gcc have any options to add version info in ELF binary file? -

android - send complex objects as post php java -

charts - What graph/dashboard product is facebook using in Dashboard: PUE & WUE -