Wandering Inviter

We thought to bring something more to the classic inviter systems and one thought was to expand on the 64m scanning range that llSensorRepeat is limited to. We created a wandering group inviter based on wanderer that is able to travel across long distances, be aesthetically pleasing and also offer a greatly extended range of scanning.

Zeppelin Assembly

Roaming primitive using an abbreviated version of [[secondlife:wanderer]].

For the Zeppelin assembly it is important to surround the build with a sphere and point its forward z axis in the perceptive direction of movement. Both roaming and a group inviter script are placed in the yellow surrounding invisible sphere that represents the root primitive for the entire build.

Script Modifications

The script below makes a nice addition to the group inviters] scripts. You can place the following script in the same primitive as the group inviters scripts in order to make the inviter primitive wander about the area and ensure a coverage larger than 64 meters.

_iPos in the script below is considered the origin point - it will have to be changed with the simulators local coordinates. The Corrade primitive will roam in a range of 20m with _iPos being the point of origin. The script can be modified by changing the segment:

wasCirclePoint(20)

where 20 represents a value of meters to roam from the _iPos origin point. For further information on the wandering algorithm, please see the Second Life wanderer page.

Code

corrade_roaming.lsl
///////////////////////////////////////////////////////////////////////////
//  Copyright (C) Wizardry and Steamworks 2011 - License: CC BY 2.0      //
//  Please see: https://creativecommons.org/licenses/by/2.0 for legal details,  //
//  rights of fair usage, the disclaimer and warranty conditions.        //
///////////////////////////////////////////////////////////////////////////
 
vector _iPos = ZERO_VECTOR;
integer _targetID = 0;
 
vector wasCirclePoint(float radius) {
    float x = llPow(-1, 1 + (integer) llFrand(2)) * llFrand(radius*2);
    float y = llPow(-1, 1 + (integer) llFrand(2)) * llFrand(radius*2);
    if(llPow(x,2) + llPow(y,2) <= llPow(radius,2))
        return _iPos + <x, y, llFrand(1)>;
    return wasCirclePoint(radius);
}
 
moveTo(vector position) {
    llTargetRemove(_targetID);
    _targetID = llTarget(position, .8);
    llLookAt(position, .6, .6);
    llMoveToTarget(position, 3);    
}
 
// Begin script.
default
{
    state_entry() {
        _iPos = llGetPos();
        llSetStatus(STATUS_PHYSICS|STATUS_BLOCK_GRAB, TRUE);
        llVolumeDetect(TRUE);
        llSetForce(<0,0,9.81> * llGetMass(), 0);
        moveTo(wasCirclePoint(20));
    }
 
    at_target(integer tnum, vector targetpos, vector ourpos) {
        if(tnum != _targetID) return;
        moveTo(wasCirclePoint(20));
    }
}
// End script.

Index


secondlife/scripted_agents/corrade/projects/in_world/group_inviters/roaming_inviter.txt ยท Last modified: 2022/11/24 07:45 by 127.0.0.1

Access website using Tor Access website using i2p Wizardry and Steamworks PGP Key


For the contact, copyright, license, warranty and privacy terms for the usage of this website please see the contact, license, privacy, copyright.