Page 1 of 2

Simple game tutorials

Posted: Mon Oct 17, 2016 8:40 am
by Santos
Hi everyone,

I made some tutorials for people who know the basics of Lua and LOVE but don't quite know how to go about making something game-like. When I was at this stage I felt like I wanted some tutorials kind of like these.

Here they are: https://simplegametutorials.github.io/

And here are pictures of the final results of the tutorials:

Image

Image

Image

Image

Image

Image

Image

Image

Image

You can make your own tutorials like these using the code here: https://github.com/simplegametutorials/ ... etutorials

Let me know what you think if you want, and let me know if you find any mistakes, there are probably lots!

Re: Simple game tutorials

Posted: Mon Oct 17, 2016 9:12 am
by Ulydev
Cool! I like written tutorials.

Re: Simple game tutorials

Posted: Mon Oct 17, 2016 8:12 pm
by davisdude
These are great! I submitted some pull-requests that were mostly just nit-picky grammar things, but I think you did a really good job explaining the concepts for the ones I read (didn't get to Flowers, Life, Snake, or Sokoban). I don't know if you do these later, but I would like to suggest that one of the last few introduces OOP and other more common practices in game-dev that aren't seen as frequently outside of game-dev in Lua.

Re: Simple game tutorials

Posted: Mon Oct 17, 2016 9:55 pm
by josefnpat
This is really fantastic! I will try and share this with the next new lover that comes around!

Re: Simple game tutorials

Posted: Mon Oct 17, 2016 11:06 pm
by paulclinger
Looks great! I suggest adding a link to the github repository for those who may be interested in checking the repository and contributing (took me few clicks to find it). Also, I think the material is at the good level of detail even for those who may not be familiar with LOVE, but a couple of links to wiki pages or "Basic Concepts" tutorial would help (just to cover things like love.load, love.draw, love.update and such).

I also think that having a table of contents may help, as the pages are quite long. I have a really primitive JavaScript code that doesn't require any content changes that I use on my Markdown pages; you just need to add `<ul id='toc'>&nbsp;</ul>` to your page, which gets replaced with the TOC. Here is one example: https://studio.zerobrane.com/doc-general-preferences

Re: Simple game tutorials

Posted: Tue Oct 18, 2016 8:33 am
by easy82
This is just great! Big thums up! :)

Re: Simple game tutorials

Posted: Tue Oct 18, 2016 8:58 am
by Zireael
Could we get a simple 2d racer tutorial? This idea has been tickling my brain for quite some time...

Re: Simple game tutorials

Posted: Tue Oct 18, 2016 9:56 am
by Santos
Ulydev, thank you! :)

davisdude, thank you HEAPS for the pull requests, I am a fan of proper spelling and grammar, and you really saved the day with the Eyes one! I added a note on the main page about window sizing.

I'm not completely sure which common practices you're referring to, feel free to let me know exactly what you mean, but I imagine my response would be similar to why OOP isn't used in these tutorials, or multiple .lua files aren't used, or the code isn't broken down into small functions, or isn't very "functional".

The short answer is: Because I don't think it would help toward the goal of these tutorials, which is to take people from the stage of not knowing how to think about programming a simple game, to being able to. For this, I think it is easier to think in terms of what "data" (as in variables/tables) needs to be stored and how it changes over time, rather than "objects", and it's easier if the program's flow of control is easy to follow.

There is probably a lot that could be said about all this, and the way I've chosen to do things may be surprising to some (or most!) people, so if anyone wants to discuss this kind of thing, please send me a PM.

josefnpat, thank you, I hope it helps new lovers!

paulclinger, thank you for your comments and for ZeroBrane Studio! I have added a link to the repository on the main page.

I know what you mean about it maybe being suitable for people unfamiliar with LOVE... I'm not sure what to do about it though. I could link to the pages about running games and callbacks, but there are other important LOVE concepts... and even then, what about people who are unfamiliar with Lua? I'll keep this in mind, I might even write something myself.

That JavaScript code is really nifty! It is true that the pages are quite long, but I'm not sure if having a table of contents would be that useful though, because unlike the ZeroBrane Studio documentation for example, the tutorials are very sequential and I'm not sure why someone would want to jump to a specific point. Let me know if I'm missing something.

easy82, thank you! :)

Zireael, sounds good to me, somebody should make one! ;) If anyone wants more simple game ideas for tutorials, let me know, I have a few.

Re: Simple game tutorials

Posted: Tue Oct 18, 2016 12:08 pm
by davisdude
Santos wrote:I'm not completely sure which common practices you're referring to, feel free to let me know exactly what you mean
I was talking about things like OOP (or ECS), camera systems, state systems, vectors, etc. Just things that are used pretty frequently within games.
Santos wrote:Because I don't think it would help toward the goal of these tutorials, which is to take people from the stage of not knowing how to think about programming a simple game, to being able to.
That makes sense. I think it might be good to put a section like "What's Next?" at the end that includes more advanced (but still simple) tutorials and concepts to learn. These concepts should stay in the realm of "simple/beginner" but would be useful, IMO.

Re: Simple game tutorials

Posted: Tue Oct 18, 2016 1:54 pm
by Santos
I think vector math is definitely something that would be good to include in a tutorial. I think an Asteroids tutorial with vectors all over the place and everything drawn with love.graphics.line and collision detection by line intersection testing and transformation matrices for rotation or whatever (I don't know much about this stuff!) would be great.

Cameras and state systems could be cool too. I feel like OOP and ECS are definitely in "architecture territory" which I want these tutorials to avoid.

I'd point people toward more advanced stuff, but really I'm a noob, so I don't think I should tell people what more advanced stuff is important because I don't know what's important! :P But I really like the "what's next?" idea, because tutorials kind of take you from point A to point B knowledge-wise, and they can leave you stranded at point B. The only learning resource I feel comfortable recommending is Handmade Hero, but that's kind of in another programming world from these tutorials. The Red Blob Games articles seem good also.