mm_os 4.1.7 → 4.1.9
This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
- package/adapter/mqtt.js +1 -0
- package/adapter/socket.js +1 -0
- package/adapter/web.js +2 -1
- package/adapter/websocket.js +1 -1
- package/com/api/drive.js +3 -3
- package/com/api/index.js +2 -2
- package/com/cmd/drive.js +2 -2
- package/com/cmd/index.js +1 -1
- package/com/cmd/script.tpl.js +7 -6
- package/com/db/drive.js +1 -1
- package/com/event/index.js +2 -2
- package/com/mqtt/index.js +6 -6
- package/com/mqtt/mm_mqtt.js +0 -5
- package/com/param/index.js +3 -2
- package/com/pendant/index.js +1 -1
- package/com/socket/drive.js +13 -13
- package/com/socket/index.js +5 -5
- package/com/sql/index.js +1 -1
- package/com/template/drive.js +30 -29
- package/com/template/index.js +27 -30
- package/common/middleware/web_after/index.js +2 -2
- package/core/app/{bat.js → index copy.js } +10 -56
- package/core/app/index.js +5 -82
- package/core/channel/index.js +1 -2
- package/core/controller/index.js +1 -3
- package/core/game/bat/world.js +1 -1
- package/core/game/index.js +1 -1
- package/core/middleware/index.js +4 -4
- package/core/middleware/script.tpl.js +3 -3
- package/core/plugin/index.js +93 -37
- package/core/room/room.js +2 -2
- package/core/scene/index.js +1 -0
- package/core/zone/bat/index.js +2 -0
- package/core/zone/index.js +1 -0
- package/package.json +6 -6
- package/server.js +4 -3
- package/software.js +5 -2
- package/tcp.js +4 -1
package/software.js
CHANGED
|
@@ -22,6 +22,7 @@ class Software {
|
|
|
22
22
|
|
|
23
23
|
/**
|
|
24
24
|
* 获取适配器
|
|
25
|
+
* @returns {object} 适配器实例
|
|
25
26
|
*/
|
|
26
27
|
Software.prototype.getAdapter = function () {
|
|
27
28
|
return this.getParent().adapter;
|
|
@@ -29,6 +30,7 @@ Software.prototype.getAdapter = function () {
|
|
|
29
30
|
|
|
30
31
|
/**
|
|
31
32
|
* 获取管理器
|
|
33
|
+
* @returns {object} 管理器实例
|
|
32
34
|
*/
|
|
33
35
|
Software.prototype.getManager = function () {
|
|
34
36
|
return this.getParent().manager;
|
|
@@ -74,7 +76,7 @@ Software.prototype._initSources = async function () {
|
|
|
74
76
|
manager.game.runAll('init', server, server.eventer, server.logger),
|
|
75
77
|
manager.app.runAll('init', server, server.eventer, server.logger)
|
|
76
78
|
]);
|
|
77
|
-
await manager.mod.runAll('init', server, server.eventer, server.logger)
|
|
79
|
+
await manager.mod.runAll('init', server, server.eventer, server.logger);
|
|
78
80
|
};
|
|
79
81
|
|
|
80
82
|
/**
|
|
@@ -134,7 +136,7 @@ Software.prototype._createManager = function (name, title, cls) {
|
|
|
134
136
|
// 设置到对应的管理器属性
|
|
135
137
|
server.manager[name] = manager;
|
|
136
138
|
return manager;
|
|
137
|
-
}
|
|
139
|
+
};
|
|
138
140
|
|
|
139
141
|
/**
|
|
140
142
|
* 启动
|
|
@@ -178,6 +180,7 @@ Software.prototype._stopSources = async function () {
|
|
|
178
180
|
|
|
179
181
|
/**
|
|
180
182
|
* 运行
|
|
183
|
+
* @returns {object} 软件实例
|
|
181
184
|
*/
|
|
182
185
|
Software.prototype.run = async function () {
|
|
183
186
|
await this.load();
|
package/tcp.js
CHANGED
|
@@ -41,6 +41,7 @@ class TCP {
|
|
|
41
41
|
|
|
42
42
|
/**
|
|
43
43
|
* 获取适配器
|
|
44
|
+
* @returns {object} 适配器实例
|
|
44
45
|
*/
|
|
45
46
|
TCP.prototype.getAdapter = function () {
|
|
46
47
|
return this.getParent().adapter;
|
|
@@ -48,6 +49,7 @@ TCP.prototype.getAdapter = function () {
|
|
|
48
49
|
|
|
49
50
|
/**
|
|
50
51
|
* 获取管理器
|
|
52
|
+
* @returns {object} 管理器实例
|
|
51
53
|
*/
|
|
52
54
|
TCP.prototype.getManager = function () {
|
|
53
55
|
return this.getParent().manager;
|
|
@@ -186,7 +188,7 @@ TCP.prototype._createManager = function (name, title, cls) {
|
|
|
186
188
|
// 设置到对应的管理器属性
|
|
187
189
|
server.manager[name] = manager;
|
|
188
190
|
return manager;
|
|
189
|
-
}
|
|
191
|
+
};
|
|
190
192
|
|
|
191
193
|
/**
|
|
192
194
|
* 启动
|
|
@@ -263,6 +265,7 @@ TCP.prototype._stopSources = async function () {
|
|
|
263
265
|
|
|
264
266
|
/**
|
|
265
267
|
* 运行
|
|
268
|
+
* @returns {object} TCP实例
|
|
266
269
|
*/
|
|
267
270
|
TCP.prototype.run = async function () {
|
|
268
271
|
await this.load();
|