meteorite icon indicating copy to clipboard operation
meteorite copied to clipboard

Game crash on starting new game, while using Godot 3.2.3 to compile + run

Open huangwei4478 opened this issue 3 years ago • 5 comments

hi, Bauxitedev!

I just came across your meteorite game and would like to have a try & take to look at this implementation inside for learning, and I found myself cannot start a new game due to the following crash in door_generic.gd, which the debugger said: "Invalid get index 'move_to_pos' (on base: null instance)"


# door_generic.gd

func _ready():
	
	var door_list_split = door_list.split(",")
	for door_name in door_list_split:
		doors.push_back(get_node(door_name))
	
	match bullet_color:
		BulletColor.RED: set_doormat_tex(load("res://%s_red.png" % door_texture_prefix))
		BulletColor.GREEN: set_doormat_tex(load("res://%s_green.png" % door_texture_prefix))
		BulletColor.BLUE: set_doormat_tex(load("res://%s_blue.png" % door_texture_prefix))
		
	for door in doors:
		var door_name = door.name
		initial_positions[door_name] = door.translation
		target_positions[door_name] = door.get_node("col").move_to_pos    # crash on this line
		

It seems like door.get_node("col") is returning null. get_node cannot find "col" node.

Do you have any idea to fix it? Any hint or advices would be very appreciated so I might make a PR for this migration.

Thanks!

huangwei4478 avatar Oct 08 '20 15:10 huangwei4478

Yup, as mentioned in the readme, only Godot 3.0.4 works. I'll have to fix it at some point but I'm still recovering from COVID so that may take a long while.

Bauxitedev avatar Oct 09 '20 09:10 Bauxitedev

I'm still recovering from COVID

Oh! I hope this doesn't mean you caught it, I hope you mean the general changes the pandemic brought on.

Zireael07 avatar Oct 09 '20 10:10 Zireael07

@Zireael07 I caught COVID in March, I'm still bedridden today, although I'm slowly recovering and lately I've started doing some light programming again.

Bauxitedev avatar Oct 09 '20 13:10 Bauxitedev

Yup, as mentioned in the readme, only Godot 3.0.4 works. I'll have to fix it at some point but I'm still recovering from COVID so that may take a long while.

Oh man... Just take good care & good rests! Hope you recover well and sound soon!

huangwei4478 avatar Oct 09 '20 15:10 huangwei4478

oh, right, forgot to cross-link the PR and the issue, um, https://github.com/Bauxitedev/meteorite/pull/10

20kdc avatar Jul 02 '21 18:07 20kdc