fix bug when selecting unimplemented entities

This commit is contained in:
Nitwel 2023-11-30 23:41:20 +01:00
parent 06bfecc390
commit c89615f3bc
3 changed files with 6 additions and 2 deletions

View File

@ -1,3 +1,3 @@
version https://git-lfs.github.com/spec/v1
oid sha256:ec74b5b5948e76d01115d7ff959610515e97aca1c42870f36b4a747f2dc4cb70
oid sha256:b55738edba8fcdaab47c5e40cf4b900b10c86ea67f9d40dc041f84f4e76ec484
size 2416

View File

@ -1,3 +1,3 @@
version https://git-lfs.github.com/spec/v1
oid sha256:46cdd3222390fdf4b7e6f591958bbf30944df088a71cab919ba54a49ace2baf8
oid sha256:3a3e64d9a45c8ab58180b00eae7ed8e306c22686656fca4ed854b87283ed4c09
size 2424

View File

@ -149,6 +149,10 @@ func _on_entity_click(entity_name):
AudioPlayer.play_effect("spawn")
var entity = EntityCreator.create_entity(type, entity_name)
if entity == null:
return
entity.set_position(global_position)
get_node("/root").add_child(entity)