FULLPIPE: Implement MovGraph::getItemIndexByStaticAni()

This commit is contained in:
Eugene Sandulenko 2014-04-22 21:20:34 +03:00
parent d356f17161
commit eeec908123
2 changed files with 9 additions and 0 deletions

View File

@ -660,6 +660,14 @@ void MovGraph::calcNodeDistancesAndAngles() {
}
}
int MovGraph::getItemIndexByStaticAni(StaticANIObject *ani) {
for (uint i = 0; i < _items.size(); i++)
if (_items[i]->ani == ani)
return i;
return -1;
}
int MovGraph2::getItemIndexByGameObjectId(int objectId) {
for (uint i = 0; i < _items2.size(); i++)
if (_items2[i]->_objectId == objectId)

View File

@ -347,6 +347,7 @@ public:
double calcDistance(Common::Point *point, MovGraphLink *link, int fuzzyMatch);
void calcNodeDistancesAndAngles();
MovGraphNode *calcOffset(int ox, int oy);
int getItemIndexByStaticAni(StaticANIObject *ani);
};
class Movement;