Advertisement
Not a member of Pastebin yet?
Sign Up,
it unlocks many cool features!
- public float speed;
- public int height;
- private void OnTriggerEnter(Collider other)
- {
- if (other.CompareTag("Player"))
- this.transform.Translate(new Vector3(0, (height * speed), 0));
- //this.transform.Translate(Vector3.up * height * speed);
- }
- }
Advertisement
Add Comment
Please, Sign In to add comment
Advertisement