Timo Hinse 0 Posted May 18, 2019 Hello... Im trying to get a addaction on holt whit a distance < 1m This works but whit a distance <~3m [ heli1, "<t color='#FF0000'>TAKE OFF</t>", "a3\ui_f\data\IGUI\Cfg\holdactions\holdAction_takeOff1_ca.paa", "a3\ui_f\data\IGUI\Cfg\holdactions\holdAction_takeOff1_ca.paa", "true", "true", {}, {}, {MLT_Helitakeoff = true; publicVariable "MLT_Helitakeoff";}, {}, [], 1, nil, true, false ] call BIS_fnc_holdActionAdd; if i try this: [ heli1, "<t color='#FF0000'>TAKE OFF</t>", "a3\ui_f\data\IGUI\Cfg\holdactions\holdAction_takeOff1_ca.paa", "a3\ui_f\data\IGUI\Cfg\holdactions\holdAction_takeOff1_ca.paa", "_this distance _target < 1", "_caller distance _target < 1", {}, {}, {MLT_Helitakeoff = true; publicVariable "MLT_Helitakeoff";}, {}, [], 1, nil, true, false ] call BIS_fnc_holdActionAdd; the addaction will not show. Share this post Link to post Share on other sites
phronk 895 Posted May 18, 2019 If it's attached to a vehicle and you want the pilot to execute it, change the distance check to something like this: "_this==driver _target", "_caller==driver _target" Something like that. The center position of vehicles is often more than 1m from the seat position of a vehicle, hence why it normally would work 1.6m+ away. Basically, replace the distance check with if the person calling the code is in the vehicle (as a driver or whatever position you're looking for) 1 Share this post Link to post Share on other sites
Timo Hinse 0 Posted May 18, 2019 1 hour ago, phronk said: why it normally would work 1.6m+ away. That worked... thank you. In heli, the action can now be performed from inside and at ohter objekts the action is very close to the object Share this post Link to post Share on other sites
3l0ckad3 17 Posted May 26, 2019 I spawned it within a trigger radius, just incase that is not always an option. Share this post Link to post Share on other sites