Skip to content

Commit

Permalink
Internal function rename
Browse files Browse the repository at this point in the history
  • Loading branch information
Axel Groß committed Jan 5, 2024
1 parent 3a2e9cf commit e9c7496
Showing 1 changed file with 5 additions and 5 deletions.
10 changes: 5 additions & 5 deletions server/ServerApp.cpp
Original file line number Diff line number Diff line change
Expand Up @@ -2288,8 +2288,8 @@ namespace {
}
}

bool GetFleetsVisibleToEmpireAtSystem(std::set<int>& visible_fleets, int empire_id, int system_id,
const ScriptingContext& context)
bool HasBlockadeOrGetFleetsVisibleToEmpireAtSystem(std::set<int>& visible_fleets, int empire_id,
int system_id, const ScriptingContext& context)
{
const ObjectMap& objects{context.ContextObjects()};

Expand All @@ -2303,7 +2303,7 @@ namespace {
if (empire_id != ALL_EMPIRES && !context.GetEmpire(empire_id))
return false; // no such empire

TraceLogger(combat) << "\t** GetFleetsVisibleToEmpire " << empire_id << " at system " << system->Name();
TraceLogger(combat) << "\t** HasBlockadeOrGetFleetsVisibleToEmpireAtSystem " << empire_id << " at system " << system->Name();
// first pass over all fleets, to find a blockade and handle empire visibility
// for visible fleets by an empire, check visibility of fleets by that empire
for (const auto* fleet : objects.findRaw<Fleet>(fleet_ids)) {
Expand Down Expand Up @@ -2537,8 +2537,8 @@ namespace {

// what fleets can the aggressive empire see?
std::set<int> aggressive_empire_visible_fleets;
bool blockade = GetFleetsVisibleToEmpireAtSystem(aggressive_empire_visible_fleets, aggressive_empire_id,
system_id, context);
bool blockade = HasBlockadeOrGetFleetsVisibleToEmpireAtSystem(aggressive_empire_visible_fleets,
aggressive_empire_id, system_id, context);
if (blockade)
return true; // at least one fleet is blockaded, there must be conflict

Expand Down

0 comments on commit e9c7496

Please sign in to comment.