Jump to content

flow dilema help required


VirtualKitten
 Share

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

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

Recommended Posts

I have some code which is rough and want to improve it it basically moves a mesh in a circle using llSetjump to startLinkParamsFast( 

I have this in a script which uses basic loop http://wiki.secondlife.com/wiki/Jump

@start

... Move item

llSleep(1)

jump to start

@end

Now I am using llSetScriptState( to stop and start this but it is fraught with problems that i will not go into here.

My question is how to make this into one script with my other code . The problem is house-keeping and there is not much time-slice afforded to llListen or MessageLink events. How then do i properly script movement in LSL script .As i think i am missing something vital

Thanks for looking D

Link to comment
Share on other sites

I think a timer might help here:

timer ()
{
    //move object
}


To start the timer, and start moving the object:

llSetTimerEvent (1.0);

and to stop the timer, and stop moving the object:

llSetTimerEvent (0.0);

Edited by KT Kingsley
  • Like 1
Link to comment
Share on other sites

22 hours ago, Sabrina Tamerlane said:

KT Kingsley is correct, but you will also have to remove anything that puts the script to sleep if you want a regular timing.

Yes, and remove the stuff that has to do with jump too.  It might be a good idea to step back and go through a basic LSL tutorial to familiarize yourself with the state/event structure that is the foundation of LSL, then take a special look at how a timer event works. 

Link to comment
Share on other sites

  • 2 weeks later...
You are about to reply to a thread that has been inactive for 1561 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...