MZ MZ Resolution Plugin

I had found these two plugins:
LZ Screen Resolution didn't work for me in any of my projects. I just made a plugin that adjusts the resolution. When I set the resolution from within the plugin manager, it works perfectly. When I change the resolution within options like the player, it changes, but it doesn't look right. Players go into the menu, press right or left and it changes the resolution. To get the plugin to work right as a player, I have to change the resolution, return to the title screen, then go back to the save file, and upon returning it is normal. I added a section to adjust the black screen sides in the code, but it isn't working right.

Does anyone see what I'm doing wrong with it?

Original thread: https://forums.rpgmakerweb.com/threads/mz-resolution-plugin.180219/