Make Monster's Color unsigned (#5318)

- update C++ monster_test::Color to unsigned type
- update Go Color:ubyte in the go_test.go
- add workaround for unsigned enum in java test
- sync generate.bat and generate.sh
This commit is contained in:
Vladimir Glavnyy
2019-05-10 00:07:38 +07:00
committed by Wouter van Oortmerssen
parent b701c7d56e
commit f9ebfcb9c4
37 changed files with 177 additions and 159 deletions

View File

@@ -20,12 +20,12 @@ public final class Vec3 extends Struct {
public void mutateZ(float z) { bb.putFloat(bb_pos + 8, z); }
public double test1() { return bb.getDouble(bb_pos + 16); }
public void mutateTest1(double test1) { bb.putDouble(bb_pos + 16, test1); }
public byte test2() { return bb.get(bb_pos + 24); }
public void mutateTest2(byte test2) { bb.put(bb_pos + 24, test2); }
public int test2() { return bb.get(bb_pos + 24) & 0xFF; }
public void mutateTest2(int test2) { bb.put(bb_pos + 24, (byte)test2); }
public Test test3() { return test3(new Test()); }
public Test test3(Test obj) { return obj.__assign(bb_pos + 26, bb); }
public static int createVec3(FlatBufferBuilder builder, float x, float y, float z, double test1, byte test2, short test3_a, byte test3_b) {
public static int createVec3(FlatBufferBuilder builder, float x, float y, float z, double test1, int test2, short test3_a, byte test3_b) {
builder.prep(8, 32);
builder.pad(2);
builder.prep(2, 4);
@@ -33,7 +33,7 @@ public final class Vec3 extends Struct {
builder.putByte(test3_b);
builder.putShort(test3_a);
builder.pad(1);
builder.putByte(test2);
builder.putByte((byte)test2);
builder.putDouble(test1);
builder.pad(4);
builder.putFloat(z);