# aeternum-map-realtime

> Client library for Aeternum Map's live location sharing

Latest version **0.3.0** (published 2023-01-08) · MIT license · 0 weekly downloads

## Install

```sh
npm install aeternum-map-realtime
pnpm add aeternum-map-realtime
yarn add aeternum-map-realtime
bun add aeternum-map-realtime
```

## Health

**Score 25/100 (F)** — status: abandoned.

Positive: has types; esm support; no vulnerabilities.

Warnings: low downloads; pre 1.0.

Negative: abandoned; low maintenance score.

## Facts

| | |
|---|---|
| Version | 0.3.0 |
| Published | 2023-01-08 |
| First published | 2022-09-17 |
| Weekly downloads | 0 |
| License | MIT |
| TypeScript types | bundled |
| Module format | ESM + CommonJS |
| Dependencies | 2 |
| Unpacked size | 6 KB |
| Known vulnerabilities | 0 |
| Install scripts | no |
| Author | Leon Machens |
| Maintainers | lmachens |

## Links

- npm: https://www.npmjs.com/package/aeternum-map-realtime
- npm.io page: https://npm.io/package/aeternum-map-realtime

## Dependencies (2)

- [peerjs](https://npm.io/package/peerjs.md) 1.4.7
- [socket.io-client](https://npm.io/package/socket.io-client.md) 4.5.4

## Recent versions

- 0.3.0 (latest) — 2023-01-08
- 0.2.0 — 2022-11-12
- 0.1.0 — 2022-10-29
- 0.0.0 — 2022-09-17

## README

# aeternum-map-realtime

Client library for Aeternum Map's live location sharing

## Install

```shell
npm install aeternum-map-realtime
```

## Usage

See [StackBlitz](https://stackblitz.com/edit/aeternum-map-realtime?file=src%2Fmain.ts) for an example.

```js
import { servers, init } from 'aeternum-map-realtime';

// `servers` is an array of all available servers
const europeServer = servers.find((server) => server.name === 'Europe');

const { destroy } = init({
  // Select one of the official servers or run your own
  serverUrl: europeServer.url,
  // You generate this token in the Overwolf app
  token: 'TOKEN_FROM_OVERWOLF_APP',
  // Fired, on start and everytime a user is joined or left
  onGroup: (group) => console.log(group),
  // Includes updates for a player
  onPlayer: (partialPlayer) => console.log(partialPlayer),
  // Fired, if a player uses an hotkey in-game
  onHotkey: (steamId, hotkey) => console.log(steamId, hotkey),
  // The connection to the server established
  onConnect: () => console.log('Connected'),
});

// Call `destory` if you like to end the connection
destroy();
```

## Aeternum Map

Aeternum Map is a New World map companion, available on https://www.overwolf.com/app/Leon_Machens-Aeternum_Map and https://aeternum-map.gg.

## License

MIT

---
_Source: https://npm.io/package/aeternum-map-realtime · Machine-readable twin of the npm.io package page. Health data is recomputed on every publish._
