2,733
edits
Red Leader (talk | contribs) (Save) |
Red Leader (talk | contribs) (Finish course_to()) |
||
Line 238: | Line 238: | ||
|syntax = geo.Coord.course_to(coord); | |syntax = geo.Coord.course_to(coord); | ||
|source = {{fgdata file|Nasal/geo.nas|t=Source}} | |source = {{fgdata file|Nasal/geo.nas|t=Source}} | ||
|text = Returns the initial bearing to another <code>geo.Coord</code> instance. | |text = Returns the initial bearing (see [http://www.movable-type.co.uk/scripts/latlong.html#bearing here]) to another <code>geo.Coord</code> instance. The bearing will be in the range 0–360. | ||
|example1 = | |example1 = var c1 = geo.Coord.new(); | ||
c1.set_latlon(0, 0); | |||
var c2 = geo.Coord.new(); | |||
c2.set_latlon(1, 1); | |||
printf("%.5f", c1.course_to(c2)); # prints "44.99564" | |||
}} | }} | ||
=== PositionedSearch === | === PositionedSearch === |