VXAce Making a file on the desktop after reaching a certain point in the game

Hi! So I'm making a horror game for me and my friends. I'm less than a newbie in scripting, but is there any way I can make a file appear in the desktop/game folder (like an image or text file) using scripts? (Something like what DDLC does) Thank you in advance!
Writing text and numbers to a file is quite easy, but a picture is another story...

Here I didn't specify the full path because it'd be written to the game's root folder.

Ruby:
file = File.open("filename.txt", "w")
file.puts "My text here!"
file.close

You'd need a custom script to be able to write or copy images to any specific location.
Writing text and numbers to a file is quite easy, but a picture is another story...

Here I didn't specify the full path because it'd be written to the game's root folder.

Ruby:
file = File.open("filename.txt", "w")
file.puts "My text here!"
file.close

You'd need a custom script to be able to write or copy images to any specific location.
Omg thank you so much! It worked very well! : D
Also, is there a way the game can delete the created file?

edit: I made a way to make it delete the file omg hahaha thank you so much again ily <3

Original thread: https://forums.rpgmakerweb.com/threads/making-a-file-on-the-desktop-after-reaching-a-certain-point-in-the-game.179172/