Exemplo n.º 1
0
 /// <summary>
 ///     Constructs new grid local coordinates.
 /// </summary>
 /// <param name="position">Position relative to the grid.</param>
 /// <param name="gridId">ID of the Grid the position is relative to.</param>
 public GridCoordinates(Vector2 position, GridId gridId)
 {
     Position = position;
     GridID   = gridId;
 }
Exemplo n.º 2
0
 /// <summary>
 ///     Constructs new grid local coordinates.
 /// </summary>
 /// <param name="x">X axis of the position.</param>
 /// <param name="y">Y axis of the position.</param>
 /// <param name="gridId">ID of the Grid the position is relative to.</param>
 public GridCoordinates(float x, float y, GridId gridId)
     : this(new Vector2(x, y), gridId)
 {
 }
Exemplo n.º 3
0
 /// <summary>
 ///     Constructs a new instance of TileRef.
 /// </summary>
 /// <param name="mapId">Identifier of the map this tile belongs to.</param>
 /// <param name="gridId">Identifier of the grid this tile belongs to.</param>
 /// <param name="xIndex">Positional X index of this tile on the grid.</param>
 /// <param name="yIndex">Positional Y index of this tile on the grid.</param>
 /// <param name="tile">Actual data of this tile.</param>
 internal TileRef(MapId mapId, GridId gridId, int xIndex, int yIndex, Tile tile)
     : this(mapId, gridId, new MapIndices(xIndex, yIndex), tile)
 {
 }