The rotation of the object around its rotation axis, in radians.
ax
number
0
The x component of the axis of rotation.
ay
number
1
The y component of the axis of rotation.
az
number
0
The z component of the axis of rotation.
layers
number
0xff
A binary bitmask of 8 layers to place the object on. The object is placed on all layers by default. For example, 0x1 will place the object on the first layer, 0x2 will place it on the second layer, 0x3 for the first two layers, etc.
tag
number
nil
A custom tag for the object, provided in the shader when the object is hit. Shaders can use this tag for whatever they want. If nil, the tag will be set to the same ID as the one returned by this function. The tag can be between 0 and 16,777,215.
Returns
Name
Type
Description
id
number
An ID for the object. Use it to move the object layer using Raytracer:set. If the Raytracer is full, the object is not added and this ID will be nil.
The rotation of the object around its rotation axis, in radians.
ax
number
0
The x component of the axis of rotation.
ay
number
1
The y component of the axis of rotation.
az
number
0
The z component of the axis of rotation.
layers
number
0xff
A binary bitmask of 8 layers to place the object on. The object is placed on all layers by default. For example, 0x1 will place the object on the first layer, 0x2 will place it on the second layer, 0x3 for the first two layers, etc.
tag
number
nil
A custom tag for the object, provided in the shader when the object is hit. Shaders can use this tag for whatever they want. If nil, the tag will be set to the same ID as the one returned by this function. The tag can be between 0 and 16,777,215.
Returns
Name
Type
Description
id
number
An ID for the object. Use it to move the object layer using Raytracer:set. If the Raytracer is full, the object is not added and this ID will be nil.
A binary bitmask of 8 layers to place the object on. The object is placed on all layers by default. For example, 0x1 will place the object on the first layer, 0x2 will place it on the second layer, 0x3 for the first two layers, etc.
tag
number
nil
A custom tag for the object, provided in the shader when the object is hit. Shaders can use this tag for whatever they want. If nil, the tag will be set to the same ID as the one returned by this function. The tag can be between 0 and 16,777,215.
Returns
Name
Type
Description
id
number
An ID for the object. Use it to move the object layer using Raytracer:set. If the Raytracer is full, the object is not added and this ID will be nil.
A binary bitmask of 8 layers to place the object on. The object is placed on all layers by default. For example, 0x1 will place the object on the first layer, 0x2 will place it on the second layer, 0x3 for the first two layers, etc.
tag
number
nil
A custom tag for the object, provided in the shader when the object is hit. Shaders can use this tag for whatever they want. If nil, the tag will be set to the same ID as the one returned by this function. The tag can be between 0 and 16,777,215.
Returns
Name
Type
Description
id
number
An ID for the object. Use it to move the object layer using Raytracer:set. If the Raytracer is full, the object is not added and this ID will be nil.
A binary bitmask of 8 layers to place the object on. The object is placed on all layers by default. For example, 0x1 will place the object on the first layer, 0x2 will place it on the second layer, 0x3 for the first two layers, etc.
tag
number
nil
A custom tag for the object, provided in the shader when the object is hit. Shaders can use this tag for whatever they want. If nil, the tag will be set to the same ID as the one returned by this function. The tag can be between 0 and 16,777,215.
Returns
Name
Type
Description
id
number
An ID for the object. Use it to move the object layer using Raytracer:set. If the Raytracer is full, the object is not added and this ID will be nil.
A binary bitmask of 8 layers to place the object on. The object is placed on all layers by default. For example, 0x1 will place the object on the first layer, 0x2 will place it on the second layer, 0x3 for the first two layers, etc.
tag
number
nil
A custom tag for the object, provided in the shader when the object is hit. Shaders can use this tag for whatever they want. If nil, the tag will be set to the same ID as the one returned by this function. The tag can be between 0 and 16,777,215.
Returns
Name
Type
Description
id
number
An ID for the object. Use it to move the object layer using Raytracer:set. If the Raytracer is full, the object is not added and this ID will be nil.