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); }
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); }
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); }