allowedService: Difference between revisions

From Bohemia Interactive Community
Jump to navigation Jump to search
(Created page with "{{RV|type=command |game1= arma3 |version1= 2.12 |branch= dev |gr1= Object Manipulation |descr= Returns which type of repair/refuel/rearm service is allowed. There are 2 typ...")
 
m (Some wiki formatting)
Line 7: Line 7:
|gr1= Object Manipulation
|gr1= Object Manipulation


|descr= Returns which type of repair/refuel/rearm service is allowed. There are 2 types, manual and auto. It could be set to none, auto only, manual only or both. When manual is allowed the action icon is shown. The engine default for historic reasons is both, auto and manual.
|descr= Returns which types of repair/refuel/rearm service are allowed. The two available types are manual, where the action is displayed to the user, and auto, where the service happens within distance.
The engine default is both (auto and manual) for historic reasons.


|s1= [[allowedService]] vehicle
|s1= [[allowedService]] vehicle
Line 13: Line 14:
|p1= vehicle: [[Object]] - supply vehicle, i.e. ammo truck
|p1= vehicle: [[Object]] - supply vehicle, i.e. ammo truck


|r1= [[Number]] - 0:none, 1:auto, 2:manual, 3:both, -1:unsupported
|r1= [[Number]] - 0: none, 1: auto, 2: manual, 3: both, -1: unsupported
 
|x1= <sqf>allowedService ammoTruck;</sqf>


|x1= <sqf>if (allowedService _vehicle == -1) then { hint "this is not a service vehicle!" };</sqf>


|seealso= [[allowService]] [[needService]]
|seealso= [[allowService]] [[needService]]
}}
}}

Revision as of 13:00, 2 February 2023

Hover & click on the images for description
Only available in Development branch(es) until its release with Arma 3 patch v2.12.

Description

Description:
Returns which types of repair/refuel/rearm service are allowed. The two available types are manual, where the action is displayed to the user, and auto, where the service happens within distance. The engine default is both (auto and manual) for historic reasons.
Groups:
Object Manipulation

Syntax

Syntax:
allowedService vehicle
Parameters:
vehicle: Object - supply vehicle, i.e. ammo truck
Return Value:
Number - 0: none, 1: auto, 2: manual, 3: both, -1: unsupported

Examples

Example 1:
if (allowedService _vehicle == -1) then { hint "this is not a service vehicle!" };

Additional Information

See also:
allowService needService

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