Watch Out, There Is a Snake in MATLAB!!!


Somewhere in the early December, I created a MATLAB code for classic snake game. It is relatively easy and simple so it only took a couple hours to finish the code. However, I decided not to post it yet in my MATLAB Fun Toolbox page because I want to do a little improvement for the graphics. Yup, instead of just using a single color pixelated snake, I wanted my snake to have texture and even have a visualization of its head and tail. Unfortunately, after almost two weeks, now DEcember almost ends and I haven’t made any improvement for the codes (Blame me, it’s holiday season and I want to be lazy). So, to avoid me forgeting to post this MATLAB Snake code, I decided to put it now at my MATLAB Fun Toolbox page and update it later.

So, here is several screenshot of my MATLAB snake code (The graphic is a disaster and I’m gonna improve it later):

MATLAB Snake – Screenshot 1

MATLAB Snake – Screenshot 2

MATLAB Snake – Screenshot 3

MATLAB Snake – Screenshot 4

MATLAB Snake – Screenshot 5

I’ve also uploaded a (bad quality) video of my MATLAB snake in youtube. Here is the video if you want to see the animation that I made for this code:

As usual, this code is free for you all and can be downloaded from my MATLAB Fun Toolbox. Please feel free to download it and give any comments or critics. FYI, for the next code in my MATLAB Fun Toolbox, I’m gonna write MATLAB Congklak code. It is a traditional bean-counting game from my country. However, I think it is gonna take awhile to finish the code because the algorithm is quite complex for the AI and I want to incorporate a pretty nice animation to make the game look nice. Please look forward to it:D…

Regards,

0X_R

Update for this post: MATLAB Othello and MATLAB Snake – A Better Video Demo

This entry was posted in Uncategorized and tagged , , . Bookmark the permalink.

2 Responses to Watch Out, There Is a Snake in MATLAB!!!

  1. George says:

    I have problems running that program in MATLAB..it gets unexpected MATLAB operator…I’ll appreciate your help

Leave a Reply

Fill in your details below or click an icon to log in:

WordPress.com Logo

You are commenting using your WordPress.com account. Log Out / Change )

Twitter picture

You are commenting using your Twitter account. Log Out / Change )

Facebook photo

You are commenting using your Facebook account. Log Out / Change )

Google+ photo

You are commenting using your Google+ account. Log Out / Change )

Connecting to %s