/
RunToLocation.java
37 lines (30 loc) · 1.65 KB
/
RunToLocation.java
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
// automatically generated by the FlatBuffers compiler, do not modify
package com.riiablo.net.packet.d2gs;
import java.nio.*;
import java.lang.*;
import java.util.*;
import com.google.flatbuffers.*;
@SuppressWarnings("unused")
public final class RunToLocation extends Table {
public static RunToLocation getRootAsRunToLocation(ByteBuffer _bb) { return getRootAsRunToLocation(_bb, new RunToLocation()); }
public static RunToLocation getRootAsRunToLocation(ByteBuffer _bb, RunToLocation obj) { _bb.order(ByteOrder.LITTLE_ENDIAN); return (obj.__assign(_bb.getInt(_bb.position()) + _bb.position(), _bb)); }
public void __init(int _i, ByteBuffer _bb) { bb_pos = _i; bb = _bb; vtable_start = bb_pos - bb.getInt(bb_pos); vtable_size = bb.getShort(vtable_start); }
public RunToLocation __assign(int _i, ByteBuffer _bb) { __init(_i, _bb); return this; }
public short x() { int o = __offset(4); return o != 0 ? bb.getShort(o + bb_pos) : 0; }
public short y() { int o = __offset(6); return o != 0 ? bb.getShort(o + bb_pos) : 0; }
public static int createRunToLocation(FlatBufferBuilder builder,
short x,
short y) {
builder.startObject(2);
RunToLocation.addY(builder, y);
RunToLocation.addX(builder, x);
return RunToLocation.endRunToLocation(builder);
}
public static void startRunToLocation(FlatBufferBuilder builder) { builder.startObject(2); }
public static void addX(FlatBufferBuilder builder, short x) { builder.addShort(0, x, 0); }
public static void addY(FlatBufferBuilder builder, short y) { builder.addShort(1, y, 0); }
public static int endRunToLocation(FlatBufferBuilder builder) {
int o = builder.endObject();
return o;
}
}