Links

Import

To make sure Databrain recognizes the correct data types you will need to setup the spreadsheet correctly.
Use the following keys to mark the appropriate fields:
  • FIELD_NAMES The actual name of the value/variable
  • FIELD_TYPES The type of the value. (vector3, float, integer, boolean etc.)
  • IGNORE Mark rows and cells you don't want to import with this key.

Default supported types

The CSV converter supports following types by default. If you have a special case you would have to override the ConvertFromCSV method -> see Manual conversion
  • string
  • int
  • float
  • double
  • bool
  • vector2
  • vector3
  • vector4
  • quaternion
  • rect
  • List<string>
  • List<int>
  • List<float>
  • List<bool>

Manual conversion

You can override the ConvertFromCSV method in your custom DataObject class to read from the imported CSV string and convert custom data in any way you want.

Formats

Make sure to separate values by comma. For example:
Vector3 0.3, 2.0, 4.0 Color 255, 220, 120, 255 List<string> A, B, C, D, E, F

Google Spreadsheets

To import a Google spreadsheet select the import module in the Databrain editor. Make sure Google Import is selected.
In Databrain a Google Spreadsheet equals to a namespace in Databrain. Whereas a Google Worksheet equals to a data type.
  1. 1.
    Open a spreadsheet file in Google.
  2. 2.
    In the top right corner, click Share.
  3. 3.
    Click Get shareable link in the top right of the Share with others box.
  4. 4.
    To choose whether a person can view, comment, or edit the file, click the Down arrow next to Anyone with the link.
  5. 5.
    Select the namespace in the import module.
  6. 6.
    Copy the link and paste it in the Google Share Link field.

Add Worksheets

Each data type equals a worksheet. That's why we now have to set the worksheet ID for each data type.
  1. 1.
    Open a spreadsheet file in Google.
  2. 2.
    Select the correct worksheet and search for the gid number in the browser URL field. Select and copy it.
  1. 3.
    Enter the gid number in the appropriate worksheet id field.
  1. 4.
    Select whether you want to append or replace the data objects.
  2. 5.
    Click on import.