Bug #32264

Script error from cba\addons\ai\fnc_searchNearby because of bis_fnc_dirto

Added by Cuel about 3 years ago. Updated about 3 years ago.

Status:Feedback Start date:06/01/2012
Priority:Normal Due date:06/09/2012
Assignee:Cuel % Done:

0%

Category:Misc Functions
Target version:-
Component: Affected Version:182
Close Reason:

Description

Trying to use the searchNearby function results in this sometimes.


_ret = ((_pos2 select 0) - (_pos1 select 0)) atan2 ((_pos2 select 1) - (_p>
Error position: <select 0)) atan2 ((_pos2 select 1) - (_p>
Error select: Type Object, expected Array,Config entry
File ca\modules\functions\geometry\fn_dirTo.sqf, line 24

called from line 29 in ai/fnc_searchNearby.sqf

scriptErrorTest.Zargabad.rar - repro mission (2.4 kB) Cuel, 06/03/2012 21:08

History

Updated by Sickboy about 3 years ago

  • Due date set to 06/09/2012
  • Status changed from New to Feedback
  • Assignee set to Cuel

Heya, would you have a repro mission to go with that?
The opted problem seems very strange, because the fn_dirTo function actually converts Objects to positions..

_pos1 = _this select 0;
_pos2 = _this select 1;

//if objects, not positions, were passed in, then get their positions
if(typename _pos1 == "OBJECT") then {_pos1 = getpos _pos1};
if(typename _pos2 == "OBJECT") then {_pos2 = getpos _pos2};

Updated by Cuel about 3 years ago

Yeah sure. I'm just forwarding this bug from a friend. But I've seen the error pop up numerous times.

Just go 4x after pressing radio alpha.

Also available in: Atom PDF