Added some null checks. The only problem remains is that nasty IndexOutOfBoundsException. For some reason old minecart isn't deleted from loadedEntityList when marked dead. Need to dig into this a bit.