From bf8305062a4d4d117afdf06bd37e05594f3ee565 Mon Sep 17 00:00:00 2001 From: Christoph Oelckers Date: Thu, 12 Dec 2019 02:13:19 +0100 Subject: [PATCH] - do not allow summon CCMD to spawn abstract classes --- src/gamedata/info.cpp | 5 +++++ 1 file changed, 5 insertions(+) diff --git a/src/gamedata/info.cpp b/src/gamedata/info.cpp index 010200a775..dbc2410b93 100644 --- a/src/gamedata/info.cpp +++ b/src/gamedata/info.cpp @@ -707,6 +707,11 @@ static void SummonActor (int command, int command2, FCommandLine argv) Printf ("Unknown actor '%s'\n", argv[1]); return; } + if (type->bAbstract) + { + Printf("Cannot instantiate abstract class %s\n", argv[1]); + return; + } Net_WriteByte (argv.argc() > 2 ? command2 : command); Net_WriteString (type->TypeName.GetChars());