mirror of
https://github.com/wesnoth/wesnoth
synced 2025-05-07 11:46:50 +00:00
remove an unused function: vacant_villages()
This commit is contained in:
parent
d9e640b306
commit
12d567263f
13
src/team.cpp
13
src/team.cpp
@ -638,19 +638,6 @@ int team::nteams()
|
||||
}
|
||||
}
|
||||
|
||||
const std::set<gamemap::location> vacant_villages(const std::set<gamemap::location>& villages, const unit_map& units)
|
||||
{
|
||||
std::set<gamemap::location> res;
|
||||
|
||||
for(std::set<gamemap::location>::const_iterator i = villages.begin(); i != villages.end(); ++i) {
|
||||
if(units.count(*i) == 0) {
|
||||
res.insert(*i);
|
||||
}
|
||||
}
|
||||
|
||||
return res;
|
||||
}
|
||||
|
||||
bool is_observer()
|
||||
{
|
||||
if(teams == NULL) {
|
||||
|
@ -2798,6 +2798,7 @@ bool unit::invisible(const gamemap::location& loc,
|
||||
return is_inv;
|
||||
}
|
||||
|
||||
//! Returns the number of units of the given side (team).
|
||||
int team_units(const unit_map& units, unsigned int side)
|
||||
{
|
||||
int res = 0;
|
||||
|
@ -430,8 +430,6 @@ struct team_data
|
||||
|
||||
team_data calculate_team_data(const class team& tm, int side, const unit_map& units);
|
||||
|
||||
const std::set<gamemap::location> vacant_villages(const std::set<gamemap::location>& villages, const unit_map& units);
|
||||
|
||||
// This object is used to temporary place a unit in the unit map,
|
||||
// swapping out any unit that is already there.
|
||||
// On destruction, it restores the unit map to its original .
|
||||
|
Loading…
x
Reference in New Issue
Block a user