示例#1
0
 public void read(ByteParser parser)
 {
     parser.readShort();
     oreType = new OreTypeModule(-1);
     oreType.read(parser);
     count = parser.readDouble();
 }
        public static Command write(short eventType, OreTypeModule oreType, string hash)
        {
            var cmd = new ByteArray(ID);

            cmd.Short(eventType);
            cmd.AddBytes(oreType.write());
            cmd.UTF(hash);
            return(new Command(cmd.ToByteArray(), false));
        }
示例#3
0
        public static Command write(string hash, OreTypeModule oreType, int x, int y)
        {
            var cmd = new ByteArray(ID);

            cmd.UTF(hash);
            cmd.AddBytes(oreType.write());
            cmd.Integer(x);
            cmd.Integer(y);
            return(new Command(cmd.ToByteArray(), false));
        }
示例#4
0
 public OreCountModule(OreTypeModule oreType, double count)
 {
     this.oreType = oreType;
     this.count   = count;
 }