diff --git a/README.md b/README.md index 597247e..756576c 100644 --- a/README.md +++ b/README.md @@ -13,11 +13,20 @@ MorriCraft is a high-performance voxel engine built with C++ and Raylib. It feat ## Version History -### v2.0.7 - Collaborative Polish (Latest) +### v2.0.9 - Identity Update (Latest) +* **Humanoid Player Models**: Replaced placeholder "blue blobs" with multi-cube humanoid shapes (Head, Body, Arms, Legs). +* **Chat Input Isolation**: All movement (WASD, Space) and action keys are now fully inhibited while the chat box is active. +* **Visual Polish**: Adjusted nameplate positioning for better clarity with the new player models. + +### v2.0.8 - Real Update & LAN +* **Real Update System**: Implemented live file download via `curl` for seamless client updates. +* **Open to LAN**: Added a button to the Pause menu to host a world session instantly. +* **UI Fixes**: Corrected the main menu "Connect" button navigation. + +### v2.0.7 - Collaborative Polish * **Streamlined Multiplayer UI**: Relocated all networking settings to a dedicated "Join Server" screen. -* **Fresh Start Survival**: Players now start in new worlds with an empty inventory for a true survival experience. -* **Full System Updater**: Overhauled the updater to handle comprehensive file replacement with a mandatory restart prompt. -* **UI/UX Refinement**: Optimized menu flows and inhibited inventory toggle during active chat. +* **Fresh Start Survival**: Players now start in new worlds with an empty inventory. +* **Full System Updater**: Overhauled the updater to handle comprehensive file replacement. ### v2.0.6 - World Sync & Visibility Hardening * **Host-Side ID Tracking**: Fixed a critical bug where the host could not see connected clients. diff --git a/build-linux/MorriCraft b/build-linux/MorriCraft index 531d185..ceb189a 100755 Binary files a/build-linux/MorriCraft and b/build-linux/MorriCraft differ diff --git a/build-linux/assets/version.txt b/build-linux/assets/version.txt index d8ba80f..c03bb3d 100644 --- a/build-linux/assets/version.txt +++ b/build-linux/assets/version.txt @@ -1 +1 @@ -v2.0.7 +v2.0.9 diff --git a/build-windows/MorriCraft.exe b/build-windows/MorriCraft.exe index 617ec76..8f46291 100755 Binary files a/build-windows/MorriCraft.exe and b/build-windows/MorriCraft.exe differ diff --git a/build-windows/assets/version.txt b/build-windows/assets/version.txt index d8ba80f..c03bb3d 100644 --- a/build-windows/assets/version.txt +++ b/build-windows/assets/version.txt @@ -1 +1 @@ -v2.0.7 +v2.0.9 diff --git a/src/main.cpp b/src/main.cpp index 9e829c5..d256ac2 100644 --- a/src/main.cpp +++ b/src/main.cpp @@ -775,7 +775,7 @@ int main(void) // By default, windows have minimize, maximize, and close buttons on the top bar. SetConfigFlags(FLAG_WINDOW_RESIZABLE | FLAG_VSYNC_HINT); - InitWindow(screenWidth, screenHeight, "MorriCraft v2.0.8"); + InitWindow(screenWidth, screenHeight, "MorriCraft v2.0.9"); LoadConfig(); SetExitKey(KEY_NULL); // Prevent ESC from closing the window @@ -1369,7 +1369,7 @@ int main(void) Vector3 oldPos = camera3D.position; Vector3 moveVec = { 0, 0, 0 }; - if (!inventoryOpen) { + if (!inventoryOpen && !isChatting) { if (IsKeyDown(KEY_W)) moveVec = Vector3Add(moveVec, forward); if (IsKeyDown(KEY_S)) moveVec = Vector3Subtract(moveVec, forward); if (IsKeyDown(KEY_A)) moveVec = Vector3Add(moveVec, right); @@ -1397,7 +1397,7 @@ int main(void) camera3D.position.y = expectedFeetY + 1.6f + 0.01f; // Jump - if (IsKeyPressed(KEY_SPACE) && !inventoryOpen) { + if (IsKeyPressed(KEY_SPACE) && !inventoryOpen && !isChatting) { playerVelocityY = 8.5f; isGrounded = false; } else { @@ -1440,7 +1440,7 @@ int main(void) // Block Raycasting (moved outside to update every frame for wireframe) hitBlock = false; - if (!inventoryOpen) { + if (!inventoryOpen && !isChatting) { Ray ray = GetMouseRay((Vector2){ (float)currentWidth / 2, (float)currentHeight / 2 }, camera3D); float closestDist = 8.0f; @@ -1795,8 +1795,8 @@ int main(void) DrawTexturePro(titleTexture, sourceRec, destRec, origin, 0.0f, WHITE); EndMode2D(); - // Show Version Number (v2.0.8) in Red - DrawTextEx(customFont, "v2.0.8", (Vector2){ (float)currentWidth - 140, (float)currentHeight - 40 }, 22, 1.0f, RED); + // Show Version Number (v2.0.9) in Red + DrawTextEx(customFont, "v2.0.9", (Vector2){ (float)currentWidth - 140, (float)currentHeight - 40 }, 22, 1.0f, RED); // --- PLAYER NAME POPUP (IF MISSING) --- if (playerName == "") { @@ -2338,9 +2338,25 @@ int main(void) // --- DRAW REMOTE PLAYERS --- for (const auto& rp : remotePlayers) { - DrawCapsule(rp.position, (Vector3){ rp.position.x, rp.position.y + 1.8f, rp.position.z }, 0.4f, 8, 8, BLUE); + rlPushMatrix(); + rlTranslatef(rp.position.x, rp.position.y, rp.position.z); + rlRotatef(rp.yaw * 180.0f/PI, 0, 1, 0); + + // Simple Humanoid Shape (Cube-based "Skin") + // Body + DrawCube((Vector3){0, 0.7f, 0}, 0.6f, 0.9f, 0.3f, BLUE); + // Head + DrawCube((Vector3){0, 1.4f, 0}, 0.45f, 0.45f, 0.45f, (Color){220, 180, 150, 255}); + // Arms + DrawCube((Vector3){-0.45f, 0.7f, 0}, 0.2f, 0.8f, 0.2f, (Color){200, 160, 130, 255}); + DrawCube((Vector3){0.45f, 0.7f, 0}, 0.2f, 0.8f, 0.2f, (Color){200, 160, 130, 255}); + // Legs + DrawCube((Vector3){-0.15f, 0.15f, 0}, 0.25f, 0.4f, 0.25f, DARKBLUE); + DrawCube((Vector3){0.15f, 0.15f, 0}, 0.25f, 0.4f, 0.25f, DARKBLUE); + rlPopMatrix(); + // Draw Nameplate - Vector2 namePos = GetWorldToScreen((Vector3){ rp.position.x, rp.position.y + 2.2f, rp.position.z }, camera3D); + Vector2 namePos = GetWorldToScreen((Vector3){ rp.position.x, rp.position.y + 1.8f, rp.position.z }, camera3D); DrawTextEx(customFont, rp.name.c_str(), (Vector2){ namePos.x - MeasureTextEx(customFont, rp.name.c_str(), 20, 1.0f).x/2, namePos.y }, 20, 1.0f, WHITE); } diff --git a/version.txt b/version.txt index d8ba80f..c03bb3d 100644 --- a/version.txt +++ b/version.txt @@ -1 +1 @@ -v2.0.7 +v2.0.9