All Questions

Community

R
Brian Rogers

Player not moving at this stage.... "Setting up Game Level"

Greetings,

I can start the Game scene and see the character but he won't respond to the Keyboard inputs. My errors seem to be in my State.gd:

any help would be appreciated.

What should my Player and PlayerState scripts look like? I followed verbatim. Would be helpful to see the finalized scripts Brian

  • Thank you for the kind words. I'm glad we could fix your issue. 🙂

  • R
    Brian Rogers

    Wow! Good spot Nathan!

    I corrected the spelling and he moves! I noticed he wasn't accessing the run or jump animations so comparing it to your final version and I noticed the "idle" animation in the Animation Player was set to "Autoplay on Load". I unchecked it, made sure it was set to loop and all is good! Finally, I can continue on with Chapter 3. Loving the course, btw.

    Thanks so much Nathan for your persistence and patience. Really great support! Very much appreciated.

    Brian

  • Correct

    The problem was that in StateMachine.gd, your _physics_process function had an incorrect name:

    func _physic_process
    

    It's missing an s so Godot would never call it.

  • R
    Brian Rogers

    Hey Nathan,

    Here's a link to my Godot Project that I'm having issues with. Can't move the character with the keyboard keys

    https://drive.google.com/drive/folders/15iJ21T1YtoUkYNvGLcj7_Lf6iPBh8OVR?usp=sharing

    I've been using Godot 3.2 beta 4. Hope you or someone else can spot the issue.


    Thanks,

    Brian

  • About the post's formatting, it may be a bug on the platform. I'll let the devs know.

    Where can I upload a project file?

    Wherever you want, you can use something like wetransfer, or a cloud service of your choice.

  • R
    Brian Rogers

    Thanks for the reply Nathan,

    Apologies for the formatting. I don't think it look like that when I sent it. I still can't get the key input to do anything. No movement in the character. Would be nice to have someone look at my project file.

    Where can I upload a project file?

  • You can download the source code for each chapter here to compare files: https://gdquest.mavenseed.com/lessons/download-all-the-godot-projects-11d7c425d3713e19

    In this archive, you have one Godot project per chapter. The projects have a git history with intermediate steps for many of the videos, if you know how to use git.

    Could you please use the code blocks when posting block? It's hard to read your code and help you otherwise. To do so, click the </> icon at the top of the text editor, paste your code, and click </> to end the code block.

    You don't have any error in there, so if the character isn't moving, there's necessarily a value or a function call that's incorrect somewhere, or a script that's not attached to a given node for instance.

    If you can't find a way to fix this, could you upload your Godot project as a .zip archive somewhere? I would need that to find and tell you how to fix the issue.