Emitter Extended Data tab: Custom Data quicktab
It is now possible to add your own custom data to each particle. For more details on using custom data, please see the Custom Data page. Items of custom data are added in this quicktab.
Interface
The interface for this quicktab initially looks like this:
Add
Click this button to add a new item of custom data. The interface will then look like this:
You can click the 'Add' button again to add as many items of custom data as required. You can remove data items individually once they have been added using the 'Remove Custom Data' button in each custom data section, or remove all custom data by clicking the 'Reset' button.
Reset
Remove all items of custom data simultaneously.
ID
This is the ID number for each custom data item. You can leave this at zero, but if you do then you must enter a name for the data item in the 'Name' field. Otherwise the data items will all look the same to the Question, Custom Data Modifier, and Action objects and they will work only on the first data item in the list. If you prefer to work with ID numbers, set this to a number of your choice; it should be unique to this data item.
You can also set this to -1, which will force X-Particles to ignore the ID value and only use the 'Name' setting to identify the data item.
Name
Alternatively, you can identify the data item by name, by entering any text string here.
Identifying custom data items
It is recommended that you leave the 'ID' value at zero and always enter a name to distinguish each custom data item from the others. However, you have a lot of flexibility in identifying these data items.
When searching for custom data items, X-Particles uses the following rules:
- if the ID value is zero or higher, and there is a string in the 'Name' field, it will look for the first data item which matches both the ID value and the name
- if the ID value is zero or higher, and the 'Name' field is empty, it will look for the first data item whose ID value matches the 'ID' field
- if the ID value is -1 and there is a string in the 'Name' field, it will look for the first data item whose name matches that in the 'Name' field
- finally, if the ID value is -1 and the 'Name' field is empty, no data item will be found
It is entirely up to you whether you prefer to use ID values, names, or a combination of the two for your custom data items. The crucial point is that you need some way to identify each data item uniquely so that the other X-Particles objects can retrieve the correct custom data.
Data Type
This is the type of data the custom data item will hold. The drop-down menu has the following options:
Integer
A whole number such as 1, 5, 17, etc.
Real
A floating-point number such as 1.0, 2.5, 3.1416, etc.
Matrix
A Cinema 4D Matrix field.
String
Any string of text.
Time
A time field specifically for time values (showing either frames or seconds depending on your Cinema 4D preferences)
Vector
A Cinema 4D Vector field.
Value on Emission
When a particle is created, the custom data item will have this initial value. This can then be changed and tested for as with the inbuilt data items such as speed, radius, etc.
Variation
This field is available if 'Data Type' is set to anything other than 'Matrix' or 'String'. It adds variation to the custom data item so that different particles receive different values on emission.
The field is a percentage value. For example, if 'Value on Emission' is set to 20, and 'Variation' to 50%, the possible values in the particle wlll be in the range 20 +/- 10 (50% of 20 is 10), so between 10 and 30.
It is possible to set this parameter to higher than 100%, but if you do, bear in mind that negative values will occur as well as positive ones. So a value of 20 with 200% variation will range between -20 and +60. This may or may not matter, depending on what you want to do with the custom data.
Remove Custom Data
Click this button to remove this custom data item, leaving the others intact.