MovementVolumeCamera ​
Inherits: RefCounted
The look the screen gets while the camera is inside a movement volume (underwater: a tint over the screen and fog; the sound is the business of AudioProfileStack). Volumes tell it when the camera enters and leaves; with several volumes around the camera (a pool inside a cave pool) the one entered last decides, and when it is left the one before it comes back. What the effect changed (fog, the sound) is put back when the last volume is left.
Methods ​
void | enter( volume: MovementVolume ) static |
void | leave( volume: MovementVolume ) static |
MovementVolume | get_active_volume() static |
bool | is_effect_on() static |
Color | get_overlay_color() static |
void | reset() static |
Constants ​
intOVERLAY_LAYER =90StringLOOK_KEY ="movement_volume"- The key of the tint in the layers of the CameraLook (with a camera in the game the tint is a layer of its look, under the interface; without one, as in a test, it is a rect of its own)
Method descriptions ​
void enter( volume: MovementVolume ) ​
The camera went inside a volume
void leave( volume: MovementVolume ) ​
The camera left a volume
MovementVolume get_active_volume() ​
The volume that decides the look now (the one the camera entered last), or null when the camera is not in any
bool is_effect_on() ​
Is the underwater look on?
Color get_overlay_color() ​
The tint on the screen now (transparent when there is none)
void reset() ​
Puts everything back as it was and forgets every volume (a scene that is left)