/// @param start_x
/// @param start_y
/// @param button
/// @param direction

var _xx = argument[0];
var _yy = argument[1];
var _button = argument[2];
var _dir = argument[3];

var _new = _button;

while(_new == _button) {
	_xx += lengthdir_x(10, _dir);
	_yy += lengthdir_y(10, _dir);
	sc_test(_xx, "/", _yy);
	if (_xx < 0 || _xx > WIN_WIDTH || _yy < 0 || _yy > WIN_HEIGHT)
		break;
	var _near = instance_nearest(_xx, _yy, obj_menu_par);
	if (_near == _button)
		continue;
	if (point_distance(_xx, _yy, _near.x, _near.y) < 100) {
		_new = _near;
		break;
	}
}
sc_test(_new);
return _new;