It would seem like that the variable MyMediaUrlPrim is null when the touch
event is triggered. And since the MyMediaUrlPrim is fetched from the scene
by id that is described in the RexPrimFreeData field, I would suspect that
the error is in there.

Cheers,
Mikko

On Mon, Dec 14, 2009 at 9:05 PM, Carlos <[email protected]> wrote:

> I`m using the samplemediaurl.py script with a MediaUrlChanger like
> this:
> "class MediaUrlChanger(rxactor.Actor):
>    def GetScriptClassName():
>        return "samplemediaurl.MediaUrlChanger"
>
>    def EventCreated(self):
>        super(self.__class__,self).EventCreated()
>        print "samplemediaurl.MediaUrlChanger"
>        self.MyMediaUrlPrim = None
>        self.MyMediaUrl = ""
>        self.RefreshData()
>
>    def EventTouch(self,vAvatar):
>        self.RefreshData()
>
>        if(self.MyMediaUrlPrim != None):
>           # self.MyMediaUrlPrim.SetNewMediaUrl(self.MyMediaUrl)
>           self.MyMediaUrlPrim.SetNewMediaUrl("http://www.theURL.com";)
>        else:
>            print "Target prim for mediaurl change not found"
>
>    def RefreshData(self):
>        myfreedata = self.rexGetPrimFreeData()
>        paramlistlines = myfreedata.splitlines()
>
>        templocalid = self.GetPrimLocalIdFromUUID(paramlistlines[0])
>        self.MyMediaUrlPrim = self.MyWorld.GetActorByLocalID(str
> (templocalid))
>        self.MyMediaUrl = paramlistlines[1]
> "
> The error message in the console when i run the script is:
> "HandleEvent_TouchStart exceptions.SystemError Referencia a objeto no
> establecida como instancia de un objeto. <traceback object at
> 0x038C0E57>"
> Any ideas?
> Thanks
> Carlos Lorenzo
>
> --
> http://groups.google.com/group/realxtend
> http://www.realxtend.org
>

-- 
http://groups.google.com/group/realxtend
http://www.realxtend.org

Reply via email to