sm.render
Render settings
Functions:
sm.render.getDrawDistance()
Client only
Gets the draw distance.
Returns:
| Type | Description |
|---|---|
| number | The draw distance. |
sm.render.getOutdoorLighting()
Client only
Gets the lighting cycle fraction.
Returns:
| Type | Description |
|---|---|
| number | The fraction of the day cycle lighting. |
sm.render.getScreenCoordinatesFromWorldPosition(pos, width, height)
Return the screen coordinates that align with the given world position.
Parameters:
| Type | Name | Description |
|---|---|---|
| Vec3 | pos | World position to align |
| integer | width | Screen width |
| integer | height | Screen height |
Returns:
| Type | Description |
|---|---|
| number, number | The x and y screen coordinates. |
sm.render.isOutdoor()
Client only
Checks if client is outdoor
Returns:
| Type | Description |
|---|---|
| boolean | True if local client is outdoor. |
sm.render.setOutdoorLighting(value)
Client only
Sets the lighting cycle fraction.
Parameters:
| Type | Name | Description |
|---|---|---|
| number | value | The fraction of the day cycle lighting. |