From 1b499d244a796b9dfb0a71961437f1ce88cccee6 Mon Sep 17 00:00:00 2001 From: Aaron Franke Date: Fri, 4 Dec 2020 19:32:11 -0500 Subject: [PATCH] Rename LightOccluder2D light_mask to occluder_light_mask --- doc/classes/LightOccluder2D.xml | 6 +++--- scene/2d/light_occluder_2d.cpp | 4 ++-- 2 files changed, 5 insertions(+), 5 deletions(-) diff --git a/doc/classes/LightOccluder2D.xml b/doc/classes/LightOccluder2D.xml index 45925dee96a..550daf92258 100644 --- a/doc/classes/LightOccluder2D.xml +++ b/doc/classes/LightOccluder2D.xml @@ -12,12 +12,12 @@ - - The LightOccluder2D's light mask. The LightOccluder2D will cast shadows only from Light2D(s) that have the same light mask(s). - The [OccluderPolygon2D] used to compute the shadow. + + The LightOccluder2D's occluder light mask. The LightOccluder2D will cast shadows only from Light2D(s) that have the same light mask(s). + diff --git a/scene/2d/light_occluder_2d.cpp b/scene/2d/light_occluder_2d.cpp index 6908fbeadaf..b5b39ccc8ff 100644 --- a/scene/2d/light_occluder_2d.cpp +++ b/scene/2d/light_occluder_2d.cpp @@ -238,7 +238,7 @@ Ref LightOccluder2D::get_occluder_polygon() const { void LightOccluder2D::set_occluder_light_mask(int p_mask) { mask = p_mask; - RS::get_singleton()->canvas_light_occluder_set_light_mask(occluder, mask); + RS::get_singleton()->canvas_light_occluder_set_light_mask(occluder, p_mask); } int LightOccluder2D::get_occluder_light_mask() const { @@ -285,7 +285,7 @@ void LightOccluder2D::_bind_methods() { ADD_PROPERTY(PropertyInfo(Variant::OBJECT, "occluder", PROPERTY_HINT_RESOURCE_TYPE, "OccluderPolygon2D"), "set_occluder_polygon", "get_occluder_polygon"); ADD_PROPERTY(PropertyInfo(Variant::BOOL, "sdf_collision"), "set_as_sdf_collision", "is_set_as_sdf_collision"); - ADD_PROPERTY(PropertyInfo(Variant::INT, "light_mask", PROPERTY_HINT_LAYERS_2D_RENDER), "set_occluder_light_mask", "get_occluder_light_mask"); + ADD_PROPERTY(PropertyInfo(Variant::INT, "occluder_light_mask", PROPERTY_HINT_LAYERS_2D_RENDER), "set_occluder_light_mask", "get_occluder_light_mask"); } LightOccluder2D::LightOccluder2D() {