Snake - The basic game is complete!

Published August 31, 2019
Advertisement

As of last night, I managed to complete everything I wanted for the basic game.  The menu system is in place, all the game options are working, there's a full screen option, and I worked through some minor issues that I wanted to address.  Full source code, and the 1.1 release, are available on my GitHub account.

goe-options-screen.jpg.b6c209c20ff263f335fb447e190ab044.jpg

goe-gameplay.jpg.f46d5fd4fa881d93a065c83c2e92dc3d.jpg

That puts me on track to start "phase 2", where I'll be working on a story mode with level progression.  I think I have some neat-o ideas:

  • Different types of fruits / veggies that have different effects on the snake.
  • Each level will have its own design (ie. not just a rectangular playing area) and new types of barriers.
  • A fun / silly story line where Adam has trapped the snake (you!) in his maze, to get revenge for tricking Eve into eating from the tree of knowledge of good and evil.  I don't want to call them "cutscenes" really, but there will be some voiced scenes between each level as Adam throws increasingly difficult dangers into the mix.

Here are some notes that might be of interest:

  • While I used Photoshop to create the images used for the icon, there's a rather nice free Icon editor out there called Greenfish Icon Editor Pro.  This is what I used to combine the various icon sizes, and export as the *.ico file.
  • I wanted to create a setup / installer program for the game.  I used Inno Setup for this.  I was hoping this would automatically solve the issue of Windows security blocking the program from running by default.  It looks like I'll need to investigate a "signing tool" to achieve this.  For now, Windows 10 users have to manually unblock the program if they want to run it.
  • One of the issues I tackled was related to the rendering of the grass and shrubs that make up the playing field.  Originally, this was done using individual draw calls for every single tile.  When I pulled the grass and shrub textures out into their own separate *.png files, and turned on texture repeating, this allowed me to render the entire grass with one draw call; and the shrub barriers with four draw calls.  This was a significant performance improvement, shaving off about 3 milliseconds per rendering frame.  Given that you only have 16.67 milliseconds to get everything done in one frame, that's pretty huge!
1 likes 0 comments

Comments

Rutin

Do you have a zip just with the game exe + required files? I'm not a fan of using installers for such games.

August 31, 2019 06:08 PM
rileyman

I'll probably just do the portable zip release going forward:  https://github.com/ryantherileyman/riley-basic-games/blob/master/garden_of_eating_1_1_0.zip

September 01, 2019 02:55 AM
Rutin

Works great! Good job on making this! :) 

September 01, 2019 07:46 AM
rileyman

Thanks! ?  Glad to know it at least works on more than just my machine, haha!

I spent most of yesterday and this morning ironing out my design specs for story mode.  I'm not really time-boxing myself for this, so I think everything in there is do-able.  After this, I'm wanting to move forward to a 2D scroller of some kind, so I want to get a bit of experience loading levels and assets dynamically using a really simple game as the base.

I tried out your pac-man style game.  Nice smooth scrolling, and the spinning ice blocks are a nice touch.  One thing I didn't think of was the ability to toggle music / sound during game play.  Maybe someday after I've gone through another game or two, I'll try out one of the challenges.  For now I just want to have fun making something simple -- that feeling of actually getting something *done* is just what I needed. ;)

September 01, 2019 10:02 PM
You must log in to join the conversation.
Don't have a GameDev.net account? Sign up!
Advertisement