Adjusting sling load point intersection test to not clip ground

Fixes #7
This commit is contained in:
sethduda 2016-07-08 15:44:36 -04:00 committed by GitHub
parent 17f945185f
commit a13e8f37de

View File

@ -73,7 +73,7 @@ ASL_Get_Sling_Load_Points = {
if(_la select 2 < 0 && _lb select 2 > 0) then {
_n = [0,0,1];
_p0 = [0,0,0];
_p0 = [0,0,0.1];
_l = (_la vectorFromTo _lb);
if((_l vectorDotProduct _n) != 0) then {
_d = ( ( _p0 vectorAdd ( _la vectorMultiply -1 ) ) vectorDotProduct _n ) / (_l vectorDotProduct _n);
@ -1166,4 +1166,4 @@ diag_log "Advanced Sling Loading Loaded";
if(isServer) then {
[] call ASL_Advanced_Sling_Loading_Install;
};
};