How to snap rotation from center cube sphere?

Hi I’d like to snap rotation from center to certein angle or Z axis. like on the image.

Hello Mateusz88,

It depends on what you regard as the ‘up’ vector from the instanced actor point of view, as in is the center always the center of gravity or does the the current surface normal determine the up vector. But there are multiple solutions nonetheless, the simplest one of the top of my head would be a line trace, where you’d extract the hit normal from the hit result. You the can use that vector to create a Rotator via the ‘Make Rotator from Z’.

Otherwise you could project the vector from the center to the instanced actor to the axes of the cube sphere (up, right and forward) and determine via the ratios which vector should be the up vector.

Hope that helps. Just let me know, if you have any questions or need further assistance.

Regards,

Vecherka.

Works like a charm:) Thank You

299589-planet-gen.jpg