#movement doesn't work?
1 messages · Page 1 of 1 (latest)
yeah
i don't need to actively controll it yet but when i click f6 it doesn't do anything
Because the variable gravity isn't attributed to anything.
It's just a random number, you'd need to put something like
var gravity = ProjectSettings.get_setting("physics/2d/default_gravity")
to grab the default gravity setting from Godot.
ok so the gravity variable doesn't give an error message anymore but the variable for velocity still does give an error message.
You shouldn't even need to put velocity as a variable if I'm not mistaken. (Since you're in a physics process)
ok so i just removed the var velocity and it doesn't give me an error message anymore, but when i click f6 it doesn't show me the the square, it just shows a gray screen.
Are you in the correct scene?
yes
Hold on two seconds.
Works just fine for me.
wait just to be sure what code did you use
ok so we used the same code but it still doesn't work for me
this is the scene i used
Looks fine.