What it does
CreateDirectionalLight brings a 3D object into being: it is how the rest of the program comes to have one. It takes lightID (an integer), x (a float), y (a float), z (a float), red (an integer), green (an integer) and blue (an integer), and returns nothing. lightID is the id you are giving a Light object: every later call names it by that number.
Syntax
CreateDirectionalLight(lightID integer, x float, y float, z float, red integer, green integer, blue integer)Parameters
| Name | Type |
|---|---|
| lightID | integer |
| x | float |
| y | float |
| z | float |
| red | integer |
| green | integer |
| blue | integer |
Every form returns
nothing
Example · generated
CreateDirectionalLight(1, 100.0, 120.0, 100.0, 255, 128, 128)DO Sync()LOOPCreateDirectionalLight is called with values of the types its signature asks for. The DO … LOOP is not decoration: a classic BASIC program ends the moment it runs out of lines, and Sync() is what draws the frame.