(svn r16711) -Codechange: use FOR_ALL_SUBSIDIES macro when iterating over all subsidies

This commit is contained in:
smatz
2009-07-01 17:43:26 +00:00
parent 023f78b5ff
commit f4d0d94184
7 changed files with 37 additions and 42 deletions

View File

@@ -8,7 +8,8 @@
AISubsidyList::AISubsidyList()
{
for (uint i = 0; i < lengthof(_subsidies); i++) {
if (AISubsidy::IsValidSubsidy(i)) this->AddItem(i);
const Subsidy *s;
FOR_ALL_SUBSIDIES(s) {
this->AddItem(s - _subsidies);
}
}