multiplayer pong game for LPC 1768

Dependencies:   mbed MbedJSONValue mbed-rtos Adafruit_ST7735 Adafruit_GFX EthernetInterface DebouncedInterrupt

Revision:
15:9d90f68e53da
Child:
17:32ae1f106002
--- /dev/null	Thu Jan 01 00:00:00 1970 +0000
+++ b/gamestate.cpp	Thu Nov 12 05:51:00 2020 +0000
@@ -0,0 +1,31 @@
+#include "gamestate.h"
+
+GameState::GameState() {
+    Coord playerOneLocation = {0, 0};
+    Coord playerTwoLocation = {0, 0};
+    Coord ballLocation = {0, 0};
+    this->p1_loc = playerOneLocation;
+    this->p2_loc = playerTwoLocation; 
+    this->ball_loc = ballLocation; 
+    this->is_done = false; 
+}
+
+Coord GameState::getPlayerOneLocation() {
+    return this->p1_loc; 
+}
+
+Coord GameState::getPlayerTwoLocation() {
+    return this->p2_loc; 
+} 
+
+Coord GameState::getBallLocation() {
+    return this->ball_loc; 
+}
+
+void GameState::update(char *server_data) {
+    
+}
+
+bool GameState::done() {
+    return this->is_done; 
+}