iterami/Docs.htm/common HTM Repos/webgl.js Prefabs/prefabs_webgl_lines_shrub(args)
- Creates a lines shrub prefab with the specified properties.
- Position is the start of the line.
- The color of each vertex is either base or leaf color, depending on distance from the start of the line.
- Types:
- Offset: random number is added to the position for each new point.
- Range: each point is a random position within specified cuboid relative to the start of the line.
- Args will be used in entity creation after being cleaned up by webgl_prefab_args(args).
| base-color
| [0, 0, 0, 1]
| array of numbers
|
| character
| webgl_character_id
| string ID
|
| draw-mode
| LINE_STRIP
| string
|
| groups
| []
| array of strings
|
| leaf-color
| [1, 1, 1, 1]
| array of numbers
|
| leaf-distance
| .5
| number
|
| points
| 10
| number
|
| prefix
| entity_id_count
| string ID
|
| type
| 'range'
| 'offset' or 'range'
|
| x-max
| 1
| number
|
| x-min
| -1
| number
|
| y-max
| 1
| number
|
| y-min
| -1
| number
|
| z-max
| 1
| number
|
| z-min
| -1
| number
|