diff options
author | Julien Dessaux | 2023-06-06 23:45:25 +0200 |
---|---|---|
committer | Julien Dessaux | 2023-06-06 23:45:25 +0200 |
commit | 458d08626f338c91a3bc14654bfeb9ca00c412cf (patch) | |
tree | a1ff1251e3046c6560456df27f1d0d62b37f3923 /lib/ships.js | |
parent | Hold back on maintenance or rate limiting events (diff) | |
download | spacetraders-458d08626f338c91a3bc14654bfeb9ca00c412cf.tar.gz spacetraders-458d08626f338c91a3bc14654bfeb9ca00c412cf.tar.bz2 spacetraders-458d08626f338c91a3bc14654bfeb9ca00c412cf.zip |
Update ships status at the end of the nav cooldown
Diffstat (limited to '')
-rw-r--r-- | lib/ships.js | 2 |
1 files changed, 2 insertions, 0 deletions
diff --git a/lib/ships.js b/lib/ships.js index 23f272d..c1bba08 100644 --- a/lib/ships.js +++ b/lib/ships.js @@ -61,6 +61,8 @@ export async function navigate(ctx) { dbShips.setShipNav(ctx.symbol, response.data.nav); const delay = new Date(response.data.nav.route.arrival) - new Date(); await api.sleep(delay); + response.data.nav.status = 'IN_ORBIT'; + dbShips.setShipNav(ctx.symbol, response.data.nav); return response; } |