# Move gameObject in its facing direction

I have the following four gameObjects, they have, respectively, the rotations: -90, 0, 90, 180. I want them to move as denoted in the image below

This is what I got so far:

public class Projecttile : MonoBehaviour
{
public float speed;

private void Update()
{
transform.Translate(transform.up * speed * Time.deltaTime);
}
}


The result of my code is the following:

Why does my code result in this outcome, and how can I make each gameObject move in the direction it's facing?

• Note: Each projecttile only got the Projecttile script attached to it, there is nothing else interfering with it. – Sebastian Nielsen Apr 9 at 20:15
• Did you read the docs on transform.Translate to verify what coordinate space it uses when you don't provide a Space parameter? Or did you mean to type Vector3.up instead of transform.up? – DMGregory Apr 9 at 20:17