|
NoJobEngine 2.0.7
|
Base class for native gameplay scripts instantiated while a scene runs. More...
#include <ScriptableEntity.h>
Classes | |
| struct | AIStateTransition |
Public Member Functions | |
| virtual | ~ScriptableEntity ()=default |
| virtual void | OnCreate () |
| Called when the runtime script instance is created. | |
| virtual void | OnUpdate (float deltaTime) |
| Called during scene updates. | |
| virtual void | OnDestroy () |
| Called before the runtime script instance is destroyed. | |
| virtual bool | GetNeuralDebugSnapshot (NeuralAgent::Snapshot &out) const |
| Provides live neural diagnostics across project DLL boundaries. | |
| virtual void | RegisterBehaviorTreeBindings (BTNativeRegistry &) const |
| const std::string & | GetAIDebugState () const |
| const std::string & | GetAIDebugPreviousState () const |
| float | GetAIDebugTimeInState () const |
| float | GetAIDebugRuntimeSeconds () const |
| const std::vector< AIStateTransition > & | GetAIDebugTransitions () const |
| template<typename T> | |
| T & | GetComponent () |
| template<typename T> | |
| bool | HasComponent () const |
| Entity | GetEntity () const |
Protected Member Functions | |
| void | TickAIDebug (float dt) |
| void | SetAIDebugState (const char *state) |
| NativeScriptComponent & | ScriptComponent () |
| float | GetFloat (const std::string &name, float fallback=0.0f) const |
| int | GetInt (const std::string &name, int fallback=0) const |
| bool | GetBool (const std::string &name, bool fallback=false) const |
| glm::vec3 | GetVec3 (const std::string &name, glm::vec3 fallback={}) const |
Friends | |
| class | Scene |
Base class for native gameplay scripts instantiated while a scene runs.
Override lifecycle callbacks to implement gameplay logic. Project scripts may expose neural snapshots to the editor through GetNeuralDebugSnapshot().
Definition at line 23 of file ScriptableEntity.h.
|
virtualdefault |
|
inline |
Definition at line 53 of file ScriptableEntity.h.
|
inline |
Definition at line 55 of file ScriptableEntity.h.
|
inline |
Definition at line 52 of file ScriptableEntity.h.
|
inline |
Definition at line 54 of file ScriptableEntity.h.
|
inline |
Definition at line 56 of file ScriptableEntity.h.
|
inlineprotected |
Definition at line 103 of file ScriptableEntity.h.
Referenced by NoJob::NeuralTrainingAgent::OnCreate().
|
inline |
Definition at line 59 of file ScriptableEntity.h.
Referenced by NoJob::BTAssetAgent::CreateTree(), NoJob::Oscillator::OnCreate(), NoJob::GenericNeuralAgent::OnUpdate(), NoJob::NeuralTrainingAgent::OnUpdate(), NoJob::Oscillator::OnUpdate(), NoJob::PongBallDemo::OnUpdate(), and NoJob::Rotator::OnUpdate().
|
inline |
Definition at line 64 of file ScriptableEntity.h.
Referenced by NoJob::BTAssetAgent::CreateTree(), NoJob::GenericNeuralAgent::OnDestroy(), NoJob::NeuralTrainingAgent::OnDestroy(), NoJob::BTAssetAgent::OnTreeStarted(), NoJob::BTAssetAgent::OnTreeStopped(), NoJob::GenericNeuralAgent::OnUpdate(), and NoJob::NeuralTrainingAgent::OnUpdate().
|
inlineprotected |
Definition at line 93 of file ScriptableEntity.h.
Referenced by NoJob::NeuralTrainingAgent::OnCreate(), NoJob::GenericNeuralAgent::OnUpdate(), NoJob::Oscillator::OnUpdate(), NoJob::PongBallDemo::OnUpdate(), and NoJob::Rotator::OnUpdate().
|
inlineprotected |
Definition at line 98 of file ScriptableEntity.h.
Referenced by NoJob::GenericNeuralAgent::OnCreate(), NoJob::NeuralTrainingAgent::OnCreate(), and NoJob::GenericNeuralAgent::OnUpdate().
|
inlinevirtual |
Provides live neural diagnostics across project DLL boundaries.
| out | Receives a copy of the current agent snapshot. |
Definition at line 39 of file ScriptableEntity.h.
|
inlineprotected |
Definition at line 108 of file ScriptableEntity.h.
Referenced by NoJob::Oscillator::OnUpdate(), and NoJob::Rotator::OnUpdate().
|
inline |
Definition at line 62 of file ScriptableEntity.h.
Referenced by NoJob::BTAssetAgent::CreateTree(), NoJob::GenericNeuralAgent::OnUpdate(), and NoJob::NeuralTrainingAgent::OnUpdate().
|
inlinevirtual |
Called when the runtime script instance is created.
Reimplemented in NoJob::BTScriptController, NoJob::GenericNeuralAgent, NoJob::NeuralTrainingAgent, and NoJob::Oscillator.
Definition at line 28 of file ScriptableEntity.h.
|
inlinevirtual |
Called before the runtime script instance is destroyed.
Reimplemented in NoJob::BTScriptController, NoJob::GenericNeuralAgent, and NoJob::NeuralTrainingAgent.
Definition at line 33 of file ScriptableEntity.h.
|
inlinevirtual |
Called during scene updates.
| deltaTime | Frame time in seconds. |
Reimplemented in NoJob::BTScriptController, NoJob::GenericNeuralAgent, NoJob::NeuralTrainingAgent, NoJob::Oscillator, NoJob::PongBallDemo, and NoJob::Rotator.
Definition at line 31 of file ScriptableEntity.h.
|
inlinevirtual |
Definition at line 43 of file ScriptableEntity.h.
|
inlineprotected |
Definition at line 88 of file ScriptableEntity.h.
Referenced by NoJob::NeuralTrainingAgent::OnCreate(), and NoJob::NeuralTrainingAgent::OnUpdate().
|
inlineprotected |
Definition at line 75 of file ScriptableEntity.h.
Referenced by NoJob::GenericNeuralAgent::OnCreate(), NoJob::NeuralTrainingAgent::OnCreate(), NoJob::GenericNeuralAgent::OnUpdate(), and NoJob::NeuralTrainingAgent::OnUpdate().
|
inlineprotected |
Definition at line 67 of file ScriptableEntity.h.
Referenced by NoJob::GenericNeuralAgent::OnUpdate(), and NoJob::NeuralTrainingAgent::OnUpdate().
|
friend |
Definition at line 122 of file ScriptableEntity.h.
References Scene.
Referenced by NoJob::NeuralTrainingAgent::OnUpdate(), and Scene.