help with error NullReferenceException: Object reference not set to an instance of an object

so I keep getting this error as soon as I join onto my mp game as the second player, but I don’t get this till the second player joins. any helps welcome. thanks

NullReferenceException: Object reference not set to an instance of an object →
ShipPlayerEnterExit.OnGUI ()

my script:

using UnityEngine;
using System.Collections;

//created by: Wender 16/09/2016
//script created for player can enter e exit controlling the ship and deactivating the player
//Setup the public Variables!
[RequireComponent(typeof(ShipController))]
public class ShipPlayerEnterExit : MonoBehaviour
{
    

    Transform thisVehicle;  //This Vehicle Information
    ShipController myHoverMotor; //Motor Script, this will be whatever your vehicle uses
    //HoverAudio myHoverAudio; //Motor Audio Script, this will be whatever your vehicle uses


    [HideInInspector]
    public Camera vehicleCamera; //Camera for this vehicle
    


    [Header("Set here a Gameobject with a collider to detection")]
    public Collider positionToEnterExitBoat;
    PlayerEnterExitPosition detection;
    [Tooltip("Draw press Z to enter exit the boat.")]
    public bool drawGUI = true;
    //This is the Player information
    GameObject myPlayer;//UFPS Player game object
    vp_FPController myController;//UFPS Player controller
    vp_FPInput myInput;//UFPS Player Input

    [Header("player position inside boat")]
    public Transform playerPositionInsideBoat;
    
    //State of this vehicle, if we are in the vehicle or not
    bool InThisVehicle = false;
    bool IsDetectingPlayerNearby = false;
    void Awake()
    {
       
    }
    void Start()
    {
        //Set references to everything
        thisVehicle = this.GetComponent<Transform>();
        detection = positionToEnterExitBoat.gameObject.AddComponent<PlayerEnterExitPosition>();
        detection.shipPlayerEnter = this;
        vehicleCamera = thisVehicle.GetComponentInChildren<Camera>(true);

        myHoverMotor = thisVehicle.GetComponent<ShipController>();
        //myHoverAudio = thisVehicle.GetComponent<HoverAudio>();


        //turn off Vehicle scripts and camera on start
        //myHoverAudio.enabled = false;
        myHoverMotor.enabled = false;
        vehicleCamera.gameObject.SetActive(false);
    

    }
   
    //Exit vehicle keyboard input.  In fixed update so it doesn't move at computer speed
    void Update()
    {
   
        if (InThisVehicle)
        {
            //Change the Input to whatever you want to use
            if (Input.GetKeyDown(KeyCode.Z))
            {
                ExitVehicle();
            }
        }
        else
        {
            if(IsDetectingPlayerNearby)
            {
                if (Input.GetKeyDown(KeyCode.Z))
                {
                    EnterVehicle();
                }
            }
        }


    }
    void OnGUI()
    {

        if(drawGUI){
            if(IsDetectingPlayerNearby && !InThisVehicle && myPlayer.GetComponent<CharacterController>().enabled && myPlayer.activeSelf)
                GUI.Label(new Rect(Screen.width / 2 - 90, Screen.height / 2 - 15, 180, 30), "Press 'Z' to Enter Boat");
            else if (InThisVehicle)
            {
                GUI.Label(new Rect(Screen.width / 2 - 90, Screen.height / 2 - 15, 180, 30), "Press 'Z' to Exit Boat");
            }
                
        }
    }
    public void ExitVehicle()
    {

       // myPlayer.SetActive(true);//turn on the player
        var playerComponents = myPlayer.GetComponents<MonoBehaviour>();
        foreach (var comp in playerComponents)
            comp.enabled= true;
        myPlayer.GetComponent<CharacterController>().enabled = true;
        myPlayer.transform.SetParent(null);
        myPlayer.transform.FindChild("FPSCamera").gameObject.SetActive(true);
        myController.SetPosition(positionToEnterExitBoat.transform.position);//move the player
        myInput.enabled = true;//enable the player's input
        myHoverMotor.enabled = false;//turn off vehicle stuff
        //myHoverAudio.enabled = false;//turn off vehicle stuff
        vehicleCamera.gameObject.SetActive(false);//turn off vehicle stuff
        InThisVehicle = false;//We aren't in the vehicle anymore

    }
    public void EnterVehicle()
    {
        FindObjectOfType<Config>().playerShip = thisVehicle.gameObject;
       // myPlayer.SetActive(false);//turn off the player
        myPlayer.transform.SetParent(thisVehicle);
        
        myPlayer.transform.position = playerPositionInsideBoat.position;
        var playerComponents = myPlayer.GetComponents<MonoBehaviour>();
        foreach (var comp in playerComponents)
            comp.enabled = false;
        myPlayer.GetComponent<CharacterController>().enabled = false;
        myPlayer.transform.FindChild("FPSCamera").gameObject.SetActive(false);
        myHoverMotor.enabled = true;//turn on vehicle stuff
        //myHoverAudio.enabled = true;//turn on vehicle stuff
        vehicleCamera.gameObject.SetActive(true);//turn on vehicle stuff
        InThisVehicle = true;//We are in the vehicle now

    }

    //Make sure your trigger collider is big enough for the player to interact
    //Also, make sure the Exit position is outside the trigger area
    public void playerDetected(Collider other)
    {
        //if a player enters trigger and the player isn't already in the vehicle
        //just in case there are multiple players
        if (InThisVehicle == false)
        {
            IsDetectingPlayerNearby = true;

            myPlayer = other.gameObject;//Get the player
            myController = myPlayer.GetComponent<vp_FPController>();//Get the controller
            myInput = myPlayer.GetComponent<vp_FPInput>();//Get the input
        }
    }

    public void playerUnDetected()
    {
        if ( InThisVehicle == false)
        {
            IsDetectingPlayerNearby = false;
        }
    }
}
[RequireComponent(typeof(Collider))]
public class PlayerEnterExitPosition : MonoBehaviour
{
    public ShipPlayerEnterExit shipPlayerEnter;

    void Start() { this.GetComponent<Collider>().isTrigger = true; }
    void OnTriggerEnter(Collider other)
    {
        //if a player enters trigger and the player isn't already in the vehicle
        //just in case there are multiple players
        if (other.gameObject.tag == "Player")
        {
            shipPlayerEnter.playerDetected(other);



        }
    }

    void OnTriggerExit(Collider other)
    {
        if (other.gameObject.tag == "Player")
        {
            shipPlayerEnter.playerUnDetected();
        }
    }
 }

Check this out, it explains a NullReferenceException in detail.