Difference between revisions of "Gps (API)"

From ComputerCraft Wiki
Jump to: navigation, search
(Page creation)
 
m (Added examples of rednet entities)
Line 1: Line 1:
The gps API provides a method to locate a connected [[Rednet_(API)|rednet]] entity.
+
The gps API provides a method to locate a connected [[Rednet_(API)|rednet]] entity (like a turtle or a computer).
  
  

Revision as of 18:34, 14 March 2012

The gps API provides a method to locate a connected rednet entity (like a turtle or a computer).


Method name Description
gps.locate(timeout, debug) Tries to locate any connected rednet entity.

@param timeout the amount of time, in seconds, to wait for a rednet response
@param debug if true, outputs debug messages
@return the location of the connected rednet entity (x, y and z) or nil if it could not be determined