From ee00143f3a4b3ce4f0e694bdc8e63c185690d63c Mon Sep 17 00:00:00 2001 From: Matt Date: Thu, 7 Feb 2019 18:23:58 +0100 Subject: [PATCH] Throw assert only in debug builds for missing game actions. --- src/openrct2/actions/GameAction.cpp | 2 ++ 1 file changed, 2 insertions(+) diff --git a/src/openrct2/actions/GameAction.cpp b/src/openrct2/actions/GameAction.cpp index 3d523e06f9..efcdfd207b 100644 --- a/src/openrct2/actions/GameAction.cpp +++ b/src/openrct2/actions/GameAction.cpp @@ -90,7 +90,9 @@ namespace GameActions result = factory(); } } +#ifdef _DEBUG Guard::ArgumentNotNull(result, "Attempting to create unregistered gameaction: %u", id); +#endif return std::unique_ptr(result); }