blob: 19a2f56611fef4445156efb1e589b1c763b1317b [file] [log] [blame]
Austin Schuhe89fa2d2019-08-14 20:24:23 -07001// automatically generated by the FlatBuffers compiler, do not modify
2
3package MyGame.Example
4
5import java.nio.*
6import kotlin.math.sign
7import com.google.flatbuffers.*
8
9@Suppress("unused")
Austin Schuhe89fa2d2019-08-14 20:24:23 -070010class Ability : Struct() {
11
12 fun __init(_i: Int, _bb: ByteBuffer) {
13 __reset(_i, _bb)
14 }
15 fun __assign(_i: Int, _bb: ByteBuffer) : Ability {
16 __init(_i, _bb)
17 return this
18 }
19 val id : UInt get() = bb.getInt(bb_pos + 0).toUInt()
20 fun mutateId(id: UInt) : ByteBuffer = bb.putInt(bb_pos + 0, id.toInt())
21 val distance : UInt get() = bb.getInt(bb_pos + 4).toUInt()
22 fun mutateDistance(distance: UInt) : ByteBuffer = bb.putInt(bb_pos + 4, distance.toInt())
23 companion object {
24 fun createAbility(builder: FlatBufferBuilder, id: UInt, distance: UInt) : Int {
25 builder.prep(4, 8)
26 builder.putInt(distance.toInt())
27 builder.putInt(id.toInt())
28 return builder.offset()
29 }
30 }
31}