Skip to content

Commit 859e293

Browse files
committed
simple_character: Move custom blocks to Input section
While these do have to do with movement, they happen because of input events. https://phabricator.endlessm.com/T35507
1 parent a05b007 commit 859e293

File tree

1 file changed

+2
-6
lines changed

1 file changed

+2
-6
lines changed

addons/block_code/simple_nodes/simple_character/simple_character.gd

Lines changed: 2 additions & 6 deletions
Original file line numberDiff line numberDiff line change
@@ -17,10 +17,6 @@ static func get_exposed_properties() -> Array[String]:
1717
return ["position"]
1818

1919

20-
static func get_custom_categories() -> Array[BlockCategory]:
21-
return [BlockCategory.new("Movement", Color("4a86d5"))]
22-
23-
2420
static func get_custom_blocks() -> Array[Block]:
2521
var b: Block
2622
var block_list: Array[Block] = []
@@ -30,14 +26,14 @@ static func get_custom_blocks() -> Array[Block]:
3026
b.block_type = Types.BlockType.EXECUTE
3127
b.block_format = "Move with player 1 buttons, speed {speed: INT}"
3228
b.statement = 'velocity = Input.get_vector("ui_left", "ui_right", "ui_up", "ui_down")*{speed}\n' + "move_and_slide()"
33-
b.category = "Movement"
29+
b.category = "Input"
3430
block_list.append(b)
3531

3632
b = CategoryFactory.BLOCKS["statement_block"].instantiate()
3733
b.block_type = Types.BlockType.EXECUTE
3834
b.block_format = "Move with player 2 buttons, speed {speed: INT}"
3935
b.statement = 'velocity = Input.get_vector("player_2_left", "player_2_right", "player_2_up", "player_2_down")*{speed}\n' + "move_and_slide()"
40-
b.category = "Movement"
36+
b.category = "Input"
4137
block_list.append(b)
4238

4339
return block_list

0 commit comments

Comments
 (0)