From 8639cecf4cedd56452b47503be19c44b304cd02f Mon Sep 17 00:00:00 2001 From: =?UTF-8?q?R=C3=A9mi=20Verschelde?= Date: Wed, 9 Dec 2015 08:38:23 +0100 Subject: Improve code formatting and update to 2.0 The scripts were streamlined using more or less the following conventions: - space after a comma in lists of arguments - space around weak operators (+, -), no space around strong operators (*, /) - space after a comment start (#) - removed trailing spaces or tabs, apart from those that delimit the function indentation level (those could be removed too but since they are added automatically by the editor when typing code, keeping them for now) - function blocks separate by two newlines The scene files were resaved with the (current) 2.0 format, and some scenes that were in XML format were converted to SCN, to be consistent across all demos. --- demos/misc/autoload/scene_b.gd | 3 +-- 1 file changed, 1 insertion(+), 2 deletions(-) (limited to 'demos/misc/autoload/scene_b.gd') diff --git a/demos/misc/autoload/scene_b.gd b/demos/misc/autoload/scene_b.gd index 4a88fddda9..599058848b 100644 --- a/demos/misc/autoload/scene_b.gd +++ b/demos/misc/autoload/scene_b.gd @@ -5,13 +5,12 @@ extends Panel # var a=2 # var b="textvar" + func _ready(): # Initalization here pass - - func _on_goto_scene_pressed(): get_node("/root/global").goto_scene("res://scene_a.scn") pass # replace with function body -- cgit v1.2.3 From 8c4f19e79d3e8ac8bc8c283073dce5ccfbf222b5 Mon Sep 17 00:00:00 2001 From: =?UTF-8?q?R=C3=A9mi=20Verschelde?= Date: Sat, 21 Nov 2015 13:31:25 +0100 Subject: Use upper-cased first letter at the start of comment sentences --- demos/misc/autoload/scene_b.gd | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-) (limited to 'demos/misc/autoload/scene_b.gd') diff --git a/demos/misc/autoload/scene_b.gd b/demos/misc/autoload/scene_b.gd index 599058848b..fdf2287a04 100644 --- a/demos/misc/autoload/scene_b.gd +++ b/demos/misc/autoload/scene_b.gd @@ -1,7 +1,7 @@ extends Panel -# member variables here, example: +# Member variables here, example: # var a=2 # var b="textvar" @@ -13,4 +13,4 @@ func _ready(): func _on_goto_scene_pressed(): get_node("/root/global").goto_scene("res://scene_a.scn") - pass # replace with function body + pass # Replace with function body -- cgit v1.2.3