mirror of
https://github.com/Kelsidavis/WoWee.git
synced 2026-03-22 23:30:14 +00:00
Compare commits
12 commits
06979e5c5c
...
22518f0936
| Author | SHA1 | Date | |
|---|---|---|---|
|
|
22518f0936 | ||
|
|
997318ae06 | ||
|
|
a825450048 | ||
|
|
de6983e385 | ||
|
|
0210c24186 | ||
|
|
42b8e3141a | ||
|
|
b5f754a9cc | ||
|
|
22fa771d00 | ||
|
|
ebab8f3ccc | ||
|
|
685736fa16 | ||
|
|
f66b9eb154 | ||
|
|
eb549a9b7a |
19 changed files with 20239 additions and 42 deletions
24
.github/workflows/build.yml
vendored
24
.github/workflows/build.yml
vendored
|
|
@ -46,6 +46,9 @@ jobs:
|
|||
libglm-dev \
|
||||
libssl-dev \
|
||||
zlib1g-dev \
|
||||
libvulkan-dev \
|
||||
vulkan-tools \
|
||||
glslc \
|
||||
libavformat-dev \
|
||||
libavcodec-dev \
|
||||
libswscale-dev \
|
||||
|
|
@ -89,14 +92,14 @@ jobs:
|
|||
- name: Install dependencies
|
||||
run: |
|
||||
brew install cmake pkg-config sdl2 glew glm openssl@3 zlib ffmpeg unicorn \
|
||||
stormlib dylibbundler || true
|
||||
stormlib vulkan-loader vulkan-headers shaderc dylibbundler || true
|
||||
# dylibbundler may not be in all brew mirrors; install separately to not block others
|
||||
brew install dylibbundler 2>/dev/null || true
|
||||
|
||||
- name: Configure
|
||||
run: |
|
||||
BREW=$(brew --prefix)
|
||||
export PKG_CONFIG_PATH="$BREW/lib/pkgconfig:$(brew --prefix ffmpeg)/lib/pkgconfig:$(brew --prefix openssl@3)/lib/pkgconfig"
|
||||
export PKG_CONFIG_PATH="$BREW/lib/pkgconfig:$(brew --prefix ffmpeg)/lib/pkgconfig:$(brew --prefix openssl@3)/lib/pkgconfig:$(brew --prefix vulkan-loader)/lib/pkgconfig:$(brew --prefix shaderc)/lib/pkgconfig"
|
||||
cmake -S . -B build \
|
||||
-DCMAKE_BUILD_TYPE=Release \
|
||||
-DCMAKE_PREFIX_PATH="$BREW" \
|
||||
|
|
@ -170,7 +173,7 @@ jobs:
|
|||
uses: msys2/setup-msys2@v2
|
||||
with:
|
||||
msystem: CLANGARM64
|
||||
update: false
|
||||
update: true
|
||||
install: >-
|
||||
mingw-w64-clang-aarch64-cmake
|
||||
mingw-w64-clang-aarch64-clang
|
||||
|
|
@ -182,8 +185,16 @@ jobs:
|
|||
mingw-w64-clang-aarch64-openssl
|
||||
mingw-w64-clang-aarch64-zlib
|
||||
mingw-w64-clang-aarch64-ffmpeg
|
||||
mingw-w64-clang-aarch64-unicorn
|
||||
mingw-w64-clang-aarch64-vulkan-loader
|
||||
mingw-w64-clang-aarch64-vulkan-headers
|
||||
mingw-w64-clang-aarch64-shaderc
|
||||
git
|
||||
|
||||
- name: Install optional packages
|
||||
shell: msys2 {0}
|
||||
run: pacman -S --noconfirm --needed mingw-w64-clang-aarch64-stormlib || true
|
||||
|
||||
- name: Configure
|
||||
shell: msys2 {0}
|
||||
run: cmake -S . -B build -G Ninja -DCMAKE_BUILD_TYPE=Release
|
||||
|
|
@ -237,9 +248,16 @@ jobs:
|
|||
mingw-w64-x86_64-zlib
|
||||
mingw-w64-x86_64-ffmpeg
|
||||
mingw-w64-x86_64-unicorn
|
||||
mingw-w64-x86_64-vulkan-loader
|
||||
mingw-w64-x86_64-vulkan-headers
|
||||
mingw-w64-x86_64-shaderc
|
||||
mingw-w64-x86_64-nsis
|
||||
git
|
||||
|
||||
- name: Install optional packages
|
||||
shell: msys2 {0}
|
||||
run: pacman -S --noconfirm --needed mingw-w64-x86_64-stormlib || true
|
||||
|
||||
- name: Configure
|
||||
shell: msys2 {0}
|
||||
run: cmake -S . -B build -G Ninja -DCMAKE_BUILD_TYPE=Release
|
||||
|
|
|
|||
6
.github/workflows/security.yml
vendored
6
.github/workflows/security.yml
vendored
|
|
@ -36,6 +36,9 @@ jobs:
|
|||
libglm-dev \
|
||||
libssl-dev \
|
||||
zlib1g-dev \
|
||||
libvulkan-dev \
|
||||
vulkan-tools \
|
||||
glslc \
|
||||
libavformat-dev \
|
||||
libavcodec-dev \
|
||||
libswscale-dev \
|
||||
|
|
@ -105,6 +108,9 @@ jobs:
|
|||
libglm-dev \
|
||||
libssl-dev \
|
||||
zlib1g-dev \
|
||||
libvulkan-dev \
|
||||
vulkan-tools \
|
||||
glslc \
|
||||
libavformat-dev \
|
||||
libavcodec-dev \
|
||||
libswscale-dev \
|
||||
|
|
|
|||
6
.gitignore
vendored
6
.gitignore
vendored
|
|
@ -42,10 +42,12 @@ wowee
|
|||
*~
|
||||
.DS_Store
|
||||
|
||||
# External dependencies (except submodules)
|
||||
# External dependencies (except submodules and vendored headers)
|
||||
extern/*
|
||||
!extern/.gitkeep
|
||||
!extern/imgui
|
||||
!extern/vk-bootstrap
|
||||
!extern/vk_mem_alloc.h
|
||||
|
||||
# ImGui state
|
||||
imgui.ini
|
||||
|
|
@ -64,7 +66,7 @@ cache/
|
|||
saves/
|
||||
wowee_[0-9][0-9][0-9][0-9]
|
||||
|
||||
# Extracted assets (run ./extract_assets.sh to generate)
|
||||
# Extracted assets (run ./extract_assets.sh or .\extract_assets.ps1 to generate)
|
||||
Data/db/
|
||||
Data/character/
|
||||
Data/creature/
|
||||
|
|
|
|||
4
.gitmodules
vendored
4
.gitmodules
vendored
|
|
@ -2,3 +2,7 @@
|
|||
path = extern/imgui
|
||||
url = https://github.com/ocornut/imgui.git
|
||||
shallow = true
|
||||
[submodule "extern/vk-bootstrap"]
|
||||
path = extern/vk-bootstrap
|
||||
url = https://github.com/charles-lunarg/vk-bootstrap.git
|
||||
shallow = true
|
||||
|
|
|
|||
|
|
@ -10,7 +10,13 @@ This document provides platform-specific build instructions for WoWee.
|
|||
|
||||
```bash
|
||||
sudo apt update
|
||||
sudo apt install -y build-essential cmake pkg-config git libsdl2-dev libglew-dev libglm-dev libssl-dev zlib1g-dev libavcodec-dev libavformat-dev libavutil-dev libswscale-dev libunicorn-dev libstorm-dev
|
||||
sudo apt install -y \
|
||||
build-essential cmake pkg-config git \
|
||||
libsdl2-dev libglew-dev libglm-dev \
|
||||
libssl-dev zlib1g-dev \
|
||||
libvulkan-dev vulkan-tools glslc \
|
||||
libavcodec-dev libavformat-dev libavutil-dev libswscale-dev \
|
||||
libunicorn-dev libstorm-dev libx11-dev
|
||||
```
|
||||
|
||||
---
|
||||
|
|
@ -20,7 +26,11 @@ sudo apt install -y build-essential cmake pkg-config git libsdl2-dev libglew
|
|||
### Install Dependencies
|
||||
|
||||
```bash
|
||||
sudo pacman -S --needed base-devel cmake pkgconf git sdl2 glew glm openssl zlib ffmpeg unicorn stormlib
|
||||
sudo pacman -S --needed \
|
||||
base-devel cmake pkgconf git \
|
||||
sdl2 glew glm openssl zlib \
|
||||
vulkan-devel vulkan-tools shaderc \
|
||||
ffmpeg unicorn stormlib
|
||||
```
|
||||
|
||||
---
|
||||
|
|
@ -49,15 +59,119 @@ cmake -S . -B build -DCMAKE_BUILD_TYPE=Release
|
|||
cmake --build build -j"$(nproc)"
|
||||
```
|
||||
|
||||
### Asset Extraction (Linux)
|
||||
|
||||
After building, extract assets from your WoW client:
|
||||
|
||||
```bash
|
||||
./extract_assets.sh /path/to/WoW/Data wotlk
|
||||
```
|
||||
|
||||
Supports `classic`, `tbc`, `wotlk` targets (auto-detected if omitted).
|
||||
|
||||
---
|
||||
|
||||
## 🍎 macOS
|
||||
|
||||
### Install Dependencies
|
||||
|
||||
Vulkan on macOS is provided via MoltenVK (a Vulkan-to-Metal translation layer),
|
||||
which is included in the `vulkan-loader` Homebrew package.
|
||||
|
||||
```bash
|
||||
brew install cmake pkg-config sdl2 glew glm openssl@3 zlib ffmpeg unicorn \
|
||||
stormlib vulkan-loader vulkan-headers shaderc
|
||||
```
|
||||
|
||||
Optional (for creating redistributable `.app` bundles):
|
||||
|
||||
```bash
|
||||
brew install dylibbundler
|
||||
```
|
||||
|
||||
### Clone & Build
|
||||
|
||||
```bash
|
||||
git clone --recurse-submodules https://github.com/Kelsidavis/WoWee.git
|
||||
cd WoWee
|
||||
|
||||
BREW=$(brew --prefix)
|
||||
export PKG_CONFIG_PATH="$BREW/lib/pkgconfig:$(brew --prefix ffmpeg)/lib/pkgconfig:$(brew --prefix openssl@3)/lib/pkgconfig:$(brew --prefix vulkan-loader)/lib/pkgconfig:$(brew --prefix shaderc)/lib/pkgconfig"
|
||||
cmake -S . -B build -DCMAKE_BUILD_TYPE=Release \
|
||||
-DCMAKE_PREFIX_PATH="$BREW" \
|
||||
-DOPENSSL_ROOT_DIR="$(brew --prefix openssl@3)"
|
||||
cmake --build build -j"$(sysctl -n hw.logicalcpu)"
|
||||
```
|
||||
|
||||
### Asset Extraction (macOS)
|
||||
|
||||
The script will auto-build `asset_extract` if needed (requires `stormlib`).
|
||||
It automatically detects Homebrew and passes the correct paths to CMake.
|
||||
|
||||
```bash
|
||||
./extract_assets.sh /path/to/WoW/Data wotlk
|
||||
```
|
||||
|
||||
Supports `classic`, `tbc`, `wotlk` targets (auto-detected if omitted).
|
||||
|
||||
---
|
||||
|
||||
## 🪟 Windows (MSYS2 — Recommended)
|
||||
|
||||
MSYS2 provides all dependencies as pre-built packages.
|
||||
|
||||
### Install MSYS2
|
||||
|
||||
Download and install from <https://www.msys2.org/>, then open a **MINGW64** shell.
|
||||
|
||||
### Install Dependencies
|
||||
|
||||
```bash
|
||||
pacman -S --needed \
|
||||
mingw-w64-x86_64-cmake \
|
||||
mingw-w64-x86_64-gcc \
|
||||
mingw-w64-x86_64-ninja \
|
||||
mingw-w64-x86_64-pkgconf \
|
||||
mingw-w64-x86_64-SDL2 \
|
||||
mingw-w64-x86_64-glew \
|
||||
mingw-w64-x86_64-glm \
|
||||
mingw-w64-x86_64-openssl \
|
||||
mingw-w64-x86_64-zlib \
|
||||
mingw-w64-x86_64-ffmpeg \
|
||||
mingw-w64-x86_64-unicorn \
|
||||
mingw-w64-x86_64-vulkan-loader \
|
||||
mingw-w64-x86_64-vulkan-headers \
|
||||
mingw-w64-x86_64-shaderc \
|
||||
mingw-w64-x86_64-stormlib \
|
||||
git
|
||||
```
|
||||
|
||||
### Clone & Build
|
||||
|
||||
```bash
|
||||
git clone --recurse-submodules https://github.com/Kelsidavis/WoWee.git
|
||||
cd WoWee
|
||||
cmake -S . -B build -G Ninja -DCMAKE_BUILD_TYPE=Release
|
||||
cmake --build build --parallel $(nproc)
|
||||
```
|
||||
|
||||
---
|
||||
|
||||
## 🪟 Windows (Visual Studio 2022)
|
||||
|
||||
For users who prefer Visual Studio over MSYS2.
|
||||
|
||||
### Install
|
||||
|
||||
- Visual Studio 2022
|
||||
- Desktop development with C++
|
||||
- CMake tools for Windows
|
||||
- Visual Studio 2022 with **Desktop development with C++** workload
|
||||
- CMake tools for Windows (included in VS workload)
|
||||
- [LunarG Vulkan SDK](https://vulkan.lunarg.com/) (provides Vulkan headers, loader, and glslc)
|
||||
|
||||
### vcpkg Dependencies
|
||||
|
||||
```powershell
|
||||
vcpkg install sdl2 glew glm openssl zlib ffmpeg stormlib --triplet x64-windows
|
||||
```
|
||||
|
||||
### Clone
|
||||
|
||||
|
|
@ -68,16 +182,29 @@ cd WoWee
|
|||
|
||||
### Build
|
||||
|
||||
Open the folder in Visual Studio (it will detect CMake automatically)
|
||||
Open the folder in Visual Studio (it will detect CMake automatically)
|
||||
or build from Developer PowerShell:
|
||||
|
||||
```powershell
|
||||
cmake -S . -B build -DCMAKE_BUILD_TYPE=Release
|
||||
cmake -S . -B build -DCMAKE_BUILD_TYPE=Release -DCMAKE_TOOLCHAIN_FILE="[vcpkg root]/scripts/buildsystems/vcpkg.cmake"
|
||||
cmake --build build --config Release
|
||||
```
|
||||
|
||||
---
|
||||
|
||||
## 🪟 Asset Extraction (Windows)
|
||||
|
||||
After building (via either MSYS2 or Visual Studio), extract assets from your WoW client:
|
||||
|
||||
```powershell
|
||||
.\extract_assets.ps1 "C:\Games\WoW-3.3.5a\Data"
|
||||
```
|
||||
|
||||
Or double-click `extract_assets.bat` and provide the path when prompted.
|
||||
You can also specify an expansion: `.\extract_assets.ps1 "C:\Games\WoW\Data" wotlk`
|
||||
|
||||
---
|
||||
|
||||
## ⚠️ Notes
|
||||
|
||||
- Case matters on Linux (`WoWee` not `wowee`).
|
||||
|
|
|
|||
|
|
@ -35,7 +35,30 @@ endif()
|
|||
|
||||
# Find required packages
|
||||
find_package(SDL2 REQUIRED)
|
||||
find_package(Vulkan REQUIRED)
|
||||
find_package(Vulkan QUIET)
|
||||
if(NOT Vulkan_FOUND)
|
||||
# Fallback: some distros / CMake versions need pkg-config to locate Vulkan.
|
||||
find_package(PkgConfig QUIET)
|
||||
if(PkgConfig_FOUND)
|
||||
pkg_check_modules(VULKAN_PKG vulkan)
|
||||
if(VULKAN_PKG_FOUND)
|
||||
add_library(Vulkan::Vulkan INTERFACE IMPORTED)
|
||||
set_target_properties(Vulkan::Vulkan PROPERTIES
|
||||
INTERFACE_INCLUDE_DIRECTORIES "${VULKAN_PKG_INCLUDE_DIRS}"
|
||||
INTERFACE_LINK_LIBRARIES "${VULKAN_PKG_LIBRARIES}"
|
||||
)
|
||||
if(VULKAN_PKG_LIBRARY_DIRS)
|
||||
set_property(TARGET Vulkan::Vulkan APPEND PROPERTY
|
||||
INTERFACE_LINK_DIRECTORIES "${VULKAN_PKG_LIBRARY_DIRS}")
|
||||
endif()
|
||||
set(Vulkan_FOUND TRUE)
|
||||
message(STATUS "Found Vulkan via pkg-config: ${VULKAN_PKG_LIBRARIES}")
|
||||
endif()
|
||||
endif()
|
||||
if(NOT Vulkan_FOUND)
|
||||
message(FATAL_ERROR "Could not find Vulkan. Install libvulkan-dev (Linux), vulkan-loader (macOS), or the Vulkan SDK (Windows).")
|
||||
endif()
|
||||
endif()
|
||||
# GL/GLEW kept temporarily for unconverted sub-renderers during Vulkan migration.
|
||||
# These files compile against GL types but their code is never called — the Vulkan
|
||||
# path is the only active rendering backend. Remove in Phase 7 when all renderers
|
||||
|
|
@ -446,6 +469,9 @@ endif()
|
|||
target_include_directories(wowee PRIVATE
|
||||
${CMAKE_CURRENT_SOURCE_DIR}/include
|
||||
${CMAKE_CURRENT_SOURCE_DIR}/src
|
||||
)
|
||||
# Vendored headers as SYSTEM to suppress third-party warnings
|
||||
target_include_directories(wowee SYSTEM PRIVATE
|
||||
${CMAKE_CURRENT_SOURCE_DIR}/extern
|
||||
${CMAKE_CURRENT_SOURCE_DIR}/extern/vk-bootstrap/src
|
||||
)
|
||||
|
|
@ -520,7 +546,7 @@ endif()
|
|||
if(MSVC)
|
||||
target_compile_options(wowee PRIVATE /W4)
|
||||
else()
|
||||
target_compile_options(wowee PRIVATE -Wall -Wextra -Wpedantic)
|
||||
target_compile_options(wowee PRIVATE -Wall -Wextra -Wpedantic -Wno-missing-field-initializers)
|
||||
endif()
|
||||
|
||||
# Debug build flags
|
||||
|
|
@ -592,12 +618,18 @@ add_custom_command(TARGET wowee POST_BUILD
|
|||
# which does NOT include System32. Copy vulkan-1.dll into the output directory so
|
||||
# SDL_Vulkan_LoadLibrary can locate it without needing a full system PATH search.
|
||||
if(WIN32)
|
||||
add_custom_command(TARGET wowee POST_BUILD
|
||||
COMMAND ${CMAKE_COMMAND} -E copy_if_different
|
||||
"$ENV{SystemRoot}/System32/vulkan-1.dll"
|
||||
"$<TARGET_FILE_DIR:wowee>/vulkan-1.dll"
|
||||
COMMENT "Copying vulkan-1.dll to output directory"
|
||||
)
|
||||
find_file(VULKAN_DLL vulkan-1.dll
|
||||
PATHS "$ENV{SystemRoot}/System32" "$ENV{VULKAN_SDK}/Bin"
|
||||
NO_DEFAULT_PATH)
|
||||
if(VULKAN_DLL)
|
||||
add_custom_command(TARGET wowee POST_BUILD
|
||||
COMMAND ${CMAKE_COMMAND} -E copy_if_different
|
||||
"${VULKAN_DLL}" "$<TARGET_FILE_DIR:wowee>/vulkan-1.dll"
|
||||
COMMENT "Copying vulkan-1.dll to output directory"
|
||||
)
|
||||
else()
|
||||
message(STATUS " vulkan-1.dll not found — skipping copy (MSYS2 provides it via PATH)")
|
||||
endif()
|
||||
endif()
|
||||
|
||||
# Install targets
|
||||
|
|
@ -659,7 +691,14 @@ if(STORMLIB_LIBRARY AND STORMLIB_INCLUDE_DIR)
|
|||
Threads::Threads
|
||||
)
|
||||
if(WIN32)
|
||||
target_link_libraries(asset_extract PRIVATE wininet bz2)
|
||||
find_library(WININET_LIB wininet)
|
||||
find_library(BZ2_LIB bz2)
|
||||
if(WININET_LIB)
|
||||
target_link_libraries(asset_extract PRIVATE ${WININET_LIB})
|
||||
endif()
|
||||
if(BZ2_LIB)
|
||||
target_link_libraries(asset_extract PRIVATE ${BZ2_LIB})
|
||||
endif()
|
||||
endif()
|
||||
set_target_properties(asset_extract PROPERTIES
|
||||
RUNTIME_OUTPUT_DIRECTORY ${CMAKE_BINARY_DIR}/bin
|
||||
|
|
|
|||
20
README.md
20
README.md
|
|
@ -36,7 +36,7 @@ Protocol Compatible with **Vanilla (Classic) 1.12 + TBC 2.4.3 + WotLK 3.3.5a**.
|
|||
### Asset Pipeline
|
||||
- Extracted loose-file **`Data/`** tree indexed by **`manifest.json`** (fast lookup + caching)
|
||||
- Optional **overlay layers** for multi-expansion asset deduplication
|
||||
- `asset_extract` + `extract_assets.sh` for MPQ extraction (StormLib tooling)
|
||||
- `asset_extract` + `extract_assets.sh` (Linux/macOS) / `extract_assets.ps1` (Windows) for MPQ extraction (StormLib tooling)
|
||||
- File formats: **BLP** (DXT1/3/5), **ADT**, **M2**, **WMO**, **DBC** (Spell/Item/Faction/etc.)
|
||||
|
||||
### Gameplay Systems
|
||||
|
|
@ -84,6 +84,14 @@ sudo pacman -S sdl2 glm openssl \
|
|||
ffmpeg zlib cmake base-devel libx11 \
|
||||
unicorn # optional: Warden module execution
|
||||
# StormLib: install from AUR for asset_extract tool
|
||||
|
||||
# macOS (Homebrew)
|
||||
brew install cmake pkg-config sdl2 glew glm openssl@3 zlib ffmpeg \
|
||||
vulkan-loader vulkan-headers shaderc \
|
||||
unicorn \
|
||||
stormlib
|
||||
# unicorn is optional (Warden module execution)
|
||||
# stormlib is optional (asset_extract tool)
|
||||
```
|
||||
|
||||
### Container build
|
||||
|
|
@ -101,8 +109,12 @@ Wowee loads assets via an extracted loose-file tree indexed by `manifest.json` (
|
|||
#### 1) Extract MPQs into `./Data/`
|
||||
|
||||
```bash
|
||||
# WotLK 3.3.5a example
|
||||
# Linux / macOS
|
||||
./extract_assets.sh /path/to/WoW/Data wotlk
|
||||
|
||||
# Windows (PowerShell)
|
||||
.\extract_assets.ps1 "C:\Games\WoW-3.3.5a\Data" wotlk
|
||||
# Or double-click extract_assets.bat
|
||||
```
|
||||
|
||||
```
|
||||
|
|
@ -117,7 +129,7 @@ Data/
|
|||
Notes:
|
||||
|
||||
- `StormLib` is required to build/run the extractor (`asset_extract`), but the main client does not require StormLib at runtime.
|
||||
- `extract_assets.sh` supports `classic`, `tbc`, `wotlk` targets.
|
||||
- `extract_assets.sh` / `extract_assets.ps1` support `classic`, `tbc`, `wotlk` targets.
|
||||
|
||||
#### 2) Point wowee at the extracted data
|
||||
|
||||
|
|
@ -206,7 +218,7 @@ make -j$(nproc)
|
|||
|
||||
## Technical Details
|
||||
|
||||
- **Platform**: Linux (primary), C++20, CMake 3.15+
|
||||
- **Platform**: Linux (primary), Windows (MSYS2/MSVC), macOS — C++20, CMake 3.15+
|
||||
- **Dependencies**: SDL2, Vulkan, GLM, OpenSSL, ImGui, FFmpeg, Unicorn Engine (StormLib for asset extraction tooling)
|
||||
- **Architecture**: Modular design with clear separation (core, rendering, networking, game logic, asset pipeline, UI, audio)
|
||||
- **Networking**: Non-blocking TCP, SRP6a authentication, RC4 encryption, WoW 3.3.5a protocol
|
||||
|
|
|
|||
5
build.sh
5
build.sh
|
|
@ -16,8 +16,9 @@ echo "Configuring with CMake..."
|
|||
cmake .. -DCMAKE_BUILD_TYPE=Release
|
||||
|
||||
# Build with all cores
|
||||
echo "Building with $(nproc) cores..."
|
||||
cmake --build . --parallel $(nproc)
|
||||
NPROC=$(nproc 2>/dev/null || sysctl -n hw.logicalcpu 2>/dev/null || echo 4)
|
||||
echo "Building with $NPROC cores..."
|
||||
cmake --build . --parallel "$NPROC"
|
||||
|
||||
# Ensure Data symlink exists in bin directory
|
||||
cd bin
|
||||
|
|
|
|||
1
extern/vk-bootstrap
vendored
Submodule
1
extern/vk-bootstrap
vendored
Submodule
|
|
@ -0,0 +1 @@
|
|||
Subproject commit 2e7c8e8323c0fe7efc96dc241610fcba35d8f530
|
||||
19845
extern/vk_mem_alloc.h
vendored
Normal file
19845
extern/vk_mem_alloc.h
vendored
Normal file
File diff suppressed because it is too large
Load diff
4
extract_assets.bat
Normal file
4
extract_assets.bat
Normal file
|
|
@ -0,0 +1,4 @@
|
|||
@echo off
|
||||
REM Convenience wrapper — launches the PowerShell asset extraction script.
|
||||
REM Usage: extract_assets.bat C:\Games\WoW\Data [expansion]
|
||||
powershell -ExecutionPolicy Bypass -File "%~dp0extract_assets.ps1" %*
|
||||
120
extract_assets.ps1
Normal file
120
extract_assets.ps1
Normal file
|
|
@ -0,0 +1,120 @@
|
|||
<#
|
||||
.SYNOPSIS
|
||||
Extracts WoW MPQ archives for use with wowee (Windows equivalent of extract_assets.sh).
|
||||
|
||||
.DESCRIPTION
|
||||
Builds the asset_extract tool (if needed) and runs it against a WoW Data directory.
|
||||
|
||||
.PARAMETER MpqDir
|
||||
Path to the WoW client's Data directory containing .MPQ files.
|
||||
|
||||
.PARAMETER Expansion
|
||||
Expansion hint: classic, turtle, tbc, wotlk. Auto-detected if omitted.
|
||||
|
||||
.EXAMPLE
|
||||
.\extract_assets.ps1 "C:\Games\WoW-3.3.5a\Data"
|
||||
.\extract_assets.ps1 "C:\Games\WoW-1.12\Data" classic
|
||||
.\extract_assets.ps1 "D:\TurtleWoW\Data" turtle
|
||||
#>
|
||||
|
||||
param(
|
||||
[Parameter(Mandatory=$true, Position=0)]
|
||||
[string]$MpqDir,
|
||||
|
||||
[Parameter(Position=1)]
|
||||
[string]$Expansion = "auto"
|
||||
)
|
||||
|
||||
$ErrorActionPreference = "Stop"
|
||||
|
||||
$ScriptDir = Split-Path -Parent $MyInvocation.MyCommand.Path
|
||||
$BuildDir = Join-Path $ScriptDir "build"
|
||||
$Binary = Join-Path $BuildDir "bin\asset_extract.exe"
|
||||
$OutputDir = Join-Path $ScriptDir "Data"
|
||||
|
||||
# --- Validate arguments ---
|
||||
if (-not (Test-Path $MpqDir -PathType Container)) {
|
||||
Write-Error "Error: Directory not found: $MpqDir"
|
||||
exit 1
|
||||
}
|
||||
|
||||
# Check for .MPQ files
|
||||
$mpqFiles = Get-ChildItem -Path $MpqDir -Filter "*.MPQ" -ErrorAction SilentlyContinue
|
||||
$mpqFilesLower = Get-ChildItem -Path $MpqDir -Filter "*.mpq" -ErrorAction SilentlyContinue
|
||||
if (-not $mpqFiles -and -not $mpqFilesLower) {
|
||||
Write-Error "Error: No .MPQ files found in: $MpqDir`nMake sure this is the WoW Data/ directory (not the WoW root)."
|
||||
exit 1
|
||||
}
|
||||
|
||||
# Note about existing CSV DBCs
|
||||
if (Test-Path (Join-Path $OutputDir "expansions")) {
|
||||
$csvPattern = $null
|
||||
if ($Expansion -ne "auto") {
|
||||
$csvPattern = Join-Path $OutputDir "expansions\$Expansion\db\*.csv"
|
||||
} else {
|
||||
$csvPattern = Join-Path $OutputDir "expansions\*\db\*.csv"
|
||||
}
|
||||
if ($csvPattern -and (Get-ChildItem -Path $csvPattern -ErrorAction SilentlyContinue)) {
|
||||
Write-Host "Note: Found CSV DBCs. DBC extraction is optional; visual assets are still required.`n"
|
||||
}
|
||||
}
|
||||
|
||||
# --- Build asset_extract if needed ---
|
||||
if (-not (Test-Path $Binary)) {
|
||||
Write-Host "Building asset_extract..."
|
||||
|
||||
# Check for cmake
|
||||
if (-not (Get-Command cmake -ErrorAction SilentlyContinue)) {
|
||||
Write-Error "Error: cmake not found. Install CMake and ensure it is on your PATH."
|
||||
exit 1
|
||||
}
|
||||
|
||||
if (-not (Test-Path $BuildDir)) {
|
||||
& cmake -S $ScriptDir -B $BuildDir -DCMAKE_BUILD_TYPE=Release
|
||||
if ($LASTEXITCODE -ne 0) { exit $LASTEXITCODE }
|
||||
}
|
||||
|
||||
$numProcs = $env:NUMBER_OF_PROCESSORS
|
||||
if (-not $numProcs) { $numProcs = 4 }
|
||||
& cmake --build $BuildDir --target asset_extract --parallel $numProcs
|
||||
if ($LASTEXITCODE -ne 0) { exit $LASTEXITCODE }
|
||||
|
||||
Write-Host ""
|
||||
}
|
||||
|
||||
if (-not (Test-Path $Binary)) {
|
||||
Write-Error "Error: Failed to build asset_extract"
|
||||
exit 1
|
||||
}
|
||||
|
||||
# --- Run extraction ---
|
||||
Write-Host "Extracting assets from: $MpqDir"
|
||||
Write-Host "Output directory: $OutputDir"
|
||||
Write-Host ""
|
||||
|
||||
$extraArgs = @("--mpq-dir", $MpqDir, "--output", $OutputDir)
|
||||
|
||||
if ($Expansion -ne "auto") {
|
||||
$extraArgs += "--expansion"
|
||||
$extraArgs += $Expansion
|
||||
}
|
||||
|
||||
# Skip DBC extraction if CSVs already present
|
||||
$skipDbc = $false
|
||||
if ($Expansion -ne "auto") {
|
||||
$csvPath = Join-Path $OutputDir "expansions\$Expansion\db\*.csv"
|
||||
if (Get-ChildItem -Path $csvPath -ErrorAction SilentlyContinue) { $skipDbc = $true }
|
||||
} else {
|
||||
$csvPath = Join-Path $OutputDir "expansions\*\db\*.csv"
|
||||
if (Get-ChildItem -Path $csvPath -ErrorAction SilentlyContinue) { $skipDbc = $true }
|
||||
}
|
||||
if ($skipDbc) {
|
||||
$extraArgs += "--skip-dbc"
|
||||
}
|
||||
|
||||
& $Binary @extraArgs
|
||||
if ($LASTEXITCODE -ne 0) { exit $LASTEXITCODE }
|
||||
|
||||
Write-Host ""
|
||||
Write-Host "Done! Assets extracted to $OutputDir"
|
||||
Write-Host "You can now run wowee."
|
||||
|
|
@ -63,18 +63,39 @@ fi
|
|||
# --- Build asset_extract if needed ---
|
||||
if [ ! -f "$BINARY" ]; then
|
||||
# --- Check for StormLib (only required to build) ---
|
||||
if ! ldconfig -p 2>/dev/null | grep -qi stormlib; then
|
||||
STORMLIB_FOUND=false
|
||||
if ldconfig -p 2>/dev/null | grep -qi stormlib; then
|
||||
STORMLIB_FOUND=true
|
||||
elif pkg-config --exists stormlib 2>/dev/null; then
|
||||
STORMLIB_FOUND=true
|
||||
elif [ -f "$(brew --prefix 2>/dev/null)/lib/libstorm.dylib" ] 2>/dev/null; then
|
||||
STORMLIB_FOUND=true
|
||||
fi
|
||||
if [ "$STORMLIB_FOUND" = false ]; then
|
||||
echo "Error: StormLib not found."
|
||||
echo "Install it with: sudo apt install libstormlib-dev"
|
||||
echo " or build from source: https://github.com/ladislav-zezula/StormLib"
|
||||
echo " Ubuntu/Debian: sudo apt install libstormlib-dev"
|
||||
echo " macOS: brew install stormlib"
|
||||
echo " From source: https://github.com/ladislav-zezula/StormLib"
|
||||
exit 1
|
||||
fi
|
||||
|
||||
echo "Building asset_extract..."
|
||||
if [ ! -d "$BUILD_DIR" ]; then
|
||||
cmake -S "$SCRIPT_DIR" -B "$BUILD_DIR" -DCMAKE_BUILD_TYPE=Release
|
||||
CMAKE_EXTRA_ARGS=()
|
||||
# On macOS, Homebrew installs to a non-default prefix that CMake
|
||||
# can't find automatically — pass it explicitly.
|
||||
if command -v brew &>/dev/null; then
|
||||
BREW="$(brew --prefix)"
|
||||
CMAKE_EXTRA_ARGS+=(
|
||||
"-DCMAKE_PREFIX_PATH=$BREW"
|
||||
"-DOPENSSL_ROOT_DIR=$(brew --prefix openssl@3)"
|
||||
)
|
||||
export PKG_CONFIG_PATH="$BREW/lib/pkgconfig:$(brew --prefix ffmpeg)/lib/pkgconfig:$(brew --prefix openssl@3)/lib/pkgconfig:$(brew --prefix vulkan-loader 2>/dev/null)/lib/pkgconfig:$(brew --prefix shaderc 2>/dev/null)/lib/pkgconfig${PKG_CONFIG_PATH:+:$PKG_CONFIG_PATH}"
|
||||
fi
|
||||
cmake -S "$SCRIPT_DIR" -B "$BUILD_DIR" -DCMAKE_BUILD_TYPE=Release "${CMAKE_EXTRA_ARGS[@]}"
|
||||
fi
|
||||
cmake --build "$BUILD_DIR" --target asset_extract -- -j"$(nproc)"
|
||||
NPROC=$(nproc 2>/dev/null || sysctl -n hw.logicalcpu 2>/dev/null || echo 4)
|
||||
cmake --build "$BUILD_DIR" --target asset_extract -- -j"$NPROC"
|
||||
echo ""
|
||||
fi
|
||||
|
||||
|
|
|
|||
|
|
@ -48,7 +48,7 @@ AllocatedBuffer uploadBuffer(VkContext& ctx, const void* data, VkDeviceSize size
|
|||
VkBufferUsageFlags usage);
|
||||
|
||||
// Check VkResult and log on failure
|
||||
inline bool vkCheck(VkResult result, const char* msg) {
|
||||
inline bool vkCheck(VkResult result, [[maybe_unused]] const char* msg) {
|
||||
if (result != VK_SUCCESS) {
|
||||
// Caller should log the message
|
||||
return false;
|
||||
|
|
|
|||
|
|
@ -22,8 +22,9 @@ echo "Configuring with CMake..."
|
|||
cmake .. -DCMAKE_BUILD_TYPE=Release
|
||||
|
||||
# Build with all cores
|
||||
echo "Building with $(nproc) cores..."
|
||||
cmake --build . --parallel $(nproc)
|
||||
NPROC=$(nproc 2>/dev/null || sysctl -n hw.logicalcpu 2>/dev/null || echo 4)
|
||||
echo "Building with $NPROC cores..."
|
||||
cmake --build . --parallel "$NPROC"
|
||||
|
||||
# Create Data symlink in bin directory
|
||||
echo "Creating Data symlink..."
|
||||
|
|
|
|||
|
|
@ -4276,6 +4276,7 @@ network::Packet AuctionListItemsPacket::build(
|
|||
p.writeUInt32(quality);
|
||||
p.writeUInt8(usableOnly);
|
||||
p.writeUInt8(0); // getAll (0 = normal search)
|
||||
p.writeUInt8(exactMatch);
|
||||
// Sort columns (0 = none)
|
||||
p.writeUInt8(0);
|
||||
return p;
|
||||
|
|
|
|||
|
|
@ -3766,7 +3766,6 @@ void GameScreen::renderBagBar(game::GameHandler& gameHandler) {
|
|||
|
||||
// Track bag slot screen rects for drop detection
|
||||
ImVec2 bagSlotMins[4], bagSlotMaxs[4];
|
||||
VkDescriptorSet bagIcons[4] = {};
|
||||
|
||||
// Slots 1-4: Bag slots (leftmost)
|
||||
for (int i = 0; i < 4; ++i) {
|
||||
|
|
@ -3780,8 +3779,6 @@ void GameScreen::renderBagBar(game::GameHandler& gameHandler) {
|
|||
if (!bagItem.empty() && bagItem.item.displayInfoId != 0) {
|
||||
bagIcon = inventoryScreen.getItemIcon(bagItem.item.displayInfoId);
|
||||
}
|
||||
bagIcons[i] = bagIcon;
|
||||
|
||||
// Render the slot as an invisible button so we control all interaction
|
||||
ImVec2 cpos = ImGui::GetCursorScreenPos();
|
||||
ImGui::InvisibleButton("##bagSlot", ImVec2(slotSize, slotSize));
|
||||
|
|
@ -7483,7 +7480,6 @@ void GameScreen::renderBankWindow(game::GameHandler& gameHandler) {
|
|||
if (slot.empty()) {
|
||||
ImGui::Button("##bank", ImVec2(42, 42));
|
||||
} else {
|
||||
auto* info = gameHandler.getItemInfo(slot.item.itemId);
|
||||
ImVec4 qc = InventoryScreen::getQualityColor(slot.item.quality);
|
||||
ImGui::PushStyleColor(ImGuiCol_Button, ImVec4(qc.x * 0.3f, qc.y * 0.3f, qc.z * 0.3f, 0.8f));
|
||||
ImGui::PushStyleColor(ImGuiCol_ButtonHovered, ImVec4(qc.x * 0.5f, qc.y * 0.5f, qc.z * 0.5f, 0.9f));
|
||||
|
|
|
|||
|
|
@ -202,7 +202,6 @@ void TalentScreen::renderTalent(game::GameHandler& gameHandler,
|
|||
auto* assetManager = core::Application::getInstance().getAssetManager();
|
||||
|
||||
uint8_t currentRank = gameHandler.getTalentRank(talent.talentId);
|
||||
uint8_t nextRank = currentRank + 1;
|
||||
|
||||
// Check if can learn
|
||||
bool canLearn = currentRank < talent.maxRank &&
|
||||
|
|
@ -297,7 +296,6 @@ void TalentScreen::renderTalent(game::GameHandler& gameHandler,
|
|||
|
||||
// Rank indicator overlay
|
||||
if (talent.maxRank > 1) {
|
||||
ImVec2 pMin = ImGui::GetItemRectMin();
|
||||
ImVec2 pMax = ImGui::GetItemRectMax();
|
||||
auto* drawList = ImGui::GetWindowDrawList();
|
||||
|
||||
|
|
|
|||
|
|
@ -50,7 +50,8 @@ if command -v zstd &>/dev/null; then
|
|||
tar cf - -C "$(dirname "$DATA_DIR")" "$(basename "$DATA_DIR")" | zstd -T0 -3 -o "$ARCHIVE"
|
||||
elif command -v pigz &>/dev/null; then
|
||||
ARCHIVE="$BACKUP_DIR/wowee_assets_$TIMESTAMP.tar.gz"
|
||||
tar cf - -C "$(dirname "$DATA_DIR")" "$(basename "$DATA_DIR")" | pigz -p "$(nproc)" > "$ARCHIVE"
|
||||
NPROC=$(nproc 2>/dev/null || sysctl -n hw.logicalcpu 2>/dev/null || echo 4)
|
||||
tar cf - -C "$(dirname "$DATA_DIR")" "$(basename "$DATA_DIR")" | pigz -p "$NPROC" > "$ARCHIVE"
|
||||
else
|
||||
ARCHIVE="$BACKUP_DIR/wowee_assets_$TIMESTAMP.tar.gz"
|
||||
tar czf "$ARCHIVE" -C "$(dirname "$DATA_DIR")" "$(basename "$DATA_DIR")"
|
||||
|
|
|
|||
Loading…
Add table
Add a link
Reference in a new issue