210 {
212
213 all_paths.Insert("CfgVehicles");
214 all_paths.Insert("cfgLiquidDefinitions");
215
216 string config_path;
217 string child_name;
218 int scope;
220 int consumable_count;
221 for(int i = 0; i < all_paths.Count(); i++)
222 {
223 config_path = all_paths.Get(i);
225
226 for(
int x = 0;
x < children_count;
x++)
227 {
229 path = config_path +
" " + child_name;
231 bool should_check = 1;
232 if (config_path == "CfgVehicles" && scope == 0)
233 {
234 should_check = 0;
235 }
236
237 if (should_check)
238 {
241
242 if (has_nutrition || has_stages)
243 {
244
246 consumable_count++;
247 }
248 }
249 }
250 }
251
252 return true;
253 }
static void RegisterItem(string classname, int id)
proto bool ConfigGetChildName(string path, int index, out string name)
Get name of subclass in config class on path.
proto native bool ConfigIsExisting(string path)
proto native int ConfigGetInt(string path)
Get int value from config on path.
proto native int ConfigGetChildrenCount(string path)
Get count of subclasses in config class on path.
proto native CGame GetGame()
array< string > TStringArray