navMeshTool.cpp 784 B

123456789101112131415161718192021222324252627282930313233343536373839
  1. #include "platform/platform.h"
  2. #include "navigation/navMeshTool.h"
  3. #include "util/undo.h"
  4. #include "math/mMath.h"
  5. #include "math/mathUtils.h"
  6. IMPLEMENT_CONOBJECT(NavMeshTool);
  7. ConsoleDocClass(NavMeshTool,
  8. "@brief Base class for NavMesh Editor specific tools\n\n"
  9. "Editor use only.\n\n"
  10. "@internal"
  11. );
  12. void NavMeshTool::_submitUndo(UndoAction* action)
  13. {
  14. AssertFatal(action, "NavMeshTool::_submitUndo() - No undo action!");
  15. // Grab the mission editor undo manager.
  16. UndoManager* undoMan = NULL;
  17. if (!Sim::findObject("EUndoManager", undoMan))
  18. {
  19. Con::errorf("NavMeshTool::_submitUndo() - EUndoManager not found!");
  20. return;
  21. }
  22. undoMan->addAction(action);
  23. }
  24. NavMeshTool::NavMeshTool()
  25. : mNavMesh(NULL)
  26. {
  27. }
  28. NavMeshTool::~NavMeshTool()
  29. {
  30. }