TriggerEnterInput.cs 708 B

12345678910111213141516171819
  1. using UnityEngine;
  2. using System.Collections;
  3. public class TriggerEnterInput : MonoBehaviour {
  4. public void OnClick()
  5. {
  6. if (transform.parent.parent.name == "CouponPopup" || transform.parent.parent.name == "CouponPopupWrongNumber ")
  7. {
  8. Debug.Log(transform.parent.parent.name +"!!!!");
  9. transform.parent.parent.localPosition = new Vector3(transform.parent.parent.localPosition.x, 88, transform.parent.parent.localPosition.z);
  10. }
  11. else
  12. {
  13. transform.parent.parent.parent.localPosition = new Vector3(transform.parent.parent.parent.localPosition.x, 88, transform.parent.parent.parent.localPosition.z);
  14. }
  15. }
  16. }