internal static void ResizeAndFillArrays()
{
Array.Resize(ref Main.backgroundTexture, nextBackground);
Array.Resize(ref Main.backgroundHeight, nextBackground);
Array.Resize(ref Main.backgroundWidth, nextBackground);
Array.Resize(ref Main.backgroundLoaded, nextBackground);
foreach (string texture in backgrounds.Keys)
{
int slot = backgrounds[texture];
Main.backgroundTexture[slot] = ModLoader.GetTexture(texture);
Main.backgroundWidth[slot] = Main.backgroundTexture[slot].Width;
Main.backgroundHeight[slot] = Main.backgroundTexture[slot].Height;
Main.backgroundLoaded[slot] = true;
}
}