Пример #1
0
    public void Reset(GameObject gameObjectParm)
    {
        BoxCollider box    = CardObject.GetComponent("BoxCollider") as BoxCollider;
        float       offset = box.bounds.size.y / 3;

        CardMoveAnim.InitAnim();
        CardMoveAnim.startPosition = gameObjectParm.transform.position;
        CardMoveAnim.EndPosition   = CardMoveAnim.startPosition - gameObjectParm.transform.up * offset;
        CardMoveAnim.SetSpeed(16.0f);
        CardMoveAnim.SetPassTime(0.001f);
    }
Пример #2
0
 public override void init(GameObject gameObjectParm)
 {
     base.init(gameObjectParm);
     if (CardMoveAnim == null)
     {
         CardMoveAnim = new cardMoveAnim();
     }
     CardMoveAnim.InitAnim();
     CardMoveAnim.startPosition = gameObjectParm.transform.position;
     CardMoveAnim.SetSpeed(4.0f);
     CardMoveAnim.SetPassTime(0.1f);
 }
Пример #3
0
    public override void init(GameObject gameObjectParm)
    {
        base.init(gameObjectParm);
        CardMoveAnim = new cardMoveAnim();
        BoxCollider box    = CardObject.GetComponent("BoxCollider") as BoxCollider;
        float       offset = box.bounds.size.y / 3;

        CardMoveAnim.startPosition = gameObjectParm.transform.position;
        CardMoveAnim.EndPosition   = CardMoveAnim.startPosition + gameObjectParm.transform.up * offset;
        CardMoveAnim.SetSpeed(16.0f);
        CardMoveAnim.SetPassTime(0.001f);
    }