.. _api_NativeBehaviour: NativeBehaviour =============== Inherited: :ref:`Component` .. _api_NativeBehaviour_description: Description ----------- All programmable game logic must be derived from NativeBehaviour class. Example: :: class ExampleBehaviour : public NativeBehaviour { A_OBJECT(ExampleBehaviour, NativeBehaviour, General) A_NOMETHODS() A_NOPROPERTIES() public: void start() { Log(Log::DBG) << "Start"; } void update() { Log(Log::DBG) << "Update"; } }; .. _api_NativeBehaviour_public: Public Methods -------------- +-------+------------------------------------------------+ | void | :ref:`start` () | +-------+------------------------------------------------+ | void | :ref:`update` () | +-------+------------------------------------------------+ .. _api_NativeBehaviour_static: Static Methods -------------- None .. _api_NativeBehaviour_methods: Methods Description ------------------- .. _api_NativeBehaviour_a3609184: void **NativeBehaviour::start** () Start is called on the same frame when a script is enabled just before the update method will be called the first time. ---- .. _api_NativeBehaviour_2173eaf4: void **NativeBehaviour::update** () Update is called every frame, if the NativeBehaviour is enabled.