2014-01-28 00:52:49 +00:00
|
|
|
// automatically generated, do not modify
|
|
|
|
|
|
|
|
package MyGame.Example;
|
|
|
|
|
|
|
|
import java.nio.*;
|
|
|
|
import java.lang.*;
|
|
|
|
import java.util.*;
|
2014-09-16 00:45:15 +00:00
|
|
|
import com.google.flatbuffers.*;
|
2014-01-28 00:52:49 +00:00
|
|
|
|
2015-10-06 00:39:08 +00:00
|
|
|
@SuppressWarnings("unused")
|
2015-04-06 23:42:08 +00:00
|
|
|
public final class Vec3 extends Struct {
|
2014-01-28 00:52:49 +00:00
|
|
|
public Vec3 __init(int _i, ByteBuffer _bb) { bb_pos = _i; bb = _bb; return this; }
|
2014-09-04 23:31:44 +00:00
|
|
|
|
2014-01-28 00:52:49 +00:00
|
|
|
public float x() { return bb.getFloat(bb_pos + 0); }
|
2015-08-01 16:07:10 +00:00
|
|
|
public void mutateX(float x) { bb.putFloat(bb_pos + 0, x); }
|
2014-01-28 00:52:49 +00:00
|
|
|
public float y() { return bb.getFloat(bb_pos + 4); }
|
2015-08-01 16:07:10 +00:00
|
|
|
public void mutateY(float y) { bb.putFloat(bb_pos + 4, y); }
|
2014-01-28 00:52:49 +00:00
|
|
|
public float z() { return bb.getFloat(bb_pos + 8); }
|
2015-08-01 16:07:10 +00:00
|
|
|
public void mutateZ(float z) { bb.putFloat(bb_pos + 8, z); }
|
2014-01-28 00:52:49 +00:00
|
|
|
public double test1() { return bb.getDouble(bb_pos + 16); }
|
2015-08-01 16:07:10 +00:00
|
|
|
public void mutateTest1(double test1) { bb.putDouble(bb_pos + 16, test1); }
|
2014-01-28 00:52:49 +00:00
|
|
|
public byte test2() { return bb.get(bb_pos + 24); }
|
2015-08-01 16:07:10 +00:00
|
|
|
public void mutateTest2(byte test2) { bb.put(bb_pos + 24, test2); }
|
2014-01-28 00:52:49 +00:00
|
|
|
public Test test3() { return test3(new Test()); }
|
|
|
|
public Test test3(Test obj) { return obj.__init(bb_pos + 26, bb); }
|
|
|
|
|
2015-07-13 17:00:48 +00:00
|
|
|
public static int createVec3(FlatBufferBuilder builder, float x, float y, float z, double test1, byte test2, short test3_a, byte test3_b) {
|
2014-07-02 00:56:12 +00:00
|
|
|
builder.prep(16, 32);
|
2014-01-28 00:52:49 +00:00
|
|
|
builder.pad(2);
|
2014-07-02 00:56:12 +00:00
|
|
|
builder.prep(2, 4);
|
2014-01-28 00:52:49 +00:00
|
|
|
builder.pad(1);
|
2015-07-13 17:00:48 +00:00
|
|
|
builder.putByte(test3_b);
|
|
|
|
builder.putShort(test3_a);
|
2014-01-28 00:52:49 +00:00
|
|
|
builder.pad(1);
|
|
|
|
builder.putByte(test2);
|
|
|
|
builder.putDouble(test1);
|
|
|
|
builder.pad(4);
|
|
|
|
builder.putFloat(z);
|
|
|
|
builder.putFloat(y);
|
|
|
|
builder.putFloat(x);
|
|
|
|
return builder.offset();
|
|
|
|
}
|
|
|
|
};
|
|
|
|
|