\r
#region Public Methods\r
\r
+ /// <summary>\r
+ /// Get an entity at a certain place on the map.\r
+ /// </summary>\r
+ /// <param name="point">The coordinates.</param>\r
+ /// <returns>The entity, or null if none is at that location.</returns>\r
public IEntity GetEntityAtCoordinates(Point point)\r
{\r
foreach (IEntity entity in State.Entities)\r
return null;\r
}\r
\r
+ /// <summary>\r
+ /// Get a player at a certain place on the map.\r
+ /// </summary>\r
+ /// <param name="point">The coordinates.</param>\r
+ /// <returns>The player, or null if none is at that location.</returns>\r
public Player GetPlayerAtCoordinates(Point point)\r
{\r
foreach (Player player in State.mCharacters)\r
return null;\r
}\r
\r
+ /// <summary>\r
+ /// Determine if a cell is open, depending on the static scenery\r
+ /// of the map and if there are any collidable entities.\r
+ /// </summary>\r
+ /// <param name="point">The coordinates.</param>\r
+ /// <returns>True if the cell is open; false otherwise.</returns>\r
public bool IsCellOpen(Point point)\r
{\r
if (!State.Map.IsCellOpen(point)) return false;\r
return true;\r
}\r
\r
+ /// <summary>\r
+ /// Remove a specific entity from the game. The entity can still\r
+ /// be tracked some other way, but it won't included when the game is\r
+ /// updating and drawing stuff.\r
+ /// </summary>\r
+ /// <param name="entity">The entity.</param>\r
+ /// <returns>The entity that was removed, or null if no entity was removed.</returns>\r
+ public IEntity RemoveEntity(IEntity entity)\r
+ {\r
+ if (State.Entities.Remove(entity)) return entity;\r
+ return null;\r
+ }\r
+\r
+ /// <summary>\r
+ /// Move on to the next map, and advance the level.\r
+ /// </summary>\r
+ public void AdvanceLevel()\r
+ {\r
+ // TODO: Load the next map, etc...\r
+ }\r
+\r
+ /// <summary>\r
+ /// Restart the current level.\r
+ /// </summary>\r
+ public void Reset()\r
+ {\r
+ State.Map.Reset();\r
+ // TODO: Do other stuff to reset everything.\r
+ }\r
+\r
+\r
public Game()\r
{\r
\r