point_array = collision_line_find_nearest_point(x1, y1, x2, y2, accuracy in pixels, solid object id, precise);
This script returns the position of a collision along a line using minimal collision checks.
An example project is included with a laser beam colliding against boxes.
The example project can accurately calculate the collision point in approximately 10 collision checks.
Added option to allow precise collision checking.
Example updated to show this.
Version 1.1.0. Published December 27, 2018
You can only review assets you've bought.
This review was left for a previous version of this asset.
Thank you for your review. Be sure to get version 1.1.0 for precise collision checks.