MCPcopy Create free account
hub / github.com/defold/defold / GetComponentId

Function GetComponentId

engine/gameobject/src/gameobject/gameobject.cpp:2202–2211  ·  view source on GitHub ↗

Source from the content-addressed store, hash-verified

2200 }
2201
2202 Result GetComponentId(HInstance instance, uint16_t component_index, dmhash_t* component_id)
2203 {
2204 assert(instance != 0x0);
2205 if (component_index < instance->m_Prototype->m_ComponentCount)
2206 {
2207 *component_id = instance->m_Prototype->m_Components[component_index].m_Id;
2208 return RESULT_OK;
2209 }
2210 return RESULT_COMPONENT_NOT_FOUND;
2211 }
2212
2213 Result GetComponent(HInstance instance, dmhash_t component_id, uint32_t* component_type, HComponent* out_component, HComponentWorld* out_world)
2214 {

Callers 8

TEST_FFunction · 0.85
TEST_FFunction · 0.85
GuiGetURLCallbackFunction · 0.85
GetSenderFunction · 0.85
BroadCastFunction · 0.85
UnloadCompleteFunction · 0.85
CameraToURLFunction · 0.85

Calls 1

assertFunction · 0.50

Tested by 2

TEST_FFunction · 0.68
TEST_FFunction · 0.68