예제 #1
0
 // Use this for initialization
 void Start()
 {
     bonusController = GameObject.Find("xBonusController").GetComponent <xBonusController>();
     auSource        = GetComponent <AudioSource>();
     bulletBody      = GetComponent <Rigidbody2D>();
     bulletBody.AddForce(new Vector2(10, 0), ForceMode2D.Impulse);
     bulletAnim.SetActive(false);
 }
예제 #2
0
 // Use this for initialization
 void Start()
 {
     bonusController        = GameObject.Find("xBonusController").GetComponent <xBonusController>();
     MoneyBoxCountTextObj   = GameObject.Find("MoneyBoxCountText");
     MoneyBoxCountText      = MoneyBoxCountTextObj.GetComponent <Text>();
     batteryBar             = GetComponent <Image>();
     MoneyBoxCountText.text = moneyBoxCount.ToString();
 }