예제 #1
0
파일: Puck.cs 프로젝트: ANANC/PuckGame
    // Use this for initialization
    void Start()
    {
        m_MaxSqr = Vector2.SqrMagnitude(new Vector2(500, 500));

        m_Transform = this.transform;

        m_Rigidbody2d = this.GetComponent <Rigidbody2D>();
        m_Rigidbody2d.gravityScale = 0;
        m_WallRect = DataMgr.GetIntanstance().GetWallRect();

        RectTransform rectTransform = m_Transform as RectTransform;

        m_WallRect.xMin += rectTransform.sizeDelta.x / 2;
        m_WallRect.xMax -= rectTransform.sizeDelta.x / 2;
        m_WallRect.yMin += rectTransform.sizeDelta.y / 2;
        m_WallRect.yMax -= rectTransform.sizeDelta.y / 2;
    }
예제 #2
0
 // Use this for initialization
 void Start()
 {
     m_Puck = DataMgr.GetIntanstance().m_Pack;
 }
예제 #3
0
 // Use this for initialization
 void Start()
 {
     m_PullBar   = DataMgr.GetIntanstance().m_Pack;
     m_Transform = this.transform;
 }