Jump to content

  • Log In with Google      Sign In   
  • Create Account


#ActualParadigm Shifter

Posted 05 January 2013 - 03:49 PM

No it isn't. His mistake last time was adding an amount on to the FOV (potentially going above 180 degrees/PI radians) when he should have been dividing the FOV by a factor (multiplying by a value between 0 and 1).

Are you casting a ray backwards from the desired hit point? Because that sounds backwards to me, you need to fire a ray from the weapon muzzle along the direction from the muzzle to the desired hit point, and if you want to limit the range you need to normalise the fire direction and scale it by the max range for the weapon.

#1Paradigm Shifter

Posted 05 January 2013 - 03:49 PM

No it isn't. His mistake last time was adding an amount on to the FOV (potentially going above 180 degrees/PI radians) when he should have been dividing the FOV by a factor (multiplying by a value between 0 and 1).<br /><br />Are you casting a ray backwards from the desired hit point? Because that sounds backwards to me, you need to fire a ray from the weapon muzzle along the direction from the muzzle to the desired hit point, and if you want to limit the range you need to normalise the fire direction and scale it by the max range for the weapon.

PARTNERS