FunkinCrew / Funkin

A rhythm game made with HaxeFlixel
https://www.newgrounds.com/portal/view/770371
Other
2.91k stars 2.26k forks source link

Bug Report: Game window does not show under Wayland on Linux #2498

Open HTV04 opened 4 months ago

HTV04 commented 4 months ago

Please check for duplicates or similar issues, as well performing simple troubleshooting steps (such as clearing cookies, clearing AppData, trying another browser) before submitting an issue.

If you are playing the game in a browser, what site are you playing it from?

If you are playing the game in a browser, what browser are you using?

What version of the game are you using? Look in the bottom left corner of the main menu. (ex: 0.2.7, 0.2.1, shit like that)

0.3.2, compiled from source

Have you identified any steps to reproduce the bug? If so, please describe them below in as much detail as possible. Use images if possible.

Yes. Set the shell variable SDL_VIDEODRIVER to wayland so that SDL uses a Wayland backend. The game window will not appear, but audio will play in the background and no errors will appear in the terminal, signifying that the game has not crashed.

Please describe your issue. Provide extensive detail and images if possible.

When SDL_VIDEODRIVER is set to wayland, programs should run normally without any additional modifications. I'm not exactly sure if this is an issue with HaxeFlixel or Lime more than it is an issue with the game. It may be a Lime issue based on the fact that it has its own version of SDL. I did rebuild Lime via lime rebuild linux -64 -release, so using a pre-built version of Lime is not the issue.

To mitigate this issue, one can set SDL_VIDEODRIVER to x11, which is currently the default, but relies on XWayland.

If you're game is FROZEN and you're playing a web version, press F12 to open up browser dev window, and go to console, and copy-paste whatever red error you're getting

Stilic commented 4 months ago

Does this happen with every HaxeFlixel game, or only FNF?

NotHyper-474 commented 1 month ago

Tried this on a template Flixel project and got the same result.

Stilic commented 1 month ago

So it's an OpenFL issue at this point.

1a2s3d4f1 commented 2 weeks ago

Use some environment variables can make game running with wayland. (See https://github.com/renpy/renpy/issues/3290)

export SDL_DYNAMIC_API=/usr/lib64/libSDL2-2.0.so.0
export SDL_VIDEODRIVER=wayland

屏幕截图_20240831_202417 PS: Wayland is not supported now. may cause some problems.

Stilic commented 2 weeks ago

SDL_DYNAMIC_API=/usr/lib64/libSDL2-2.0.so.0

I don't have window decorations on Gnome.

1a2s3d4f1 commented 2 weeks ago

You could install sdl library from package manager of system. example sudo pacman -S sdl2

moxie-coder commented 2 weeks ago

I've not had a problem with FNF under Arch in Wayland, I've not tested the vanilla game yet but outside of that, it seems to be fine for me

Stilic commented 2 weeks ago

You could install sdl library from package manager of system. example sudo pacman -S sdl2

I already have it installed.