DEKI/ENGINE docs
manual api reference
Deki 0.40.1
Modular C++ engine with a visual editor, for 2D and 3D
Loading...
Searching...
No Matches
Deki::PropertyRef Struct Reference

A picked field of a component on an object. More...

#include <deki/reflection/PropertyRef.h>

Public Member Functions

bool IsSet () const
void Rehash ()

Public Attributes

std::string component
uint32_t componentTypeId = 0
std::string field
uint32_t fieldHash = 0
std::string object

Detailed Description

A picked field of a component on an object.

The editor sets one with three dropdowns (object, then component, then field), so only valid references can be made. The component is stored by the qualified class name scenes use, the field by its name. Both are hashed once at load (Rehash); resolving is then a small linear scan with no string work.

The object is a name, because object ids are per scene and a graph asset is shared by every scene that uses it. "" means the object this component is on.

Resolve once (Awake, state entry) into a PropertyBinding and reuse it, not every frame.

Member Function Documentation

◆ IsSet()

bool Deki::PropertyRef::IsSet ( ) const
inline

◆ Rehash()

void Deki::PropertyRef::Rehash ( )

Member Data Documentation

◆ component

std::string Deki::PropertyRef::component

◆ componentTypeId

uint32_t Deki::PropertyRef::componentTypeId = 0

◆ field

std::string Deki::PropertyRef::field

◆ fieldHash

uint32_t Deki::PropertyRef::fieldHash = 0

◆ object

std::string Deki::PropertyRef::object

The documentation for this struct was generated from the following file: