Constraining actor to move within circle?

jrj.clarkjrj.clark Member, PRO Posts: 17

Hi there,

I have a fixed point determined by X and Y attributes.
How can I get my actor to move only a certain radius away from this fixed point?

I know I can use constrain if the actor moves more than a certain distance in the X or Y direction, but this limits the actor's movement to a box shape, not a circle.

Thanks in advance!


  • SocksSocks London, UK.Member Posts: 12,822

    You need to provide more information, is the actor bouncing around the scene using the physics engine, is it being dragged by the player through touch, is it being moved by the player using the keyboard (and if it is then what behaviour is being used, change velocity, move, move to . . . etc), or maybe the actor is static and only moves when a certain attribute is changed . . . etc (and a thousand other posibilities).

  • jrj.clarkjrj.clark Member, PRO Posts: 17

    Thanks for the feedback Socks.

    I have an actor that I want a player to 'pick up' and move to a new location. This is done by the player through touching/clicking the actor and dragging it to the new desired location.

    I only want that actor to be able to move a certain distance from the starting point - and I want that distance to be the same in all directions, hence the need for a circle.

Sign In or Register to comment.