Skip to content

arogers1/PySnakeAI

 
 

Folders and files

NameName
Last commit message
Last commit date

Latest commit

 

History

6 Commits
 
 
 
 
 
 
 
 
 
 
 
 
 
 

Repository files navigation

PySnakeAI

Forked from rwdavis.

This is adapated from the Snake Game on pygame.org

http://pygame.org/project-Snake+in+35+lines-818-.html

It has been slightly modified to allow an AI interface in the future.

dirs is the next move of the snake. 0=Down, 1=Right, 2=Up, 3=Left

sg.xs and sg.ys are the current positions of the snake sg.applepos is the position of the apple

##UPDATE 4-20-16: Now has an AI interface. The AI class simply needs to have a get_input() method and to accept the SnakeGame object as a constructor parameter.

About

No description, website, or topics provided.

Resources

Stars

Watchers

Forks

Releases

No releases published

Packages

No packages published

Languages

  • Python 100.0%