MCPcopy Create free account
hub / github.com/OpenDungeons/OpenDungeons / tileToVector3

Method tileToVector3

source/entities/MovableGameEntity.cpp:51–65  ·  view source on GitHub ↗

Source from the content-addressed store, hash-verified

49}
50
51void MovableGameEntity::tileToVector3(const std::list<Tile*>& tiles, std::vector<Ogre::Vector3>& path,
52 bool skipFirst, Ogre::Real z)
53{
54 for(Tile* tile : tiles)
55 {
56 if(skipFirst)
57 {
58 skipFirst = false;
59 continue;
60 }
61
62 Ogre::Vector3 dest(static_cast<Ogre::Real>(tile->getX()), static_cast<Ogre::Real>(tile->getY()), z);
63 path.push_back(dest);
64 }
65}
66
67void MovableGameEntity::setWalkPath(const std::string& walkAnim, const std::string& endAnim, bool loopEndAnim,
68 bool playIdleWhenAnimationEnds, const std::vector<Ogre::Vector3>& path)

Callers 7

handleFightMethod · 0.80
handleSearchJobMethod · 0.80
handleFightMethod · 0.80
handleFleeMethod · 0.80
handleFindHomeMethod · 0.80
handleGetFeeMethod · 0.80
handleEatChickenMethod · 0.80

Calls 2

getXMethod · 0.45
getYMethod · 0.45

Tested by

no test coverage detected