Skip to content

HTTPS clone URL

Subversion checkout URL

You can clone with
or
.
Download ZIP
Browse files

Fix crash when placing transporters on the map in a map editor. Close…

…s ticket:3714
  • Loading branch information...
commit 508f26a174fd356b778419dd7c4eeaacfd27d8ac 1 parent d37f527
@perim perim authored
Showing with 11 additions and 1 deletion.
  1. +11 −1 src/game.cpp
View
12 src/game.cpp
@@ -4284,7 +4284,17 @@ static bool loadSaveDroid(const char *pFileName, DROID **ppsCurrentDroidLists)
}
else
{
- psDroid->psGroup = NULL;
+ if (psDroid->droidType == DROID_TRANSPORTER
+ || psDroid->droidType == DROID_SUPERTRANSPORTER
+ || psDroid->droidType == DROID_COMMAND)
+ {
+ DROID_GROUP *psGroup = grpCreate();
+ psGroup->add(psDroid);
+ }
+ else
+ {
+ psDroid->psGroup = NULL;
+ }
}
psDroid->died = ini.value("died", 0).toInt();
psDroid->lastEmission = ini.value("lastEmission", 0).toInt();
Please sign in to comment.
Something went wrong with that request. Please try again.