From dfb2aea8a6d4b24b78fc2631cc99cefc9ebed4bd Mon Sep 17 00:00:00 2001 From: KJeff01 Date: Sat, 2 Dec 2023 12:32:20 -0600 Subject: [PATCH] Check startPosition coordinates for RTB when no HQ exists in mp Retreats units back to the startPosition area much like campaign does for LZ data. --- src/order.cpp | 6 ++++++ 1 file changed, 6 insertions(+) diff --git a/src/order.cpp b/src/order.cpp index 7fb94c5a5b0..912029b351b 100644 --- a/src/order.cpp +++ b/src/order.cpp @@ -1667,12 +1667,18 @@ void orderDroidBase(DROID *psDroid, DROID_ORDER_DATA *psOrder) // see if the LZ has been set up int iDX = getLandingX(psDroid->player); int iDY = getLandingY(psDroid->player); + Vector2i startPos = getPlayerStartPosition(psDroid->player); if (iDX && iDY) { psDroid->order = *psOrder; actionDroid(psDroid, DACTION_MOVE, iDX, iDY); } + else if (bMultiPlayer && (startPos.x != 0 && startPos.y != 0)) + { + psDroid->order = *psOrder; + actionDroid(psDroid, DACTION_MOVE, startPos.x, startPos.y); + } else { // haven't got an LZ set up so don't do anything