Viewing Issue Simple Details Jump to Notes ] View Advanced ] Issue History ] Print ]
ID Category Severity Reproducibility Date Submitted Last Update
0003029 [opensim] [REGION] Scripting Engine major always 2009-01-21 14:23 2010-02-14 21:05
Reporter mohax View Status public  
Assigned To melanie
Priority normal Resolution fixed  
Status resolved   Product Version
Summary 0003029: attach(key )attached) event unrecognized
Description The basic attach() event handler is still unrecognized although attachments seem to be working.

// should at least say something like:
// [14:19] Object: Running attach event test. Should say av key.
// [14:20] Object: Attached: 7a41dd02-dac9-4d4a-a013-92ca1a65335b

default
{
    state_entry()
    {
        llSay(0, "Running attach event test. Should say av key.");
    }
    attach(key _attached)
    {
        llSay(0, "Attached: " + (string) _attached);
    }
}
Additional Information
Tags No tags attached.
Git Revision
SVN Revision 0
Run Mode Grid (Multiple Regions per Sim)
Physics Engine ODE
Environment Mono / Windows
Mono Version None
Attached Files

- Relationships
duplicate of 0002837new Script in attachment doesnt receive attach event. 

-  Notes
(0008924)
melanie (administrator)
2009-01-21 14:53

Because attachments have no persistent state in opensim, the handling is different.
(0008925)
mohax (reporter)
2009-01-21 14:55

Does this mean there are no plans to implement the attach() event as handles in Second Life currently? If so, just need to know so we can work around.
(0008926)
melanie (administrator)
2009-01-21 14:59

There are no immediate plans for compatibility. Scripts in OpenSim will have to account for the fact that script state and data is lost and scripts restart from the beginning on each attach.
(0008927)
mohax (reporter)
2009-01-21 15:01

I wonder if just an on_rez() event with more primitive llGetAttached(ATTACH_RHAND) might cover it. Will test.
(0008928)
mohax (reporter)
2009-01-21 15:11

The following work around tested successfully in ReactionGrid. Primitive, but gets the job done at least for event handling that normally would have happened when first wearing/attaching an item.

default
{
    state_entry()
    {
        llSay(0, "Work around for missing attach() event handler");
    }
    
    on_rez(integer _param)
    {
        if (llGetAttached() == ATTACH_RHAND)
        {
            llSay(0, "Attached to right hand.");
        }
    }
}
(0008953)
mohax (reporter)
2009-01-22 11:12

I can only assume the reason attach(key attached) event handling is being omitted is because the 'attached' key is part of the attachment state. Still couldn't we call the attach() handler without that property? Most just use it to indicate an attachment has been worn or removed. It seems ignoring that requirement would be unnecessary, even against the OpenSim goals of SL compatibility.
(0012521)
greg0254 (reporter)
2009-07-19 06:16

Since no one has posted any comments here since January, I thought I would throw my two cents in and say I would love to see the attach event implemented, mainly for reasons of compatibility and code portability. I am just hoping, with all of the changes and refactoring that have taken place since January, that maybe it has become more do-able. If not...well, all thing considered, we're still doing OK.
(0012522)
melanie (administrator)
2009-07-19 06:54

We need ROBUST to do it. attach() goes hand in hand with proper attachment state handling, which we can't have until we have overwritable private assets, which ROBUST provides API and functionality for.Without that, attach() makes no sense.
(0015002)
Revolution (reporter)
2010-02-14 20:25

Attach works on 2c0c21d0a5fd89120d8be47cd959acd96b286fe3.

- Issue History
Date Modified Username Field Change
2009-01-21 14:23 mohax New Issue
2009-01-21 14:23 mohax SVN Revision => 0
2009-01-21 14:23 mohax Run Mode => Grid (Multiple Regions per Sim)
2009-01-21 14:23 mohax Physics Engine => ODE
2009-01-21 14:23 mohax Environment => Mono / Windows
2009-01-21 14:23 mohax Mono Version => None
2009-01-21 14:53 melanie Note Added: 0008924
2009-01-21 14:55 mohax Note Added: 0008925
2009-01-21 14:59 melanie Note Added: 0008926
2009-01-21 15:01 mohax Note Added: 0008927
2009-01-21 15:11 mohax Note Added: 0008928
2009-01-22 11:12 mohax Note Added: 0008953
2009-01-25 13:32 idb Relationship added duplicate of 0002837
2009-03-17 09:22 BeatrixNewt Issue Monitored: BeatrixNewt
2009-07-19 06:16 greg0254 Note Added: 0012521
2009-07-19 06:54 melanie Note Added: 0012522
2010-02-14 20:25 Revolution Note Added: 0015002
2010-02-14 20:25 Revolution Status new => feedback
2010-02-14 21:05 melanie Status feedback => resolved
2010-02-14 21:05 melanie Resolution open => fixed
2010-02-14 21:05 melanie Assigned To => melanie


Mantis 1.1.1[^]
Copyright © 2000 - 2008 Mantis Group
Powered by Mantis Bugtracker