Skip to content

Commit 6e31c86

Browse files
authored
feat: include config side in :VEHICLE:CREATE: command (#82)
Adds `str side _x` as index [6] to the vehicle creation data sent to the extension. This provides the vehicle's configured faction side (WEST, EAST, GUER, CIV) at creation time, so the extension and web frontend can display correct faction colors for vehicles even when their crew is empty. Previously, vehicle side was only available per-frame in :VEHICLE:STATE: (index 11), and the JSON export hardcoded it as "UNKNOWN" on the entity definition. This caused vehicles to render as black (dead) icons whenever no crew was present.
1 parent c5b18fe commit 6e31c86

1 file changed

Lines changed: 2 additions & 1 deletion

File tree

addons/recorder/fnc_captureLoop.sqf

Lines changed: 2 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -213,7 +213,8 @@ GVAR(PFHObject) = [
213213
_class, //3
214214
getText (configFile >> "CfgVehicles" >> _vehType >> "displayName"), //4
215215
typeOf _x, //5
216-
format ["%1", [_x] call BIS_fnc_getVehicleCustomization] //6
216+
format ["%1", [_x] call BIS_fnc_getVehicleCustomization], //6
217+
str side _x //7
217218
];
218219
_x setVariable [QGVARMAIN(newVehicleData), _newVehicleData];
219220

0 commit comments

Comments
 (0)