Skip to content

User home directory is not detected on Windows #72

@the-Arioch

Description

@the-Arioch

2.2.1beta1 when run on Windows 10 opens menu, but fails to enter the game mode itself.

Console log:

[SDL Init] [Graphics....libpng warning: Interlace handling should be turned on when using png_read_image
libpng warning: Interlace handling should be turned on when using png_read_image
libpng warning: Interlace handling should be turned on when using png_read_image
......] [Sound Init] Ready.
output in file /.frozen-bubble/rc failed: No such file or directory

Bug reason:

d:\Strawberry\perl\site\lib\Games\FrozenBubble\Stuff.pm

$FBHOME = "$ENV{HOME}/.frozen-bubble";

There is no HOME variable in Windows NT, there are

HOMEDRIVE=C:
HOMEPATH=\Users\abcdefgh

However yet better, for the Windows filesystem standard, would be using yet another variable - the roaming (network-shared in the domain) application data - APPDATA environment var - and then there is no need to hide the FB folder (not that dot-files were hidden on Windows anyway)

So, the correct line, for windows would be

$FBHOME = "$ENV{APPDATA }/frozen-bubble";

Metadata

Metadata

Assignees

No one assigned

    Labels

    No labels
    No labels

    Projects

    No projects

    Milestone

    No milestone

    Relationships

    None yet

    Development

    No branches or pull requests

    Issue actions