Or did I miss it, how can one actually see in a game? It has become clearer to me what game development is all about. It has taken me only a week and I’m knee deep in the swamp of questions about game development fundamentals. And I’m loving it.
Every problem that arise while further designing my game seems to be much harder than the previous one. I read some articles about game development which anticipated the importance of scope. However it has really struck me how big of a challenge it is actually to decide and focus what to do next. As I’m a one man game studio I get to do all the neat stuff by myself!
I decided not to build graphics yet as the game is lacking so many fundamental things. Even though making some nice graphics would be really fun but that would only mess up the code. I currently have no ways to separate layout and functionality. Okay, so I decided to continue building some more core elements to make the game worth playing. I somehow managed to build a simple AI for an offensive melee unit in a grid based movement.
Next challenge: Ranged attack
Next challenge is to build a ranged attack. This is a point where math at the latest kicks in. I’m trying to figure out Bresenham’s line algorithm.
Here’s a modified and maybe a more useful adaptation of it called “Bresenham-based supercover line algorithm”:
http://lifc.univ-fcomte.fr/~dedu/projects/bresenham/index.html
Bresenham’s algorithm explained:
http://www.gamedev.net/page/resources/_/technical/game-programming/line-drawing-algorithm-explained-r1275
Here’s an implementation in PHP:
http://alex.moutonking.com/wordpress/?p=44
Here’s another link about the implementation of Bresenham’s algorithm in other programming languages:
http://roguebasin.roguelikedevelopment.org/index.php?title=Bresenham’s_Line_Algorithm
Now if you’ll excuse me, I have some studying to do.