What could this runtime error mean?

classic Classic list List threaded Threaded
16 messages Options
Reply | Threaded
Open this post in threaded view
|

What could this runtime error mean?

Dr Ramesh Ramloll
Hello there,
I was hoping someone could let me know what the following error could mean. 
(0): Object reference not set to an instance of an object
Thanks
Ramesh
--
'Consider how the lilies grow. They do not labor or spin.'
Rameshsharma Ramloll PhD, CEO CTO DeepSemaphore LLC, Affiliate Research Associate Professor, Idaho State University, Pocatello, ID 83209 Tel: 208-240-0040

_______________________________________________
Opensim-users mailing list
[hidden email]
https://lists.berlios.de/mailman/listinfo/opensim-users
Reply | Threaded
Open this post in threaded view
|

Re: What could this runtime error mean?

Chris M
From my understanding "Object reference not set to an instance of an object" generally means that somewhere in the coding a null object is attempting to be used; that is, an object that has nothing in it to work with.  This can be caused by any number of situations; as such it would be difficult to say what caused it just from that one line. (Anyone who knows more about this please feel free to correct me if I'm not accurate on this; I have some knowledge in C# programming but it is limited :) )

Could you tell us what you were doing or what was happening when this error popped up?

On 1/27/2014 3:55 PM, Dr Ramesh Ramloll wrote:
Hello there,
I was hoping someone could let me know what the following error could mean. 
(0): Object reference not set to an instance of an object
Thanks
Ramesh
--
'Consider how the lilies grow. They do not labor or spin.'
Rameshsharma Ramloll PhD, CEO CTO DeepSemaphore LLC, Affiliate Research Associate Professor, Idaho State University, Pocatello, ID 83209 Tel: 208-240-0040


_______________________________________________
Opensim-users mailing list
[hidden email]
https://lists.berlios.de/mailman/listinfo/opensim-users


-- 
OpenSim: 10 Region Standalone on 0.7.6 Dev
Physics: Open Dynamics Engine
OS: Windows 7 (x64)
CPU: AMD Phenom II X4 840 3.2 GHz
Memory: 11 GB DDR3
Database: MySQL 5.1.63 (x64)

_______________________________________________
Opensim-users mailing list
[hidden email]
https://lists.berlios.de/mailman/listinfo/opensim-users
Reply | Threaded
Open this post in threaded view
|

Re: What could this runtime error mean?

Jeff Kelley
In reply to this post by Dr Ramesh Ramloll
At 4:55 PM -0500 27/1/14, Dr Ramesh Ramloll wrote:

>  (0): Object reference not set to an instance of an object

This is an error in object-oriented programming and is equivalent to
"variable not defined" in classic programming.

object x;
shake.x; cannot shake x because x not defined


-- Jeff
_______________________________________________
Opensim-users mailing list
[hidden email]
https://lists.berlios.de/mailman/listinfo/opensim-users
Reply | Threaded
Open this post in threaded view
|

Re: What could this runtime error mean?

Dr Ramesh Ramloll
In reply to this post by Dr Ramesh Ramloll
Hello,
so far this is what am thinking,
It is actually triggered when  an lsl script is running (but not always strangely). I am thinking that if the script is compiling fine, then at least at the script level all the variables should be defined properly.
I will keep playing a little more with it and see what may be going on. If you have more ideas let me know.
Ramesh


On Mon, Jan 27, 2014 at 5:41 PM, Jeff Kelley <[hidden email]> wrote:
At 4:55 PM -0500 27/1/14, Dr Ramesh Ramloll wrote:

 (0): Object reference not set to an instance of an object

This is an error in object-oriented programming and is equivalent to "variable not defined" in classic programming.

object x;
shake.x; cannot shake x because x not defined


-- Jeff

_______________________________________________
Opensim-users mailing list
[hidden email]
https://lists.berlios.de/mailman/listinfo/opensim-users



--
'Consider how the lilies grow. They do not labor or spin.'
Rameshsharma Ramloll PhD, CEO CTO DeepSemaphore LLC, Affiliate Research Associate Professor, Idaho State University, Pocatello, ID 83209 Tel: 208-240-0040

_______________________________________________
Opensim-users mailing list
[hidden email]
https://lists.berlios.de/mailman/listinfo/opensim-users
Reply | Threaded
Open this post in threaded view
|

Re: What could this runtime error mean?

Jeff Kelley
At 6:13 PM -0500 27/1/14, Dr Ramesh Ramloll wrote:

>It is actually triggered when  an lsl script is running (but not
>always strangely).
>I am thinking that if the script is compiling fine, then at least at
>the script level
>all the variables should be defined properly.


This is correct. LSL is static and has no objects. The error comes
from the simulator, maybe triggered by your script. Are you trying to
target something by uuid?


-- Jeff
_______________________________________________
Opensim-users mailing list
[hidden email]
https://lists.berlios.de/mailman/listinfo/opensim-users
Reply | Threaded
Open this post in threaded view
|

Re: What could this runtime error mean?

Dahlia Trimble
In reply to this post by Dr Ramesh Ramloll
It's an attempt to use a null reference and it can happen in many places in the code base. Usually it's a good idea to make sure a reference is valid before using it but this doesn't always happen. especially in open source projects with many contributors. There should be more information printed along with that message which could help indicate where it came from.


On Mon, Jan 27, 2014 at 3:13 PM, Dr Ramesh Ramloll <[hidden email]> wrote:
Hello,
so far this is what am thinking,
It is actually triggered when  an lsl script is running (but not always strangely). I am thinking that if the script is compiling fine, then at least at the script level all the variables should be defined properly.
I will keep playing a little more with it and see what may be going on. If you have more ideas let me know.
Ramesh


On Mon, Jan 27, 2014 at 5:41 PM, Jeff Kelley <[hidden email]> wrote:
At 4:55 PM -0500 27/1/14, Dr Ramesh Ramloll wrote:

 (0): Object reference not set to an instance of an object

This is an error in object-oriented programming and is equivalent to "variable not defined" in classic programming.

object x;
shake.x; cannot shake x because x not defined


-- Jeff

_______________________________________________
Opensim-users mailing list
[hidden email]
https://lists.berlios.de/mailman/listinfo/opensim-users



--
'Consider how the lilies grow. They do not labor or spin.'
Rameshsharma Ramloll PhD, CEO CTO DeepSemaphore LLC, Affiliate Research Associate Professor, Idaho State University, Pocatello, ID 83209 Tel: <a href="tel:208-240-0040" value="+12082400040" target="_blank">208-240-0040

_______________________________________________
Opensim-users mailing list
[hidden email]
https://lists.berlios.de/mailman/listinfo/opensim-users


_______________________________________________
Opensim-users mailing list
[hidden email]
https://lists.berlios.de/mailman/listinfo/opensim-users
Reply | Threaded
Open this post in threaded view
|

Re: What could this runtime error mean?

Dr Ramesh Ramloll
In reply to this post by Dr Ramesh Ramloll

On Mon, Jan 27, 2014 at 6:25 PM, Jeff Kelley <[hidden email]> wrote:
Are you trying to target something by uuid?

Yes indeed Jeff, I select NPCs by clicking on them and click objects to make each NPC do stuff with the objects.
R


--
'Consider how the lilies grow. They do not labor or spin.'
Rameshsharma Ramloll PhD, CEO CTO DeepSemaphore LLC, Affiliate Research Associate Professor, Idaho State University, Pocatello, ID 83209 Tel: 208-240-0040

_______________________________________________
Opensim-users mailing list
[hidden email]
https://lists.berlios.de/mailman/listinfo/opensim-users
Reply | Threaded
Open this post in threaded view
|

Re: What could this runtime error mean?

Dr Ramesh Ramloll
Ok, I found a way to block the error from happening at the script level. In short, isolated the case where it happens, and made sure that it does not arise. But I have no clue about underlying issues. BUT :( now I have to update a LOT of objects with new code. Lately I have been finding it hard to update the same script in N objects, and N is growing exponentially. The time it is taking to update an application is already taking days, and the task is pretty boring, go thru each and every object, update, re-compile manually. This is the hardest scalability problem for opensim. This issue has been raised earlier and it seems there is no solution. 


On Mon, Jan 27, 2014 at 6:59 PM, Dr Ramesh Ramloll <[hidden email]> wrote:

On Mon, Jan 27, 2014 at 6:25 PM, Jeff Kelley <[hidden email]> wrote:
Are you trying to target something by uuid?

Yes indeed Jeff, I select NPCs by clicking on them and click objects to make each NPC do stuff with the objects.
R


--
'Consider how the lilies grow. They do not labor or spin.'
Rameshsharma Ramloll PhD, CEO CTO DeepSemaphore LLC, Affiliate Research Associate Professor, Idaho State University, Pocatello, ID 83209 Tel: <a href="tel:208-240-0040" value="+12082400040" target="_blank">208-240-0040



--
'Consider how the lilies grow. They do not labor or spin.'
Rameshsharma Ramloll PhD, CEO CTO DeepSemaphore LLC, Affiliate Research Associate Professor, Idaho State University, Pocatello, ID 83209 Tel: 208-240-0040

_______________________________________________
Opensim-users mailing list
[hidden email]
https://lists.berlios.de/mailman/listinfo/opensim-users
Reply | Threaded
Open this post in threaded view
|

Re: What could this runtime error mean?

Jeff Kelley
At 7:33 PM -0500 27/1/14, Dr Ramesh Ramloll wrote:

>  Lately I have been finding it hard to update the same script in N objects,
>  and N is growing exponentially.

If the objects lies in the same region, use llRemoteLoadScriptPin.

You should "bless" each object before with llSetRemoteScriptAccessPin.

Your updater has to discover every objects, you have three choices:

llSensor and variants (moving sensor, panoramic sensor)

llCastRay

Network the objects : poll them with a llRegionSay("ping"), have a
listen handler which echoes back, this way you collect all their
UUIDs.

Set  ScriptDelayFactor to 0 if you can. You will turbo-load your scripts.



-- Jeff
_______________________________________________
Opensim-users mailing list
[hidden email]
https://lists.berlios.de/mailman/listinfo/opensim-users
Reply | Threaded
Open this post in threaded view
|

Re: What could this runtime error mean?

Dr Ramesh Ramloll
In reply to this post by Dr Ramesh Ramloll
ultimately I will have to try that. Thanks.
R


On Mon, Jan 27, 2014 at 8:00 PM, Jeff Kelley <[hidden email]> wrote:
At 7:33 PM -0500 27/1/14, Dr Ramesh Ramloll wrote:

 Lately I have been finding it hard to update the same script in N objects,
 and N is growing exponentially.

If the objects lies in the same region, use llRemoteLoadScriptPin.

You should "bless" each object before with llSetRemoteScriptAccessPin.

Your updater has to discover every objects, you have three choices:

llSensor and variants (moving sensor, panoramic sensor)

llCastRay

Network the objects : poll them with a llRegionSay("ping"), have a listen handler which echoes back, this way you collect all their UUIDs.

Set  ScriptDelayFactor to 0 if you can. You will turbo-load your scripts.




-- Jeff
_______________________________________________
Opensim-users mailing list
[hidden email]
https://lists.berlios.de/mailman/listinfo/opensim-users



--
'Consider how the lilies grow. They do not labor or spin.'
Rameshsharma Ramloll PhD, CEO CTO DeepSemaphore LLC, Affiliate Research Associate Professor, Idaho State University, Pocatello, ID 83209 Tel: 208-240-0040

_______________________________________________
Opensim-users mailing list
[hidden email]
https://lists.berlios.de/mailman/listinfo/opensim-users
Reply | Threaded
Open this post in threaded view
|

Re: What could this runtime error mean?

DZ-2
In reply to this post by Dr Ramesh Ramloll


On Mon, Jan 27, 2014 at 6:25 PM, Jeff Kelley <[hidden email]> wrote:

> Are you trying to target something by uuid?


Yes indeed Jeff, I select NPCs by clicking on them and click objects to
make each NPC do stuff with the objects.
R


I most often encounter that error when I am processing through a list of NPCs and one of them has gone "awol"  ( gotten stuck)  or has been logged out prior to the command being sent.   I haven't been able to document cases where asking for a list of agents in the sim has included inactive/no longer functional NPC's,  but that seems to be the case when I see those errors... If I dig around  I usually find the NPC struggling to walk out the corner of the sim. Some of them I can only kill them by restarting the sim. 

d

_______________________________________________
Opensim-users mailing list
[hidden email]
https://lists.berlios.de/mailman/listinfo/opensim-users
Reply | Threaded
Open this post in threaded view
|

Re: What could this runtime error mean?

Dahlia Trimble
If you see "Object not set to an instance of an object" in your viewer anywhere while scripting or from the use of a script, it's a bug and should be reported on http://opensimulator.org/mantis



On Mon, Jan 27, 2014 at 8:22 PM, dz <[hidden email]> wrote:


On Mon, Jan 27, 2014 at 6:25 PM, Jeff Kelley <[hidden email]> wrote:

> Are you trying to target something by uuid?


Yes indeed Jeff, I select NPCs by clicking on them and click objects to
make each NPC do stuff with the objects.
R


I most often encounter that error when I am processing through a list of NPCs and one of them has gone "awol"  ( gotten stuck)  or has been logged out prior to the command being sent.   I haven't been able to document cases where asking for a list of agents in the sim has included inactive/no longer functional NPC's,  but that seems to be the case when I see those errors... If I dig around  I usually find the NPC struggling to walk out the corner of the sim. Some of them I can only kill them by restarting the sim. 

d

_______________________________________________
Opensim-users mailing list
[hidden email]
https://lists.berlios.de/mailman/listinfo/opensim-users


_______________________________________________
Opensim-users mailing list
[hidden email]
https://lists.berlios.de/mailman/listinfo/opensim-users
Reply | Threaded
Open this post in threaded view
|

NPC crowds (Was: What could this runtime error mean?)

Jeff Kelley
In reply to this post by Dr Ramesh Ramloll
At 6:59 PM -0500 27/1/14, Dr Ramesh Ramloll wrote:

>  Yes indeed Jeff, I select NPCs by clicking on them and click objects
>  to make each NPC do stuff with the objects.

I've seen your videos and was amazed by your NPC crowds.

Just a question about that : do you dress an avatar to create each template?

I've looked into automatic crowd generation. Unfortunately I
discovered baked textures in the appearance notecard. Baked textures
do not exist before the avatar has been rezed so this is a
chicken-and-egg situation : the notecard cant' be written before the
avatar exists; we need the notecard for the avatar to exist.


-- Jeff
_______________________________________________
Opensim-users mailing list
[hidden email]
https://lists.berlios.de/mailman/listinfo/opensim-users
Reply | Threaded
Open this post in threaded view
|

Re: NPC crowds (Was: What could this runtime error mean?)

Dr Ramesh Ramloll
In reply to this post by Dr Ramesh Ramloll
Hi Jeff
Yes, I create the avatar manually (the usual way on my own avatar) then create the notecard and then create copies of the manually created avatar as NPCs from the notecard in code.
R


On Tue, Jan 28, 2014 at 4:57 AM, Jeff Kelley <[hidden email]> wrote:
At 6:59 PM -0500 27/1/14, Dr Ramesh Ramloll wrote:

 Yes indeed Jeff, I select NPCs by clicking on them and click objects
 to make each NPC do stuff with the objects.

I've seen your videos and was amazed by your NPC crowds.

Just a question about that : do you dress an avatar to create each template?

I've looked into automatic crowd generation. Unfortunately I discovered baked textures in the appearance notecard. Baked textures do not exist before the avatar has been rezed so this is a chicken-and-egg situation : the notecard cant' be written before the avatar exists; we need the notecard for the avatar to exist.


-- Jeff
_______________________________________________
Opensim-users mailing list
[hidden email]
https://lists.berlios.de/mailman/listinfo/opensim-users



--
'Consider how the lilies grow. They do not labor or spin.'
Rameshsharma Ramloll PhD, CEO CTO DeepSemaphore LLC, Affiliate Research Associate Professor, Idaho State University, Pocatello, ID 83209 Tel: 208-240-0040

_______________________________________________
Opensim-users mailing list
[hidden email]
https://lists.berlios.de/mailman/listinfo/opensim-users
Reply | Threaded
Open this post in threaded view
|

Re: NPC crowds (Was: What could this runtime error mean?)

drwhiet@spacefriends.de
Just out of curiosity . why don't you just create the avatar appearance notcard and copy this notecard to the to created npc and read it? So you can have an inventory folder full of different avatar appearances ? 


Best regards
Wordfromthe Wise 

Am 28.01.2014 um 13:28 schrieb Dr Ramesh Ramloll <[hidden email]>:

Hi Jeff
Yes, I create the avatar manually (the usual way on my own avatar) then create the notecard and then create copies of the manually created avatar as NPCs from the notecard in code.
R


On Tue, Jan 28, 2014 at 4:57 AM, Jeff Kelley <[hidden email]> wrote:
At 6:59 PM -0500 27/1/14, Dr Ramesh Ramloll wrote:

 Yes indeed Jeff, I select NPCs by clicking on them and click objects
 to make each NPC do stuff with the objects.

I've seen your videos and was amazed by your NPC crowds.

Just a question about that : do you dress an avatar to create each template?

I've looked into automatic crowd generation. Unfortunately I discovered baked textures in the appearance notecard. Baked textures do not exist before the avatar has been rezed so this is a chicken-and-egg situation : the notecard cant' be written before the avatar exists; we need the notecard for the avatar to exist.


-- Jeff
_______________________________________________
Opensim-users mailing list
[hidden email]
https://lists.berlios.de/mailman/listinfo/opensim-users



--
'Consider how the lilies grow. They do not labor or spin.'
Rameshsharma Ramloll PhD, CEO CTO DeepSemaphore LLC, Affiliate Research Associate Professor, Idaho State University, Pocatello, ID 83209 Tel: 208-240-0040
_______________________________________________
Opensim-users mailing list
[hidden email]
https://lists.berlios.de/mailman/listinfo/opensim-users

_______________________________________________
Opensim-users mailing list
[hidden email]
https://lists.berlios.de/mailman/listinfo/opensim-users
Reply | Threaded
Open this post in threaded view
|

Re: NPC crowds (Was: What could this runtime error mean?)

Dr Ramesh Ramloll
Hi Spacefriends,
Yes you are right. The appearance is captured in a notecard, then a given npc read from the notecard.


On Tue, Jan 28, 2014 at 11:30 AM, Spacefriends <[hidden email]> wrote:
Just out of curiosity . why don't you just create the avatar appearance notcard and copy this notecard to the to created npc and read it? So you can have an inventory folder full of different avatar appearances ? 


Best regards
Wordfromthe Wise 

Am 28.01.2014 um 13:28 schrieb Dr Ramesh Ramloll <[hidden email]>:

Hi Jeff
Yes, I create the avatar manually (the usual way on my own avatar) then create the notecard and then create copies of the manually created avatar as NPCs from the notecard in code.
R


On Tue, Jan 28, 2014 at 4:57 AM, Jeff Kelley <[hidden email]> wrote:
At 6:59 PM -0500 27/1/14, Dr Ramesh Ramloll wrote:

 Yes indeed Jeff, I select NPCs by clicking on them and click objects
 to make each NPC do stuff with the objects.

I've seen your videos and was amazed by your NPC crowds.

Just a question about that : do you dress an avatar to create each template?

I've looked into automatic crowd generation. Unfortunately I discovered baked textures in the appearance notecard. Baked textures do not exist before the avatar has been rezed so this is a chicken-and-egg situation : the notecard cant' be written before the avatar exists; we need the notecard for the avatar to exist.


-- Jeff
_______________________________________________
Opensim-users mailing list
[hidden email]
https://lists.berlios.de/mailman/listinfo/opensim-users



--
'Consider how the lilies grow. They do not labor or spin.'
Rameshsharma Ramloll PhD, CEO CTO DeepSemaphore LLC, Affiliate Research Associate Professor, Idaho State University, Pocatello, ID 83209 Tel: <a href="tel:208-240-0040" value="+12082400040" target="_blank">208-240-0040
_______________________________________________
Opensim-users mailing list
[hidden email]
https://lists.berlios.de/mailman/listinfo/opensim-users

_______________________________________________
Opensim-users mailing list
[hidden email]
https://lists.berlios.de/mailman/listinfo/opensim-users



--
'Consider how the lilies grow. They do not labor or spin.'
Rameshsharma Ramloll PhD, CEO CTO DeepSemaphore LLC, Affiliate Research Associate Professor, Idaho State University, Pocatello, ID 83209 Tel: 208-240-0040

_______________________________________________
Opensim-users mailing list
[hidden email]
https://lists.berlios.de/mailman/listinfo/opensim-users