3956 {
3957 array<string> slots = new array<string>;
3958 ConfigGetTextArray("Attachments", slots);
3959
3960 array<string> mags = new array<string>;
3961 ConfigGetTextArray("magazines", mags);
3962
3963
3964
3966
3970
3971 string config_path;
3972 string child_name;
3973 int scope;
3975 int consumable_count;
3976
3977 for (int i = 0; i < all_paths.Count(); i++)
3978 {
3979 config_path = all_paths.
Get(i);
3980 int children_count =
g_Game.ConfigGetChildrenCount(config_path);
3981
3982 for (
int x = 0;
x < children_count;
x++)
3983 {
3984 g_Game.ConfigGetChildName(config_path,
x, child_name);
3985 path = config_path +
" " + child_name;
3986 scope =
g_Game.ConfigGetInt( config_path +
" " + child_name +
" scope" );
3987 bool should_check = true;
3988 if ( config_path == "CfgVehicles" && scope == 0)
3989 {
3990 should_check = false;
3991 }
3992
3993 if ( should_check )
3994 {
3995 string inv_slot;
3996 g_Game.ConfigGetText( config_path +
" " + child_name +
" inventorySlot",inv_slot );
3997 for (int z = 0; z < slots.Count(); z++)
3998 {
3999 if (slots.Get(z) == inv_slot)
4000 {
4002 continue;
4003
4004 }
4005 }
4006 }
4007 }
4008 }
4009 };
proto native GameInventory GetInventory()
EntityAI CreateInInventory(string type)
creates entity somewhere in inventory
proto int Insert(T value)
class array< Class T > TStringArray
proto string Get(int index)
Gets n-th character from string.