• Tutorials
  • Dodge the creeps: How to connect the start_game signal to the new_game() function in the main scene?

For those who are familiar, I'm nearing the end of the Dodge The Creeps tutorial in the "Your first game" section of the Godot docs. I've checked over all of my code and everything looks correct, but I can't figure out what it's asking for in this final step.

"Now we need to connect the HUD functionality to our Main script. This requires a few additions to the Main scene:

In the Node tab, connect the HUD’s start_game signal to the new_game() function.

In new_game(), update the score display and show the “Get Ready” message:"

The specific section of the tutorial can be found here.

Any help you can offer would be immensely appreciated. :smile:

    select MAIN in scene dock click 'chainlink' then select HUD scene

    In scene dock... select HUD below that..(inspector) select Nodes to get signals click "start_game", then CONNECT in bottom right in connector dialog, bottom left change (type it in) Method In Node: new_game() click Connect (in this same dialog box)

    with HUD selected in scene explorer... now in the INSPECTOR Node 'signals' you should see HUD.gd [-> start_game() # red letters ...->] .. :: new_game() #green letters

    add code as instructed. I just did this, so I am hoping I have not forgot anything.

    Also... I just found this looking for clarification on the particles: There's 6 videos in this playlist on this very project.

    16 days later

    You rock man! Sorry for getting back so late about this. Lot of stuff happening at home.

    No worries. Lots of stuff here too. Also I did, I think get through this, then the 'particles' were another quest which you will definitely need those videos. Then some other tutorial was incomplete... I want to like this, but the docs are not doing it for me. I've been giving the defold engine a shot.

    21 days later

    I get the basics down well enough, I'm kind of new to programming myself. But I agree about the docs, a lot of the more advanced functions go way over my head.

    Right, to be fair: Godot's documentation isn't intended to be a introductory course to programming. It's worth checking out some python and/or lua tutorials first I suppose.

    It certainly wouldn't be a bad idea to perhaps have a series of that variety in the future, though. A "introduction to programming through godot" or some such.

      7 days later

      I do have some experience with Python 3.6. There are enough similarities to keep me from being totally lost, but subtleties of GD script elude me. It is just something that will develop over time with use I am sure. :-)

      6 years later

      soundchaser

      Please check that the main.gd script is associated with the main.tscn scene. To do this, check the dependencies of main.tscn by right-clicking in the file system.

      Necro alert! The thread is 6 years old.