NullReferenceException at OnEntityMountedError
[4/12/2020 4:03:38 PM] Failed to call hook 'OnEntityMounted' on plugin 'NeedForSpeed v1.0.4' (NullReferenceException: Object reference not set to an instance of an object)
  at Oxide.Plugins.NeedForSpeed.OnEntityMounted (BaseMountable entity, BasePlayer player) [0x00055] in <3c1640a5b56f4e80b75aae3fa3079bcf>:0 
  at Oxide.Plugins.NeedForSpeed.DirectCallHook (System.String name, System.Object& ret, System.Object[] args) [0x0007c] in <3c1640a5b56f4e80b75aae3fa3079bcf>:0 
  at Oxide.Plugins.CSharpPlugin.InvokeMethod (Oxide.Core.Plugins.HookMethod method, System.Object[] args) [0x00079] in <008b12f41ec4452da1a5497eeb849299>:0 
  at Oxide.Core.Plugins.CSPlugin.OnCallHook (System.String name, System.Object[] args) [0x000d8] in <ac41dd3599754d448b8c218b34645820>:0 
  at Oxide.Core.Plugins.Plugin.CallHook (System.String hook, System.Object[] args) [0x00060] in <ac41dd3599754d448b8c218b34645820>:0 

We also use this plugin and have run into this. We observe this happens when a player sits in a non-vehicle seat:

                        PluginSettings data = pair.Value;
                        var vehicle = player.GetMountedVehicle();
                        BasePlayer driver = vehicle.GetDriver();
                        if (driver == null) return;
                        if (vehicle == null) return;

This code right here is the culprit. Notice how it performs a null check after it's been referenced in the definition of the driver variable. Simply moving the vehicle null check before referencing it solves the issue:

                        PluginSettings data = pair.Value;
                        var vehicle = player.GetMountedVehicle();
                        if (vehicle == null) return;
                        BasePlayer driver = vehicle.GetDriver();
                        if (driver == null) return;

or even more succinctly:

                        PluginSettings data = pair.Value;
                        var vehicle = player.GetMountedVehicle();
                        BasePlayer driver = vehicle?.GetDriver();
                        if (driver == null) return;​