Triggering a switch based on the presence of a file

Hi there!

Is there any way I can make my game look if a certain file is present in the game folder and then trigger a switch if the file is present?

The point is to add secret content to the game that is only activated if the player patches the game by adding a file with a specific name. Could just be an empty .txt file, as long it's present.
You'll want to use the node Filesystem "existssync" function

https://nodejs.org/api/fs.html#fs_fs_existssync_path

Original thread: https://forums.rpgmakerweb.com/threads/triggering-a-switch-based-on-the-presence-of-a-file.104181/