DayZ 1.27
DayZ Explorer by KGB
 
Загрузка...
Поиск...
Не найдено

◆ PluginsInit()

void PluginManager::PluginsInit ( )
inlineprivate

См. определение в файле PluginManager.c строка 101

102 {
103 int i = 0;
104 int regCount = m_PluginRegister.Count();
105
106 array<PluginBase> pluginPtrs = {};
107 pluginPtrs.Reserve(regCount);
108
109 foreach (typename pluginType : m_PluginRegister)
110 {
111 PluginBase moduleExist = GetPluginByType( pluginType );
112 if ( moduleExist )
113 {
114 m_PluginsPtrs.Remove( pluginType );
115 }
116
117 PluginBase moduleNew = PluginBase.Cast(pluginType.Spawn());
118 m_PluginsPtrs.Set(pluginType, moduleNew);
119 pluginPtrs.Insert(moduleNew);
120 }
121
122 foreach (PluginBase plugin : pluginPtrs)
123 {
124 if ( plugin )
125 {
126 plugin.OnInit();
127 }
128 }
129 }
PluginBase GetPluginByType(typename plugin_type)
Returns registred plugin by class type, better is to use global funtion GetPlugin(typename plugin_typ...
Определения PluginManager.c:157
ref map< typename, ref PluginBase > m_PluginsPtrs
Определения PluginManager.c:4
ref array< typename > m_PluginRegister
Определения PluginManager.c:3

Перекрестные ссылки GetPluginByType(), m_PluginRegister и m_PluginsPtrs.