diff --git a/addons/police/functions/fnc_copKilledMsg.sqf b/addons/police/functions/fnc_copKilledMsg.sqf index 60df0ed7..c3736ae9 100644 --- a/addons/police/functions/fnc_copKilledMsg.sqf +++ b/addons/police/functions/fnc_copKilledMsg.sqf @@ -23,12 +23,14 @@ if (_timeOfDeath isEqualType 0) then { _timeOfDeath = [_timeOfDeath] call BIS_fnc_timeToString; }; -if (isNull _nearestTown) then { - _nearestTown = [_deadCop] call EFUNC(common,getNearestCityLocation); +private _nearestCity = if (isNull _nearestTown) then { + [_deadCop] call EFUNC(civilian,getNearestCity) +} else { + [_nearestTown] call EFUNC(civilian,getCityByLocation) }; private _msg = ""; -private _nearestCityArea = _nearestTown getVariable QGVAR(cityArea); +private _nearestCityArea = _nearestCity getVariable QEGVAR(civilian,cityArea); private _isInCity = (position _deadCop) inArea _nearestCityArea; // Check if distance is greater than 250 m. If so then change output a bit to represent that.