Hi, I'm searching for a JS that do the event will not work if a file (test.asd for example) didn't exist.
Any idea? (Sorry for bad english)
Any idea? (Sorry for bad english)
Hmm that's really odd honestly... uploading a demo project to the plugin's page.
what the heck??? that's really strange... and no other error messages?
Sorry, new in this. What is and how can I donwload it?
var CTB = CTB || {}; CTB.File = CTB.File || {};
var Imported = Imported || {}; Imported["CT_Bolt File"] = 1.00;
"use strict";
(function ($_$) {
$_$.Check = function(file) {if (file){var fs = require('fs');try {var stats = fs.statSync(file);return stats.isFile();}catch (e){return false;};}}
})(CTB.File, this);
var CTB = CTB || {}; CTB.File = CTB.File || {};
var Imported = Imported || {}; Imported["CT_Bolt File"] = 1.00;
"use strict";
(function ($_$) {
$_$.Check =(file)=> {if (file){var fs = require('fs');try {var stats = fs.statSync(file);return stats.isFile();}catch (e){return false;};}};
})(CTB.File, this);
Well, now there isn't errors in console! But it doesn't work well, Did I something wrong?
And is it, in the demo is the same, the two events says file not found
this is honestly very strange... works perfect for me on my end...
Yeah, I used this two codes. The largest send my a error in console and the shortest says that the file doesn't exist
Original thread: https://forums.rpgmakerweb.com/threads/needs-a-file-for-event.121557/