Commit graph

1981 commits

Author SHA1 Message Date
copilot-swe-agent[bot]
0a463f2380 Initial plan 2026-03-22 23:50:40 +00:00
copilot-swe-agent[bot]
10593749dd Update Yggdrasil auth config docs
Co-authored-by: milutinke <441903+milutinke@users.noreply.github.com>
Agent-Logs-Url: https://github.com/MCCTeam/Minecraft-Console-Client/sessions/9b1c26c4-240d-40de-be7b-ba1174f7e2bd
2026-03-22 23:44:46 +00:00
copilot-swe-agent[bot]
c82b6c844b Initial plan 2026-03-22 23:37:28 +00:00
Anon
3ee0177d62
Merge pull request #2963 from milutinke/authlib-injector-accounts 2026-03-23 00:21:34 +01:00
Anon
ff9aa62702 Add configurable authlib-injector API path and HTTP support for Yggdrasil auth
Re-implements the changes from PR #2890, adapted for the current codebase
which uses System.Text.Json.Nodes and HttpClient instead of the legacy
Json.JSONData and hand-rolled SslStream HTTP client.

Changes:
- Settings.cs: Convert AuthlibServer from struct to class with
  [TomlDoNotInlineObject]; convert Host to a property that parses
  'host:port' syntax; add AuthlibInjectorAPIPath (default '/api/yggdrasil')
  for servers that use a different prefix (e.g. Drasl uses '/authlib-injector');
  add UseHttps (default true) so local/dev auth servers without TLS work.

- ConfigComments.resx: Add descriptive inline comments for the new
  AuthlibServer fields (Host, Port, AuthlibInjectorAPIPath, UseHttps).

- ProtocolHandler.cs: Replace three hardcoded '/api/yggdrasil/...' paths
  with AuthlibInjectorAPIPath-based paths (authenticate, refresh, join).
  Replace hand-rolled TcpClient+SslStream HTTP in DoHTTPSRequest with
  HttpClient+SocketsHttpHandler (ConnectCallback routes through ProxyHandler).
  Add useHttps parameter so HTTP-only auth servers are supported.

- KeyUtils.cs: Add AuthServerSupportsProfileKeys() that fetches the
  authlib-injector metadata endpoint and checks feature.enable_profile_key.
  Update GetNewProfileKeys() to skip key fetch when the auth server does not
  support profile keys; build the cert URL dynamically using AuthlibInjectorAPIPath
  for Yggdrasil; always fetch real certs instead of returning a dummy response.
  Remove MakeDummyResponse() which is no longer needed.

Tested against a local Drasl instance with authlib-injector 1.2.7 on a
1.21.11 Minecraft server — full auth flow (login, profile key fetch, session
join) confirmed working end-to-end.

Co-authored-by: Copilot <223556219+Copilot@users.noreply.github.com>
2026-03-23 00:15:32 +01:00
Anon
72ec3122ae
Merge pull request #2961 from milutinke/update-json-http-client 2026-03-22 23:06:58 +01:00
Anon
6c9dcfd216
Merge pull request #2962 from MCCTeam/copilot/update-mcc-integration-testing 2026-03-22 23:04:02 +01:00
Anon
d44fc22c8a Fix offline Microsoft auth profile-key checks and complete status ping/pong during auto-version detection. 2026-03-22 22:19:59 +01:00
copilot-swe-agent[bot]
02873957a8 skill: update mcc-integration-testing to use tools/mcc-env.sh instead of ~/.zshrc
- Replace `source ~/.zshrc` with `source "$REPO_ROOT/tools/mcc-env.sh"` in
  ensure_offline_server.sh and run_full_spectrum_test.sh
- Convert both scripts from zsh to bash (#!/usr/bin/env bash) so mcc-env.sh
  can be sourced natively; replace ${0:A:h} with portable SCRIPT_DIR expansion
- Update SKILL.md: drop ~/.zshrc references, point to tools/mcc-env.sh and
  standalone tools/start-server.sh + tools/mc-rcon.sh; update server path
  from ~/Minecraft/Servers/ to MinecraftOfficial/downloads/; replace
  `mcc-build` with `dotnet build MinecraftClient.sln -c Release`
- Update evals.json expectation to match new workflow

Co-authored-by: milutinke <441903+milutinke@users.noreply.github.com>
Agent-Logs-Url: https://github.com/MCCTeam/Minecraft-Console-Client/sessions/1ff08b70-7be3-4211-9b77-a9e10ff1d157
2026-03-22 21:19:55 +00:00
copilot-swe-agent[bot]
07189509b0 Initial plan 2026-03-22 21:15:19 +00:00
Anon
af405e5632 Fixed Profile Component crashing on 1.21.9 2026-03-22 21:53:13 +01:00
Anon
5c39d3b83d
Merge pull request #12 from milutinke/master 2026-03-22 20:42:41 +01:00
Anon
5e99e3a42d
Merge pull request #11 from milutinke/copilot/update-json-http-client 2026-03-22 20:39:28 +01:00
Anon
757cbe1a68 Fix ParseJson crash on non-JSON plain-text input (e.g. vanilla MOTD)
When the MC server sends a plain-text string (not valid JSON) for fields like
the ServerData MOTD, JsonNode.Parse() throws JsonReaderException. This was a
regression introduced by the System.Text.Json modernization.

Fix: catch JsonException in ParseJson() and return JsonValue.Create(json) so
plain-text strings are treated as literal string values rather than crashing.

Tested against a real Minecraft 1.21.11 server (offline mode): MCC connects
and stays connected without crashing.

Co-authored-by: Copilot <223556219+Copilot@users.noreply.github.com>
2026-03-22 19:53:15 +01:00
copilot-swe-agent[bot]
d2c1cbf2a5 Fix Json.ParseJson crash on empty/null input
ParseJson now returns null for null, empty, or whitespace-only input
instead of throwing JsonReaderException. This matches the behavior of
the old hand-rolled parser and is needed because MC protocol packets
may contain empty strings where JSON text is expected (e.g. empty chat
messages in DeathCombatEvent packets).

Discovered during end-to-end testing against a Minecraft 1.21.11
protocol server.

Co-authored-by: milutinke <441903+milutinke@users.noreply.github.com>
Agent-Logs-Url: https://github.com/milutinke/Minecraft-Console-Client/sessions/34df723e-4a63-45a0-a942-e119d81a575b
2026-03-22 17:22:08 +00:00
copilot-swe-agent[bot]
64ccdcb39b Address code review feedback
- Replace GetAwaiter().GetResult() with synchronous ReadAsStream()
- Use JsonNode.DeepClone() instead of serialize/parse round-trip
- Extract timeout magic number to named constant

Co-authored-by: milutinke <441903+milutinke@users.noreply.github.com>
Agent-Logs-Url: https://github.com/milutinke/Minecraft-Console-Client/sessions/afcd1b7b-ea23-4a0d-bb46-a90b623406fc
2026-03-22 16:46:33 +00:00
copilot-swe-agent[bot]
37fe626325 Replace hand-rolled ProxiedWebRequest with HttpClient/SocketsHttpHandler
- Rewrite ProxiedWebRequest to use System.Net.Http.HttpClient internally
- Use SocketsHttpHandler with native SOCKS4/4a/5 and HTTP proxy support
- Remove 250+ lines of manual HTTP/1.1 parsing, chunked transfer, TLS pinning
- Proper TLS negotiation (no longer pinned to TLS 1.2)
- Remove unused ITcpFactory interface and isProxied flag
- Maintain same public API (Get(), Post(), Response class) for all consumers

Co-authored-by: milutinke <441903+milutinke@users.noreply.github.com>
Agent-Logs-Url: https://github.com/milutinke/Minecraft-Console-Client/sessions/afcd1b7b-ea23-4a0d-bb46-a90b623406fc
2026-03-22 16:44:35 +00:00
copilot-swe-agent[bot]
15aabd9423 Replace legacy custom JSON parser with System.Text.Json
- Rewrite Json.cs to use System.Text.Json.Nodes (JsonNode, JsonObject, JsonArray)
- Add JsonNodeExtensions.GetStringValue() for backward-compatible string access
- Update all 14 consumer files to use the new JsonNode API
- Remove ~300 lines of hand-rolled JSON parsing code from 2013
- Replace KeyUtils.EscapeString with delegation to Json.EscapeString

Co-authored-by: milutinke <441903+milutinke@users.noreply.github.com>
Agent-Logs-Url: https://github.com/milutinke/Minecraft-Console-Client/sessions/afcd1b7b-ea23-4a0d-bb46-a90b623406fc
2026-03-22 16:39:26 +00:00
Anon
f31ed82ce1
[skipci]Merge pull request #2960 from milutinke/ai-dev-workflow-docs 2026-03-22 17:33:42 +01:00
Anon
611951668e Updated documentation to use <details> tag, updated the AGENTS md 2026-03-22 17:31:41 +01:00
copilot-swe-agent[bot]
7893bd7fe4 Initial plan 2026-03-22 16:19:28 +00:00
Anon
d20b139215
[skipci]Merge pull request #2959 from milutinke/ai-dev-workflow-docs 2026-03-22 16:57:59 +01:00
Anon
dc50df3b94 Fixed documentation about configuration missmatch, updated to reflect the latest state. 2026-03-22 16:55:14 +01:00
Anon
9657ed91d2
[skipci]Merge pull request #2958 from MCCTeam/copilot/update-best-practices-for-csharp14 2026-03-22 16:52:58 +01:00
copilot-swe-agent[bot]
95fc0fd0f8 Update Modern Syntax range to C# 10-14 and add unbound generics nameof example
Co-authored-by: milutinke <441903+milutinke@users.noreply.github.com>
Agent-Logs-Url: https://github.com/MCCTeam/Minecraft-Console-Client/sessions/8cdef112-415b-4769-877d-61f0e7a300eb
2026-03-22 15:51:19 +00:00
copilot-swe-agent[bot]
4ac3601aa7 Fix British spelling 'Synchronisation' to American 'Synchronization' in collections table
Co-authored-by: milutinke <441903+milutinke@users.noreply.github.com>
Agent-Logs-Url: https://github.com/MCCTeam/Minecraft-Console-Client/sessions/8cdef112-415b-4769-877d-61f0e7a300eb
2026-03-22 15:49:05 +00:00
Anon
454ce331b2 Updated docs for Yggdrasil authlib multi-user selection and cleaned the code a bit 2026-03-22 16:48:38 +01:00
copilot-swe-agent[bot]
1e2847a48e Update csharp-best-practices skill from C# 12 / .NET 8 to C# 14 / .NET 10
Co-authored-by: milutinke <441903+milutinke@users.noreply.github.com>
Agent-Logs-Url: https://github.com/MCCTeam/Minecraft-Console-Client/sessions/8cdef112-415b-4769-877d-61f0e7a300eb
2026-03-22 15:48:20 +00:00
copilot-swe-agent[bot]
4d51282040 Initial plan 2026-03-22 15:44:10 +00:00
Anon
7162691b57 Added humanizer skill for Docs 2026-03-22 16:39:37 +01:00
Anon
4fb4c018e4
Merge pull request #2781 from a08381/authlib-multi-user 2026-03-22 16:36:20 +01:00
Anon
bdb561ed4a
Merge pull request #2957 from milutinke/ai-dev-workflow-docs 2026-03-22 16:32:09 +01:00
Anon
5c2c176ba1 Updated the latest version to: 26.1. Fixed Warning, Tip and info blocks not-rendering properly. Updated Physics section to be up to date. Fixed a formatting error on the Installation page. 2026-03-22 16:29:14 +01:00
Anon
535b95f4b9
Merge pull request #2956 from milutinke/ai-dev-workflow-docs 2026-03-22 16:09:02 +01:00
Anon
d95b6bb9eb Added links for skills 2026-03-22 16:04:45 +01:00
Anon
aa59c4d75a Updated the installation methods, updated creating bots. Removed Web Socket Bot pages. 2026-03-22 15:57:44 +01:00
Anon
e4aeb51f71 Updated documentation to the latest state 2026-03-22 15:40:05 +01:00
Anon
9613e0df51 Added AI Assisted development documentation. Updated Vuepress to the latest version. Added SEO and Sitemap plugins to Vuepress. 2026-03-22 14:29:02 +01:00
BruceChen
cffddb398e
Merge pull request #2955 from BruceChenQAQ/master
Add Minecraft 26.1 Support
2026-03-22 20:27:28 +08:00
BruceChen
d1837d104b feat: handle 26.1 protocol changes and snapshot version support
- Protocol18: add MC_26_1_Version constant (775), version-gated palette
  routing for blocks/items/entities/metadata, and new TimeUpdate packet
  format (WorldClock map replaces dayTime+tickDayTime)
- Protocol18Terrain: read new fluidCount short in chunk sections (26.1+)
- DataTypes: add CatSoundVariant to entity metadata VarInt readers
- ProtocolHandler: add NormalizeSnapshotProtocol() to map RC/snapshot
  protocol numbers (e.g. 0x4000012E → 775) to release versions, pass
  raw protocol version through for server handshake compatibility

Made-with: Cursor
2026-03-22 20:04:08 +08:00
BruceChen
d4014f7c87 feat: add 26.1 packet palette, structured components registry, and version routing
Add PacketPalette261 with new packet types (GameRuleValues, LowDiskSpaceWarning,
Attack, SetGameRule). Create StructuredComponentsRegistry261 with 6 new components
(additional_trade_cost, dye, pig/cow/chicken/cat sound_variant). Update version
routing in PacketType18Handler, EntityMetadataPalette, StructuredComponentsHandler,
and Program.cs to support protocol 775 (26.1).

Made-with: Cursor
2026-03-22 20:04:08 +08:00
BruceChen
e3d3a86ac2 feat: add 26.1 palette files and new enum values
Add item, block, entity, and entity metadata palettes for Minecraft 26.1.
New enums: GoldenDandelion (item/block), PottedGoldenDandelion (block),
CatSoundVariant, CowSoundVariant, PigSoundVariant, ChickenSoundVariant
(entity metadata). Update gen_entity_metadata_palette.py FIELD_TO_ENUM
mapping for the new sound variant types.

Made-with: Cursor
2026-03-22 20:04:08 +08:00
Anon
052993a2c1
Merge pull request #2954 from milutinke/mcc-gui-update 2026-03-22 12:49:14 +01:00
Anon
33fccf85b5 Added changes from 2927 2026-03-22 12:45:52 +01:00
breadbyte
d25f2f40ec
Update Github Actions to be more robust with releases (#2952)
* Update build-and-release.yml
2026-03-22 18:34:19 +08:00
BruceChen
397ab07d1f [skipci] docs: update MCC development workflow documentation
- Revised the SKILL.md file to enhance clarity and detail regarding the development workflow for Minecraft Console Client (MCC).
- Expanded sections on project structure, build commands, and debugging steps, including specific instructions for compiling, starting a test server, and running MCC.
- Added environment setup details and a checklist for server configuration, improving usability for developers.
- Included new tools and scripts for server management and decompilation processes, streamlining the development experience.

These updates provide comprehensive guidance for developers working with MCC in WSL.
2026-03-22 16:34:12 +08:00
BruceChen
3afbae4f89 fix: correct global state indexing in block shape processing
- Adjusted the indexing logic in BlockShapes.cs to ensure proper mapping of state counts to shape IDs.
- Introduced a global state offset to accurately reference shape IDs in the list, preventing out-of-bounds errors during shape assignment.

These changes enhance the reliability of block shape processing in the physics engine.
2026-03-22 16:34:12 +08:00
BruceChen
38e86eb209
Merge pull request #2953 from BruceChenQAQ/master
feat: implement physics engine for player movement and collision detection
2026-03-22 15:51:23 +08:00
BruceChen
e3a2593781 feat: add cursor indexing ignore rules for SpecStory files
- Introduced a new `.cursorindexingignore` file to prevent indexing of SpecStory auto-save files while allowing explicit context inclusion via @ references.
- Updated `.gitignore` to exclude the entire `.specstory/` directory and `.vscode/settings.json`, ensuring these files are not tracked by Git.

These changes help streamline project management by excluding unnecessary files from indexing and version control.
2026-03-22 15:30:42 +08:00
BruceChen
a3c918e946 feat: implement physics engine for player movement and collision detection
- Introduced a comprehensive physics engine that replicates Minecraft's movement mechanics, including player input handling, gravity, and collision detection.
- Added classes for player physics, movement input, and collision detection, ensuring accurate simulation of player interactions with the game world.
- Integrated AABB (Axis-Aligned Bounding Box) structures for precise collision detection against blocks.
- Enhanced movement capabilities with support for jumping, sneaking, and sprinting, along with step-up mechanics for navigating terrain.

These changes significantly improve the realism and responsiveness of player movement within the game environment.
2026-03-22 15:29:22 +08:00