public ChunkedMapEngine(Rectangle ScreenRectangle, ChunkedMap map, MapCamera mapCamera, int threadSleepMilliseconds) { Map = map; MaxChunkIndices = new Vector2((Map.MapRectangle.Width / Map.ChunkSize.X) - 1, (Map.MapRectangle.Height / Map.ChunkSize.Y) - 1); ExclusiveContentManager = new ExclusiveContentManager(GameEnvironment.Game.Content.ServiceProvider, GameEnvironment.Game.Content.RootDirectory); MapCamera = mapCamera; Chunks = new List <int>(); ChunkIndices = new List <Vector2>(); ChunkIndicesToDraw = new List <Vector2>(); ChunkTextures = new Dictionary <int, Texture2D>(); LastLoadedChunks = new List <int>(); CentralChunkPosition = new Vector2(); CentralChunkIndices = new Vector2(); LastCentralChunkIndices = new Vector2(); HasUpdated = false; ThreadSleepMilliseconds = threadSleepMilliseconds; }
public UnboundedMapEngine(Rectangle ScreenRectangle, ChunkedMap map, MapCamera mapCamera, int threadSleepMilliseconds, bool isRepeatRandom) : base(ScreenRectangle, map, mapCamera, threadSleepMilliseconds) { IsRepeatRandom = isRepeatRandom; }