Skip to content

Conversation

@LakeYS
Copy link
Owner

@LakeYS LakeYS commented Jan 18, 2025

This is a behind-the-scenes modernization and patch-up for 2025.

  • Updated to discord.js 14.
  • Migrated code from CommonJS to ESM.
  • Replaced telnet-client with a custom provider using Net.Socket to connect to the game.
  • Replaced variable declarations to use 'let' and 'const'.
  • Rewrote regex expressions for clarity.
  • Replaced the outdated ESLint config, add the used ESLint version as a dev dependency,

Lake and others added 11 commits September 29, 2024 18:07
- Update regex and logic to support version 1.0 of the game.
- Use a single regex string to capture both chat and GMSG strings instead of separately handling both.
- To handle the lack of player names in message IDs, maintain an index of entity IDs to player names. Update this on startup with the 'lpi' command and whenever new players join through the 'PlayerSpawnedInWorld' message.
Bring variable definitions up to modern times. Removes ambiguity over
which variables are reassigned.
* Update telnet-client to 2.2.1. Fixes issues with message spam due to
  the client sending repeated data.
* Update ws to clear vulnerability
Fix the 'unknown player' warning erroneously being logged every time a
GMSG is sent.
Fix command errors due to const in a for loop.
Revert the workaround for player names as the new updates no-longer need
this.
@LakeYS LakeYS self-assigned this Jan 18, 2025
Lake and others added 4 commits January 17, 2025 22:10
* Migrate from CommonJS to ESM.
* Clean up DemoClient class definitions and exports.
* Use default exports for lib/ scripts.
* Drop support for running without semver-compare for now.
Replace the telnet-client package with a custom provider using the
Node.js Net API. Remove handling designed to work around the quirks in
the telnet-client package.
@LakeYS LakeYS marked this pull request as draft April 27, 2025 14:47
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

2 participants