title: how to change properties of the constructor class from starling class
body: <p>How do i change properties  of the constructor class from a starling class I just added to it. or how do i call a function from the staring class that is a property of the mainClass</p>
  
  <p>In my case how to change the alpha of an object in the mainClass of the FLA, from the starling class ( PuzzleGame ) and viceversa .</p>
  
  <p>I have this: </p>
  
  <pre><code>public class MainClass extends Sprite
  {
      private var myStarling:Starling;
      public var square:Sprite; 
  
      public function MainClass()
      {
          myStarling = new Starling( PuzzleGame, stage);
          myStarling.start();
          createAbox();
      }
  
      public function SendText()
      {
          trace("we are changing this in the main class")
      }
  
      public function createAbox()
      {
          square = new Sprite();
          square.graphics.beginFill(0x0000FF);
          square.graphics.drawRect(0,0,100,100);
          square.graphics.endFill();
          square.x = 100;
          square.y = 100;
          square.alpha = 0.5;
          addChild(square);
          square.addEventListener(MouseEvent.CLICK, onClick);
      }
  
      private function onClick(ev:MouseEvent):void
      {
          this.square.alpha = 1;
          //here how do i make the circle.alpha = 0.5;
              //circle is an object created in the PuzzleGame
      }
  </code></pre>
  
  <p>and </p>
  
  <pre><code>public class PuzzleGame extends Sprite
  {
      public var circle:Image;
  
      public function PuzzleGame()
      {
          super();
          trace("you are in PuzzleGame");
          var s2:flash.display.Shape = new flash.display.Shape  ;
          s2.graphics.beginFill(0xff0000,1);
          s2.graphics.drawCircle(40,40,40);
          s2.graphics.endFill();
  
          var bmpData:BitmapData = new BitmapData(100,100);
          bmpData.draw(s2);
  
          circle = Image.fromBitmap(new Bitmap(bmpData));
          circle.x = 400;
          circle.y = 150;
          circle.alpha = 0.5;
          addChild(circle);
          circle.addEventListener(TouchEvent.TOUCH,onTouch);
      }
  
      private function onTouch(e:TouchEvent):void
      {
              parent.SendText();
  
          var touch:Touch = e.getTouch(circle);
          if (touch)
          {
              if (touch.phase == TouchPhase.ENDED)
              {
                  circle.alpha = 1;
  
                  //here how do i make the square.alpha = 0.5
                      //something like            parent.square.alpha = 0.5
              }
          }
      }
  </code></pre>