Thomas Davies / Mbed 2 deprecated LetTheBallDrop

Dependencies:   N5110 mbed PowerControl

Revision:
1:3305d7e44880
Parent:
0:c2c1df1163f1
Child:
2:d4402bc3dd45
--- a/GameScreen.cpp	Sat Mar 07 01:49:37 2015 +0000
+++ b/GameScreen.cpp	Sat Mar 07 09:58:29 2015 +0000
@@ -2,4 +2,31 @@
 #include "N5110.h"
 #include "GameScreen.h"
 
-//void GameScreen::moveBall(int xPos,int yPos){}
\ No newline at end of file
+//need to extend on initialization to set some variables
+void GameScreen::Initialize()
+{
+    init();
+    
+    platGapSize = 4;
+    platThickness = 2;
+    maxX_ = 48;
+    maxY_ = 84;
+    
+        
+}
+
+//draw platform
+//  ___________  ________  < y
+//               ^ x       
+void GameScreen::drawPlatform(int x,int y)
+{
+
+    
+    for (int a = 0; a < 48; a ++)
+    {
+        for (int b = y; b < (y+platThickness); b++)
+        {
+            setPixel(b,a);    
+        }
+    }
+}
\ No newline at end of file