main.cpp
来自「rcssserver3d Robocup 3D比赛官方指定平台」· C++ 代码 · 共 54 行
CPP
54 行
#include <zeitgeist/zeitgeist.h>#include <oxygen/oxygen.h>#if HAVE_KEROSIN_H#include <kerosin/kerosin.h>#endifusing namespace boost;using namespace std;using namespace zeitgeist;#ifdef GetObject#undef GetObject#endifint main(){ Zeitgeist zg("." PACKAGE_NAME); shared_ptr<CoreContext> context = zg.CreateContext();#if HAVE_KEROSIN_H kerosin::Kerosin kKerosin(zg);#endif oxygen::Oxygen kOxygen(zg); shared_ptr<ScriptServer> scriptServer = shared_static_cast<ScriptServer>(context->Get("/sys/server/script")); scriptServer->Run("coretest.rb"); cout << "CoreTest - A Small Interactive Text-Based Console Sample" << endl << endl; cout << "Enter 'exit' command to quit application" << endl << endl; bool done = false; while (!done) { std::string command = ""; boost::shared_ptr<Leaf> selectedObject = scriptServer->GetContext()->GetSelection(); cout << endl << selectedObject->GetFullPath() << "> "; getline(cin, command,'\n'); if (command.compare("exit")==0) { done = true; } else { scriptServer->Eval(command.c_str()); } } return 0;}
⌨️ 快捷键说明
复制代码Ctrl + C
搜索代码Ctrl + F
全屏模式F11
增大字号Ctrl + =
减小字号Ctrl + -
显示快捷键?