[network] update

This commit is contained in:
2019-05-24 15:43:00 +03:00
parent 26ad5f47cd
commit 50a0cee044
19 changed files with 621 additions and 227 deletions

View File

@@ -4,7 +4,7 @@ const Config = require('./config.json');
const packageInfo = require('./package.json');
const {Sdk, Haxe, Project, FlashPlayer} = require('gulp-haxetool');
const dateformat = require('dateformat');
const argv = require('yargs').argv;
// ToDo: update default in gulp-haxetool
FlashPlayer.VERSION = '32';
@@ -49,11 +49,13 @@ const config = new Project.Config({
'src/common/resources'
],
macros: [
//'yield.parser.Parser.auto()', // ToDo: bug with extraParams.hxml in yield library
`CompilationOption.set('build','${dateformat(new Date(), 'yyyy-mm-dd HH:MM:ss')}')`,
]
});
const host = argv.host || 'localhost';
const port = argv.port || 5000;
/**
* client
*/
@@ -83,6 +85,10 @@ const client = new Project(
//'dev_layout',
//'bitmap_text',
],
macros: [
`CompilationOption.set('host','${host}')`,
`CompilationOption.set('port',${port})`,
]
}),
module.exports.generate
).bind(module, gulp);