I export my game in NW.js for Steam. I need a way to automatically save a snapshot to a specific folder (Desktop/DinoSystem or Documents/DinoSystem).
I succesfully did something similiar with save dialog using js:
"var fs = require('fs');fs['writeFileSync']('" &replace(NodeWebkit.ChosenPath,"\","\\")& "','" &CanvasSnapshot& "'.split(',')[1], {'encoding': 'base64'});"
But now i need it to automatically save the screen in the aforementioned folder! Any hint?