Hacker News new | ask | show | jobs
by ldd 2017 days ago
I was seriously considering adding Linux support for my game, that already has turn-based multiplayer, and this thread was the last thing I needed to convince myself it could work.

Performance may be an issue. I wonder if people would be ok with electron games sold on steam running on linux...

13 comments

One of the games I run the infrastructure from had an issue with Proton. It caused issues with the multiplayer parts of the game.

We were forced to disable support for Proton a few months ago. We posted a bug in the Proton GitHub repo and got a great response from the Devs. The issue was resolved in the very next patch and we were able to enable Proton support again.

Other than that issue our players very rarely come to us with Proton specific issues.

Normally electron apps bother me on linux because they don't use my carefully selected GTK/QT/Openbox theming like most native apps do (whereas on windows I don't care because I don't have the ability to make anything look how I want).

But I expect games to be fullscreen and have their own bespoke UI look and feel anyway, so it's not really an issue with them.

Electron apps bother me because nobody bothers to make Linux builds for proprietary electron apps. Running windows builds of electron apps under wine doesn't always work. At this point windows applications using Microsoft APIs are more cross platform portable than electron apps.
Do you have consistency between GTK/Qt, or only within each? I've never really bothered to set it up (just installed some theme I pulled a name from Arch wiki for, so buttons look like they're from this century) because I assumed I could go to a load of effort and still notice which is used for each program I use.

And then find myself caring which I install if I have the option, or not wanting to if it's only available in the wrong one.. whereas I'm presently free of that.

With a bit of effort it’s a solved problem, however as soon as that was sorted, developers started using snaps and flatpaks that just Do Not Care about your system settings... and we’re back at square -1, because now you won’t even get consistency between Gtk apps and Gtk apps.

The Linux desktop sometimes is like a bad comedy sketch.

Well now I've gone from not caring about snap/flatpak (only selling point seemed to be ease of install; I've never had a problem with arch & the AUR) to making mental note to steer well clear if the temptation ever began to set in.
Yes snap is bad. Compared to the AUR qhere you can read the build script, snap is compiled by someone else and the build script isnt available to perform yourself, at least as far as I looked.
The advantage here is that malware can't be shipped as part of the build process.
I tried Ubuntu for a couple of weeks because I felt that the installation procedure for Arch would take some time for me to set up and I wanted to be up and running a bit faster.

After 4 weeks and every app having so many hoops to jump through because of snaps to get them working together I jumped ship and went back to Arch and the AUR. It's just such a difference in user experience. I feel that Ubuntu is doing a big disservice with snaps (haven't used flatpack that much) to the Linux Desktop community. If it's impossible for me to understand how to use it efficiently, then there is no way in hell I will point my father towards Ubuntu.

Out of curiosity, which apps do you use that come packaged in a snap? My Ubuntu 20.04 tells me this:

  $ snap list
  Name                 Version                     Rev    Tracking         Publisher   Notes
  canonical-livepatch  9.5.5                       95     latest/stable    canonical  -
  core                 16-2.48                     10444  latest/stable    canonical  core
  core18               20200929                    1932   latest/stable    canonical  base
  gnome-3-28-1804      3.28.0-19-g98f9e67.98f9e67  145    latest/stable    canonical  -
  gnome-3-34-1804      0+git.3556cb3               60     latest/stable    canonical  -
  gtk-common-themes    0.1-50-gf7627e4             1514   latest/stable/…  canonical  -
  snap-store           3.38.0-55-geb45541          498    latest/stable/…  canonical  -
I think it's the bare minimum before utterly removing all support for snaps [1].

I installed everything I need either as .deb or docker. BTW, slack has a deb on its download page.

I installed another 20.04 on my old laptop from 2006 yesterday because I read that its kernel would finally support again the old ATI X1600 graphic card. It does. When I run emacs and thunderbird from terminal it told me "command not found" and something along the lines of do you want to install as a snap or with apt? I run the apt commands.

[1] https://www.kevin-custer.com/blog/disabling-snaps-in-ubuntu-...

Thunderbird, Kdenlive, Darktable, Gimp, KeePassXC, VLC, Minecraft

Those are the ones I remember. I needed to install them via snap because the deb packages were too old to be able to open my files which I copied over from my Arch installation.

I mean, it's just back to the state of windows where even most of Microsoft's apps aren't consistent with each other
Windows actually used to be decent and fairly consistent, but I agree that it's gone to shit in the last decade. They botched scaling to HiDpi and fragmented their UIs in the sad attempt to chase convergence with touch UIs.
did it ? except win 3.1 (but then I was a small kid) I remember a huge majority of apps having their own little fancy skins in 98, XP, etc
Do snaps/flatpaks really not look at your local configs? Thats... terrible. I've avoided them already anyway because they seem like wholly unnecessary (and quite significant) bloat.
Flatpak does respect your GTK+ Theme - but you have to either have it installed in ~/.local/share/themes or youbhave to download your theme as flatpak package aswell. But that implies that someone has to maintain the flatpak packge.

While the most popular themes are available, more "niece" themes are missing. Do a `flatpak remote-ls flathub | grep --color "org.gtk.Gtk3theme"` to see all available themes.

Note: I'm maintaining a theme on flathub.

Maybe it's just me, but distro repo usually has only esoteric and metro themes, so if I want something usable, it ends up in .local.
No, probably because that's outside their scope and so they're not allowed to read them.
Surely the sane thing to do security wise would be to mark each flatpak as needing config files foo and bar, and sticking those into the sandbox as well on launch. The app itself doesn't need filesystem access at runtime. Linux apps suddenly not reading standard config files on my system would be a pretty big downside.
They do by the way of an xsettingsdaemon (so not accessing directly) for security reasons. The obstacle instead is that they are self-contained, so they should not depend on the theme files outside their system. Hence, they will read what theme you are using and then inside their system look for a matching one.
You can set up QT to use GTK themes (seems like this is the default in KDE Plasma): https://wiki.archlinux.org/index.php/Uniform_look_for_Qt_and...

I currently just don't have any QT based apps on my Arch system though I don't think.

I came at it the other way - make GTK apps look like Qt ones. Everything on my system uses Breeze Dark. The only way I can tell GTK programs from Qt ones is the "About" dialog, or the file picker. (Oh, how I wish I could use the Qt file picker in GTK programs)

(edit: QT -> Qt. Seasons greetings to the flagkilled throwaway who informed me of my mistake.)

It's not actually translating GTK themes to QT, its special themes with both QT and GTK versions.
The linked wiki page lists both.
It lists both for Qt 4, but afaiu for Qt5 you need to use special combined themes.
Ah, thanks, I think it's adwaita (mentioned there) that I picked at (pseudo)random, so maybe I already have it.

Not sure if I have any either to be honest, but that's what I mean, I like not worrying about it.

I'm a big fan of the Arc theme.
Yes: https://wiki.archlinux.org/index.php/Uniform_look_for_Qt_and...

(Distros that are not Arch usually set up one of these solutions out of the box).

It works very well for traditional QWidget/GTK style desktop apps. However, with both QtQuick/QML apps and modern Gnome apps, they have more divergent paradigms and particularly the QML apps tend to be less consistent with each other, never mind other UI toolkits, for much of the same reason webapps also are.

Maybe I'm weird but I would rather use a wine app than a native electron app.
I've never thought that Linux Desktop provides unified desktop experience.
It does out of the box on a lot of distros, and you absolutely can DIY it to the point where you have a consistent look and feel with even totally custom theming. Check out /r/unixporn for some examples. (Although they often lean towards a very specific aesthetic - bitmap fonts and anime girls are a bit of a meme there)
It's spelled Qt, not QT.

QT means QuickTime.

I feel such persistence in the face of adversity should be rewarded :)
Not sure if you've seen crosscode, but they released on steam and other platforms with impactjs and they're doing very well. (Not quite electron, but still html tech) If it runs well, who cares about the tech :-) People seem to complain about electron in tools and background apps. If it's the main/fullscreen app, it shouldn't be a problem.
Never in my life would I have expected crosscode to be anything like HTML/JS based. That’s one of the most fluent games I’ve played.
It took a lot of work to make it performant on something like a switch. In the end I'm not sure if it's quite HTML/JS based anymore. I can't find the tech talk video where the porting guy goes into all his work to make it work on a switch.

Save yourself some hassle, just make your game with gamemaker, UE4 or unity if you have any ambitions of going cross platform in the vague future unless it's really simple point and click slow paced strategy games, a dating sim / story game or similar.

It runs on top of a multimedia library called Kha while running on consoles (https://github.com/Kode/Kha).

Here's the talk you're (probably) talking about: https://www.youtube.com/watch?v=KfBzlzvt8RU

Eh, I loved it but for a 2D game I had an awful lot of slowdowns on my gaming laptop (https://www.newegg.com/matte-black-with-gold-diamond-cut-msi...)
Don't know if that's the best analogy. Most Electron application's performances are "good enough"; there's still room for improvement, but it's not as important as performance in video games.
Crosscode ran badly when I tried it.
There's some issue with the build of nodejs they're using on macs, but otherwise it should be quite good. No issues across multiple machines I've played on. May be something specific to yours?
Linux gamer here. I spend a lot of money on the steam store.
Now you have to tell us how much money so we have an idea what unixhero boldly confesses on a forum where the A+ players hangout.
Get ready for 2% of your player base to make 50% of the support requests.
Plan B worth it, Valve invest his resources not just for fun.
you will have the same bad performance of electron on Windows, Linux and OSX.
Thank you! At the very least please try to make it work with proton :)
Go for it. Others already do that use Electron. Shapez.io is one such title and it's open source too so you can get some pointers if needed from it.
Haven't heard of Shapez.io before, so went to try it out.

Going to Shapez.io though gives a Cloudflare error: "Error 521: Web server is down". :(

Trying the Wayback Machine, there's "something" on there but it doesn't seem to work. (?) eg:

http://web.archive.org/web/20201120204614/https://shapez.io/

Just checked, https://shapez.io/ works fine here. There's the GitHub too: https://github.com/tobspr/shapez.io
very weird to have this as my most upvoted post, but eh. If there is a time to shill out, it's now:

A game inspired by Nuzlocke Challenges + Slay the Spire

discord: http://discord.gg/u64Mg4X

twitter: https://twitter.com/_ldd

mailing list: tiny.cc/dxx5tz

If it can run in Electron, why not just make it a PWA?
Discord and spotify are both electron on Linux, so I would imagine it would work.
Spotify used to be Qt, has it changed?
Yes, yes it has. The UI is still quite good, and doesn't seem to have the downsides that many Electron apps have, except for the amount of memory used by it (still much less than Slack or Skype)
One of the selling points of Electron was making easy to port apps between platforms.
Performance is not an issue.
Some games seem to report measurably better performance on Linux, even. I imagine outside the steady-state, loading times could be a boon for Linux given that Linux filesystems are "faster"
Almost all games use their own VFS layer which heavily lean toward "few huge files with a lookup table" to work around NTFS' deficiencies. They used to be often chunked into 2 GB files, but since a few years developers stopped doing that. Some games even ship all their assets in a single file.
Historically they do that because of consoles, not NTFS.
We always appreciate the effort.