ZIYI CHEN ml17z4c 201214999
Dependencies: mbed
Food/Food.cpp
- Committer:
- ziyi11
- Date:
- 2019-05-08
- Revision:
- 9:a8b2086a46e5
- Parent:
- 8:52e0506e98b8
File content as of revision 9:a8b2086a46e5:
#include "Food.h" Food::Food() { } Food::~Food() { } void Food::init(int x, int y) { _x = x; _y = y; } int Food::xcoordinate() { return _x; } int Food::ycoordinate() { return _y; } void Food::random() { _x = rand() % 40; _y = rand() % 20; }