コード例 #1
0
 void Start()
 {
     _gameManager         = FindObjectOfType <GameManager>();
     _audioManager        = AudioManager.instance;
     OnHoverTool          = this.GetComponent <OnHover>();
     _theGSB              = FindObjectOfType <GlobalStatsBar>();
     _myTargetLocation    = this.transform.parent.GetComponentInParent <TargetLocation>();
     _myBoxCollider       = this.GetComponent <BoxCollider2D>();
     _mySpriteRenderer    = this.GetComponent <SpriteRenderer> ();
     BorderRenderer.color = _mySpriteRenderer.color;
     _ttManager           = FindObjectOfType <TutorialToolTipManager>();
 }
コード例 #2
0
    private void Start()
    {
        _theMessageManager = this.GetComponent <MessageManager>();
        _goalText          = GameObject.Find("Canvas/GoalText").GetComponent <Text>();
        theGSB             = this.GetComponent <GlobalStatsBar>();
        UpdateGoalDisplay();

        _ashPark        = GameObject.Find("World Map/Ash Park").GetComponent <TargetLocation>();
        _freemason      = GameObject.Find("World Map/Freemason").GetComponent <TargetLocation>();
        _philmont       = GameObject.Find("World Map/Philmont").GetComponent <TargetLocation>();
        _quinnSquare    = GameObject.Find("World Map/Quinn Square").GetComponent <TargetLocation>();
        _eastBeaHeights = GameObject.Find("World Map/East Bea Heights").GetComponent <TargetLocation>();

        _turnsMaintained = new int[CurrentVC.StatsToTrack.Count];
    }