Skip to content

Commit

Permalink
fix no texture
Browse files Browse the repository at this point in the history
  • Loading branch information
tbox1911 committed Aug 17, 2024
1 parent 2192949 commit f9c75bf
Show file tree
Hide file tree
Showing 2 changed files with 6 additions and 4 deletions.
3 changes: 1 addition & 2 deletions core.liberation/addons/VAM/fn_resetVehicle.sqf
Original file line number Diff line number Diff line change
Expand Up @@ -6,6 +6,5 @@ _vehicle setVariable ["GRLIB_vehicle_color", "", true];
_vehicle setVariable ["GRLIB_vehicle_color_name", "", true];
_vehicle setVariable ["GRLIB_vehicle_composant", [], true];

private _texture_def = (configOf _vehicle >> "TextureSources") call Bis_fnc_getCfgSubClasses select 0;
if (!isNil "_texture_def") then { [_vehicle, ""] spawn RPT_fnc_TextureVehicle };
[_vehicle, ""] spawn RPT_fnc_TextureVehicle;
[_vehicle, true, [true]] spawn bis_fnc_initVehicle;
7 changes: 5 additions & 2 deletions core.liberation/addons/VAM/fn_textureVehicle.sqf
Original file line number Diff line number Diff line change
Expand Up @@ -6,12 +6,15 @@ private _texture = "";

if (_name == "") then {
_texture = (configOf _vehicle >> "TextureSources") call Bis_fnc_getCfgSubClasses select 0;
_name = _texture;
} else {
_texture = [ RPT_colorList, { _x select 0 == _name } ] call BIS_fnc_conditionalSelect select 0 select 1;
};

if (isNil "_texture") then { _texture = _name };
if (isNil "_texture") then {
_texture = _name;
} else {
_name = _texture;
};

camo_class_names = [_texture];
camo_display_names = [_name];
Expand Down

0 comments on commit f9c75bf

Please sign in to comment.