using System.Collections;
using System.Collections.Generic;
using UnityEngine;

public class Shoot : MonoBehaviour{
    public Rigidbody2D rb;
    [Range (1.0f,4.0f)]public float speed;
    
    void Start(){
        speed = 8f;
      rb = GetComponent<Rigidbody2D>();   
      rb.velocity = transform.right * speed;
      Destroy(gameObject,10f);
    }
    void Update(){
        transform.GetChild(0).eulerAngles = new Vector3(0f, 0f, 0f);
    }
}