diff options
Diffstat (limited to 'doc/classes/Light2D.xml')
-rw-r--r-- | doc/classes/Light2D.xml | 67 |
1 files changed, 34 insertions, 33 deletions
diff --git a/doc/classes/Light2D.xml b/doc/classes/Light2D.xml index a487fdf2fe..88ad371983 100644 --- a/doc/classes/Light2D.xml +++ b/doc/classes/Light2D.xml @@ -4,7 +4,8 @@ Casts light in a 2D environment. </brief_description> <description> - Casts light in a 2D environment. Light is defined by a (usually grayscale) texture, a color, an energy value, a mode (see constants), and various other parameters (range and shadows-related). Note that Light2D can be used as a mask. + Casts light in a 2D environment. Light is defined by a (usually grayscale) texture, a color, an energy value, a mode (see constants), and various other parameters (range and shadows-related). + [b]Note:[/b] Light2D can also be used as a mask. </description> <tutorials> <link>http://docs.godotengine.org/en/latest/tutorials/2d/2d_lights_and_shadows.html</link> @@ -12,73 +13,73 @@ <methods> </methods> <members> - <member name="color" type="Color" setter="set_color" getter="get_color"> + <member name="color" type="Color" setter="set_color" getter="get_color" default="Color( 1, 1, 1, 1 )"> The Light2D's [Color]. </member> - <member name="editor_only" type="bool" setter="set_editor_only" getter="is_editor_only"> - If [code]true[/code], Light2D will only appear when editing the scene. Default value: [code]false[/code]. + <member name="editor_only" type="bool" setter="set_editor_only" getter="is_editor_only" default="false"> + If [code]true[/code], Light2D will only appear when editing the scene. </member> - <member name="enabled" type="bool" setter="set_enabled" getter="is_enabled"> - If [code]true[/code], Light2D will emit light. Default value: [code]true[/code]. + <member name="enabled" type="bool" setter="set_enabled" getter="is_enabled" default="true"> + If [code]true[/code], Light2D will emit light. </member> - <member name="energy" type="float" setter="set_energy" getter="get_energy"> + <member name="energy" type="float" setter="set_energy" getter="get_energy" default="1.0"> The Light2D's energy value. The larger the value, the stronger the light. </member> - <member name="mode" type="int" setter="set_mode" getter="get_mode" enum="Light2D.Mode"> - The Light2D's mode. See MODE_* constants for values. + <member name="mode" type="int" setter="set_mode" getter="get_mode" enum="Light2D.Mode" default="0"> + The Light2D's mode. See [code]MODE_*[/code] constants for values. </member> - <member name="offset" type="Vector2" setter="set_texture_offset" getter="get_texture_offset"> + <member name="offset" type="Vector2" setter="set_texture_offset" getter="get_texture_offset" default="Vector2( 0, 0 )"> The offset of the Light2D's [code]texture[/code]. </member> - <member name="range_height" type="float" setter="set_height" getter="get_height"> + <member name="range_height" type="float" setter="set_height" getter="get_height" default="0.0"> The height of the Light2D. Used with 2D normal mapping. </member> - <member name="range_item_cull_mask" type="int" setter="set_item_cull_mask" getter="get_item_cull_mask"> + <member name="range_item_cull_mask" type="int" setter="set_item_cull_mask" getter="get_item_cull_mask" default="1"> The layer mask. Only objects with a matching mask will be affected by the Light2D. </member> - <member name="range_layer_max" type="int" setter="set_layer_range_max" getter="get_layer_range_max"> - Maximum layer value of objects that are affected by the Light2D. Default value: [code]0[/code]. + <member name="range_layer_max" type="int" setter="set_layer_range_max" getter="get_layer_range_max" default="0"> + Maximum layer value of objects that are affected by the Light2D. </member> - <member name="range_layer_min" type="int" setter="set_layer_range_min" getter="get_layer_range_min"> - Minimum layer value of objects that are affected by the Light2D. Default value: [code]0[/code]. + <member name="range_layer_min" type="int" setter="set_layer_range_min" getter="get_layer_range_min" default="0"> + Minimum layer value of objects that are affected by the Light2D. </member> - <member name="range_z_max" type="int" setter="set_z_range_max" getter="get_z_range_max"> - Maximum [code]Z[/code] value of objects that are affected by the Light2D. Default value: [code]1024[/code]. + <member name="range_z_max" type="int" setter="set_z_range_max" getter="get_z_range_max" default="1024"> + Maximum [code]z[/code] value of objects that are affected by the Light2D. </member> - <member name="range_z_min" type="int" setter="set_z_range_min" getter="get_z_range_min"> - Minimum [code]z[/code] value of objects that are affected by the Light2D. Default value: [code]-1024[/code]. + <member name="range_z_min" type="int" setter="set_z_range_min" getter="get_z_range_min" default="-1024"> + Minimum [code]z[/code] value of objects that are affected by the Light2D. </member> - <member name="shadow_buffer_size" type="int" setter="set_shadow_buffer_size" getter="get_shadow_buffer_size"> - Shadow buffer size. Default value: [code]2048[/code]. + <member name="shadow_buffer_size" type="int" setter="set_shadow_buffer_size" getter="get_shadow_buffer_size" default="2048"> + Shadow buffer size. </member> - <member name="shadow_color" type="Color" setter="set_shadow_color" getter="get_shadow_color"> + <member name="shadow_color" type="Color" setter="set_shadow_color" getter="get_shadow_color" default="Color( 0, 0, 0, 0 )"> [Color] of shadows cast by the Light2D. </member> - <member name="shadow_enabled" type="bool" setter="set_shadow_enabled" getter="is_shadow_enabled"> - If [code]true[/code], the Light2D will cast shadows. Default value: [code]false[/code]. + <member name="shadow_enabled" type="bool" setter="set_shadow_enabled" getter="is_shadow_enabled" default="false"> + If [code]true[/code], the Light2D will cast shadows. </member> - <member name="shadow_filter" type="int" setter="set_shadow_filter" getter="get_shadow_filter" enum="Light2D.ShadowFilter"> - Shadow filter type. Use [enum Light2D.ShadowFilter] constants as values. Default value: [code]SHADOW_FILTER_NONE[/code]. + <member name="shadow_filter" type="int" setter="set_shadow_filter" getter="get_shadow_filter" enum="Light2D.ShadowFilter" default="0"> + Shadow filter type. See [enum ShadowFilter] for possible values. </member> - <member name="shadow_filter_smooth" type="float" setter="set_shadow_smooth" getter="get_shadow_smooth"> + <member name="shadow_filter_smooth" type="float" setter="set_shadow_smooth" getter="get_shadow_smooth" default="0.0"> Smoothing value for shadows. </member> - <member name="shadow_gradient_length" type="float" setter="set_shadow_gradient_length" getter="get_shadow_gradient_length"> + <member name="shadow_gradient_length" type="float" setter="set_shadow_gradient_length" getter="get_shadow_gradient_length" default="0.0"> Smooth shadow gradient length. </member> - <member name="shadow_item_cull_mask" type="int" setter="set_item_shadow_cull_mask" getter="get_item_shadow_cull_mask"> + <member name="shadow_item_cull_mask" type="int" setter="set_item_shadow_cull_mask" getter="get_item_shadow_cull_mask" default="1"> The shadow mask. Used with [LightOccluder2D] to cast shadows. Only occluders with a matching shadow mask will cast shadows. </member> - <member name="texture" type="Texture" setter="set_texture" getter="get_texture"> + <member name="texture" type="Texture" setter="set_texture" getter="get_texture" default="null"> [Texture] used for the Light2D's appearance. </member> - <member name="texture_scale" type="float" setter="set_texture_scale" getter="get_texture_scale"> + <member name="texture_scale" type="float" setter="set_texture_scale" getter="get_texture_scale" default="1.0"> The [code]texture[/code]'s scale factor. </member> </members> <constants> <constant name="MODE_ADD" value="0" enum="Mode"> - Adds the value of pixels corresponding to the Light2D to the values of pixels under it. This is the common behaviour of a light. + Adds the value of pixels corresponding to the Light2D to the values of pixels under it. This is the common behavior of a light. </constant> <constant name="MODE_SUB" value="1" enum="Mode"> Subtracts the value of pixels corresponding to the Light2D to the values of pixels under it, resulting in inversed light effect. |