BIS fnc showRespawnMenuDisableItem: Difference between revisions

From Bohemia Interactive Community
Jump to navigation Jump to search
m (Text replacement - "{{Function " to "{{RV|type=function ")
(added missing parameter with descriptions & updated example)
Line 9: Line 9:
|eff= global
|eff= global


| Limits respawn loadout or role for [[Arma 3 Respawn]].
| Disables respawn loadout, role or position for [[Arma 3 Respawn]].
* Only role or only loadout can be limited at one moment, if there is limit for both, then only role uses limit.
* Only role or only loadout can be limited at one moment, if there is limit for both, then only role uses limit.
* If the limit definition for role is called multiple times with different numbers, then the highest number is used.  
* If the limit definition for role is called multiple times with different numbers, then the highest number is used.  
* If disabling a position then respawnReference must be supplied


| [mode, uiControl, item, message] call [[BIS_fnc_showRespawnMenuDisableItem]];
| [mode, uiControl, listboxItem, message, respawnReference] call [[BIS_fnc_showRespawnMenuDisableItem]];


|p1= '''mode''': [[String]] - Available options are ''disable'', ''enable'' and ''state''
|p1= '''mode''': [[String]] - Available options are ''disable'', ''enable'' and ''state''
Line 20: Line 21:
*BIS_RscRespawnControlsMap_ctrlRoleList
*BIS_RscRespawnControlsMap_ctrlRoleList
*BIS_RscRespawnControlsMap_ctrlComboLoadout
*BIS_RscRespawnControlsMap_ctrlComboLoadout
|p3= '''item''': [[Number]] or [[String]] - Index or name of item in the list
|p3= '''listboxItem''': [[Number]] or [[String]] - Index or name of item in the respawn position listbox
|p4= '''message''': [[String]] - (Optional) Message shown when disabled item is selected
|p4= '''message''': [[String]] - Message shown when disabled item is selected, use "" for default message
|p5= '''respawnReference''': [[String]] - Reference to respawn position either Marker name or [[vehicleVarName|Object var name]]


|
|
   
   
|x1= <code><nowiki>[</nowiki>"disable",uiNamespace getVariable "BIS_RscRespawnControlsMap_ctrlRoleList",2,"Restricted for this part of mission!"] [[call]] [[BIS_fnc_showRespawnMenuDisableItem]];</code>
|x1= <code><nowiki>[</nowiki>
"disable",
uiNamespace getVariable "BIS_RscRespawnControlsMap_ctrlRoleList",
2,
"Restricted for this part of mission!",
myRespawnModule [[call]] [[BIS_fnc_objectVar]]
] [[call]] [[BIS_fnc_showRespawnMenuDisableItem]];</code>


| [[BIS_fnc_addRespawnInventory]], [[BIS_fnc_addRespawnPosition]], [[Arma 3 Respawn]]
| [[BIS_fnc_addRespawnInventory]], [[BIS_fnc_addRespawnPosition]], [[Arma 3 Respawn]]

Revision as of 18:25, 28 January 2021

Hover & click on the images for description

Description

Description:
Description needed
Execution:
call
Groups:
Respawn

Syntax

Syntax:
Syntax needed
Parameters:
mode: String - Available options are disable, enable and state
uiControl: Control - List in which item should be disabled/enabled
  • BIS_RscRespawnControlsMap_ctrlLocList
  • BIS_RscRespawnControlsMap_ctrlRoleList
  • BIS_RscRespawnControlsMap_ctrlComboLoadout
listboxItem: Number or String - Index or name of item in the respawn position listbox
message: String - Message shown when disabled item is selected, use "" for default message
respawnReference: String - Reference to respawn position either Marker name or Object var name
Return Value:
Return value needed

Examples

Example 1:
[ "disable", uiNamespace getVariable "BIS_RscRespawnControlsMap_ctrlRoleList", 2, "Restricted for this part of mission!", myRespawnModule call BIS_fnc_objectVar ] call BIS_fnc_showRespawnMenuDisableItem;

Additional Information

See also:
See also needed

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