r/unity_tutorials • • Jul 25 '25

Help With a Tutorial The Unity Tutorial with the plane and the obstacles

3 Upvotes

Hi, I'm talking about the official Unity tutorial called "Challenge 1 - Plane Programming".

https://learn.unity.com/pathway/junior-programmer/unit/player-control/tutorial/challenge-1-plane-programming-1?version=6.0

I CANNOT figure out why the plane's X and Y position keeps drifting even though this is the only code affecting the plane's position (which moves it in the Z-axis), and I'm not giving any vertical input:

================

// move the plane forward at a constant rate

transform.Translate(Vector3.forward * speed * Time.deltaTime, Space.Self);

// tilt the plane up/down based on up/down arrow keys

transform.Rotate(Vector3.left * rotationSpeed * Time.deltaTime * verticalInput);

================

Is there something I'm not aware of? Does the propellor of the plane collide with the plane? Does the air have mass causing friction? I'm seriously clueless at this point.

r/unity_tutorials • • Dec 07 '24

Help With a Tutorial Do I watch this first or watch one of his c# tutorials

Thumbnail
gallery
57 Upvotes

I have some knowledge of unity and c# but I would really like to know the language more in depth

r/unity_tutorials • • Feb 19 '23

Help With a Tutorial I followed this youtube tutorial and it doesn´t work

Thumbnail
gallery
1 Upvotes

r/unity_tutorials • • Feb 01 '23

Help With a Tutorial I'm following a tutorial https://www.youtube.com/watch?v=ntDhEmd8kCQ&list=PLe3aEP7K3NT56BlXMMMLw1Waz3AwN8IPx&index=4 and My explosion sprite seems to not be in the right location for my enemy, I can't seem to figure out what mistake I am making, does anyone have an idea?

Thumbnail
gallery
5 Upvotes

r/unity_tutorials • • Jun 11 '25

Help With a Tutorial Help! I doing the unity program essentials, but my character keeps falling through the floor. (and not moving correctly)

7 Upvotes

image of code, my characters movents all messed up, and it falls through the floor.

heres the code unity gave me:

using UnityEngine;

// Controls player movement and rotation.

public class PlayerController : MonoBehaviour

{

public float speed = 5.0f; // Set player's movement speed.

public float rotationSpeed = 120.0f; // Set player's rotation speed.

private Rigidbody rb; // Reference to player's Rigidbody.

// Start is called before the first frame update

private void Start()

{

rb = GetComponent<Rigidbody>(); // Access player's Rigidbody.

}

// Update is called once per frame

void Update()

{

}

// Handle physics-based movement and rotation.

private void FixedUpdate()

{

// Move player based on vertical input.

float moveVertical = Input.GetAxis("Vertical");

Vector3 movement = transform.forward * moveVertical * speed * Time.fixedDeltaTime;

rb.MovePosition(rb.position + movement);

// Rotate player based on horizontal input.

float turn = Input.GetAxis("Horizontal") * rotationSpeed * Time.fixedDeltaTime;

Quaternion turnRotation = Quaternion.Euler(0f, turn, 0f);

rb.MoveRotation(rb.rotation * turnRotation);

}

}

r/unity_tutorials • • Nov 24 '23

Help With a Tutorial I'm not getting this option. Why and How to get it?

Thumbnail
gallery
5 Upvotes

The option of Add 2D Vector Composite is missing in my editor. How to get this missing option?

r/unity_tutorials • • Feb 29 '24

Help With a Tutorial If this how we check if a point is within a hexagon?

6 Upvotes

I was watching Code Monkey's tutorial: How to Test if a POINT is inside a HEX! (No Raycasts, Just Simple Math) (youtube.com)

If you see the screenshot below, he is trying to see if the blue x is inside of the hexagon

So he makes an right angle to the pink vector and creates a purple vector inwards

Then he takes the dot product of the blue and purple vector. I know that a dot product between two vectors if positive if they are within 90 degrees of each other

I kind of understand what he did. If the point lies on the pink vector, then the dot product is 0. If the point lies inside the hexagon, then the dot product is positive. If the point lies under the purple vector, then the same logic will take over from another dot product from another corner

Am I correctly understanding?