using Microsoft.Xna.Framework; using xTile; namespace StardewModdingAPI { /// Encapsulates access and changes to map content being read from a data file. public interface IAssetDataForMap : IAssetData { /********* ** Public methods *********/ /// Copy layers, tiles, and tilesheets from another map onto the asset. /// The map from which to copy. /// The tile area within the source map to copy, or null for the entire source map size. This must be within the bounds of the map. /// The tile area within the target map to overwrite, or null to patch the whole map. The original content within this area will be erased. This must be within the bounds of the existing map. /// Indicates how the map should be patched. void PatchMap(Map source, Rectangle? sourceArea = null, Rectangle? targetArea = null, PatchMapMode patchMode = PatchMapMode.Overlay); /// Extend the map if needed to fit the given size. Note that this is an expensive operation and resizes the map in-place. /// The minimum map width in tiles. /// The minimum map height in tiles. /// Whether the map was resized. bool ExtendMap(int minWidth = 0, int minHeight = 0); } }