mirror of
https://github.com/mapbase-source/source-sdk-2013.git
synced 2024-12-26 23:05:30 +03:00
Updated Skyboxes (markdown)
parent
e09f745dc3
commit
b1fa3c6eec
25
Skyboxes.md
25
Skyboxes.md
@ -1,8 +1,8 @@
|
|||||||
**sky_camera** is the entity used to create a skybox. The area around it will be projected around the map via the `tools/skybox` texture.
|
**sky_camera** is the entity used to create a skybox. The area around it will be projected around the map via the `tools/skybox` texture. [Click here for more information on sky_camera in Source.](https://developer.valvesoftware.com/wiki/Sky_camera)
|
||||||
|
|
||||||
Outside of Mapbase, sky_camera is static. Once it's been placed, the skybox can't move. You can move the sky_camera itself through things like logic_measure_direction, but it doesn't update the skybox. There is a trick to update the skybox by continuously removing and respawning the sky_camera, but this is crude and usually isn't very smooth.
|
Outside of Mapbase, sky_camera is static. Once it's been placed, the skybox can't move. You can move the sky_camera itself through things like logic_measure_movement, but it doesn't update the skybox. There is a trick to update the skybox by continuously removing and respawning the sky_camera, but this is a complicated workaround and usually isn't very smooth.
|
||||||
|
|
||||||
---
|
## Moving skyboxes
|
||||||
|
|
||||||
In Mapbase, sky_camera has been updated to support parenting and continuous updating. Not just that, but there's a new option to use the sky_camera's angles for actual skybox rotation rather than fog direction.
|
In Mapbase, sky_camera has been updated to support parenting and continuous updating. Not just that, but there's a new option to use the sky_camera's angles for actual skybox rotation rather than fog direction.
|
||||||
|
|
||||||
@ -12,14 +12,29 @@ Together, these changes create the ability for the skybox to move around freely
|
|||||||
|
|
||||||
* **Use Angles for Sky** `<void>` - Uses angles for actual skybox rotation, as if the world were tilted on this entity's axis.
|
* **Use Angles for Sky** `<void>` - Uses angles for actual skybox rotation, as if the world were tilted on this entity's axis.
|
||||||
---
|
---
|
||||||
* **ForceUpdate** `<void>` - Forces the 3D skybox to update with this sky_camera's position.
|
* **ForceUpdate** `<void>` - Forces the 3D skybox to update with this sky_camera's position once.
|
||||||
* **StartUpdating** `<void>` - Begins per-tick skybox updating, which is needed if you want this sky_camera to move.
|
* **StartUpdating** `<void>` - Begins per-tick skybox updating, which is needed if you want this sky_camera to move.
|
||||||
* **StopUpdating** `<void>` - Ends per-tick skybox updating if it was enabled before.
|
* **StopUpdating** `<void>` - Ends per-tick skybox updating if it was enabled before.
|
||||||
|
|
||||||
There's also a spawnflag for a sky_camera to spawn continuously updating its position.
|
There's also a spawnflag for a sky_camera to spawn continuously updating its position.
|
||||||
|
|
||||||
---
|
## Multiple skyboxes
|
||||||
|
|
||||||
HL2: Downfall's multiple skybox support has been added as well.
|
HL2: Downfall's multiple skybox support has been added as well.
|
||||||
|
|
||||||
(todo)
|
(todo)
|
||||||
|
|
||||||
|
## Sky color
|
||||||
|
|
||||||
|
Mapbase adds the ability to use a specific solid color instead of a sky texture, controlled with the `SetSkyColor` input on sky_camera. The color is enabled and disabled through the "alpha" value, or the 4th number in a color. For example, you could use `SetSkyColor > 0 255 0` to turn the sky green and `SetSkyColor > 0 255 0 0` to turn the sky back to normal. Blending the sky color with the skybox was attempted, but is unfortunately not possible. Any alpha value above 0 enables the solid effect while 0 disables it.
|
||||||
|
|
||||||
|
This was intended to be used to make the skybox match the color of dense fog, but HDR causes a noticeable contrast in between the world and the sky. The pictures below show a skybox with thick blueish fog and the result of setting the sky to the same color, highlighting the HDR problem.
|
||||||
|
|
||||||
|
<p align="center">
|
||||||
|
<img src="https://cdn.discordapp.com/attachments/526449481252601863/603706099098452139/mapbase_demo030039.jpg" width="384"/>
|
||||||
|
<img src="https://cdn.discordapp.com/attachments/526449481252601863/603706133366046720/mapbase_demo030041.jpg" width="384"/>
|
||||||
|
</p>
|
||||||
|
|
||||||
|
## New fog inputs/keyvalues
|
||||||
|
|
||||||
|
`sky_camera` now has inputs and keyvalues from `env_fog_controller`, which allows for more skybox fog control. Lerping is not yet supported.
|
Loading…
Reference in New Issue
Block a user