Mobs Do not spawn

:information_source: Attention Topic was automatically imported from the old Question2Answer platform.
:bust_in_silhouette: Asked By Drimenlon

I am following the tutorial from dodge-the-creeps but the mobs do not appear. I want to know how the Path2D works because I think thats the problem but I am no sure.!

I put the url of images that show my project, hope someone know why mobs do not work. sorry for bad english.

Hello Drimenlon. You can find a completed version of this project at these locations:
Releases · kidscancode/Godot3_dodge · GitHub
GitHub - godotengine/godot-demo-projects: Demonstration and Template Projects
and just compare it :wink:

tetrahomerge | 2020-07-27 17:10

you need instance

func_on_MobTimer_timerout():

in

func _ready():

for spawner fist mob

Lian_er | 2021-04-21 02:55

:bust_in_silhouette: Reply From: ChristianSF

Do you get any error messages at all (not recognizable by looking at your images)?

Try to add a

print("Mob has spawned")

into your _on_MobTimer_timeout() function and check if you see that text appear after starting the game.

I know that I had made a mistake following that tutorial, too. In my opinion (which doesn’t help you at all, I know), this tutorial should not be the first newbies are confronted with. It’s already too complicated to follow with all those intertwined Timers and game characters.

:bust_in_silhouette: Reply From: njamster

From the second screenshot it looks like you didn’t connect the timeout-signal of the StartTimer-node to the _on_StartTimer_timeout-callback. Then the MobTimer isn’t started as well, thus cannot timeout and spawn any mobs.

:bust_in_silhouette: Reply From: Jang_kayld

I figured it out! I was having the same trouble so I tried checking everywhere. I noticed something though. I don’t know if I missed it or something but my MobTimer did not have auto start turned on and so I turned it on. Guess what, IT WORKED! It only works when auto start is turned on but I don’t know if that’s how it really should be.