Reload window icon when mounting and unmounting assets

The window icon is simply another asset that can be customized by level
makers. And in fact, one of my levels changes the window icon. It's
simply named VVVVVV.png, but it doesn't sit in the graphics folder,
rather it sits in the root VVVVVV directory.

I noticed that this asset was missed when per-level assets loading was
added, so I decided to add it in.

There's a NULL check on screenbuffer because reloadresources() gets
called before screenbuffer's init() does.
This commit is contained in:
Misa authored and Ethan Lee committed 2020-11-01 13:59:13 -05:00
1 parent 6d8b8d08b9
commit c590c4b436
1 file changed
+5
+5
View File
@@ -3242,6 +3242,11 @@ void Graphics::reloadresources() {
images.push_back(grphx.im_image11);
images.push_back(grphx.im_image12);
if (screenbuffer != NULL)
{
screenbuffer->LoadIcon();
}
music.init();
}