Spawn Actor on mouse location with editor widget

Shaon Biswas
Wed, 25 Aug 2021 06:48:04 +0000
UI

Greetings to everyone,

I am making a game with maps that use a grid system. I am using an actor and spawn objects in the world. Each object acts as a grid. This will be significant as I can change the map easily if I need.

Because I need to have many objects instead of spawning them manually, I want to make an editor widget that can spawn the objects.

So what I am trying to do is get the mouse location and spawn an object at the mouse location. But the problem is how do I get the mouse location. In normal blueprints “convert mouse location to world space” can be used but not in the editor widget. Is there a way to get the mouse location or any other way to spawn the objects?

Thank you

2 posts - 2 participants