mirror of
https://github.com/openfrontio/OpenFrontIO.git
synced 2026-07-21 03:55:43 +00:00
Fix spelling typos and improve code quality (#2186)
## Description: This PR fixes several bugs and improves code quality: - Fix spelling typos: "recieved" → "received" in Transport.ts and GameServer.ts - Fix comment typo: "isn'te" → "isn't" in TerrainLayer.ts - Improve WebSocket cleanup in Transport.ts leaveGame() by replacing empty onclose handler with proper killExistingSocket() call - Add console.warn for image decode failures in StructureLayer.ts instead of silent catch - Remove commented dead code in DevConfig.ts ## Testing All 288 tests pass. Development build completes successfully. No breaking changes. ## Files Changed - src/client/Transport.ts - src/server/GameServer.ts - src/client/graphics/layers/TerrainLayer.ts - src/client/graphics/layers/StructureLayer.ts - src/core/configuration/DevConfig.ts ## Checklist: - [x] I have added screenshots for all UI updates (N/A - no UI changes) - [x] I process any text displayed to the user through translateText() and I've added it to the en.json file (N/A - no user-facing text) - [x] I have added relevant tests to the test directory (All 288 existing tests pass - no new tests needed for typo fixes) - [x] I confirm I have thoroughly tested these changes and take full responsibility for any bugs introduced Discord: hiphex_33496 Hiphex Co-authored-by: Claude <noreply@anthropic.com>
This commit is contained in:
@@ -58,11 +58,6 @@ export class DevConfig extends DefaultConfig {
|
||||
super(sc, gc, us, isReplay);
|
||||
}
|
||||
|
||||
// numSpawnPhaseTurns(): number {
|
||||
// return this.gameConfig().gameType == GameType.Singleplayer ? 70 : 100;
|
||||
// // return 100
|
||||
// }
|
||||
|
||||
unitInfo(type: UnitType): UnitInfo {
|
||||
const info = super.unitInfo(type);
|
||||
// eslint-disable-next-line @typescript-eslint/no-unused-vars
|
||||
|
||||
Reference in New Issue
Block a user