This repository was archived by the owner on Feb 9, 2020. It is now read-only.
File tree Expand file tree Collapse file tree
network/minecraft/protocol Expand file tree Collapse file tree Original file line number Diff line number Diff line change @@ -42,13 +42,10 @@ class ResourcePackClientResponsePacket extends DataPacket {
4242 }
4343
4444 _encodePayload ( ) {
45- this . writeByte ( this . status )
46- . writeLShort ( this . packIds . length ) ;
45+ this . writeByte ( this . status ) ;
46+ this . writeLShort ( this . packIds . length ) ;
4747 this . packIds . forEach ( id => {
48- this . writeShort ( id . length ) ;
49- let buf = Buffer . alloc ( id . length ) ;
50- buf . write ( id ) ;
51- this . append ( buf ) ;
48+ this . writeString ( id ) ;
5249 } ) ;
5350 }
5451
Original file line number Diff line number Diff line change @@ -2,7 +2,6 @@ const FileSystem = require("fs");
22
33const Plugin = pocketnode ( "plugin/Plugin" ) ;
44const PluginLogger = pocketnode ( "plugin/PluginLogger" ) ;
5- const TextFormat = pocketnode ( "utils/TextFormat" ) ;
65const Config = pocketnode ( "utils/Config" ) ;
76
87class PluginBase extends Plugin {
Original file line number Diff line number Diff line change @@ -142,8 +142,8 @@ class PluginManager {
142142
143143 if ( pluginApi [ 1 ] . toUpperCase ( ) !== serverApi [ 1 ] . toUpperCase ( ) ) { }
144144
145- let pluginNumbers = pluginApi [ 0 ] . split ( "." ) . concat ( [ "0" , "0" ] ) . map ( v => { return parseInt ( v ) } ) ;
146- let serverNumbers = serverApi [ 0 ] . split ( "." ) . map ( v => { return parseInt ( v ) } ) ;
145+ let pluginNumbers = pluginApi [ 0 ] . split ( "." ) . concat ( [ "0" , "0" ] ) . map ( v => parseInt ( v ) ) ;
146+ let serverNumbers = serverApi [ 0 ] . split ( "." ) . map ( v => parseInt ( v ) ) ;
147147
148148 if ( pluginNumbers [ 0 ] !== serverNumbers [ 0 ] ) continue ;
149149
Original file line number Diff line number Diff line change @@ -72,7 +72,7 @@ class ZippedResourcePack extends ResourcePack {
7272 }
7373
7474 getPackChunk ( start , end ) {
75- return this . _data . slice ( start , start + end ) ;
75+ return this . _data . slice ( start , start + end ) ;
7676 }
7777
7878 static validManifest ( manifest ) {
You can’t perform that action at this time.
0 commit comments