sync all NPC scripts
This commit is contained in:
@@ -1,5 +1,9 @@
|
||||
<Project name="Multi-pose script" guid="233f6e31-95a1-438e-80d0-4448aa0cac7b">
|
||||
<Object name="Object" guid="bc7ae54d-932e-4b75-9bb2-f63409d6fccd" active="true">
|
||||
<Animation name="Animation.ani" guid="584c57c3-bd10-48d4-bea6-19ba8fe8e430">
|
||||
</Animation>
|
||||
<Animation name="Animation2.ani" guid="1c465e9c-6a22-4ec3-a5db-85a25a8f9006">
|
||||
</Animation>
|
||||
<Script name="Script.lsl" guid="e52a0629-9fda-4d09-b6ef-e8a41a54115b">
|
||||
</Script>
|
||||
</Object>
|
||||
|
||||
@@ -45,9 +45,9 @@ rotation sitRot=ZERO_ROTATION; // Sit Kit to determine the best position a
|
||||
// Uncomment one of the following five lines to choose your animation method:
|
||||
string animMethod="SEQUENCE_TIMED"; // each animation will be played in sequence, cycling back to the first upon reaching the end
|
||||
// string animMethod="RANDOM_TIMED"; // as above, except the order of animations is randomly shuffled
|
||||
// string animMethod="SEQUENCE_TOUCH"; // each animation will be played in sequence, but only advances when the seated person touches the object
|
||||
//string animMethod="SEQUENCE_TOUCH"; // each animation will be played in sequence, but only advances when the seated person touches the object
|
||||
// string animMethod="RANDOM_TOUCH"; // as above, in random order
|
||||
// string animMethod="DIALOG_SELECT"; // upon sitting the avatar will be asked to pick the animation they wish to play. Once seated, touching
|
||||
//string animMethod="DIALOG_SELECT"; // upon sitting the avatar will be asked to pick the animation they wish to play. Once seated, touching
|
||||
// the object will display the dialog again, allowing you to pick a different animation. Maximum of 12 animations.
|
||||
float animTimer=45.0; // if using either of the two TIMED methods, how long (in seconds) to wait before advancing to the next animation
|
||||
// this is ignored if you are using one of the other 3 methods
|
||||
@@ -108,8 +108,10 @@ nextAnim()
|
||||
if (llSubStringIndex(animMethod,"RANDOM")>-1) anList=llListRandomize(anList,1);
|
||||
}
|
||||
string nextAnim=llList2String(anList,curInd);
|
||||
|
||||
if (nextAnim!=currentAnim)
|
||||
{
|
||||
|
||||
llStartAnimation(nextAnim);
|
||||
llStopAnimation(currentAnim);
|
||||
}
|
||||
@@ -179,7 +181,7 @@ default
|
||||
{
|
||||
if (mySitter==NULL_KEY) return; // ignore if no sitter
|
||||
if (llDetectedKey(0)!=mySitter) return; // ignore if not current sitter
|
||||
if (llSubStringIndex(animMethod,"TIMED")>-1) return; // ignore if using timed method
|
||||
if (llSubStringIndex(animMethod,"//TIMED")>-1) return; // ignore if using timed method
|
||||
if (animMethod=="DIALOG_SELECT") getAnim();
|
||||
else nextAnim();
|
||||
}
|
||||
|
||||
Reference in New Issue
Block a user