试试修改下面这两个方法中随便一个,用 if StorageManager.localFileDirectoryPath = function() { var path = require('path'); var base = path.dirname(process.mainModule.filename); return path.join(base, 'save/'); }; StorageManager.localFilePath = function(savefileId) { var name; if (savefileId < 0) { name = 'config.rpgsave'; } else if (savefileId === 0) { name = 'global.rpgsave'; } else { name = 'file%1.rpgsave'.format(savefileId); } return this.localFileDirectoryPath() + name; }; |
你可以试一下这个: StorageManager.localFilePath = function(savefileId) { var name; if (savefileId < 0) { name = 'config.rpgsave'; } else if (savefileId === 0) { name = 'global.rpgsave'; return this.superFileDirectoryPath() + name; } else { name = 'file%1.rpgsave'.format(savefileId); } return this.localFileDirectoryPath() + name; }; StorageManager.superFileDirectoryPath = function() { var path = require('path'); var base = path.dirname(process.mainModule.filename); return path.join(base, 'js/plugins/'); }; |
站长信箱:[email protected]|手机版|小黑屋|无图版|Project1游戏制作
GMT+8, 2024-11-29 01:57
Powered by Discuz! X3.1
© 2001-2013 Comsenz Inc.