mirror of
https://github.com/cyberarm/w3d_hub_linux_launcher.git
synced 2026-09-21 07:43:57 +00:00
Compare commits
3 Commits
53e7a72ceb
...
developmen
| Author | SHA1 | Date | |
|---|---|---|---|
| 2737336c5d | |||
| 9348367994 | |||
| 80954522e5 |
@@ -12,17 +12,24 @@ module W3DHubLauncher
|
||||
end
|
||||
|
||||
def self.run(app, *args)
|
||||
exe_path = app.id == "ecw" ? format("%s/game500.exe", app.installation_path) : format("%s/game.exe", app.installation_path)
|
||||
exe_path = case app.id
|
||||
when "ecw" # ecw is a little special. each of its numbered exes represents a max render distance.
|
||||
format("%s/game500.exe", app.installation_path)
|
||||
when "ren" # little hacky. TT auto patching launcher doesn't work* on linux so bypass it.
|
||||
format("%s/game2.exe", app.installation_path)
|
||||
else # the rest of the games are reasonably sane.
|
||||
format("%s/game.exe", app.installation_path)
|
||||
end
|
||||
|
||||
env = {}
|
||||
unless wine_prefix(app).to_s.empty?
|
||||
env["WINEPREFIX"] = wine_prefix(app).to_s
|
||||
end
|
||||
env["DXVK_HUD"] = "full"
|
||||
# env["DXVK_HUD"] = "full"
|
||||
|
||||
pid = Process.spawn(
|
||||
env,
|
||||
"#{wine_command(app)}#{exe_path} -launcher #{args.join(' ')}"
|
||||
"#{wine_command(app)}\"#{exe_path}\" -launcher #{args.join(' ')}"
|
||||
)
|
||||
|
||||
Process.detach(pid)
|
||||
|
||||
@@ -227,7 +227,9 @@ module W3DHubLauncher
|
||||
end
|
||||
end
|
||||
else
|
||||
button "Import", enabled: false, tip: "Import existing application installation", fill: true, height: 1.0, **CTA_BUTTON_THEME
|
||||
button "Import", tip: "Import existing application installation", fill: true, height: 1.0, **CTA_BUTTON_THEME do |btn|
|
||||
dialog(Dialog::ImportApplication, application: @current_app, channel: @current_channel)
|
||||
end
|
||||
end
|
||||
end
|
||||
end
|
||||
|
||||
@@ -168,13 +168,13 @@ module W3DHubLauncher
|
||||
map_image_container = stack(width: 1.0, height: (@server_details_container.content_width / 640.0) * 360, background_image: safe_get_image(server.map_preview_image_path, fallback_path: "#{ROOT_PATH}/media/default_map_preview.png")) do
|
||||
caption(
|
||||
server.current_map,
|
||||
text_border: false,
|
||||
text_border: true,
|
||||
text_border_size: 1,
|
||||
text_border_color: Gosu::Color::RED,
|
||||
text_border_color: 0xaa_000000,
|
||||
text_shadow: false,
|
||||
width: 1.0,
|
||||
height: 1.0,
|
||||
padding_bottom: PADDING,
|
||||
padding_bottom: HALF_PADDING,
|
||||
text_align: :center,
|
||||
text_v_align: :bottom,
|
||||
tip: server.current_map
|
||||
|
||||
Binary file not shown.
|
Before Width: | Height: | Size: 16 KiB After Width: | Height: | Size: 24 KiB |
Reference in New Issue
Block a user