{"name":"allowedService","operator":null,"title":"allowedService","type":"command","url":"https://community.bistudio.com/wiki/allowedService","revid":338348,"updated":"2023-02-28T14:43:47Z","groups":["Object Manipulation"],"status":"ok","replaced_by":[],"games":[{"game":"arma3","name":"Arma 3","version":"2.12"}],"since":{"game":"arma3","name":"Arma 3","version":"2.12"},"arma3_since":"2.12","branch":null,"locality":{"argument":"global","effect":null,"server_exec":false},"exec":null,"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.\nThe engine default is both (manual and auto) for historic reasons.","syntaxes":[{"syntax":"allowedService vehicle","since":null,"effect":null,"exec":null,"params":[{"name":"vehicle","type":"Object","optional":false,"default":null,"description":"supply vehicle, i.e. ammo truck","types":["Object"],"since":null,"text":"vehicle: Object - supply vehicle, i.e. ammo truck"}],"returns":{"type":"Number","types":["Number"],"description":"0: none, 1: auto, 2: manual, 3: both, -1: unsupported","text":"Number - 0: none, 1: auto, 2: manual, 3: both, -1: unsupported"},"form":"unary","operator":null,"left":null,"right":{"text":"vehicle","types":["Object"]}}],"examples":[{"text":"```sqf\nif (allowedService _vehicle == -1) then { hint \"this is not a service vehicle!\" };\n```","code":["if (allowedService _vehicle == -1) then { hint \"this is not a service vehicle!\" };"]}],"multiplayer":null,"problems":null,"aliases":[],"see_also":["allowService","needService"],"notes":[],"categories":["Arma 3: New Scripting Commands","Arma 3: Scripting Commands","Command Group: Object Manipulation","Introduced with Arma 3 version 2.12","Scripting Commands"]}