Skip to content

Commit

Permalink
Update README.md
Browse files Browse the repository at this point in the history
  • Loading branch information
Owen3H authored Jun 24, 2024
1 parent 75ca0b2 commit 12fd6cb
Showing 1 changed file with 5 additions and 5 deletions.
10 changes: 5 additions & 5 deletions README.md
Original file line number Diff line number Diff line change
Expand Up @@ -51,8 +51,8 @@ const desc = `Type **/n spawn ${route.nation.name}** and head **${route.directio

To continously track a player, you can use the `track` method.
- First parameter (player name) is **required**, but case insensitive.
- Second parameter (interval) is optional. Defaults to 3000ms.
- Third parameter (route) is optional. Defaults to FASTEST.
- Second parameter (interval) is optional. Defaults to `3000` milliseconds.
- Third parameter (route) is optional. Defaults to `FASTEST`.
```ts
// Start tracking a player, with 5s delay, outputting the safest route.
const tracker = await Aurora.GPS.track("PlayerName", 5000, Routes.SAFEST).catch(e => {
Expand All @@ -61,14 +61,14 @@ const tracker = await Aurora.GPS.track("PlayerName", 5000, Routes.SAFEST).catch(

// Listen for any errors that may occur.
tracker.on('error', e => {
console.error("An error occurred: " + e);
console.error("An error occurred: " + e)
})

tracker.on('underground', (playerInfo) => {
console.log("Player went underground - " + playerInfo);
console.log("Player went underground - " + playerInfo)
})

tracker.on('locationUpdate', (routeInfo) => {
console.log("Player's location updated - " + routeInfo);
console.log("Player's location updated - " + routeInfo)
})
```

0 comments on commit 12fd6cb

Please sign in to comment.