LogDoctor/docs/html/classSnake.html

7.5 KiB

<html xmlns="http://www.w3.org/1999/xhtml" lang="en-US"> <head> </head>
LogDoctor 2.00
Parse Apache2/Nginx/IIS logs and create statistics
Loading...
Searching...
No Matches
Inheritance diagram for Snake:

Classes

struct  Tile
 

Public Member Functions

const bool inTile (const unsigned int &x, const unsigned int &y, const bool &avoid_tail=true)
 Checks whether is there a part of the snake in the given position.
 
void setDirection (const Direction new_direction)
 Sets the new direction (of the head)
 
const Direction & direction ()
 Returns the current direction (of the head)
 
void update (QGraphicsScene *field_scene=nullptr, const bool &dry=false, const bool &is_borning=false)
 Updates the position and direction of the entire snake.
 

Private Member Functions

void grow (const bool &is_borning)
 Increases the length of the body of the snake of 1 part.
 

The documentation for this class was generated from the following files:
  • logdoctor/games/snake/snake.h
  • logdoctor/games/snake/snake.cpp

Generated by doxygen 1.9.5 </html>