This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
if [[ $# -ne 2 ]] | |
then | |
echo "usage : $0 <outputFile> <repo>" | |
exit 1 | |
fi | |
outputFile=$1 | |
repo=$2 | |
rm $outputFile | |
cd $repo | |
git checkout master |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
{ | |
"handshaking": { | |
"toServer": { | |
"handshake": { | |
"id": "0x00", | |
"fields": [ | |
{ | |
"name": "protocolVersion", | |
"type": "varint" | |
}, |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
{ | |
"handshaking": { | |
"toClient": {}, | |
"toServer": { | |
"set_protocol": { | |
"id": "0x00", | |
"fields": [ | |
{ | |
"name": "protocolVersion", | |
"type": "varint" |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
var proto=require("./../../enums/protocol"); | |
var fs=require("fs"); | |
function transformProtocol(protocol) | |
{ | |
var transformedProtocol = Object | |
.keys(protocol) | |
.reduce(function(transformedProtocol, state) { | |
transformedProtocol[state] = Object | |
.keys(protocol[state]) |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
var proto=require("./../../enums/protocol"); | |
var fs=require("fs"); | |
function tranformProtocol(protocol) | |
{ | |
return {"types":transformTypesObject(protocol.types),"states":transformStates(protocol.states)}; | |
} | |
function transformStates(states) | |
{ |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
{ | |
"types": { | |
"varint": "native", | |
"string": "native", | |
"ushort": "native", | |
"ubyte": "native", | |
"long": "native", | |
"buffer": "native", | |
"int": "native", | |
"byte": "native", |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
var dump=serv.world.dump(); | |
var begin=1; | |
var total=20; | |
var x,z; | |
for(x=-begin;x<begin;x++) | |
for(z=-begin;z<begin;z++) { | |
player._client.write('map_chunk', { | |
x: x, | |
z: z, | |
groundUp: true, |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
var fs = require('fs'); | |
function parsePackets(path) | |
{ | |
var files = fs.readdirSync(path); | |
return files | |
.filter(function(name) {return !(name == "DataPacket.php" || name == "Info.php");}) | |
.map(function(name){ | |
var file = (fs.readFileSync(path + name, 'utf8')); |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
{ | |
"handshaking": { | |
"toServer": { | |
"ji": { | |
"id": "0x00", | |
"fields": [ | |
"ushort" | |
] | |
} | |
} |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
var Chunk = require('prismarine-chunk')("1.8"); | |
var Vec3 = require("vec3"); | |
var chunk=new Chunk(); | |
for (var x = 0; x < 16;x++) { | |
for (var z = 0; z < 16; z++) { | |
chunk.setBlockType(new Vec3(x, 50, z), 2); | |
for (var y = 0; y < 256; y++) { | |
chunk.setSkyLight(new Vec3(x, y, z), 15); |
OlderNewer