Skip to content
Merged
Show file tree
Hide file tree
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
Original file line number Diff line number Diff line change
Expand Up @@ -925,8 +925,8 @@ void OpenContain::exitObjectViaDoor( Object *exitObj, ExitDoorType exitDoor )
std::vector<Coord3D> exitPath;
exitPath.push_back(endPosition);
exitPath.push_back(endPosition); // Do it twice, in case units stack up due to brief flying. jba.
if (m_rallyPointExists) {
exitPath.push_back(m_rallyPoint);
if (const Coord3D *rallyPoint = getRallyPoint()) {
exitPath.push_back(*rallyPoint);
}

if( ai )
Expand Down Expand Up @@ -1422,6 +1422,18 @@ const Coord3D *OpenContain::getRallyPoint() const
if (m_rallyPointExists)
return &m_rallyPoint;

#if !RETAIL_COMPATIBLE_CRC
// TheSuperHackers @bugfix arcticdolphin 02/03/2026 Use primary exit interface rally point if available.
if (getObject())
{
ExitInterface *primaryExit = getObject()->getObjectExitInterface();
if (primaryExit && primaryExit != static_cast<const ExitInterface *>(this))
{
return primaryExit->getRallyPoint();
}
}
#endif

return nullptr;
}

Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -1032,6 +1032,20 @@ UpdateSleepTime ChinookAIUpdate::update()
// we're completely healed, so take off again
pp->setHealee(getObject(), false);
setMyState(TAKING_OFF, nullptr, nullptr, CMD_FROM_AI);

#if !RETAIL_COMPATIBLE_CRC
// TheSuperHackers @bugfix arcticdolphin 02/03/2026 Move healed Chinook to rally point if present.
if (Object *airfield = TheGameLogic->findObjectByID( m_airfieldForHealing ))
{
if (ExitInterface *exitInterface = airfield->getObjectExitInterface())
{
if (const Coord3D *rallyPoint = exitInterface->getRallyPoint())
{
aiMoveToPosition( rallyPoint, CMD_FROM_AI );
}
}
}
#endif
}
else
{
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -1776,6 +1776,20 @@ UpdateSleepTime JetAIUpdate::update()
getStateMachine()->clear();
setLastCommandSource( CMD_FROM_AI );
getStateMachine()->setState( TAKING_OFF_AWAIT_CLEARANCE );

#if !RETAIL_COMPATIBLE_CRC
// TheSuperHackers @bugfix arcticdolphin 02/03/2026 Move healed helicopter to rally point if present.
if (Object *airfield = TheGameLogic->findObjectByID( jet->getProducerID() ))
{
if (ExitInterface *exitInterface = airfield->getObjectExitInterface())
{
if (const Coord3D *rallyPoint = exitInterface->getRallyPoint())
{
aiMoveToPosition( rallyPoint, CMD_FROM_AI );
}
}
}
#endif
}
else
{
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -1045,8 +1045,8 @@ void OpenContain::exitObjectViaDoor( Object *exitObj, ExitDoorType exitDoor )
std::vector<Coord3D> exitPath;
exitPath.push_back(endPosition);
exitPath.push_back(endPosition); // Do it twice, in case units stack up due to brief flying. jba.
if (m_rallyPointExists) {
exitPath.push_back(m_rallyPoint);
if (const Coord3D *rallyPoint = getRallyPoint()) {
exitPath.push_back(*rallyPoint);
}

if( ai )
Expand Down Expand Up @@ -1609,6 +1609,18 @@ const Coord3D *OpenContain::getRallyPoint() const
if (m_rallyPointExists)
return &m_rallyPoint;

#if !RETAIL_COMPATIBLE_CRC
// TheSuperHackers @bugfix arcticdolphin 02/03/2026 Use primary exit interface rally point if available.
if (getObject())
{
ExitInterface *primaryExit = getObject()->getObjectExitInterface();
if (primaryExit && primaryExit != static_cast<const ExitInterface *>(this))
{
return primaryExit->getRallyPoint();
}
}
#endif

return nullptr;
}

Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -1094,6 +1094,20 @@ UpdateSleepTime ChinookAIUpdate::update()
// we're completely healed, so take off again
pp->setHealee(getObject(), false);
setMyState(TAKING_OFF, nullptr, nullptr, CMD_FROM_AI);

#if !RETAIL_COMPATIBLE_CRC
// TheSuperHackers @bugfix arcticdolphin 02/03/2026 Move healed Chinook to rally point if present.
if (Object *airfield = TheGameLogic->findObjectByID( m_airfieldForHealing ))
{
if (ExitInterface *exitInterface = airfield->getObjectExitInterface())
{
if (const Coord3D *rallyPoint = exitInterface->getRallyPoint())
{
aiMoveToPosition( rallyPoint, CMD_FROM_AI );
}
}
}
#endif
}
else
{
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -1998,6 +1998,20 @@ UpdateSleepTime JetAIUpdate::update()
getStateMachine()->clear();
setLastCommandSource( CMD_FROM_AI );
getStateMachine()->setState( TAKING_OFF_AWAIT_CLEARANCE );

#if !RETAIL_COMPATIBLE_CRC
// TheSuperHackers @bugfix arcticdolphin 02/03/2026 Move healed helicopter to rally point if present.
if (Object *airfield = TheGameLogic->findObjectByID( jet->getProducerID() ))
{
if (ExitInterface *exitInterface = airfield->getObjectExitInterface())
{
if (const Coord3D *rallyPoint = exitInterface->getRallyPoint())
{
aiMoveToPosition( rallyPoint, CMD_FROM_AI );
}
}
}
#endif
}
else
{
Expand Down
Loading