1
0
Fork 0

Positioned support for adding user waypoints.

This commit is contained in:
jmt 2009-09-28 23:42:10 +00:00 committed by Tim Moore
parent 5755b7ae0e
commit e1555ba9a5
2 changed files with 8 additions and 0 deletions

View file

@ -460,6 +460,12 @@ FGPositioned::~FGPositioned()
removeFromIndices(this); removeFromIndices(this);
} }
FGPositioned*
FGPositioned::createUserWaypoint(const std::string& aIdent, const SGGeod& aPos)
{
return new FGPositioned(WAYPOINT, aIdent, aPos, true);
}
SGBucket SGBucket
FGPositioned::bucket() const FGPositioned::bucket() const
{ {

View file

@ -209,6 +209,8 @@ public:
* Map a type to a human-readable string * Map a type to a human-readable string
*/ */
static const char* nameForType(Type aTy); static const char* nameForType(Type aTy);
static FGPositioned* createUserWaypoint(const std::string& aIdent, const SGGeod& aPos);
protected: protected:
FGPositioned(Type ty, const std::string& aIdent, const SGGeod& aPos, bool aIndex = true); FGPositioned(Type ty, const std::string& aIdent, const SGGeod& aPos, bool aIndex = true);