Commit graph

66 commits

Author SHA1 Message Date
CosminPerRam
5634d3cf15 fix: grammatic error in comment 2024-02-24 18:14:59 +02:00
CosminPerRam
b5c22141db feat: use another optional chaining 2024-02-24 18:14:28 +02:00
CosminPerRam
b1b41d6e24 fix: shortest RTT not registering properly 2024-02-24 18:06:15 +02:00
CosminPerRam
93245ace70 feat: check if a param is a promise with instanceof 2024-02-24 17:44:18 +02:00
CosminPerRam
0ec26540aa feat: transform some strings to literals 2024-02-23 03:28:01 +02:00
CosminPerRam
bb536749df feat: rework core protocol a bit 2024-02-23 03:20:39 +02:00
CosminPerRam
ec708d7219
feat: add query port to the results (#476) 2024-01-17 00:20:56 +02:00
CosminPerRam
cee42e7a88
chore: Convert all files to LF endings (#400)
* Convert to LF?

* Modify gitattributes

* Force LF

* Git --renormalize

* Update .gitattributes to enforce eol=lf

* Redo CRLF -> LF on remaining files
2023-11-12 13:14:43 +02:00
CosminPerRam
5c4a7327b0 Remove dynamic import of got 2023-10-14 19:34:44 +03:00
Tom
01794f6339
Add support for running using deno (#362)
* Add missing CRLF line ending

* Add support for running using deno

Prefix node imports with "node:" and gate a socket API that is not
implemented in [deno](https://deno.land) so that the library can be used
there. This should not break node and doesn't in my brief testing.
2023-10-10 12:25:57 +03:00
CosminPerRam
93a9095d99
Add eslint (#364)
* Add initial prettier and eslint configs

* Modify prettierrc

* Run eslint on everything

* Actually remove prettier

* Fix some eslints

* Remove label in gs2

* Update CHANGELOG

* Update eslintrc to specify es2021
2023-09-19 19:52:35 +03:00
CosminPerRam
bff9507189 Replace use of deprecated internal debugLog with logger.debug 2023-09-18 10:48:24 +03:00
CosminPerRam
ad9adff06c
Move to ES6 module (#357)
* Redo imports and exports for lib

* Redo imports and exports for bim

* Redo imports and exports for games

* Remove remaining module.exports

* Use export default in lib

* Use export default in protocols

* Fix import in genreadme.js

* Make package module and solve __dirname

* Fix minecraft protocol imports

* Fix imports on games and make binary runnable

* Renamed protocol class exports to lowercase

* Export promises class as default

* Update README.md to use imports instead of require

* Update CHANGELOG to mention the changes.

* Remove Valve unused imports

* Fix iconv import
2023-09-14 23:28:31 +03:00
cetteup
3c38fe48fe feat: Allow direct control of IP family to be returned by DNS lookup
implements #306
2022-12-13 10:46:43 +01:00
Michael Morrison
c7a669ce6b Update got, which now requires node 14 2022-02-05 20:10:14 -06:00
Michael Morrison
ce4e728493 Add support for udp bind port override (3.0.5) Fixes #149 2021-05-18 23:13:18 -05:00
Michael Morrison
fe124a4487 Bring discord protocol up to date with gamedig 3.0 2021-05-18 22:33:36 -05:00
Michael Morrison
f70112d092 * Properly handle non-indexed team names in gamespy1 Fixes #213
* Rename raw.steamappid and raw.gameid to raw.appId in steam protocol
* Don't query valve rules by default, unless requestRules option is set Fixes #176
2021-02-25 01:58:35 -06:00
Michael Morrison
052736edd7 Reduced chance of protocol collisions between gamespy3 and minecraftbedrock (2.0.27) 2021-02-12 11:36:51 -06:00
Michael Morrison
487b17dd73 Swap from request to got 2020-07-04 23:28:03 -05:00
mmorrison
62723d85f0 Cherry-picked: Reject only with Error instead of Object or String Fixes #132 2019-10-15 14:47:22 -05:00
mmorrison
f0a24b8f65 Use @types/node@8.0.0 to validate (and fix) small node 8 api issues 2019-02-19 21:15:34 -06:00
mmorrison
dd5dce21db Improve multi-attempt logging 2019-02-13 22:46:13 -06:00
mmorrison
2ffeda6098 Improve starmade protocol 2019-02-05 03:19:06 -06:00
mmorrison
81750805f6 Add support for rFactor (2.0.10) 2019-02-04 01:11:28 -06:00
mmorrison
94c263669d Improve packet ordering and deduplication of players from gamespy1 protocol 2019-01-22 00:11:39 -06:00
mmorrison
2a87360a0e Minor debug logging improvements 2019-01-20 04:21:40 -06:00
mmorrison
9a536b160e Prevent tcp socket errors from dumping straight to console (2.0.7) 2019-01-20 03:52:40 -06:00
mmorrison
05619469b7 Add punycode support (2.0.6) 2019-01-20 03:45:57 -06:00
mmorrison
5aaff8e1e0 Added support for cs2d (2.0.5) 2019-01-13 23:54:36 -06:00
mmorrison
dfa5c95efc Remove callback support and global Gamedig.debug option 2019-01-12 22:38:49 -06:00
mmorrison
fdc08b5c09 Finalized 2.0 release notes 2019-01-12 22:22:26 -06:00
mmorrison
6496660633 Add ping field, start improving README for 2.0 2019-01-12 21:32:24 -06:00
mmorrison
e937c725bb More async 2019-01-12 05:45:09 -06:00
mmorrison
29ce0b82d0 Additional async rewrite 2019-01-12 04:43:36 -06:00
mmorrison
efe12a00aa More async conversion 2019-01-10 22:20:56 -06:00
mmorrison
484e99b29c Improve logging 2019-01-09 05:50:30 -06:00
mmorrison
9b8423b20a More async conversions 2019-01-09 05:35:11 -06:00
mmorrison
77b2cc1c7f Initial es6 async conversion work 2019-01-07 00:52:29 -06:00
mmorrison
8b3126e430 Use win1252 character encoding for samp (1.0.48) Fixes #99 2019-01-06 14:10:46 -06:00
mmorrison
ab4436d4cb Increase default timeout to 2000ms to align with steam server browser and allow for better compatibility with bad connections. 2018-11-11 06:13:31 -06:00
mmorrison
b5f49fe343 Add socketTimeout and attemptTimeout 2018-01-31 04:03:13 -06:00
mmorrison
3a96e00508 Put query duration into the unstable query object 2018-01-31 00:47:09 -06:00
mmorrison
94815a247d Switch maxAttempts from a query param to an option Fixes #73 2018-01-31 00:41:57 -06:00
mmorrison
2cf975b9f6 Add query duration Fixes #76 2018-01-31 00:34:11 -06:00
mmorrison
4c18b6a3fd Add support for FiveM closes #55 2017-08-10 06:49:42 -05:00
mmorrison
c0548fb886 Minor cleanup to satisfy code inspection 2017-08-09 05:41:30 -05:00
mmorrison
3674d384d0 Convert tabs to spaces 2017-08-09 05:32:09 -05:00
mmorrison
b015d58a0a Fixes for ase, geneshift, minecraftping, and quake 2 arising from cleanup 2017-08-09 05:04:32 -05:00
mmorrison
69288baebc Upgrade syntax of everything to more modern javascript 2017-08-09 04:05:55 -05:00