ctrlMapMouseOver: Difference between revisions

From Bohemia Interactive Community
Jump to navigation Jump to search
(add. classification)
m (sa)
 
(81 intermediate revisions by 8 users not shown)
Line 1: Line 1:
{{Command|= Comments
{{RV|type=command
____________________________________________________________________________________________


| arma2 |= Game name
|game1= arma2
|version1= 1.00


|1.00|= Game version
|game2= arma2oa
____________________________________________________________________________________________
|version2= 1.50


| Returns description of map sign mouse cursor is over. |= Description
|game3= tkoh
____________________________________________________________________________________________
|version3= 1.00


| '''ctrlMapMouseOver''' control |= Syntax
|game4= arma3
|version4= 0.50


|p1= control: [[Control]] - |= PARAMETER1
|gr1= GUI Control - Map


|p2= |= PARAMETER2
|descr= Returns description of map sign mouse cursor is over. Works with in-game map as well as 2D editor map in edit mode.


|p3= |= PARAMETER3
|s1= [[ctrlMapMouseOver]] control


| [[Array]] |= RETURNVALUE
|p1= control: [[Control]] - map control


|r1= [[Array]] - possible values:
* ["unit", [[Object]]]
* ["vehicle", [[Object]]]
* ["vehicleGroup", [[Object]]]
* ["object", [[Object]]]
* ["waypoint", [[Waypoint]]]
* ["trigger", [[Object]]]
* ["marker", [[String]]]
* ["task", [[Task]]]
* ["customMark"]


|x1= <code>(example)</code>|= EXAMPLE1
|x1= <sqf>(uiNamespace getVariable "_map") ctrlMapCursor ["Track","HC_overFriendly"];


____________________________________________________________________________________________
_mouseover = if (count (ctrlMapMouseOver (uiNamespace getVariable "_map")) > 0) then
{
ctrlMapMouseOver (uiNamespace getVariable "_map")
}
else
{
[""]
};


|  |= SEEALSO
if (_mouseover select 0 == "task" && str(_logic getVariable "onTaskAssigned") != str{}) then
{
//--- Task
(uiNamespace getVariable "_map") ctrlMapCursor ["Track","HC_overMission"];
}
else
{
//--- Waypoint
(uiNamespace getVariable "_map") ctrlMapCursor ["Track","HC_move"];
};</sqf>


| |= MPBEHAVIOUR
|x2= <sqf>onEachFrame {hintSilent str ctrlMapMouseOver (findDisplay 12 displayCtrl 51)};</sqf>
____________________________________________________________________________________________
 
|seealso= [[findDisplay]] [[displayCtrl]] [[BIS_fnc_createTooltip]]
}}
}}
<h3 style='display:none'>Notes</h3>
<dl class='command_description'>
<!-- Note Section BEGIN -->
<!-- Note Section END -->
</dl>
<h3 style='display:none'>Bottom Section</h3>
[[Category:ArmA 2: New Scripting Commands List|{{uc:{{PAGENAME}}}}]]
[[Category:Scripting Commands ArmA2|{{uc:{{PAGENAME}}}}]]
[[Category:Scripting Commands|{{uc:{{PAGENAME}}}}]]

Latest revision as of 12:51, 30 December 2023

Hover & click on the images for description

Description

Description:
Returns description of map sign mouse cursor is over. Works with in-game map as well as 2D editor map in edit mode.
Groups:
GUI Control - Map

Syntax

Syntax:
ctrlMapMouseOver control
Parameters:
control: Control - map control
Return Value:
Array - possible values:

Examples

Example 1:
(uiNamespace getVariable "_map") ctrlMapCursor ["Track","HC_overFriendly"]; _mouseover = if (count (ctrlMapMouseOver (uiNamespace getVariable "_map")) > 0) then { ctrlMapMouseOver (uiNamespace getVariable "_map") } else { [""] }; if (_mouseover select 0 == "task" && str(_logic getVariable "onTaskAssigned") != str{}) then { //--- Task (uiNamespace getVariable "_map") ctrlMapCursor ["Track","HC_overMission"]; } else { //--- Waypoint (uiNamespace getVariable "_map") ctrlMapCursor ["Track","HC_move"]; };
Example 2:
onEachFrame {hintSilent str ctrlMapMouseOver (findDisplay 12 displayCtrl 51)};

Additional Information

See also:
findDisplay displayCtrl BIS_fnc_createTooltip

Notes

Report bugs on the Feedback Tracker and/or discuss them on the Arma Discord or on the Forums.
Only post proven facts here! Add Note