From 9ed683d2ad4ae63b8af3913b8e94607be438dbbb Mon Sep 17 00:00:00 2001 From: David Markowitz Date: Sat, 6 Apr 2024 22:29:10 -0700 Subject: [PATCH] Update SlashCommandHandler.cpp --- dGame/dUtilities/SlashCommandHandler.cpp | 5 +++++ 1 file changed, 5 insertions(+) diff --git a/dGame/dUtilities/SlashCommandHandler.cpp b/dGame/dUtilities/SlashCommandHandler.cpp index c7b7b052..34ae013c 100644 --- a/dGame/dUtilities/SlashCommandHandler.cpp +++ b/dGame/dUtilities/SlashCommandHandler.cpp @@ -1977,7 +1977,12 @@ namespace DEVGMCommands { auto newEntity = Game::entityManager->CreateEntity(info); if (newEntity == nullptr) { + ChatPackets::SendSystemMessage(sysAddr, u"Failed to spawn entity."); + return; } + + Game::entityManager->ConstructEntity(newEntity); + numberToSpawn--; } }