Epok Engine

EPOK RUNTIME

epok::bp::spawn_actor

Function · 1 overload

Function

Bounded actor spawn for the SpawnActor node.

Belongs to
epok::bp
Header
actor_blueprint.hpp
Overloads
1

Declaration

Declaration
inline ObjectId spawn_actor(Actor* context, uint64_t class_id, ObjectId logical_parent)

Bounded actor spawn for the SpawnActor node.

ParameterTypeMeaning
contextActor *Value supplied for context. Keep referenced or pointed-to data valid for the complete call.
class_iduint64_tValue supplied for class_id. Keep referenced or pointed-to data valid for the complete call.
logical_parentObjectIdValue supplied for logical_parent. Keep referenced or pointed-to data valid for the complete call.

Returns: ObjectId. Check the value before continuing when it represents success, availability or a resource handle.

Example

C++ example
#include "actor_blueprint.hpp"

// Assume these named values have been initialized with valid data:
// Actor * context
// uint64_t class_id
// ObjectId logical_parent

auto result = epok::bp::spawn_actor(context, class_id, logical_parent);

Why use it

It provides direct, allocation-conscious access to compiled Blueprint execution and object interaction. No exception-based error path is implied by the signature.

Trade-offs and warnings

Pointer/reference arguments are borrowed unless the source contract says otherwise; keep them valid for the complete operation and never assume null is accepted.

Declared in runtime/actor_blueprint.hpp:73

Related members