![](/media/cache/img/default_profile.jpg.50x50_q85.jpg)
testing documentation
Dependencies: mbed ll16j23s_test_docs
Diff: Food/Food.h
- Revision:
- 12:33a5cff31339
- Parent:
- 10:a2d643b3c782
--- a/Food/Food.h Tue May 26 23:29:22 2020 +0000 +++ b/Food/Food.h Tue May 26 23:57:47 2020 +0000 @@ -13,8 +13,6 @@ @version V1.0 */ - - class Food { @@ -23,9 +21,32 @@ Food(); ~Food(); + + /** Initialises magnetometer and seeds random function + *@param Gamepad + *@param LCD + *@param Magnetometer + */ void init(Gamepad &pad, N5110 &lcd, FXOS8700CQ &mag); + + + /** Chooses random coordinates for food + *@param Gamepad + *@param LCD + *@returns returns true if selected position is already on (ie the snake or walls are at this coordinate) + */ bool rand_pos(Gamepad &pad, N5110 &lcd); - void draw(N5110 &lcd, int &_frame); + + + /** Animates food + *@param LCD + */ + void draw(N5110 &lcd); + + + /** Runs food functions that need looping + *@param LCD + */ void run(N5110 &lcd); int _x;