From 75487b11bb3b19d6b6c5c9727ddc7c88c2f6b3f9 Mon Sep 17 00:00:00 2001
From: Sebi <pape@vr.rwth-aachen.de>
Date: Wed, 22 Jan 2020 08:51:20 +0100
Subject: [PATCH] Fixing Nullptr dereference

---
 Source/CAVEOverlay/Private/CAVEOverlayController.cpp | 2 +-
 1 file changed, 1 insertion(+), 1 deletion(-)

diff --git a/Source/CAVEOverlay/Private/CAVEOverlayController.cpp b/Source/CAVEOverlay/Private/CAVEOverlayController.cpp
index d18b4b7..9c9662a 100644
--- a/Source/CAVEOverlay/Private/CAVEOverlayController.cpp
+++ b/Source/CAVEOverlay/Private/CAVEOverlayController.cpp
@@ -312,7 +312,7 @@ void ACAVEOverlayController::Tick(float DeltaTime)
 		}
 	}
 
-	if (!Head) return; //Display Cluster not initialized
+	if (!Head || !Cave_Origin) return; //Display Cluster not initialized
 
 	//Tape Logic
 	FVector Shutter_Position = Cave_Origin->GetComponentLocation() - Head->GetComponentLocation();
-- 
GitLab