Skip to content

Zero Hour rebuilt from EA's source: x64, Direct3D 11, VS2022/CMake, ~60 original bugs fixed, an AI that builds a base. Bring your own game.

merge: language read from zero hour's own archive

Olcay Seygandd16bbfbb43e
diff --cc CHANGELOG.md
index e74375223,0e897f10c..9adb55500
--- a/CHANGELOG.md
+++ b/CHANGELOG.md
@@@ -153,11 -23,11 +153,12 @@@ found and fixed — EA's own, not
- The game runs on Apple silicon Macs and on Linux, the Steam Deck included, as a program built for that machine. There is no Wine or Proton underneath. It draws through Metal on a Mac and through Vulkan on Linux, from the same Zero Hour files you already own.
- The first start finds your game. It looks in your Steam libraries, `~/Games`, `/Applications`, and CrossOver and Whisky bottles, and asks for the folder only when it comes up empty.
- One command builds it. `./build-macos.sh` leaves a Mac app ready to open and `./build-linux.sh` a folder ready to start, and each checks your machine first and names the package to install for anything missing. On Linux it can make an AppImage, a .deb, an .rpm, an Arch package and a Flatpak, none of them carrying EA's files, and the Flatpak has played a full check match on a Steam Deck.
+- No Windows needed to get the game's files onto a Mac or Linux either. `./extract-game.sh` takes a Zero Hour or Generals disc, an `.iso` of one, or a folder copied from a Windows install, and lays the two games out where the game finds them, Generals inside Zero Hour's folder. It asks before it writes to the default folder or over files already there, and says when a game is still missing.
- One game on every machine. A replay recorded on a Mac plays back on Linux and on Windows to the same checksum, and the other way round, and a Mac and a Linux PC have played a LAN match together without once disagreeing. A Mac or Linux game could not join a Windows one: the check every machine runs before a network game failed, because the Mac and Linux copies of the game's data files ended each line differently from Windows'. They agree now. A match between Windows and a Mac has not been played yet.
+ - A German, French or other non-English Zero Hour on a Mac or Linux speaks its own language. Windows' installer writes the language into the registry, and nothing does that on a Mac or Linux, so the game took English and found it in the original Generals' files beside Zero Hour: the menus came up in Generals' English with Zero Hour's own lines missing, so it looked like plain Generals. With no language set it now takes the one your Zero Hour's own files are in. A language you set yourself still wins.
- Text on the Linux menus is as wide as on Windows. Linux has no Arial, and the font standing in for it reports a wider average letter, so every menu font the game sets to a fixed width came out a quarter narrower than it should, the "Generals" lettering and the menu buttons among them. Each is measured against Arial's own figure now, and lands within one percent of Windows.
- The game no longer crashes on some Linux PCs as its window opens. The game hands out memory its own way, and on Linux the graphics driver gets its memory from the game too. Some drivers, AMD's on Debian 12 among them, need every piece lined up on a 16-byte boundary, and the game's lined up on 4, so the start died or went through depending on where the pieces happened to fall. On Linux everything outside the game's own pools now comes from the system, which lines it up as the driver expects.
-- `./build-linux.sh` stopped on Linux Mint and Arch after the centred Classic interface went in: the new code compared layout names with a Windows-only spelling that GCC on Linux has never heard of. It uses the name every platform knows now, and so do the two debug-build spots with the same habit. Nobody has rebuilt on Linux since, so whether anything else stands in the way is not known yet.
+- `./build-linux.sh` stopped on Linux Mint and Arch after the centred Classic interface went in: the new code compared layout names with a Windows-only spelling that GCC on Linux has never heard of. It uses the name every platform knows now, and so do the two debug-build spots with the same habit. From 3.0.0 on, `./build-macos.sh` and `./build-linux.sh` stopped again, on another Windows-only spelling in the mod code and, on Linux, a file name written in the wrong case, which Windows does not mind. The log blamed the audio library because it was the last file the build had started; the real error sat higher up. Both are fixed, after Andreas Berger found them.
- Windows on Arm laptops, the Snapdragon ones, get a build made for them. Microsoft never shipped those machines the library the game loads its textures and shaders through, so the game brings its own, the texture code the Mac and Linux versions already run. Switched on in place of Microsoft's library on an ordinary Windows PC, it draws the same battlefields, with no tree, house or patch of ground going missing. Nobody has played it on a Snapdragon laptop yet.
- Thanks to ilyasakin, whose port this is.