General

Possible to set RingArea attractor_x via script?

Started by notlion on .

Sign in or create an account to join the conversation.

3 posts

Topic starter
Hi, guys! New to Lemur here.

I'm trying to implement a 'hold' behavior on a RingArea. I want the attractor position to be set to the current x,y when I toggle a switch on. Problem is, the attractor_x and y don't seem able to be set with setattribute. Is there another way? If not then I guess this is a feature request ;)

Thanks!
ryan
Thank you! I ended up getting it working by making two scripts on the Switch:
// On
velocity.attraction_x = velocity.x;
velocity.attraction_y = velocity.y;
// Off
velocity.attraction_x = 0.5;
velocity.attraction_y = 0.5;
Love that I can code this right on the controller, instead of in my app.

ryan