Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

[Runtime Issue]: Case sensitive filesystems encountering errors #262

Closed
12 of 20 tasks
Jayman2000 opened this issue May 1, 2024 · 3 comments · Fixed by #294
Closed
12 of 20 tasks

[Runtime Issue]: Case sensitive filesystems encountering errors #262

Jayman2000 opened this issue May 1, 2024 · 3 comments · Fixed by #294
Labels
bug Something isn't working
Milestone

Comments

@Jayman2000
Copy link
Contributor

Jayman2000 commented May 1, 2024

Build Version

v1.5.0 0254bec

Operating System Environment

  • Microsoft Windows (32-bit)
  • Microsoft Windows (64-bit)
  • Mac OS X
  • Linux (specify distribution and version below)

CPU Environment

  • x86 (32-bit Intel/AMD)
  • x86_64 (64-bit Intel/AMD)
  • ARM (32-bit)
  • ARM64 (64-bit; sometimes called AArch64)
  • Other (RISC V, PPC...)

Game Modes Affected

  • Single player
  • Anarchy
  • Hyper-Anarchy
  • Robo-Anarchy
  • Team Anarchy
  • Capture the Flag
  • Bounty
  • Entropy
  • Hoard
  • Monsterball
  • Cooperative

Game Environment

The game data is from a fresh installation of the Windows Dual-Jewel version of Descent 3 that has been updated to v1.4.

I’m running NixOS 23.11.

Description

If you build game with ENABLE_LOGGER set to ON, then this message will get logged:

PPIC: Error opening PPics.Hog database

It appears the the name of the file is case sensitive. When I installed Descent 3 in Wine, it named the file PPICS.HOG, but the game wants it to be named PPics.Hog. I was able to workaround this issue by running ln -s PPICS.HOG PPics.Hog

Regression Status

All I know is that this bug doesn’t happen when I run the Windows version of Descent 3 v1.4 in Wine.

Steps to Reproduce

  1. Build the game with the logger enabled.
  2. Put a copy of the game in a case sensitive directory.
  3. Start the game. While the game is starting, the previously mentioned PPIC error will get logged.
  4. Create a new pilot named “dopefish”.
  5. Attempt to select a pilot picture for that pilot. The game will tell you that there are no pilot pictures for that pilot. It should give you a menu to select dopefish’s pilot picture.
@Jayman2000 Jayman2000 added the bug Something isn't working label May 1, 2024
@JeodC
Copy link
Member

JeodC commented May 1, 2024

There are several files the game opens and reads. We will need to add case insensitivity to all of them. PPics.hog in particular is defined here.

@JeodC JeodC changed the title [Runtime Issue]: Error opening PPics.Hog database on case sensitive filesystems [Runtime Issue]: Case sensitive filesystems encountering errors May 1, 2024
@JeodC
Copy link
Member

JeodC commented May 1, 2024

Here is a rough list of what needs changes to case insensitivity:

@phlash
Copy link

phlash commented May 6, 2024

OK folks, I have searched through the tree for all uses of open() and fopen(), then assessed if they need to be case insensitive by looking at the callers and purposes, ugly results in attached files, TL;DR as hinted by @JeodC above:

  • movie/d3movie.cpp: mve_PlayMovie(), mve_SequenceStart()
  • cfile/cfile.cpp: cf_OpenLibrary()

Usefully there is already a cf_FindRealFileNameCaseInsensitive() which I shall try first to resolve supplied names.

opens.txt
fopens.txt

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
bug Something isn't working
Projects
None yet
Development

Successfully merging a pull request may close this issue.

3 participants