aboutsummaryrefslogtreecommitdiff
path: root/scene/2d/light_2d.h
diff options
context:
space:
mode:
authorRémi Verschelde2017-03-05 16:44:50 +0100
committerRémi Verschelde2017-03-05 16:44:50 +0100
commit5dbf1809c6e3e905b94b8764e99491e608122261 (patch)
tree5e5a5360db15d86d59ec8c6e4f7eb511388c5a9a /scene/2d/light_2d.h
parent45438e9918d421b244bfd7776a30e67dc7f2d3e3 (diff)
downloadgodot-5dbf180.tar.gz
godot-5dbf180.tar.zst
godot-5dbf180.zip
A Whole New World (clang-format edition)
I can show you the code Pretty, with proper whitespace Tell me, coder, now when did You last write readable code? I can open your eyes Make you see your bad indent Force you to respect the style The core devs agreed upon A whole new world A new fantastic code format A de facto standard With some sugar Enforced with clang-format A whole new world A dazzling style we all dreamed of And when we read it through It's crystal clear That now we're in a whole new world of code
Diffstat (limited to 'scene/2d/light_2d.h')
-rw-r--r--scene/2d/light_2d.h51
1 files changed, 24 insertions, 27 deletions
diff --git a/scene/2d/light_2d.h b/scene/2d/light_2d.h
index 2bdcca5d0..e9f0e069d 100644
--- a/scene/2d/light_2d.h
+++ b/scene/2d/light_2d.h
@@ -33,7 +33,8 @@
class Light2D : public Node2D {
- GDCLASS(Light2D,Node2D);
+ GDCLASS(Light2D, Node2D);
+
public:
enum Mode {
MODE_ADD,
@@ -73,80 +74,77 @@ private:
Vector2 texture_offset;
ShadowFilter shadow_filter;
-
void _update_light_visibility();
-protected:
+protected:
void _notification(int p_what);
static void _bind_methods();
-public:
-
- virtual void edit_set_pivot(const Point2& p_pivot);
+public:
+ virtual void edit_set_pivot(const Point2 &p_pivot);
virtual Point2 edit_get_pivot() const;
virtual bool edit_has_pivot() const;
- void set_enabled( bool p_enabled);
+ void set_enabled(bool p_enabled);
bool is_enabled() const;
void set_editor_only(bool p_editor_only);
bool is_editor_only() const;
- void set_texture( const Ref<Texture>& p_texture);
+ void set_texture(const Ref<Texture> &p_texture);
Ref<Texture> get_texture() const;
- void set_texture_offset( const Vector2& p_offset);
+ void set_texture_offset(const Vector2 &p_offset);
Vector2 get_texture_offset() const;
- void set_color( const Color& p_color);
+ void set_color(const Color &p_color);
Color get_color() const;
- void set_height( float p_height);
+ void set_height(float p_height);
float get_height() const;
- void set_energy( float p_energy);
+ void set_energy(float p_energy);
float get_energy() const;
- void set_texture_scale( float p_scale);
+ void set_texture_scale(float p_scale);
float get_texture_scale() const;
- void set_z_range_min( int p_min_z);
+ void set_z_range_min(int p_min_z);
int get_z_range_min() const;
- void set_z_range_max( int p_max_z);
+ void set_z_range_max(int p_max_z);
int get_z_range_max() const;
- void set_layer_range_min( int p_min_layer);
+ void set_layer_range_min(int p_min_layer);
int get_layer_range_min() const;
- void set_layer_range_max( int p_max_layer);
+ void set_layer_range_max(int p_max_layer);
int get_layer_range_max() const;
- void set_item_cull_mask( int p_mask);
+ void set_item_cull_mask(int p_mask);
int get_item_cull_mask() const;
- void set_item_shadow_cull_mask( int p_mask);
+ void set_item_shadow_cull_mask(int p_mask);
int get_item_shadow_cull_mask() const;
- void set_mode( Mode p_mode );
+ void set_mode(Mode p_mode);
Mode get_mode() const;
- void set_shadow_enabled( bool p_enabled);
+ void set_shadow_enabled(bool p_enabled);
bool is_shadow_enabled() const;
- void set_shadow_buffer_size( int p_size );
+ void set_shadow_buffer_size(int p_size);
int get_shadow_buffer_size() const;
- void set_shadow_gradient_length( float p_multiplier);
+ void set_shadow_gradient_length(float p_multiplier);
float get_shadow_gradient_length() const;
- void set_shadow_filter( ShadowFilter p_filter);
+ void set_shadow_filter(ShadowFilter p_filter);
ShadowFilter get_shadow_filter() const;
- void set_shadow_color( const Color& p_shadow_color);
+ void set_shadow_color(const Color &p_shadow_color);
Color get_shadow_color() const;
-
virtual Rect2 get_item_rect() const;
String get_configuration_warning() const;
@@ -158,5 +156,4 @@ public:
VARIANT_ENUM_CAST(Light2D::Mode);
VARIANT_ENUM_CAST(Light2D::ShadowFilter);
-
#endif // LIGHT_2D_H