Skip to content
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

Remove nametags and actions on hidden units #2892

Merged
merged 1 commit into from
Nov 29, 2015
Merged
Show file tree
Hide file tree
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
2 changes: 1 addition & 1 deletion addons/interact_menu/functions/fnc_renderActionPoints.sqf
Original file line number Diff line number Diff line change
Expand Up @@ -34,7 +34,7 @@ _fnc_renderNearbyActions = {

// Quick oclussion test. Skip objects more than 1 m behind the camera plane
_lambda = ((getPosASL _x) vectorDiff _cameraPos) vectorDotProduct _cameraDir;
if (_lambda > -1) then {
if ((_lambda > -1) && {!isObjectHidden _target}) then {
_numInteractions = 0;
// Prevent interacting with yourself or your own vehicle
if (_target != ACE_player && {_target != vehicle ACE_player}) then {
Expand Down
2 changes: 1 addition & 1 deletion addons/nametags/functions/fnc_drawNameTagIcon.sqf
Original file line number Diff line number Diff line change
Expand Up @@ -22,7 +22,7 @@

params ["_player", "_target", "_alpha", "_heightOffset", "_iconType"];

if (_iconType == ICON_NONE) exitWith {}; //Don't waste time if not visable
if ((_iconType == ICON_NONE) || {isObjectHidden _target}) exitWith {}; //Don't waste time if not visable

private ["_position", "_color", "_name", "_size", "_icon", "_scale"];

Expand Down