Not a member of Pastebin yet?
Sign Up,
it unlocks many cool features!
- Vector3 velocity;
- void Start()
- {
- velocity = Quaternion.Euler(0, 0, angle) * Vector3.right * speed;
- }
- void Update()
- {
- velocity.y += gravity * Time.deltaTime;
- transform.position += velocity * Time.deltaTime;
- }
Advertisement
Add Comment
Please, Sign In to add comment