• Shuhei Tanuma's avatar
    C# Unity can't cast integer represented enum value. · 37e28d98
    Shuhei Tanuma authored
    ```
    namespace MyGame;
    
    enum CommandType : byte {
    	None = 0,
    }
    
    table Command {
    	id:int;
    	type:CommandType;
    }
    ```
    
    then generate c# files. it'll output compile error like these.
    
    ```
    Assets/MyGame/Command.cs(18,39): error CS1041: Identifier expected
    Assets/MyGame/Command.cs(18,39): error CS1737: Optional parameter cannot precede required parameters
    
    16:   public static Offset<Command> CreateCommand(FlatBufferBuilder builder,
    17:   int id = 0,
    18:   CommandType type = (CommandType)0) {
    ```
    37e28d98
Name
Last commit
Last update
..
FlatBuffers.Test Loading commit data...
MyGame Loading commit data...
prototest Loading commit data...
GoTest.sh Loading commit data...
JavaScriptTest.js Loading commit data...
JavaScriptTest.sh Loading commit data...
JavaTest.bat Loading commit data...
JavaTest.java Loading commit data...
JavaTest.sh Loading commit data...
PythonTest.sh Loading commit data...
generate_code.sh Loading commit data...
go_test.go Loading commit data...
include_test1.fbs Loading commit data...
include_test2.fbs Loading commit data...
monster_test.bfbs Loading commit data...
monster_test.fbs Loading commit data...
monster_test_generated.h Loading commit data...
monster_test_generated.js Loading commit data...
monsterdata_python_wire.mon Loading commit data...
monsterdata_test.golden Loading commit data...
monsterdata_test.json Loading commit data...
monsterdata_test.mon Loading commit data...
py_test.py Loading commit data...
test.cpp Loading commit data...
unicode_test.json Loading commit data...