Getting world vector from cursor.

It’s a bit hard to explain, but it’s kinda like a strategy game.

First of all, I use a custom top-down view, and when someone presses left mouse a DermaMenu pops up with the option “Move to”. When you press the “Move to” it has to do simply get the world vector of where you pressed on the screen then make the player move there. I’ve struggled with this for ages now…

Does someone have any clue?

It turns a screen position into a (normalized) direction vector. All you need to do is perform a trace in that direction to get a world position.

Hm, let me try that. Thanks.

[editline]24th May 2013[/editline]

Well, that worked. Now, is it possible making the player move to the location (Not using the SetPos)?

[editline]24th May 2013[/editline]

Or, I could try using NextBot, still tho I have no clue how it works.