diff -r ef9e171617a3 -r df6f3b4b0038 src/ai/core/town/query.cpp --- a/src/ai/core/town/query.cpp Thu Mar 15 13:36:45 2007 +0000 +++ b/src/ai/core/town/query.cpp Thu Mar 15 13:50:58 2007 +0000 @@ -6,6 +6,7 @@ #include "../../../town.h" #include "../../../strings.h" #include "../../../variables.h" /* For SetDParam */ +#include "table/strings.h" TownID AITown::GetMaxTownID() { @@ -27,9 +28,8 @@ static const int len = 64; char *town_name = MallocT(len); - const Town *t = ::GetTown(town_id); - SetDParam(0, t->townnameparts); - GetString(town_name, t->townnametype, &town_name[len - 1]); + SetDParam(0, town_id); + GetString(town_name, STR_TOWN, &town_name[len - 1]); return town_name; }