public GridCoordinates(float X, float Y, IMapGrid argGrid) { Position = new Vector2(X, Y); GridID = argGrid.Index; }
public GridCoordinates(float X, float Y, GridId argGrid) { Position = new Vector2(X, Y); GridID = argGrid; }
public GridCoordinates(Vector2 argPosition, GridId argGrid) { Position = argPosition; GridID = argGrid; }
/// <summary> /// Construct new grid local coordinates relative to the default grid of a map. /// </summary> public GridCoordinates(Vector2 argPosition, IMap argMap) { Position = argPosition; GridID = argMap.DefaultGrid.Index; }
public LocalCoordinates(float X, float Y, GridId argGrid, MapId argMap) { Position = new Vector2(X, Y); GridID = argGrid; MapID = argMap; }
public GridCoordinates(Vector2 argPosition, IMapGrid argGrid) { Position = argPosition; GridID = argGrid.Index; }
public LocalCoordinates(Vector2 argPosition, GridId argGrid, MapId argMap) { Position = argPosition; GridID = argGrid; MapID = argMap; }
public LocalCoordinates(float X, float Y, IMapGrid argGrid) { Position = new Vector2(X, Y); GridID = argGrid.Index; MapID = argGrid.MapID; }
public LocalCoordinates(Vector2 argPosition, IMapGrid argGrid) { Position = argPosition; GridID = argGrid.Index; MapID = argGrid.MapID; }
public void RaiseOnGridRemoved(MapId mapId, GridId gridId) { OnGridRemoved?.Invoke(mapId, gridId); }
/// <summary> /// Gets the grid associated with the given grid ID. If the grid with the given ID does not exist, return null. /// </summary> /// <param name="gridId">The id of the grid to get.</param> /// <returns></returns> public IMapGrid GetGrid(GridId gridId) { _grids.TryGetValue(gridId, out var output); return(output); }
/// <summary> /// Checks if a grid exists with the given ID. /// </summary> /// <param name="gridId">The ID of the grid to check.</param> /// <returns></returns> public bool GridExists(GridId gridId) { return(_grids.ContainsKey(gridId)); }
public IMapGrid GetGrid(GridId gridID) { return(_grids[gridID]); }