Jump to content

NullReferenceException upon load

Pending 2.3.0

Terceran
Terceran

Posted

Failed to call hook 'OnServerInitialized' on plugin 'BetterNpc v2.3.0' (NullReferenceException: Object reference not set to an instance of an object)
  at Oxide.Plugins.BetterNpc.OnServerInitialized () [0x000a4] in <2234d34bde7b4e3eb68ad0c8771678f4>:0 
  at Oxide.Plugins.BetterNpc.DirectCallHook (System.String name, System.Object& ret, System.Object[] args) [0x001fa] in <2234d34bde7b4e3eb68ad0c8771678f4>:0 
  at Oxide.Plugins.CSharpPlugin.InvokeMethod (Oxide.Core.Plugins.HookMethod method, System.Object[] args) [0x00079] in <42f9bedc659b4f4786eb778d3cd58968>:0 
  at Oxide.Core.Plugins.CSPlugin.OnCallHook (System.String name, System.Object[] args) [0x000de] in <15f61ddda771464d8246ebdce8ff4811>:0 
  at Oxide.Core.Plugins.Plugin.CallHook (System.String hook, System.Object[] args) [0x00060] in <15f61ddda771464d8246ebdce8ff4811>:0 

aimacak

Posted (edited)

1 hour ago, Terceran said:

Failed to call hook 'OnServerInitialized' on plugin 'BetterNpc v2.3.0' (NullReferenceException: Object reference not set to an instance of an object)
  at Oxide.Plugins.BetterNpc.OnServerInitialized () [0x000a4] in <2234d34bde7b4e3eb68ad0c8771678f4>:0 
  at Oxide.Plugins.BetterNpc.DirectCallHook (System.String name, System.Object& ret, System.Object[] args) [0x001fa] in <2234d34bde7b4e3eb68ad0c8771678f4>:0 
  at Oxide.Plugins.CSharpPlugin.InvokeMethod (Oxide.Core.Plugins.HookMethod method, System.Object[] args) [0x00079] in <42f9bedc659b4f4786eb778d3cd58968>:0 
  at Oxide.Core.Plugins.CSPlugin.OnCallHook (System.String name, System.Object[] args) [0x000de] in <15f61ddda771464d8246ebdce8ff4811>:0 
  at Oxide.Core.Plugins.Plugin.CallHook (System.String hook, System.Object[] args) [0x00060] in <15f61ddda771464d8246ebdce8ff4811>:0 

Hello, does the error occur every time the plugin is reloaded, or was it only once during the update? If it occurs every time the plugin is reloaded, please provide the exact sequence of actions, because I can’t reproduce it 😞
oxide or carbon?
procedural or custom map?

Edited by aimacak
Terceran

Posted

Oxide, procedural map. It did it when I updated versions, but I noticed it's not doing it now when I reload. 

aimacak

Posted

4 minutes ago, Terceran said:

Oxide, procedural map. It did it when I updated versions, but I noticed it's not doing it now when I reload. 

Then I’ll assume it’s related to updating the plugin on the fly; I think few people manually unload the previous version before loading the new one, right? 🙂

Terceran

Posted

It happened on both of my servers, and I didn't manually unload. It overwrote the .cs file and it auto-loaded and threw the exception in both cases.

aimacak

Posted

Actually, I’m doing the same thing, and I think this is the cause of this error, since there are no errors on a second reboot, and everything works fine for people when they restart the server. Why did this error occur specifically with this update? Probably because some new relationships between plugins appeared in the OnServerInitialized method.

Terceran

Posted

Yes, I know the navmesh stuff just changed heavily, so anything is possible. It seems to be a temporary error and has no known lasting effects, so I'm fine with leaving it be. I'll let you know if I ever see it again.

  • Like 1

About Us

Codefling is the largest marketplace for plugins, maps, tools, and more, making it easy for customers to discover new content and for creators to monetize their work.

Downloads
3.1m
Total downloads
Customers
12.1k
Customers served
Files Sold
171.5k
Total sales
Payments
3.7m
Processed total
×
×
  • Create New...

Important Information

We have placed cookies on your device to help make this website better. You can adjust your cookie settings, otherwise we'll assume you're okay to continue.