Open a topdown game template
Open Project setting, input, action mapping, add move forwrad, bacward, right, left button as WSDA
Create a BP pawn called BP cameraPawn
Add spring arm and camera component
spring arm details: rotation -50, target arm lenght 1200, tick enable camera lag and rotations, both speed as 5 (camera lag is to smooth out the camera movement)
Create a Game mode and Controller BP called BP_CameraGameMode, and BP CameraController,
set Gamemode class of controller, pawn and gamemode:
For Camera Controller graph: