MV [Solved] Needing edit to Foreground plug-in

Hello fellow game makers!
I am using the Foreground plug-in on a few of my maps, and it's great. I use it for shadows mainly. However, I added a time system, and... well... shadows seem goofy at night, and make the screen so dark, the Player cannot see.
Is there a way to edit the plug-in to allow for a script call that turns the image on/off? I'd love to throw that on there so that at x time, an event will turn it on/off automatically.
Thank you!
Spoiler: plugin information
1713904237425.png
There probably is already a function it's calling after it reads the map notes. You'll have to link the plugin if you want someone to look for that function for you.
There probably is already a function it's calling after it reads the map notes. You'll have to link the plugin if you want someone to look for that function for you.
I'm fairly sure it comes with RMMV.
Edit: confirmed, it comes with RMMV as a DLC.
Just going by the plugin's instructions, it doesn't do what you want.

You would either use a different method to get the shadows, or keep that plugin and make multiple copies of the map to transfer the player to depending on the time of day.
Just going by the plugin's instructions, it doesn't do what you want.

You would either use a different method to get the shadows, or keep that plugin and make multiple copies of the map to transfer the player to depending on the time of day.
Thank you very much for having a look.
Yes/no question: would it be worthwhile for me to build-in the script calls? I'm tempted to try my hand at it; what kind of time investment would it likely be?
Thank you very much for having a look.
Yes/no question: would it be worthwhile for me to build-in the script calls? I'm tempted to try my hand at it; what kind of time investment would it likely be?
Realistically, if you have no programming background I'm guessing hours until you manage to stumble upon the right script in the right place or until you give up.

E: Could you post what settings you're using for your map notetags?
Realistically, if you have no programming background I'm guessing hours until you manage to stumble upon the right script in the right place or until you give up.

E: Could you post what settings you're using for your map notetags?
I do have programming experience, Javascript is just something I haven't officially learned in a long time. I can certainly provide that screenshot, though.
Spoiler: Notetag
1713924769649.png
Hi there!
I think you can try to set the alpha(opacity) value of the foreground to a variable value.
Open the plugin with any text editor, and on the last function of the plugin, you can add a line:

this._foreground.alpha = $gameVariables.value(ID)
or
this._foreground.visible = $gameSwitches.value(ID)

one or another. Replace ID with the ID of a switch or variable you want to use.
For the variable, when it's value is 1 it will be visible. When it is 0, it will be invisible.

For the switch, when the switch is OFF it will be invisible. When it is ON, it will be visible.
Example:
1713925693296.png
Hi there!
I think you can try to set the alpha(opacity) value of the foreground to a variable value.
Open the plugin with any text editor, and on the last function of the plugin, you can add a line:

this._foreground.alpha = $gameVariables.value(ID)
or
this._foreground.visible = $gameSwitches.value(ID)

one or another. Replace ID with the ID of a switch or variable you want to use.
For the variable, when it's value is 1 it will be visible. When it is 0, it will be invisible.

For the switch, when the switch is OFF it will be invisible. When it is ON, it will be visible.
Example:
View attachment 302862
This worked BEAUTIFULLY. Thank you so so much!
I have to play with my conditional statements now, thank you!

This thread is being closed, due to being solved. If for some reason you would like this thread re-opened, please report this post and leave a message why. Thank you.

Original thread: https://forums.rpgmakerweb.com/threads/solved-needing-edit-to-foreground-plug-in.168021/