null_script_host.h¶
| File Path | engine/include/conjure/scripting/null_script_host.h |
| API ↗ | Hosting, the native API and hot reload, Scripting |
The C++ fake of the managed side. It implements conjure_managed_api with recording functions: slots come from a LIFO free list, apply_fields stores the blob per slot and collect_fields echoes it, run_phase, dispatch_collisions and set_active are logged, sample_memory reports the figures set_managed_memory gave it, load_game_assembly registers fake classes (add_fake_class and an optional <assembly>.classes.json fixture) through the native table so the registry, blob and reload paths all run without .NET. Every scripting, scene, engine and editor test uses it; one null host is active (initialised) at a time.
Structs¶
| File | Description |
|---|---|
null_host_recorder::activity_record |
One slot of a set_active call: the state asked for and whether the slot was live and changed. |
null_host_recorder::apply_record |
|
null_host_recorder::collision_record |
|
null_host_recorder::create_record |
|
null_host_recorder::destroy_record |
|
null_host_recorder::phase_record |
|
null_script_host::slot_state |
Classes¶
| File | Description |
|---|---|
null_host_recorder |
What the null host recorded. Cleared by null_script_host::reset_recorder(). Each list keeps at most MAX_RECORDS entries and counts the rest in dropped_count(), so a long-running null host (the headless editor runs one by default) stays bounded; set_enabled(false) records nothing at all (the counters keep counting). |
null_script_host |
Type Aliases¶
null_script_host::activity_hook¶
Runs inside set_active for every live slot whose state changed, after the change: what OnEnable (active) or OnDisable (inactive) would do.
null_script_host::collision_hook¶
Runs inside dispatch_collisions for every record: what OnCollisionEnter and friends would do.
null_script_host::create_hook¶
Runs inside create_instances once a request's slot is assigned. As the create hook, for a request without CREATE_FLAG_ALREADY_CREATED: what OnCreate would do. As the reload hook, for a request with it: what OnReload would do.
null_script_host::destroy_hook¶
Runs inside destroy_instances for every live slot before it is freed when callOnDestroy is set: what OnDestroy would do.
null_script_host::phase_hook¶
Runs inside run_phase after the counters were bumped: what the phase callbacks would do.