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

Completely eliminate the awkward installer with a runtime script instead #83

Open
zekesonxx opened this issue Sep 14, 2017 · 5 comments
Labels
installer Relating to the BLT4L installation system
Milestone

Comments

@zekesonxx
Copy link
Member

Introducing: blt4l_launcher. A single-file bash launcher script, designed for distro packaging with no external dependencies (except zenity for error messages, but that's wholly optional).

Features:

  • Automatically copy in mods/ if missing
  • Automatically copy in mods/base/ if missing
  • Detects the Steam runtime and switches binaries as needed
  • Loads a binary in the gamedir if present (so, will look for $PAYDAY2/libblt_loader.so before /usr/lib/blt4l/libblt_loader.so)
  • Fail gracefully

Rough idea of new blt4l install instructions:

  1. Install the respective blt4l package for your distro: Debian, Fedora, Arch, etc
  2. Set PAYDAY 2's launch options in Steam to blt4l %command%
  3. Run the game

Pros over the old system:

  • Distro packaging friendly
    • Easily change library or mods dir paths using simple patch files on the script
    • No install time scripts
  • Handles running with or without the Steam runtime without missing a beat
  • No user interaction needed to install the mods directory
  • Simply delete mods/base and run the game again to repair/update the base mod
  • Easily distribute updates or modifications to the base mod, just tell the user to delete mods/base to update.
  • Don't have to figure out where the game is (Steam will automatically put us there)

Cons over the old system:

  • Doesn't automatically modify the game's launch options
    but it is a lot simpler to explain to a user on how to do it
  • Less friendly to installing outside of a package manager

Folder mockup of a proper package install (Arch standards here):

/usr
└── bin
    └──blt4l (installer script)
└── lib
    └── blt4l
        ├── libblt_loader.so (compiled for the distro)
        ├── libblt_loader_steamrt.so (compiled for the steam runtime)
        └── mods (mods folder from the repo)
            └── ...
@RomanHargrave
Copy link
Member

RomanHargrave commented Sep 15, 2017

Doesn't automatically modify the game's launch options

but we could write a launcher installer launcher 🎉

all in all, I like this

@zekesonxx
Copy link
Member Author

Technically I could add something like blt4l -install that would inject the launch options into Steam's vdf files, but that feels like a lot of work and added script bulk for almost no payoff.

@RomanHargrave RomanHargrave added the installer Relating to the BLT4L installation system label Sep 15, 2017
@zekesonxx
Copy link
Member Author

@RomanHargrave shall I move the repo over to the blt4linux organization?

@RomanHargrave
Copy link
Member

If you want.

@RomanHargrave
Copy link
Member

I'm revisiting issues at the moment, and had some thoughts on this.

The installer is more than just that, it's a collection of scripts to automate a source build for end users. Setting the launch parameters is somewhat of a tertiary concern. Perhaps if we were to install a launch wrapper, and then configure steam to use it instead of the current approach. It has the benefit of the launcher in being more end-user friendly and robust, as well as giving us the ability to redirect the game output to a file, and we retain the automated process of building BLT and putting it in the proper place (most of the time). Ultimately, the launcher alone runs in to the same problem as does the installer here, though, which is putting files in the proper place. If we want to properly store BLT in known location (like /var, or /opt, with the launcher in the path), we need to have write access to the root filesystem, otherwise we need to rely on the user having an environment configured to search $HOME/.local/bin or similar, which is not 100% guaranteed.

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
installer Relating to the BLT4L installation system
Projects
None yet
Development

No branches or pull requests

2 participants