Hello! I have some problems with this script because it only works properly only in host mode, but on a dedicated server no longer works, ie works partly, I must first unlock the vehicle as admin and enter as a driver, only then can I lock / unlock the vehicle, I've added to your script detection UID and now I do not know how to eliminate the error, so that work properly
init.sqf
...
UIDarray=["uid1","uid2","etc"];
...
box_fnc_locks=compile preprocessFileLineNumbers "init_locks.sqf";
call box_fnc_locks;
mission.sqm
...
init="0 = this execVM ""locks.sqf"";";
...
//added to any vehicle that wants to lock / unlock
locks.sqf
WaitUntil{not isNull player};
waitUntil {(getPlayerUID player) != ""};
_uid = getPlayerUID player;
if (_uid in UIDArray) then
{
0 = _this addaction ["<t color='#ffff00'>Unlock vehicle</t>","vehicleunlock.sqf",[],0,false,false,"","(locked _target)"];
0 = _this addaction ["<t color='#ffff00'>Lock vehicle</t>","vehiclelock.sqf",[],0,false,false,"","(!locked _target)"];
} else {};
the rest of the files (vehiclelock.sqf, vehicleunlock.sqf) no change
CAN YOU HELP ME?