Beispiel #1
0
    // ------------------------------------------------------------------
    // Desc:
    // ------------------------------------------------------------------
    protected new void Awake()
    {
        base.Awake();

        Application.targetFrameRate = 60;

        if (instance == null) {
            instance = this;
        }

        spawner = GetComponent<Spawner>();
        player = FindObjectOfType( typeof (Player) ) as Player;
        gamePanel = FindObjectOfType (typeof(GamePanel)) as GamePanel;
        if ( gamePanel == null ) {
            Debug.LogError ( "Can't find GamePanel in the scene" );
        }
        challengeMng = FindObjectOfType (typeof(ChallengeMng)) as ChallengeMng;
        spawner.Init();
    }
Beispiel #2
0
 // ------------------------------------------------------------------
 // Desc:
 // ------------------------------------------------------------------
 void Awake()
 {
     challengeMng = Stage.instance.challengeMng;
     spBullet = GetComponent<exSprite>();
 }