| 58 | |
| 59 | == Formatting of special types == |
| 60 | Until now we denoted the new value just as ''newvalue''. For primitive types like {{{int}}} or {{{float}}} it's really that easy. But there exist more complex formattings for non-primitive types: |
| 61 | * std::string: " my text with trailing spaces " |
| 62 | * Put strings into quotes if you don't want trailing spaces to be striped |
| 63 | |
| 64 | * Vector2: (10, 20) |
| 65 | * Vector3: (10, 20, 50) |
| 66 | * Vector4: (10, 20, 50, 100) |
| 67 | * Quaternion: (1, 2, 3, 4) |
| 68 | * ColourValue: (0.1, 0.2, 0.3, 1.0) |
| 69 | |
| 70 | * bool: true and false (or just 1 and 0 as usual) |
| 71 | |
| 72 | == Comments == |
| 73 | It's possible to add comments into the config-file. They will be kept even if the file changes. |
| 74 | |
| 75 | Comments are introduces by one of the following symbols: |
| 76 | 1. '''#'''comment in script-language style |
| 77 | 1. '''%'''comment in matlab style |
| 78 | 1. ''';'''comment in unreal tournament config-file style |
| 79 | 1. '''//'''comment in code style |
| 80 | |
| 81 | == Whitespaces == |
| 82 | If you add whitespaces to your config-file, for example like this: |
| 83 | {{{ |
| 84 | [Sectionname] |
| 85 | |
| 86 | varname = value |
| 87 | }}} |
| 88 | instead of |
| 89 | {{{ |
| 90 | [Sectionname] |
| 91 | varname=value |
| 92 | }}} |
| 93 | this will have no effect, but if the file gets saved, Orxonox will strip the whitespaces. |