-
Notifications
You must be signed in to change notification settings - Fork 4
New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
How to get textures of other gear. #2
Comments
Thanks for letting me know. I didn't really look that deep into it, I just noted that getObjectTextures doesn't return any textures apart from the uniform and didn't look into it further. I will definitely look into implementing these textures into the mod as well, now that I know that this is possible. How would you determine which texture to use though if multiple are supplied? |
Generally speaking, the first texture is the 'main' one, and the others texture if there are any is stuff like straps, radios, headsets. If I were you I'd only bother calculating the first one. |
I'll look into the implementation of this after I roll out the first update. |
Faster yet would be (and working): private _vest = vest player;
private _backpack = backpack player;
private _headgear = headgear player;
// Either an array of texture paths, or [""] if there is no hidden selections defined.
private _vestTextures = [configfile >> "CfgWeapons" >> _vest >> "hiddenSelectionsTextures", "ARRAY", [""]] call CBA_fnc_getConfigEntry;
private _headgearTextures = [configfile >> "CfgWeapons" >> _headgear >> "hiddenSelectionsTextures", "ARRAY", [""]] call CBA_fnc_getConfigEntry;
private _backpackTextures = [configfile >> "CfgVehicles" >> _backpack >> "hiddenSelectionsTextures", "ARRAY", [""]] call CBA_fnc_getConfigEntry;
[_vestTextures, _headgearTextures, _backpackTextures] |
You say in the mod description it's an engine limitation you can't get the object textures of vests, headgear and backpacks but this isn't strictly true.
99% of gear have hidden selections that list the textures used, although not all do.
The text was updated successfully, but these errors were encountered: