I made a simple code to rotate the camera in Top-Down, I also have WASD set as character movement.
Someone can tell me how to change the moving so that when I rotate the camera W will swap functions with S?
That is, I look north with the camera, press W and the character goes north.
I rotate the camera 180* and W continues to direct the character north instead of south.
You need to get the direction of the spring arm and apply movement to the actor based on that. Nothing in your code is connecting those two things at the moment.
I went in the top down blueprint and changed nothing except making a forward movement EIA (axis1d), and mouseinput (axis2d), and it works how you’re wanting (except the ASD keys of course, which you can set up by following this exactly)
It not working for me.
When the game is launched, indeed the character runs along with the camera rotation.
But when I press the key to move it all goes back to the basic settings and again the character runs up and not where I turn the camera
In addition, I changed the controls a bit and instead of an additional class with controls I just added it to the settings, now this is how my character’s movement in the world looks like
It is because you are in the player controller instead of the character
I made a solution for you in player controller that is fully functional that you can copy for WASD movement. I included all relevant information so you can learn what you need
Going to need more information then, my code is working perfectly in a blank top down project. Here is a sample of what my code does https://www.youtube.com/watch?v=wUg2cKgyDg0
Summary
I added the IA’s, added the IA’s to the IMC, deleted everything in the player controller except to add the mapping context, then pasted in the nodes for forward backwards left and right and it’s working exactly as expected on 2 different projects.
Post full editor screenshots of your copied player controller event graph, your IMC, and your character blueprint (unless it’s empty)
You did not add mapping context in these screenshots, you must select the asset and do not use “add mapping context (message)” node. I believe your code in the character BP is also doing nothing, experiment with removing it all together during this troubleshooting process.
Please make these changes and add these debugging statements to your code and report back
I overlooked such a small detail as selecting a file.
Thanks a lot
Now the character runs in the indicated direction but with a slight deviation, I need to increase the strength of this turning along with the 1:1 camera