Re-syncing dances; & extended animations
|
|
Ricky Shaftoe
Owner, "Rickymations"
Join date: 27 May 2005
Posts: 366
|
03-04-2008 08:15
I have two animation-related issues.
1. For a couple of years I've sold my dance poseballs with a sync script that relies on linked messages and states. The script works fine, but usually not til the dancers hop on and off once or twice. I've seen some scripts that re-sync automatically, while the dancers stay on the poseballs. I've fooled around a bit with trying to do this myself, perhaps by using llGetTimeOfDay (which is how I sync in the first place), but I can't seem to get it right. Anyone have any suggestions?
2. I'd also like to try to make some of the extended 'story romance' poseball sets, like Craig Altman makes at Bits & Bobs. He's managed to overcome the 30-second limit on uploaded anims by stringing them together. I presume I just need to crank out, say, three sets of 30 second animations and then play them in succession. And use a counter to define which animation should be playing currently. This I haven't tried yet. I figured I'd ask for suggestions before I dive in. Any thoughts?
|
|
Void Singer
Int vSelf = Sing(void);
Join date: 24 Sep 2005
Posts: 6,973
|
03-04-2008 18:02
the link msg is your friend, send the resynch msg to the whole object, each script triggers the animation from the start upon recieving it, no need to get up.
much better than sending a msg to one while triggering the other, because you know they both get the instruction at the same time.
_____________________
| | . "Cat-Like Typing Detected" | . This post may contain errors in logic, spelling, and | . grammar known to the SL populace to cause confusion | | - Please Use PHP tags when posting scripts/code, Thanks. | - Can't See PHP or URL Tags Correctly? Check Out This Link... | - 
|
|
Nika Talaj
now you see her ...
Join date: 2 Jan 2007
Posts: 5,449
|
03-04-2008 19:34
From: Void Singer the link msg is your friend, send the resynch msg to the whole object, each script triggers the animation from the start upon recieving it, no need to get up.
much better than sending a msg to one while triggering the other, because you know they both get the instruction at the same time. Sorry, Void, I don't understand how this relates to his question? As I read the OP, he's planning to have many animations in one object, and wants to play them end-to-end. Or possibly two objects, if it's a couples pose set (or three lalala ... anyway). I think his question was, what's the best way to play the string of animations end-to-end ... He suggested using a timer, but then it seems to me the script is so dependent on the individual animations. Is there any way to say, "play this (unlooped) animation to completion, then start the next one"?
|
|
Ricky Shaftoe
Owner, "Rickymations"
Join date: 27 May 2005
Posts: 366
|
03-04-2008 20:21
From: someone As I read the OP, he's planning to have many animations in one object, and wants to play them end-to-end. Or possibly two objects, if it's a couples pose set (or three lalala ... anyway). I think his question was, what's the best way to play the string of animations end-to-end ...Is there any way to say, "play this (unlooped) animation to completion, then start the next one"? Actually, you're both right. I am indeed interested in the question as Nika frames it: I would like to place 6 animations in a set of poseballs, 3 in each ball, and play them in succession. Thus I'd get a 90 second dance instead of a 30 second dance. But I'm also interested in resyncing in mid-stream, which is a separate issue, even if I'm playing only a single pair of 30-second dance animations. I noticed one poseball set today that responds to "/1 sync" by restarting each animation. And I've noticed others that seem to resync without any input from the user; how the balls know to do this isn't clear to me. Void suggests sending a resynch msg "to the whole object," but I recall having trouble getting it to work that way. I ended up sending linked messages back and forth between each ball. Got any sample pseudo-code or code that might work, Void? Eventually I'm interested in combining both my questions. I'd like to play 90-second dance animations (3 x 30 seconds); and I'd like to be able to resync in mid-stream (either in response to user input or automatically) without requiring the users to hop off.
|
|
Void Singer
Int vSelf = Sing(void);
Join date: 24 Sep 2005
Posts: 6,973
|
03-04-2008 21:35
in one of the scripts listen ( <standard crap> ){ //-- if msg == 'sync' llMessageLinked( LINK_SET, 0, "Pose Synch", "" ); }
in both of the scripts link_message( <standard crap> ){ //-- if msg == "Pose Synch", trigger anim }
as for synching the next playing anim, you have 3 choices... time it, which could mean being off if the server or client is lagging, detect it, by polling the playing animation list and waiting for the last one to stop, or play around with the priorities, and overlap them using one of the previous methods (makes for seamless playback but reduces overall time, basically start in 4, play the folowup before the end in 3 and when 4 ends 3 is already picked up ...)
_____________________
| | . "Cat-Like Typing Detected" | . This post may contain errors in logic, spelling, and | . grammar known to the SL populace to cause confusion | | - Please Use PHP tags when posting scripts/code, Thanks. | - Can't See PHP or URL Tags Correctly? Check Out This Link... | - 
|
|
Ricky Shaftoe
Owner, "Rickymations"
Join date: 27 May 2005
Posts: 366
|
03-05-2008 10:20
Thanks for your reply. I hadn't thought of overlapping animations playing sequentially. That is a problem for the current 3-in-a-row poseballs I've used: there's usually a slight gap between each animation.
Thanks also for the suggestion on resyncing. I'll give it a whirl.
|