User Tools

Site Tools


mod-management-functions

Differences

This shows you the differences between two versions of the page.

Link to this comparison view

Both sides previous revision Previous revision
mod-management-functions [2020/07/17 14:35]
maxime
mod-management-functions [2020/12/14 09:49] (current)
maxime [registerPrefabComponent]
Line 76: Line 76:
 Registers a component to a prefab (see [[:​components|Components]] for a complete explanation) Registers a component to a prefab (see [[:​components|Components]] for a complete explanation)
  
-''​void **myMod:​registerPrefabComponent**(//​prefabPath//, //​componentData//​)''​+''​void **myMod:​registerPrefabComponent**(//​prefabIdOrPath//, //​componentData//​)''​
  
 ^ Name ^ Type ^ Description ^ ^ Name ^ Type ^ Description ^
-| //''​prefabPath''//​ | ''​string''​ | the path to the prefab |+| //''​prefabIdOrPath''//​ | ''​string''​ | the ID or path to the prefab |
 | //''​componentData''//​ | ''​table''​ | the data defining the component. The table must contain at least the component'​s type (''​DataType'',​ see [[api#​component_classes|API]] for the complete list) | | //''​componentData''//​ | ''​table''​ | the data defining the component. The table must contain at least the component'​s type (''​DataType'',​ see [[api#​component_classes|API]] for the complete list) |
  
mod-management-functions.txt ยท Last modified: 2020/12/14 09:49 by maxime