"bullet" instance spawns but only goes in one direction. c#

I got the G2GD lesson set just a few days ago and have started working on video 3, where you learn to make your first blaster. I have followed the script exactly as I was told to and the projectiles aren’t behaving properly. In the video, the projectile properly moves in the direction that the camera is facing. However, when I apply it, the projectile goes only along the Z axis. I’m using this script:

using UnityEngine;
using System.Collections;

/// <summary>
/// Fire blaster. This script is attached to the player and allows
/// them to fire the Blaster projectile.
/// </summary>

public class FireBlaster : MonoBehaviour {
	
	//Variable Start
	
	//The Blaster projectile is attached to this in the inspector
	
	public GameObject blaster;
	
	//Quick reference
	
	private Transform myTransform;
	
	private Transform cameraHeadTransfrom;
	
	//The position at which the projectile should be 
	//instantiated.
	
	private Vector3 launchPosition =  new Vector3();
	
	//Variable End
	
	// Use this for initialization
	void Start () 
	{
		myTransform = transform;
		
		cameraHeadTransfrom = myTransform.FindChild("CameraHead");
	}
	
	// Update is called once per frame
	void Update () 
	{
		if(Input.GetButton("Fire Weapon"))
			
		{
			//The launch position of projectile will be just in front of CameraHead
			launchPosition = cameraHeadTransfrom.TransformPoint(0,0,0.2f);
			
			
			//Create blaster projectile at launch position and tilt it's angle
			//so that it is horizontal using the angle eulerAngles.x +90
			
			Instantiate(blaster,launchPosition,Quaternion.Euler(cameraHeadTransfrom.eulerAngles.x + 90, 
																myTransform.eulerAngles.y, 0));
		}
	}
}

What is wrong with it?

I have no Unity by hand so can’t test it, but my guess is - you should change that part:

Instantiate(blaster,launchPosition,Quaternion.Euler(cameraHeadTransfrom.eulerAngles.x + 90, myTransform.eulerAngles.y, 0));

to something like:

 Instantiate(blaster,launchPosition,cameraHeadTransfrom.rotation);

ok here’s the script for the blaster. between the two is there any way to identify the problem? Nucas I am trying your thing right now as well.

using UnityEngine;
using System.Collections;
/// <summary>
/// Blaster script. This script is attached to the Blaster
/// Projectile and it governs the Projectile's behavior
/// </summary>

public class BlasterScript : MonoBehaviour {
	//variable start
	
	//quick var reference
	
	private Transform myTransform;
	
	//flight speed of projectile
	
	private float projectileSpeed = 10;
	
	//prevent projectile from causing
	//further harm after it hits something
	
	private bool expended = false;
	
	//cast a ray in front of projectile
	//to see if it it will hit a collider it likes
	
	private RaycastHit hit;
	
	//range of the ray
	
	private float range = 1.5f;
	
	//Projectile's Life span
	private float expireTime = 5;
	
	
	//variables end
	
	// Use this for initialization
	void Start () 
	{
		myTransform = transform;
		
		//As soon as the projectile is created, start a countown
		//To destroy it
		
		StartCoroutine(DestroyMyselfAfterSomeTime());
		
	}
	
	// Update is called once per frame
	void Update () 
	{
		//Translate the projectile upwards (pointy end)
		
		myTransform.Translate(Vector3.up * projectileSpeed * Time.deltaTime);
		
		// if the ray hits something, execute this
		
		if(Physics.Raycast(myTransform.position,myTransform.up, out hit, range) &&
			expended == false)
		{
			//if collider has the tag "Floor" then..
			
			if(hit.transform.tag == "floor")
			{
				expended = true; 
				
				// make projectile invisible
				myTransform.renderer.enabled = false;
				
				//Turn off light to get rid of halo
				myTransform.light.enabled = false;
			}
		}
		
	}
	
	IEnumerator DestroyMyselfAfterSomeTime()
	{
		//wait for the timer to count up to expireTime
		//and then destroy the projectile
		
		yield return new WaitForSeconds(expireTime);
		
		Destroy(myTransform.gameObject);
	}
	
}