Hey everybody! I am very new to these forums and I have recently gotten interested in coding. My one question is: How do you think I should get started with coding and creating my own games? Thank you to everyone that replies!
MOD EDIT: Colour formatting removed. Please do not uses excessive colour in your text, it makes it very hard to read for everyone else (as per the forum rules).
Follow a short tutorial, whether in video or blog format - whatever you prefer.
Once you've finished, copy it and try and make additions/changes to it. I made changes during the tutorials I watched but that can mess you up (break your game) and cost you time, but it can also give you experience with debugging so there are pros/cons either way.
When trying to write your own code, make comments first, for what should happen, and then, once you think you have the logic down, find the code you need to make it work. Being able to think about what NEEDS to happen based on what you WANT to happen is as important as knowing GML.
EG you want to make a player character move around:
GML:
//Check for horizontal input, calculate pixels_to_move_per_step
//Check for vertical input, calculate pixels_to_move_per_step
//Update the player's x with horizontal mmovement value
//Update the player's y with vertical movement
Now you've added some objects that you want to stop the player colliding with, so some updates are in order
GML:
//Check for horizontal input, calculate pixels_to_move_per_step
//Check for vertical input, calculate pixels_to_move_per_step
//Check for collision horizontally. If there is a collision, move as close to the object as possible and set horizontal speed to 0
//Check for collision vertically. If there is a collision, move as close to the object as possible and set vertical speed to 0
//Update the player's x with horizontal mmovement value (it will be set to 0 if there was a collision)
//Update the player's y with vertical movement (it will be set to 0 if there was a vertical collision)
You have to get used to the syntax used in GML, but I'm told that being able to organise your thoughts into usable comments and then converting that into code is helpful n many languages.