I’ve been to every thread and answer page that i can find and no one seems to have an answer for this, i simply want to use my mouse location to get the player pawn or character to move to it accurately using pathfinding, the mouse location part is fine i figured that out on my own, but the simple move to location stops short my goals are as follows
use the mouse location as the destination for the pawn to pathfind to
move the PLAYER pawn/character to that destination root
my main goal is for a movement cost (in action points) to be used when the player moves to a destination, sort of like divinity 2
how about a aiMoveTo. If theres no need to actually posses the character then you can treat it like a god game and have every character use a ai controller. then you just have a reference to the character you want to move and use a ai move to.
basically instead of thinking of the character as the player you would think of the player controller as the player. then the controller tells a ai character what to do.
create a player controller and create the script below. on input (mouse press) you get a character ref (character you want to move) then do a ai move to with the destination being based on the mouse location.
next place a character in the level and make it so it doesn’t get possessed by the player. pass a reference of this character to the player controller and set the variable (this can be done easily via get player controller → cast to (insert class here)).
the result here is that the character will be possessed by a ai controller which is compatible with ai move to. AI don’t have to be the enemy or not in the players control. the character in the level is basically a empty husk or a robot with no brain of its own.