public void Setup(ContentManager Content, LevelSave Source) { if (Source is null) { return; } Floors.Clear(); Main.Objects = Source.LoadedObjects; Floor = Content.Load <Texture2D>("Floor"); SetFlooring(Source); }
public void SetFlooring(LevelSave Source) { for (int i = 0; i < Source.LevelSize.X; i += Floor.Width) { for (int h = 0; h < Source.LevelSize.Y; h += Floor.Height) { Floors.Add(new Point(i, h)); column = h; } row = i; } column += Floor.Height; row += Floor.Width; Source.LevelSize = new Point(row, column); }