You didn't mention what language you are learning?
3 hours ago, Timothy Sharp said:
rom bools to deactivating GameObjects to press a key and you will get a debugger output. What else is there?
First there is the 4 main data types: Bool, Int, Float and Strings. These are the core of programming. Also learn arrays.
After that you need to learn functions. These are short codes, for example a typical game function could look like this C#:
public PlayerTakeDamage (int AmountOfDamage){
this.HealthPoints -= AmountOfDamage;
//After taking damage see if player is still alive
if (this.HealthPoints < 1)
{
this.IsAlive = false;
}
}
You also need to learn classes, because these will allow you to make "objects" that can be used as data types or as structures for complex code.
public class Vector2D(){
public float x = 0;
public float y = 0;
public Vector2D(float startX, float startY){
self.x = startX;
self.y = startY;
}
}
//Now you can use the new class as a data type
Vector2D MyPosition = new Vector2D(10f,0.5f);
Then loops will be a good idea.
string Word = "Hello World";
void PrintEveryCharacter(string InText){
foreach (char Character in InText){
print(Character);
}
}
//it will be used like this:
PrintEveryCharacter(Word);
//Ruturns H e l l o w o r l d
After that you should know enough building blocks to start making a game.