比較バージョン

キー

  • この行は追加されました。
  • この行は削除されました。
  • 書式設定が変更されました。
In this section we creates a new behaviour module. This module is a simple follow target module.

Writing the behaviour module

First thing to do is create a class and hinerit from the base BehaviourModule class. With a constructor a desctructor and a static creator function used by atoms to create an isntance of this module.


コード ブロック
languagecpp
class FollowTargetModule: public Atoms::BehaviourModule
{
	public:

		FollowTargetModule()
		{}

		virtual ~FollowTargetModule()
		{}

		static Atoms::BehaviourModule* creator(const std::string& parameter);
};

Atoms::BehaviourModule* creator(const std::string& parameter)
{
	return new FollowTargetModule();
}


Register the behaviour module

Compile the behaviour module

Use the behaviour module