feat: add 1.8.8 reflect & export io namespace

Signed-off-by: MiaoWoo <admin@yumc.pw>
This commit is contained in:
2020-04-07 13:31:20 +08:00
parent d22b72f10a
commit 1c29a059d9
5 changed files with 53 additions and 5 deletions

View File

@ -5,6 +5,7 @@ import * as reflect from '@ms/common/dist/reflect'
import chat from './enhance/chat'
const refList: Array<{ server: string, future: string }> = [
{ server: 'aq', future: 'g' },//spigot 1.8.8
{ server: 'an', future: 'g' },//spigot 1.12.2
{ server: 'getServerConnection', future: 'f' },//after spigot 1.14.4
{ server: 'func_147137_ag', future: 'field_151274_e' }//catserver 1.12.2
@ -74,7 +75,7 @@ export class BukkitServer implements server.Server {
} catch (error) {
}
}
if (!promise) { throw Error(`Can't found ServerConnection or ChannelFuture !`) }
if (!promise) { console.error("Can't found ServerConnection or ChannelFuture !"); return }
this.pipeline = reflect.on(promise).get('channel').get().pipeline()
}
}