function [stopvalue, isterminal, direction] = Skydive3Event(t,y,g,c,m,R)

% find when the altitude, i.e., y(1), is zero and stop

stopvalue = y(1);   % the value we want to make zero
isterminal = 1;     % stop when stopvalue is zero
direction = [];     % direction from which we approach zero doesn't matter
