Skip to content

Commit 56c44f5

Browse files
committed
Add blocks to reference nodes in the scene
https://phabricator.endlessm.com/T35497
1 parent 51c3924 commit 56c44f5

File tree

1 file changed

+12
-0
lines changed

1 file changed

+12
-0
lines changed

addons/block_code/ui/picker/categories/category_factory.gd

Lines changed: 12 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -178,6 +178,18 @@ static func get_general_categories() -> Array[BlockCategory]:
178178
# Objects & Types
179179
var type_list: Array[Block] = []
180180

181+
b = BLOCKS["parameter_block"].instantiate()
182+
b.block_type = Types.BlockType.NODE
183+
b.block_format = "This object"
184+
b.statement = "self"
185+
type_list.append(b)
186+
187+
b = BLOCKS["parameter_block"].instantiate()
188+
b.block_type = Types.BlockType.NODE
189+
b.block_format = "%{name: STRING}"
190+
b.statement = "%{name}"
191+
type_list.append(b)
192+
181193
b = BLOCKS["parameter_block"].instantiate()
182194
b.block_type = Types.BlockType.STRING
183195
b.block_format = "As String {value: VARIANT}"

0 commit comments

Comments
 (0)