This section described methods for creating a serializable references to tables, fields, rows and cells. For regular database access use CodeGen addon generated classes or basic API
How to reference a | Method | Screenshot |
---|---|---|
Table | Use BGMetaReference class | |
Code example
|
||
Field | Option #1. Use BGFieldReference class | |
Code example
|
||
Option #2. Use field reference class, generated by CodeGen addon | ||
Code example
|
||
Row | Option #1. Use MonoBehaviour generated components | |
Code example
|
||
Option #2. Use BGEntityGo component (can reference a row from any table but no generated properties/methods) | ||
Code example
|
||
Option #3. Use classes, generated by CodeGen addon | ||
Code example
|
||
Option #4. Use BGEntityReference class | ||
Code example
|
||
Cell | Cell includes table, field and row. Use BGCellReference class | |
Code example
|