Not a member of Pastebin yet?
Sign Up,
it unlocks many cool features!
- using UnityEngine;
- public class Bullet : MonoBehaviour
- {
- Vector3 moveDirection;
- public void Setup(Vector3 direction)
- {
- moveDirection = direction;
- }
- private void Update()
- {
- transform.position = transform.position + moveDirection * Time.deltaTime;
- }
- }
Advertisement
Add Comment
Please, Sign In to add comment