Skip to content

Commit

Permalink
Merge pull request #316 from CBATeam/randPos2D
Browse files Browse the repository at this point in the history
fix CBA_fnc_randPos broken for 2D positions
  • Loading branch information
Killswitch00 committed Apr 24, 2016
2 parents c5d83d3 + 9ba0f40 commit f0b919d
Showing 1 changed file with 3 additions and 1 deletion.
4 changes: 3 additions & 1 deletion addons/common/fnc_randPos.sqf
Original file line number Diff line number Diff line change
Expand Up @@ -29,4 +29,6 @@ params [

private _position = _entity call CBA_fnc_getPos;

_position vectorAdd [_radius - 2 * random _radius, _radius - 2 * random _radius, 0]
_position set [0, (_position select 0) + (_radius - 2 * random _radius)];
_position set [1, (_position select 1) + (_radius - 2 * random _radius)];
_position

0 comments on commit f0b919d

Please sign in to comment.