home *** CD-ROM | disk | FTP | other *** search
/ Mobiclic 170 / MOBICLIC170.ISO / pc / index.swf / scripts / com / milanpresse / capsule / AbstractMenuCapsule.as next >
Text File  |  2014-12-16  |  1KB  |  58 lines

  1. package com.milanpresse.capsule
  2. {
  3.    import flash.display.Sprite;
  4.    
  5.    public class AbstractMenuCapsule extends GameEngineCapsule
  6.    {
  7.        
  8.       
  9.       private var _layers:Array;
  10.       
  11.       private var _menu;
  12.       
  13.       public function AbstractMenuCapsule()
  14.       {
  15.          this._layers = [];
  16.          super();
  17.          this.createLayers();
  18.       }
  19.       
  20.       public function createLayers() : void
  21.       {
  22.          this._layers["background"] = addChild(new Sprite());
  23.          this._layers["activeModule"] = addChild(new Sprite());
  24.          this._layers["top"] = addChild(new Sprite());
  25.       }
  26.       
  27.       public function set menu(param1:*) : void
  28.       {
  29.          this._menu = param1;
  30.       }
  31.       
  32.       public function get menu() : Sprite
  33.       {
  34.          return this._menu;
  35.       }
  36.       
  37.       public function get layerModule() : Sprite
  38.       {
  39.          return this._layers["activeModule"];
  40.       }
  41.       
  42.       public function get layerMenu() : Sprite
  43.       {
  44.          return this._layers["top"];
  45.       }
  46.       
  47.       public function talk() : void
  48.       {
  49.          this._menu.talk();
  50.       }
  51.       
  52.       public function talkEnd() : void
  53.       {
  54.          this._menu.talkEnd();
  55.       }
  56.    }
  57. }
  58.