Index: src/com/medievaltech/advancewars/GameView.java
===================================================================
--- src/com/medievaltech/advancewars/GameView.java	(revision b97a61801c2efdfad66c28c6dcde99b537243f98)
+++ src/com/medievaltech/advancewars/GameView.java	(revision 113d7cfbe433bf0f295c897fe301c6e7b1c3cf4e)
@@ -1,5 +1,8 @@
 package com.medievaltech.advancewars;
 
-import com.medievaltech.game.*;
+import java.io.*;
+
+import com.medievaltech.advancewars.Tile.TerrainType;
+import com.medievaltech.unit.*;
 import com.medievaltech.gui.*;
 
@@ -12,13 +15,4 @@
 import android.widget.TextView;
 
-/**
- * View that draws, takes keystrokes, etc. for a simple LunarLander game.
- * 
- * Has a mode which RUNNING, PAUSED, etc. Has a x, y, dx, dy, ... capturing the
- * current ship physics. All x/y etc. are measured with (0,0) at the lower left.
- * updatePhysics() advances the physics based on realtime. draw() renders the
- * ship, and does an invalidate() to prompt another draw() as soon as possible
- * by the system.
- */
 class GameView extends SurfaceView implements SurfaceHolder.Callback {
 	
@@ -39,5 +33,4 @@
         private int mCanvasHeight = 1;
         private int mCanvasWidth = 1;
-        public int mPlayerWins = 0, mPlayerLosses = 0;
 
         /** Message handler used by thread to interact with TextView */
@@ -51,5 +44,8 @@
         	mUnitPaint;
         
-        private Map mMap;
+        //maybe make this private and make an accessor for it
+        public Map mMap;
+        
+        public Tile grassTile, oceanTile;
 
         /** Indicate whether the surface has been created & is ready to draw */
@@ -59,5 +55,5 @@
         private SurfaceHolder mSurfaceHolder;
         
-        private com.medievaltech.gui.Window wndMainMenu, wndBattleMap;
+        private com.medievaltech.gui.Window wndMainMenu;
         private Unit selectedUnit;
         
@@ -66,5 +62,4 @@
             mSurfaceHolder = surfaceHolder;
             mHandler = handler;
-            mContext = context;
             
             mLinePaint = new Paint();
@@ -107,6 +102,6 @@
             wndMainMenu.addGUIObject("btnQuit", new Button("Quit", 100, 195, 120, 20, mLinePaint, mButtonPaint));
             
-            Tile grassTile = new Tile(mTilePaint1);
-            Tile oceanTile = new Tile(mTilePaint2);
+            grassTile = new Tile(mTilePaint1, TerrainType.LAND);
+            oceanTile = new Tile(mTilePaint2, TerrainType.SEA);
             
             mMap = new Map(grassTile, 6, 8, new Point(10, 25));
@@ -336,7 +331,4 @@
         private void doDraw(Canvas canvas) {
         	canvas.drawColor(Color.BLACK);
-        	
-        	String text;
-        	Paint.FontMetrics metrics = mTextPaint.getFontMetrics();
         	
         	switch(mGameState) {
@@ -380,7 +372,4 @@
     }
 
-    /** Handle to the application context, used to e.g. fetch Drawables. */
-    private Context mContext;
-
     /** Pointer to the text view to display "Paused.." etc. */
     private TextView mStatusText;
@@ -421,4 +410,46 @@
     				thread.mGameState = GameState.BATTLE_MAP;
     			}else if(thread.wndMainMenu.getGUIObject("btnLoadGame").isClicked(event.getX(), event.getY())) {
+    				BufferedReader b;
+            		try {
+            			b = new BufferedReader(new FileReader(android.os.Environment.getExternalStorageDirectory()+"/save.txt"));
+            			
+            			int width = Integer.parseInt(b.readLine());
+            			int height = Integer.parseInt(b.readLine());
+            			
+            			String offset = b.readLine();
+            			Log.i("GameSave", offset);
+            			int offsetX = Integer.parseInt(offset.substring(0, offset.indexOf("x")));
+            			int offsetY = Integer.parseInt(offset.substring(offset.indexOf("x")+1));
+            			
+            			thread.mMap = new Map(thread.grassTile, width, height, new Point(offsetX, offsetY));
+            			
+            			Log.i("GameSave", "Created the map");
+            			
+            			for(int x=0; x<width; x++) {
+            				String line = b.readLine();
+            				Log.i("GameSave", line);
+            				String[] arr = line.split(",");
+            				for(int y=0; y<arr.length; y++) {
+            					TerrainType type = TerrainType.values()[Integer.parseInt(arr[y])];
+            					if(type.equals(TerrainType.LAND))
+                					thread.mMap.setTile(x, y, new Tile(thread.grassTile, new Point(10, 25)));
+                				else
+                					thread.mMap.setTile(x, y, new Tile(thread.oceanTile, new Point(10, 25)));
+            				}
+            			}
+            			
+            			while(b.ready()) {
+            				String unit = b.readLine();
+            				Log.i("GameSave", unit);
+            				int x = Integer.parseInt(unit.substring(0, unit.indexOf(",")));
+                			int y = Integer.parseInt(unit.substring(unit.indexOf(",")+1));
+            				
+            				mGame.mThread.mMap.getTile(x, y).addUnit(new Soldier(mGame.mThread.mUnitPaint));
+            			}
+            			
+            			b.close();
+            		}catch(IOException ioe) {
+            			ioe.printStackTrace();
+            		}
     				thread.mGameState = GameState.BATTLE_MAP;
     			}else if(thread.wndMainMenu.getGUIObject("btnQuit").isClicked(event.getX(), event.getY())) {
