Jump to content

trivis

Resident
  • Content Count

    20
  • Joined

  • Last visited

Posts posted by trivis

  1. Thank you very much for all this insights!!!! This is so very helpful.

    I also tried the stopping in combination with llScaleByFactor(1.00); that seems to work as good workaround for now. I am sure anymore, but i think i did the stopping with llTargetOmega(ZERO_VECTOR,0.0,1.0);

    The llScaleByFactor() was kinda accidentally part of my script, in a reset module.

  2. Thank you for this idea. It was my first thought too. Tried it, but also without the effect that i am looking for, unfortunately. 

    And thanks for the knowledge of that the spinning isnt rotating. So, perhaps there isnt a solution.

    Anyhow, thanks for thinking with me. I really appreciate and value your contribution!

    Trivis

  3. Hello all,

    I have a cylinder attached to my body center. It rotates by use of llTargetOmega(). That works all fine. I can increase/decrease the speed or stop the spinning.

    After some spinning around i like to not only stop the spinning but also want to reset the rotation, that is that the cylinder goes back to the default avatar rotation.

    When using llSetRot() i am not able to set the rotation back to the original point. 

    Any help around? 🙂

    Thanks in advance,

    Trivis

  4. Worked on the problem... it works fine when I use a "point object" which is left or right of a "avatar object". 

    When the avatar object is a real avatar it doesnt work.

    The script is:

    default {
        touch_start(integer total_number) {
            key id; 
            id = llGetOwner(); // avatar
    //        id = "e9f7952f-2ac4-0cb7-db9d-4f9a61509593"; // object
            // target avatar
            vector avPos = llList2Vector(llGetObjectDetails(id,[OBJECT_POS]),0);
            rotation avRot = llList2Rot(llGetObjectDetails(id,[OBJECT_ROT]),0);
            // the math
            vector A = avPos - <0,1,0>*avRot;
            vector B = avPos + <0,1,0>*avRot;
            vector C = llGetPos();
            vector AB = B - A;
            vector AC = C - A;
            float diff = (B.x-A.x)*(C.y-A.y)-(B.y-A.y)*(C.x-A.x);
            // left or right
            // diff > 0 left, diff < 0 right, diff == 0 front/back
            if (diff > 0 ) llOwnerSay("I am on the left");
            if (diff < 0 ) llOwnerSay("I am on the right");
        }
    }

    Is there anyone who is able to pull me out this deep well?

  5. Thanks Wulfie!,

    The new script isnt a problem, i am not testing and trying in an existing script :-)

    I will try to calculate and understand what you wrote where the solution is! But... the rotation of the target avatar is also involved, isnt it? Looks to me that this rotation is just the issue :)

    Thanks again,

    Trivis

  6. Somehow I thought this would be easy, but I am still struggling with some rotation things (what's new lol).

    I am building a positioning HUD. This HUD needs to position me an exact distance left or right of a target-avatar. My rotation is not important (as i understood that a HUD cant rotate me after positioning). The id of the target avatar is known by using llSensor.

    The positioning of the target is, of course important.

    My question is how can I determine if I am standing somewhere left or right of my target-avatar (I can be standing in front of the or behind it), and after that positioning myself that exact distance left or right of my target?

     

    Thanks in advance for your help,

    Trivis

  7. At first it seemed not too difficult to tackle the following problem, but in the end I did not manage to do it. Rotations are the story of my (second) life :-)

    The problem: I have an object consisting of several prims. When someone touches the object i would like to point one of the childprims to the avatar who touched the object. See attached picture.

    The rotation of (only!) that childprim only need to be done around in its XY-plane, so only a rotation around its Z-axis.

    Does anyone has a working solution?

    Thanks in advance for any help.

     

    rotation question.png

  8. Thank you all for your response! Highly appriciated.

    In the most simple version it would be nice to give the gift a 'unique' number of a sequence... That is: the first recipient will get numer 1, the second numer 2, the third nr3 and so on... But it is clear to me that i have to find another way :-)

    Thanks again!

    trivis

  9. Dear scripters,

    I am looking for a way to change the object description of an item i have in the content tab of a giver object.

    The idea is that when someone touches the main object the description of the object to give away will be changed first, so i can make the gift more personalized.

    Havent found a way yet to do so. Was wondering if it is possible, and if yes, how so?

     

    Thanks in advance!

  10. Thanks Innula!

    This is how i have done it so far. Have a long negative channel based on the ownerkey and clothingobject. Works all fine. This means that the listener in the clothing is ALWAYS listening... most of the time for 'nothing'.

    So I was thinking if the clothing would not listen at first but use a timer to llRegionSayTo and let the hud listen, wouldnt that be more efficient? 

    Thanks again for your swift response, Innula.

    Trivis

  11. Dear all,

    Perhaps you have an answer to my question. 

    I have two objects. One is a clothing and the other one is a hud. The hud is for changing the texture of the clothing. So clothing would be worn "often" and the hud "sometimes".

    To make the texture-exchange as easy as possible, I have two scripting options for both objects to see eachother. One is that the clothing has a listener that is always open and reacts with llRegionSayTo. The other options is that the clothing has a timer, for let's say every 10 or 15 seconds and the hud has a listener.

    After the two object "see" eachother the exchange of information can start.

    Will there be a best option of those two options?

    Thanks in advance,

    Trivis

    • Like 1
×
×
  • Create New...