Jump to content

How to make an Animesh to spin offset from his center ?


chrixbed
 Share

You are about to reply to a thread that has been inactive for 80 days.

Please take a moment to consider if this thread is worth bumping.

Recommended Posts

I made an animesh and I would like to make it spin around a cube with an offset from the center. If I apply a llTargetOmega() that will make the Animesh spin but without any distance from the center. Normally if I just link 2 prims together and distance them apart they will spin around the linkset center. Unfortunately, the Animesh only spins on itself, it can't be offset.

I would like to make the Animesh spin around an offset center, is there a way to do that?

Detail video: https://gyazo.com/8eb7bf82052c9c10468c245c8abece1c

6f0bcafb026b0fed5369819c2f0361e2.png

Edited by chrixbed
Link to comment
Share on other sites

SL linking doesn't have any 'heirarchy', so when you link the red box+animesh to the plywood cube, the animesh becomes linked as a child of the plywood cube.

The only solution I can think of would be to make an animation that moves the center joint, and apply that animation to the animesh.

  • Like 1
  • Thanks 1
Link to comment
Share on other sites

14 hours ago, Extrude Ragu said:

I think Quiestess was saying you'd use an animation to offset the animesh, not to rotate it. ie you can still use target omega but you need a 1 frame animation that moves the whole animesh away from center

*coughs* Yes, I'm glad I considered that such would be much better than using the animation without omega.

  • Like 1
  • Thanks 1
Link to comment
Share on other sites

I like the idea of having an animation that offsets the Animesh. The only issue I have with that is it seems to be limited to 10 meters by axes as far as I know. Also in my case, I made a giant Animesh and the 10 meters is not visible. Anywhoe as try to use llSetKeyframedMotion() or some Pathfinding LSL functions with success to simulate a rotation ? Or maybe I should just llSetPos() the prim using a circle equation or some sort?

Link to comment
Share on other sites

Pathfinding has many caveats where it could be used at all and is generally pretty poor, and llSetPos is simple but not server efficient. 

Keyframed motion is by far the cheapest method; it's not "free", but once a keyframed motion has been started, it'll run with quite low resource usage. It isn't reliable, though, the movement may drift over time so you'd be wise to stop it once in a while and use standard positionining to ensure your object is where it should be, then restart the animation. You'd just use the same circle equation for the path as you'd do with llSetPos, except you'd precompute keyframes into a list instead of using the formula directly as a function of time.

Link to comment
Share on other sites

You could do the whole spinning job with a custom animation. Animations which walk characters in a circle work fine. That's the cleanest solution if you can edit an animation file.

If you use actual prim motion, stick to one system. There's keyframe motion, physical motion, pathfinding motion, and position-set motion.  They are not interlocked. If you use more than one on the same object,  there may be some interference.

Keyframe motion, followed by a check on the final position and an adjustment for the next cycle, is useful.

Link to comment
Share on other sites

You are about to reply to a thread that has been inactive for 80 days.

Please take a moment to consider if this thread is worth bumping.

Please sign in to comment

You will be able to leave a comment after signing in



Sign In Now
 Share

×
×
  • Create New...