Compare commits
54 Commits
| Author | SHA1 | Date |
|---|---|---|
|
|
c09704151c | |
|
|
0a142d0713 | |
|
|
3c6acb866a | |
|
|
28c674c19b | |
|
|
4b915379e8 | |
|
|
7c001ef8cc | |
|
|
f0b8d2f3db | |
|
|
d8781b0211 | |
|
|
a16868c8b1 | |
|
|
3207c2d991 | |
|
|
87453dcd15 | |
|
|
a9a8d853b8 | |
|
|
8880cf7d4b | |
|
|
da08a68875 | |
|
|
78ea9a4503 | |
|
|
f2875dcdf7 | |
|
|
d5b58fd2fd | |
|
|
a2c7bacc94 | |
|
|
7c136d758f | |
|
|
cbe650009c | |
|
|
d96c97df26 | |
|
|
78bbf35bd3 | |
|
|
90d6b3c6f1 | |
|
|
0dc7a18aaf | |
|
|
4e8bc59eeb | |
|
|
5530a1a58c | |
|
|
9c302e4154 | |
|
|
0278668eab | |
|
|
8d65e549b2 | |
|
|
1d67db9e79 | |
|
|
b2cadb2aaa | |
|
|
091cfab86f | |
|
|
1a1cf3cc5f | |
|
|
910e2d6a6e | |
|
|
b200e9e07f | |
|
|
63c496d237 | |
|
|
236f66aa2a | |
|
|
d04256a56c | |
|
|
b2a36a249b | |
|
|
2114e50a9f | |
|
|
00cbe915d2 | |
|
|
d91ad97868 | |
|
|
d8f80b9248 | |
|
|
f169322dc0 | |
|
|
2bdfbd9fbc | |
|
|
23f941247d | |
|
|
ed11185fe3 | |
|
|
8983f05b2a | |
|
|
de7c60d9d7 | |
|
|
be2148a415 | |
|
|
69ba3372f6 | |
|
|
70b417b87c | |
|
|
fbf45cc41c | |
|
|
446e9ae771 |
|
|
@ -12,3 +12,4 @@ build-windows/*
|
||||||
!build-linux/assets/
|
!build-linux/assets/
|
||||||
!build-windows/MorriCraft.exe
|
!build-windows/MorriCraft.exe
|
||||||
!build-windows/assets/
|
!build-windows/assets/
|
||||||
|
!build-windows/MorriCraft-Windows.zip
|
||||||
|
|
|
||||||
|
|
@ -20,6 +20,7 @@ add_executable(MorriCraft src/main.cpp)
|
||||||
target_link_libraries(MorriCraft PRIVATE raylib)
|
target_link_libraries(MorriCraft PRIVATE raylib)
|
||||||
if(WIN32)
|
if(WIN32)
|
||||||
target_link_libraries(MorriCraft PRIVATE ws2_32)
|
target_link_libraries(MorriCraft PRIVATE ws2_32)
|
||||||
|
target_link_options(MorriCraft PRIVATE -static-libgcc -static-libstdc++ -static)
|
||||||
endif()
|
endif()
|
||||||
|
|
||||||
# Copy assets to build directory
|
# Copy assets to build directory
|
||||||
|
|
|
||||||
251
README.md
|
|
@ -1,103 +1,192 @@
|
||||||
# MorriCraft
|
# 🟦 MorriCraft
|
||||||
|
|
||||||

|

|
||||||
|
|
||||||
MorriCraft is a high-performance voxel engine built with C++ and Raylib. It features a custom physics engine, dynamic world generation, and an interactive inventory and crafting system.
|
**MorriCraft** is a high-performance, multiplayer-ready voxel engine built from the ground up using **C++** and **Raylib**. Inspired by classic survival games, it features a custom physics engine, real-time world synchronization, and a deep crafting system.
|
||||||
|
|
||||||
## Features
|
---
|
||||||
- **Custom Physics**: Stable "Ground-Lock" system prevents camera jitter and ensures smooth movement.
|
|
||||||
- **Dynamic World Generation**: Multi-octave Perlin noise (FBM) for realistic terrain, including biomes like grass, sand, and forests.
|
|
||||||
- **Advanced Crafting**: Includes both a 2x2 player inventory grid and a 3x3 workbench system.
|
|
||||||
- **Optimized Rendering**: Texture batching and neighbor-chunk caching for stable 60+ FPS.
|
|
||||||
- **Cross-Platform**: Builds for both Linux and Windows.
|
|
||||||
|
|
||||||
## Version History
|
## 🌟 Key Features
|
||||||
|
|
||||||
### v2.0.2 - The Social & Sync Update (Latest)
|
### ⚔️ Combat & Survival
|
||||||
* **Integrated Chat System**: Press `Enter` to open the chat box and communicate with other players in real-time.
|
- **PvP Combat**: Real-time melee combat with synchronized hit registration, knockback, and audio feedback.
|
||||||
* **Player Notifications**: Added automated alerts for players joining or leaving the session.
|
- **Health System**: 8-heart health system with a visual HUD and damage mechanics.
|
||||||
* **Multi-Player Visibility**: Fixed player tracking to ensure all peers are correctly identified and rendered for all clients.
|
- **Survival Mechanics**: Block-breaking progress and material-specific dig times.
|
||||||
* **Handshake Optimization**: Host now pushes seed, time, and existing player states instantly upon connection.
|
|
||||||
* **Update Integrity**: Fixed the auto-update system to correctly write version files after a successful download.
|
|
||||||
|
|
||||||
### v2.0.1 - World State Synchronization
|
### 👥 Multiplayer & LAN
|
||||||
* **Real-Time Block Sync**: Introduced `NetSetBlock` to synchronize all mining and placement actions across peers.
|
- **P2P Architecture**: Cross-platform networking stack using standard sockets (Windows/Linux).
|
||||||
* **Time Sync**: Host acts as the master clock, ensuring identical day/night cycles for everyone.
|
- **Instant LAN Hosting**: Host your world with a single click from the pause menu.
|
||||||
* **Seed Sync**: Corrected world generation so that clients automatically adopt the host's seed.
|
- **Skin Personalization**: Built-in skin editor to customize your character's shirt and pants, fully synchronized across the network.
|
||||||
|
- **Global Chat**: Press `Enter` to communicate with other players in real-time.
|
||||||
|
|
||||||
### v2.0.0 - The Multiplayer Milestone
|
### 🔨 Crafting & Inventory
|
||||||
* **P2P Architecture**: Implemented a cross-platform peer-to-peer networking stack using standard sockets.
|
- **20+ Recipes**: Full crafting tree from logs to tools — wooden & stone tier tools, furnace, chest, doors, fences, ladders, and more.
|
||||||
* **Direct Connect**: Added the ability to join servers via IP and Port from the main menu.
|
- **Dual Crafting Modes**: 2×2 player inventory grid and 3×3 Workbench with pattern matching.
|
||||||
* **Remote Avatars**: Introduced 3D representation for other players with dynamic floating nameplates.
|
- **Smart Stacking**: Left-click merges same-type stacks, right-click picks up or places one item at a time.
|
||||||
* **Server Mode**: Integrated a non-blocking host listener into the standard world generation flow.
|
- **Inventory Tooltips**: Hover over any item to see its name.
|
||||||
|
|
||||||
### v1.9.1 - The Connectivity & Polish Update
|
### 🌲 World & Visuals
|
||||||
* **Persistent Configuration**: Added `config.cfg` to save player preferences and identity.
|
- **Multi-Texture Blocks**: Oak logs render with bark sides and ringed tops/bottoms. Grass has separate top/side/bottom faces.
|
||||||
* **Player Identity**: Implemented a required name-entry sequence on first launch.
|
- **High-Detail Foliage**: Custom leaf textures with natural green tinting.
|
||||||
* **Auto-Update System**: Integrated version-checking, update notes viewer, and download progress simulation.
|
- **Dynamic Lighting**: Full day/night cycle with atmospheric color shifts.
|
||||||
* **Multiplayer Preparation**: Added Server Mode toggle and Direct Connect interface foundation.
|
- **Optimized Rendering**: Texture batching, neighbor-chunk caching, and frustum culling for 60+ FPS.
|
||||||
* **Performance Fixes**: Resolved edge-case frustum culling artifacts.
|
|
||||||
* **Audio Refinement**: Fixed music transitions between menus and gameplay states.
|
|
||||||
* **UI Polish**: Optimized layout for the Options and Main Menu screens.
|
|
||||||
|
|
||||||
### v1.6.6 (Latest)
|
### ⚙️ Technical
|
||||||
- **Tool Scaling**: Increased the size of held items (Axes/Sticks) in first-person for better visibility.
|
- **Dynamic World Gen**: Multi-octave Perlin noise (FBM) with forests, sand beaches, and ore veins.
|
||||||
- **Custom Assets**: Integrated a high-detail community wooden axe asset.
|
- **Cross-Platform**: Standalone binaries for Windows and Linux with zero external DLL dependencies.
|
||||||
- **Visual Polish**: Improved the viewmodel orientation and stability.
|
- **Auto-Update System**: Built-in version checking and download support.
|
||||||
|
|
||||||
### v1.6.5
|
---
|
||||||
- **Audio Optimization**: Implemented a rapid-crossfade system for cleaner day/night music transitions.
|
|
||||||
- **UI Bug Fixes**: Resolved music state issues when entering the Options and Crafting menus.
|
|
||||||
|
|
||||||
### v1.6.4
|
## 🚀 Getting Started
|
||||||
- **Immersive Audio**: Added material-specific digging sounds (Grass, Wood, Stone, Sand).
|
|
||||||
- **Viewmodel Overhaul**: Held blocks are now rendered as 3D textured cubes instead of white boxes.
|
|
||||||
- **Audio Sync**: Tied digging sounds to mining progress for better tactile feedback.
|
|
||||||
|
|
||||||
### v1.6.3
|
### Prerequisites
|
||||||
|
- **Linux**: `libpulse-dev`, `glfw` development headers.
|
||||||
|
- **Windows**: Download the pre-built zip from Releases, or cross-compile with MinGW-w64.
|
||||||
|
|
||||||
### v1.5.2
|
### Build Instructions
|
||||||
- **Stability Fixes**: Resolved texture corruption and state-management bugs with workstations.
|
|
||||||
- **In-Game Clock**: Added a 12-hour AM/PM HUD clock and day/night status indicator.
|
|
||||||
- **Lighting Engine**: Implemented a global day/night cycle (300s) with dynamic sun/moon and world tinting.
|
|
||||||
|
|
||||||
### v1.4.2
|
#### 🐧 Linux
|
||||||
- **UI Redesign**: Overhauled the inventory and crafting windows to match the classic Minecraft layout.
|
```bash
|
||||||
- **Character Preview**: Added a player preview placeholder in the inventory.
|
mkdir build-linux && cd build-linux
|
||||||
- **Centered Layout**: All UI grids are now symmetrically centered.
|
cmake ..
|
||||||
|
make -j$(nproc)
|
||||||
|
./MorriCraft
|
||||||
|
```
|
||||||
|
|
||||||
### v1.4.1
|
#### 🪟 Windows (Cross-compile)
|
||||||
- **Texture Fixes**: Corrected leaf and log textures.
|
```bash
|
||||||
- **Inventory Stability**: Fixed the double-toggle bug when pressing 'E'.
|
mkdir build-windows && cd build-windows
|
||||||
- **Bug Fixes**: Resolved grass rendering issues and fixed tree generation.
|
cmake -DCMAKE_TOOLCHAIN_FILE=../toolchain-windows.cmake ..
|
||||||
|
make -j$(nproc)
|
||||||
|
```
|
||||||
|
A pre-built `MorriCraft-Windows.zip` is available in the repository root.
|
||||||
|
|
||||||
### v1.4.0
|
---
|
||||||
- **Crafting Table**: Implemented the Crafting Table block and 3x3 grid interaction.
|
|
||||||
- **Advanced UI**: Centered stack counts and added red versioning to the title screen.
|
|
||||||
|
|
||||||
### v1.3.x
|
## 🎮 Controls
|
||||||
- **Physics**: Implemented "Ground-Lock" stabilization.
|
| Key | Action |
|
||||||
- **Inventory**: Added basic drag-and-drop support.
|
|-----|--------|
|
||||||
- **Wireframes**: Added real-time block selection highlights.
|
| **WASD** | Movement |
|
||||||
|
| **Space** | Jump |
|
||||||
|
| **Mouse** | Look / Aim |
|
||||||
|
| **Left Click** | Attack / Destroy Block |
|
||||||
|
| **Right Click** | Place Block / Use Workbench |
|
||||||
|
| **E** | Open Inventory |
|
||||||
|
| **Enter** | Open Chat |
|
||||||
|
| **1-9** | Hotbar Selection |
|
||||||
|
| **ESC** | Pause / Menu |
|
||||||
|
|
||||||
## Build Instructions
|
---
|
||||||
|
|
||||||
### Linux
|
## 📜 Crafting Recipes
|
||||||
1. `mkdir build-linux && cd build-linux`
|
|
||||||
2. `cmake ..`
|
|
||||||
3. `make -j$(nproc)`
|
|
||||||
|
|
||||||
### Windows (Cross-compile from Linux)
|
### 2×2 Player Grid
|
||||||
1. `mkdir build-windows && cd build-windows`
|
| Input | Output |
|
||||||
2. `cmake -DCMAKE_TOOLCHAIN_FILE=../toolchain-windows.cmake ..`
|
|-------|--------|
|
||||||
3. `make -j$(nproc)`
|
| 1 Log | 4 Planks |
|
||||||
|
| 4 Planks (2×2) | 1 Crafting Table |
|
||||||
|
| 2 Planks (vertical) | 4 Sticks |
|
||||||
|
|
||||||
## Controls
|
### 3×3 Crafting Table
|
||||||
- **WASD**: Movement
|
| Recipe | Output | Recipe | Output |
|
||||||
- **Space**: Jump
|
|--------|--------|--------|--------|
|
||||||
- **Mouse**: Look / Aim
|
| PPP / .S. / .S. | Wooden Pickaxe | CCC / .S. / .S. | Stone Pickaxe |
|
||||||
- **Left Click**: Destroy Block
|
| PP. / PS. / .S. | Wooden Axe | CC. / CS. / .S. | Stone Axe |
|
||||||
- **Right Click**: Place Block / Use Crafting Table
|
| .P. / .P. / .S. | Wooden Sword | .C. / .C. / .S. | Stone Sword |
|
||||||
- **E**: Toggle Inventory
|
| .P. / .S. / .S. | Wooden Shovel | .C. / .S. / .S. | Stone Shovel |
|
||||||
- **1-9**: Hotbar Selection
|
| PP. / .S. / .S. | Wooden Hoe | CC. / .S. / .S. | Stone Hoe |
|
||||||
- **ESC**: Pause Menu / Close Inventory
|
| CCC / C.C / CCC | Furnace | PPP / P.P / PPP | Chest |
|
||||||
|
| PP. / PP. / PP. | Door ×3 | PSP / PSP | Fence ×3 |
|
||||||
|
| S.S / SSS / S.S | Ladder ×3 | ... / ... / CCC | Stone Slab ×6 |
|
||||||
|
|
||||||
|
*P = Plank, S = Stick, C = Cobblestone. Mirrored variants supported.*
|
||||||
|
|
||||||
|
---
|
||||||
|
|
||||||
|
## 📜 Version History
|
||||||
|
|
||||||
|
### v2.3.7 - Major Update: High-Quality 3D Torches & Asset Redesign (Current)
|
||||||
|
- **Hunger System**: Added player hunger bar, starvation mechanics, and health regeneration when full.
|
||||||
|
- **Apple Item**: Added edible Apple item to restore hunger.
|
||||||
|
- **Grass Texture**: Improved `grass_top` texture with better pixel art.
|
||||||
|
- **World Spawn Fix**: Fixed missing terrain chunks behind the player on new world generation.
|
||||||
|
|
||||||
|
### v2.2.26 - Hunger & World Gen Patch
|
||||||
|
- **'E' Key Bug Fix**: Resolved an issue where the inventory overlay would get out of sync with container/cheat GUIs, preventing the menu from staying open or resulting in a missing cursor.
|
||||||
|
- **/test Command**: Refined the `/test` command to grant exactly 1x Crafting Table and 64x Oak Logs with descriptive feedback.
|
||||||
|
- **Help Command**: Updated `/help` to include all debug commands (`/test`, `/cheat`, `/fly`, `/seed`).
|
||||||
|
- **/fly Command**: Added a simple toggle behavior to the `/fly` command.
|
||||||
|
|
||||||
|
### v2.2.23 - Persistence & Viewmodel Fixes
|
||||||
|
|
||||||
|
### v2.2.22 - World Generation Polish
|
||||||
|
|
||||||
|
### v2.2.21 - Save Fix & Updater Polish
|
||||||
|
|
||||||
|
### v2.2.20 - UI Polish & Spawn Fixes
|
||||||
|
|
||||||
|
### v2.2.19 - Torch & persistence Overhaul
|
||||||
|
|
||||||
|
### v2.2.18 - Persistence & UI Fixes
|
||||||
|
|
||||||
|
### v2.2.6 - World Management
|
||||||
|
- **7:00 AM Spawn**: New worlds now start in the morning for immediate daylight.
|
||||||
|
- **Naming System**: Cleaner sequential naming (`World`, `World 1`, `World 2`) instead of nested parentheses.
|
||||||
|
- **Anti-Stuck Physics**: Active collision resolution pushes players out of blocks if they overlap.
|
||||||
|
- **Build Path**: Windows artifacts are now stored in `build-windows/` for easier deployment.
|
||||||
|
|
||||||
|
### v2.2.5 - UX & Inventory Polish
|
||||||
|
- **Shift-Click**: Holding Shift and clicking picks up entire item stacks instantly.
|
||||||
|
- **Scrollable Menus**: Added scroll bars and mouse-wheel support for the "Load World" menu.
|
||||||
|
- **UI Padding**: Increased padding across all panels to ensure text never overlaps borders.
|
||||||
|
|
||||||
|
### v2.2.4 - Visual & Update Stability
|
||||||
|
- **X-Ray Fix**: Neighborhood chunk dirtying ensures internal faces are culled immediately.
|
||||||
|
- **Smart Updates**: Client only prompts for updates if the remote version is strictly higher.
|
||||||
|
- **15x15 Pre-Gen**: Expanded spawn area pre-generation (225 chunks) to eliminate horizon drop-offs.
|
||||||
|
|
||||||
|
### v2.2.3 - Async Generation & Help
|
||||||
|
- **Loading Screen**: Added a progress bar for asynchronous world generation/loading.
|
||||||
|
- **Help Command**: Added `/help` to chat to display all available console commands.
|
||||||
|
- **Spawn Surface**: Guaranteed surface placement after full chunk pre-generation.
|
||||||
|
|
||||||
|
### v2.2.1 - World & Seed Polish
|
||||||
|
- **Cliff Fix**: Resolved issues where new worlds would spawn with missing chunks.
|
||||||
|
- **Render Distance**: Increased default render distance to 4 for a more expansive view.
|
||||||
|
- **Auto-Updater**: Platform-aware updates target Windows vs Linux binaries.
|
||||||
|
|
||||||
|
### v2.2.0 - Biome & Generation Update
|
||||||
|
- **Seed Fix**: Proper avalanche-hash for seeds, making every world truly unique.
|
||||||
|
- **Biomes**: Added Grassland, Desert, and Rocky biomes with sand beaches at sea level.
|
||||||
|
- **Commands**: Added `/seed` command to view the world seed in chat.
|
||||||
|
|
||||||
|
### v2.1.9 - Crafting Overhaul
|
||||||
|
- **20+ Recipes**: Added Log→Planks and full wooden/stone tool tier crafting.
|
||||||
|
- **Smart Inventory**: Left-click stacks same items, right-click picks up or places one.
|
||||||
|
- **Future Item IDs**: Added furnace, chest, ladder, fence, torch, door, and stone slab types.
|
||||||
|
|
||||||
|
### v2.1.8 - Forest Fidelity
|
||||||
|
- **HQ Leaves**: New high-definition leaf texture with proper green tinting.
|
||||||
|
- **Tree Fix**: Corrected log rendering to use multi-texture bark/ring mapping.
|
||||||
|
|
||||||
|
### v2.1.7 - Log Realism
|
||||||
|
- **Oak Log Textures**: Dedicated bark (side) and ring (top) textures for logs.
|
||||||
|
|
||||||
|
### v2.1.6 - Inventory Insight
|
||||||
|
- **Item Tooltips**: Mouse-over identification for all inventory items.
|
||||||
|
|
||||||
|
### v2.1.2 - Combat & Health
|
||||||
|
- **PvP Melee**: Ray-traced hit detection with knockback and audio feedback.
|
||||||
|
- **Heart HUD**: 8-heart health system.
|
||||||
|
|
||||||
|
### v2.1.0 - Personalization
|
||||||
|
- **Skin Editor**: Shirt and pants color customization, synced across network.
|
||||||
|
- **Humanoid Models**: Multi-cube player avatars replacing placeholder blobs.
|
||||||
|
|
||||||
|
### v2.0.0 - Multiplayer
|
||||||
|
- **P2P Networking**: Cross-platform sockets with direct connect and LAN hosting.
|
||||||
|
- **Chat System**: Real-time text communication between players.
|
||||||
|
|
||||||
|
---
|
||||||
|
*Developed by the MorriCraft Team. Built with Raylib 5.0.*
|
||||||
|
|
|
||||||
|
Before Width: | Height: | Size: 6.9 MiB After Width: | Height: | Size: 6.9 MiB |
|
After Width: | Height: | Size: 14 KiB |
|
Before Width: | Height: | Size: 166 B After Width: | Height: | Size: 291 B |
|
After Width: | Height: | Size: 748 KiB |
|
Before Width: | Height: | Size: 200 B After Width: | Height: | Size: 285 B |
|
Before Width: | Height: | Size: 219 B After Width: | Height: | Size: 318 B |
BIN
assets/dirt.png
|
Before Width: | Height: | Size: 197 B After Width: | Height: | Size: 279 B |
BIN
assets/grass.png
|
Before Width: | Height: | Size: 329 B After Width: | Height: | Size: 9.9 KiB |
|
Before Width: | Height: | Size: 298 B After Width: | Height: | Size: 7.0 KiB |
|
Before Width: | Height: | Size: 199 B After Width: | Height: | Size: 296 B |
|
Before Width: | Height: | Size: 212 B After Width: | Height: | Size: 303 B |
|
After Width: | Height: | Size: 5.2 KiB |
|
After Width: | Height: | Size: 5.0 KiB |
|
After Width: | Height: | Size: 5.1 KiB |
BIN
assets/plank.png
|
Before Width: | Height: | Size: 195 B After Width: | Height: | Size: 285 B |
BIN
assets/sand.png
|
Before Width: | Height: | Size: 188 B After Width: | Height: | Size: 275 B |
BIN
assets/stick.png
|
Before Width: | Height: | Size: 4.8 KiB After Width: | Height: | Size: 321 B |
BIN
assets/stone.png
|
Before Width: | Height: | Size: 151 B After Width: | Height: | Size: 226 B |
|
After Width: | Height: | Size: 552 KiB |
|
|
@ -0,0 +1 @@
|
||||||
|
v2.3.7
|
||||||
|
Before Width: | Height: | Size: 440 B After Width: | Height: | Size: 390 B |
|
After Width: | Height: | Size: 339 KiB |
|
After Width: | Height: | Size: 594 KiB |
|
After Width: | Height: | Size: 462 KiB |
|
After Width: | Height: | Size: 575 KiB |
|
Before Width: | Height: | Size: 6.9 MiB After Width: | Height: | Size: 6.9 MiB |
|
After Width: | Height: | Size: 14 KiB |
|
Before Width: | Height: | Size: 166 B After Width: | Height: | Size: 291 B |
|
After Width: | Height: | Size: 748 KiB |
|
Before Width: | Height: | Size: 200 B After Width: | Height: | Size: 285 B |
|
After Width: | Height: | Size: 36 KiB |
|
Before Width: | Height: | Size: 219 B After Width: | Height: | Size: 318 B |
|
Before Width: | Height: | Size: 197 B After Width: | Height: | Size: 279 B |
|
Before Width: | Height: | Size: 329 B After Width: | Height: | Size: 9.9 KiB |
|
Before Width: | Height: | Size: 298 B After Width: | Height: | Size: 7.0 KiB |
|
Before Width: | Height: | Size: 199 B After Width: | Height: | Size: 296 B |
|
Before Width: | Height: | Size: 212 B After Width: | Height: | Size: 303 B |
|
After Width: | Height: | Size: 5.2 KiB |
|
After Width: | Height: | Size: 5.0 KiB |
|
After Width: | Height: | Size: 5.1 KiB |
|
Before Width: | Height: | Size: 195 B After Width: | Height: | Size: 285 B |
|
Before Width: | Height: | Size: 188 B After Width: | Height: | Size: 275 B |
|
Before Width: | Height: | Size: 4.8 KiB After Width: | Height: | Size: 321 B |
|
Before Width: | Height: | Size: 151 B After Width: | Height: | Size: 226 B |
|
After Width: | Height: | Size: 552 KiB |
|
|
@ -1 +1 @@
|
||||||
v2.0.0
|
v2.3.7
|
||||||
|
|
|
||||||
|
Before Width: | Height: | Size: 440 B After Width: | Height: | Size: 390 B |
|
After Width: | Height: | Size: 339 KiB |
|
After Width: | Height: | Size: 594 KiB |
|
After Width: | Height: | Size: 462 KiB |
|
After Width: | Height: | Size: 575 KiB |
|
Before Width: | Height: | Size: 6.9 MiB After Width: | Height: | Size: 6.9 MiB |
|
After Width: | Height: | Size: 14 KiB |
|
Before Width: | Height: | Size: 166 B After Width: | Height: | Size: 291 B |
|
After Width: | Height: | Size: 748 KiB |
|
Before Width: | Height: | Size: 200 B After Width: | Height: | Size: 285 B |
|
Before Width: | Height: | Size: 219 B After Width: | Height: | Size: 318 B |
|
Before Width: | Height: | Size: 197 B After Width: | Height: | Size: 279 B |
|
Before Width: | Height: | Size: 329 B After Width: | Height: | Size: 9.9 KiB |
|
Before Width: | Height: | Size: 298 B After Width: | Height: | Size: 7.0 KiB |
|
Before Width: | Height: | Size: 199 B After Width: | Height: | Size: 296 B |
|
Before Width: | Height: | Size: 212 B After Width: | Height: | Size: 303 B |
|
After Width: | Height: | Size: 5.2 KiB |
|
After Width: | Height: | Size: 5.0 KiB |
|
After Width: | Height: | Size: 5.1 KiB |
|
Before Width: | Height: | Size: 195 B After Width: | Height: | Size: 285 B |
|
Before Width: | Height: | Size: 188 B After Width: | Height: | Size: 275 B |
|
Before Width: | Height: | Size: 4.8 KiB After Width: | Height: | Size: 321 B |
|
Before Width: | Height: | Size: 151 B After Width: | Height: | Size: 226 B |
|
After Width: | Height: | Size: 552 KiB |
|
|
@ -1 +1 @@
|
||||||
v2.0.0
|
v2.3.7
|
||||||
|
|
|
||||||
|
Before Width: | Height: | Size: 440 B After Width: | Height: | Size: 390 B |
|
After Width: | Height: | Size: 339 KiB |
|
After Width: | Height: | Size: 594 KiB |
|
After Width: | Height: | Size: 462 KiB |
|
After Width: | Height: | Size: 575 KiB |
|
|
@ -0,0 +1 @@
|
||||||
|
v2.3.7
|
||||||
2765
src/main.cpp
|
|
@ -54,7 +54,14 @@ enum PacketType {
|
||||||
PACKET_TIME_SYNC = 3,
|
PACKET_TIME_SYNC = 3,
|
||||||
PACKET_SEED_SYNC = 4,
|
PACKET_SEED_SYNC = 4,
|
||||||
PACKET_CHAT = 5,
|
PACKET_CHAT = 5,
|
||||||
PACKET_DISCONNECT = 6
|
PACKET_DISCONNECT = 6,
|
||||||
|
PACKET_PLAYER_HIT = 7
|
||||||
|
};
|
||||||
|
|
||||||
|
struct PacketPlayerHit {
|
||||||
|
uint32_t targetID;
|
||||||
|
float damage;
|
||||||
|
float attackerX, attackerZ;
|
||||||
};
|
};
|
||||||
|
|
||||||
struct PacketHeader {
|
struct PacketHeader {
|
||||||
|
|
@ -64,6 +71,8 @@ struct PacketHeader {
|
||||||
|
|
||||||
struct PacketHandshake {
|
struct PacketHandshake {
|
||||||
char name[32];
|
char name[32];
|
||||||
|
uint8_t shirtR, shirtG, shirtB;
|
||||||
|
uint8_t pantsR, pantsG, pantsB;
|
||||||
};
|
};
|
||||||
|
|
||||||
struct PacketPlayerUpdate {
|
struct PacketPlayerUpdate {
|
||||||
|
|
|
||||||