mirror of
https://github.com/EnderIce2/rpc-bridge.git
synced 2025-07-06 04:49:14 +00:00
Compare commits
15 Commits
9d2440f616
...
v1.4.0.0
Author | SHA1 | Date | |
---|---|---|---|
77a2a748ad
|
|||
0d4f46e536
|
|||
d065019137
|
|||
e03dce1a7c
|
|||
7c806779d2
|
|||
885cf775f9
|
|||
7c07952df1
|
|||
ea566cfdeb
|
|||
d56de21e74
|
|||
26a016cb26
|
|||
edfcce2ae9
|
|||
9bec33c358 | |||
3e6b5dbb43
|
|||
4c432a0e50
|
|||
65b5625a57
|
8
.github/ISSUE_TEMPLATE/bug_report.md
vendored
8
.github/ISSUE_TEMPLATE/bug_report.md
vendored
@ -21,11 +21,11 @@ Steps to reproduce the behavior:
|
||||
If applicable, add screenshots to help explain your problem.
|
||||
|
||||
**Log File**
|
||||
Located in `/path/to/prefix/drive_c/windows/logs/bridge.log`
|
||||
Located in `/path/to/prefix/drive_c/windows/logs/bridge.log` or a screenshot with the terminal should suffice.
|
||||
|
||||
**Device (please complete the following information):**
|
||||
- OS: [e.g. SteamOS, Ubuntu, macOS]
|
||||
- Version [e.g. 22.04]
|
||||
**System Info (please complete the following information):**
|
||||
- OS: [e.g. SteamOS 3.0, Ubuntu 22.04, macOS 15, or output from command `uname -srm`]
|
||||
- Wine: [e.g. 10.5]
|
||||
|
||||
**Additional context**
|
||||
Add any other context about the problem here.
|
||||
|
35
.github/workflows/build.yml
vendored
Normal file
35
.github/workflows/build.yml
vendored
Normal file
@ -0,0 +1,35 @@
|
||||
name: Build Project
|
||||
|
||||
on:
|
||||
push:
|
||||
branches: [ "master" ]
|
||||
paths-ignore:
|
||||
- 'ISSUE_TEMPLATE/**'
|
||||
- 'workflows/**'
|
||||
- '.vsocde/**'
|
||||
- 'docs/**'
|
||||
pull_request:
|
||||
branches: [ "master" ]
|
||||
paths-ignore:
|
||||
- 'ISSUE_TEMPLATE/**'
|
||||
- 'workflows/**'
|
||||
- '.vsocde/**'
|
||||
- 'docs/**'
|
||||
|
||||
permissions:
|
||||
contents: write
|
||||
|
||||
jobs:
|
||||
build:
|
||||
runs-on: ubuntu-latest
|
||||
steps:
|
||||
- uses: actions/checkout@v4
|
||||
- name: dependencies
|
||||
run: sudo apt update && sudo apt -y install gcc-mingw-w64 make
|
||||
- name: make
|
||||
run: make
|
||||
- name: artifact
|
||||
uses: actions/upload-artifact@v4
|
||||
with:
|
||||
name: bridge
|
||||
path: build
|
@ -1,29 +1,21 @@
|
||||
name: Build and Deploy docs
|
||||
name: Deploy Documentation
|
||||
|
||||
on:
|
||||
push:
|
||||
branches: [ "master" ]
|
||||
branches: [ master ]
|
||||
paths:
|
||||
- docs/**
|
||||
- mkdocs.yml
|
||||
pull_request:
|
||||
branches: [ "master" ]
|
||||
paths:
|
||||
- docs/**
|
||||
- mkdocs.yml
|
||||
|
||||
permissions:
|
||||
contents: write
|
||||
|
||||
jobs:
|
||||
build:
|
||||
runs-on: ubuntu-latest
|
||||
steps:
|
||||
- uses: actions/checkout@v4
|
||||
- name: dependencies
|
||||
run: sudo apt update && sudo apt -y install gcc-mingw-w64 make
|
||||
- name: make
|
||||
run: make
|
||||
- name: artifact
|
||||
uses: actions/upload-artifact@v4
|
||||
with:
|
||||
name: bridge
|
||||
path: build
|
||||
|
||||
deploy:
|
||||
runs-on: ubuntu-latest
|
||||
steps:
|
8
Makefile
8
Makefile
@ -4,8 +4,10 @@ C_OBJECTS = $(C_SOURCES:.c=.o)
|
||||
GIT_COMMIT = $(shell git rev-parse --short HEAD)
|
||||
GIT_BRANCH = $(shell git rev-parse --abbrev-ref HEAD)
|
||||
|
||||
CFLAGS = -std=c17 -Wno-int-conversion -DGIT_COMMIT='"$(GIT_COMMIT)"' -DGIT_BRANCH='"$(GIT_BRANCH)"'
|
||||
LFLAGS = -lgdi32
|
||||
CWARNFLAGS = -Wno-int-conversion -Wno-incompatible-pointer-types
|
||||
|
||||
CFLAGS = -std=c17 -DGIT_COMMIT='"$(GIT_COMMIT)"' -DGIT_BRANCH='"$(GIT_BRANCH)"'
|
||||
LFLAGS = -lgdi32 -lws2_32
|
||||
|
||||
# DBGFLAGS = -Wl,--export-all-symbols -g -O0 -ggdb3 -Wall
|
||||
|
||||
@ -18,7 +20,7 @@ build: $(C_OBJECTS)
|
||||
|
||||
%.o: %.c
|
||||
$(info Compiling $<)
|
||||
x86_64-w64-mingw32-gcc $(CFLAGS) $(DBGFLAGS) -c $< -o $@
|
||||
x86_64-w64-mingw32-gcc $(CFLAGS) $(CWARNFLAGS) $(DBGFLAGS) -c $< -o $@
|
||||
|
||||
clean:
|
||||
rm -f $(C_OBJECTS) build/bridge.exe bridge.res
|
||||
|
154
bridge.c
154
bridge.c
@ -20,11 +20,13 @@
|
||||
#define __darwin_close 0x2000006
|
||||
#define __darwin_socket 0x2000061
|
||||
#define __darwin_connect 0x2000062
|
||||
#define __darwin_mmap 0x20000C5
|
||||
#define __darwin_fcntl 0x200005C
|
||||
#define __darwin_sysctl 0x20000CA
|
||||
|
||||
#define O_RDONLY 00
|
||||
|
||||
/* macos & linux are the same for PROT_READ, PROT_WRITE, MAP_FIXED & MAP_PRIVATE */
|
||||
#define PROT_READ 1
|
||||
#define PROT_WRITE 2
|
||||
#define MAP_PRIVATE 0x02
|
||||
@ -32,6 +34,8 @@
|
||||
#define MAP_ANON 0x20
|
||||
#define MAP_FAILED ((void *)-1)
|
||||
|
||||
#define __darwin_MAP_ANON 0x1000
|
||||
|
||||
#define SYS_SOCKET 1
|
||||
#define SYS_CONNECT 3
|
||||
|
||||
@ -134,8 +138,17 @@ static inline int sys_close(int fd)
|
||||
|
||||
static inline unsigned int *sys_mmap(unsigned int *addr, size_t length, int prot, int flags, int fd, off_t offset)
|
||||
{
|
||||
assert(IsLinux);
|
||||
return linux_syscall(__linux_mmap2, addr, length, prot, flags, fd, offset);
|
||||
if (IsLinux)
|
||||
return linux_syscall(__linux_mmap2, addr, length, prot, flags, fd, offset);
|
||||
else
|
||||
{
|
||||
if (flags & MAP_ANON)
|
||||
{
|
||||
flags &= ~MAP_ANON;
|
||||
flags |= __darwin_MAP_ANON;
|
||||
}
|
||||
return darwin_syscall(__darwin_mmap, addr, length, prot, flags, fd, offset);
|
||||
}
|
||||
}
|
||||
|
||||
static inline int sys_munmap(unsigned int *addr, size_t length)
|
||||
@ -195,11 +208,7 @@ char *native_getenv(const char *name)
|
||||
|
||||
/* I hope the 0x20000 is okay */
|
||||
if (environStr == NULL)
|
||||
{
|
||||
environStr = sys_mmap(0x20000, 4096, PROT_READ | PROT_WRITE,
|
||||
MAP_PRIVATE | MAP_ANON | MAP_FIXED, -1, 0);
|
||||
print("Allocated 4096 bytes at %#lx\n", environStr);
|
||||
}
|
||||
environStr = sys_mmap(0x20000, 0x1000, PROT_READ | PROT_WRITE, MAP_PRIVATE | MAP_ANON | MAP_FIXED, -1, 0);
|
||||
|
||||
if ((uintptr_t)environStr > 0x7effffff)
|
||||
print("Warning: environStr %#lx is above 2GB\n", environStr);
|
||||
@ -209,18 +218,17 @@ char *native_getenv(const char *name)
|
||||
|
||||
int fd = sys_open(environStr, O_RDONLY, 0);
|
||||
|
||||
// sys_munmap(environStr, 4096);
|
||||
if (fd < 0)
|
||||
{
|
||||
print("Failed to open /proc/self/environ: %d\n", fd);
|
||||
return NULL;
|
||||
}
|
||||
|
||||
char buffer[4096];
|
||||
char *buffer = sys_mmap(0x22000, 0x1000, PROT_READ | PROT_WRITE, MAP_PRIVATE | MAP_ANON | MAP_FIXED, -1, 0);
|
||||
char *result = NULL;
|
||||
int bytesRead;
|
||||
|
||||
while ((bytesRead = sys_read(fd, buffer, sizeof(buffer) - 1)) > 0)
|
||||
while ((bytesRead = sys_read(fd, buffer, 0x1000 - 1)) > 0)
|
||||
{
|
||||
buffer[bytesRead] = '\0';
|
||||
char *env = buffer;
|
||||
@ -290,9 +298,6 @@ void ConnectToSocket(int fd)
|
||||
"%s/snap.discord-canary/discord-ipc-%d",
|
||||
};
|
||||
|
||||
struct sockaddr_un socketAddr;
|
||||
socketAddr.sun_family = AF_UNIX;
|
||||
|
||||
int sockRet = 0;
|
||||
for (int i = 0; i < sizeof(discordUnixSockets) / sizeof(discordUnixSockets[0]); i++)
|
||||
{
|
||||
@ -301,21 +306,39 @@ void ConnectToSocket(int fd)
|
||||
|
||||
for (int j = 0; j < 16; j++)
|
||||
{
|
||||
snprintf(pipePath, pipePathLen, discordUnixSockets[i], runtime, j);
|
||||
strcpy_s(socketAddr.sun_path, sizeof(socketAddr.sun_path), pipePath);
|
||||
print("Probing %s\n", pipePath);
|
||||
|
||||
if (IsLinux)
|
||||
{
|
||||
unsigned long socketArgs[] = {
|
||||
(unsigned long)fd,
|
||||
(unsigned long)(intptr_t)&socketAddr,
|
||||
sizeof(socketAddr)};
|
||||
struct sockaddr_un *socketAddr = sys_mmap(0x23000, 0x1000, PROT_READ | PROT_WRITE, MAP_PRIVATE | MAP_ANON | MAP_FIXED, -1, 0);
|
||||
print("Socket address allocated at %#lx\n", socketAddr);
|
||||
socketAddr->sun_family = AF_UNIX;
|
||||
|
||||
snprintf(pipePath, pipePathLen, discordUnixSockets[i], runtime, j);
|
||||
strcpy_s(socketAddr->sun_path, sizeof(socketAddr->sun_path), pipePath);
|
||||
print("Probing %s\n", pipePath);
|
||||
|
||||
// unsigned long socketArgs[] = {
|
||||
// (unsigned long)fd,
|
||||
// (unsigned long)(intptr_t)&socketAddr,
|
||||
// sizeof(socketAddr)};
|
||||
unsigned long *socketArgs = sys_mmap(0x24000, 0x1000, PROT_READ | PROT_WRITE, MAP_PRIVATE | MAP_ANON | MAP_FIXED, -1, 0);
|
||||
socketArgs[0] = (unsigned long)fd;
|
||||
socketArgs[1] = (unsigned long)(intptr_t)socketAddr;
|
||||
socketArgs[2] = sizeof(struct sockaddr_un);
|
||||
socketArgs[3] = 0;
|
||||
|
||||
sockRet = sys_socketcall(SYS_CONNECT, socketArgs);
|
||||
}
|
||||
else
|
||||
{
|
||||
struct sockaddr_un socketAddr;
|
||||
socketAddr.sun_family = AF_UNIX;
|
||||
|
||||
snprintf(pipePath, pipePathLen, discordUnixSockets[i], runtime, j);
|
||||
strcpy_s(socketAddr.sun_path, sizeof(socketAddr.sun_path), pipePath);
|
||||
print("Probing %s\n", pipePath);
|
||||
|
||||
sockRet = sys_connect(fd, (caddr_t)&socketAddr, sizeof(socketAddr));
|
||||
}
|
||||
|
||||
print(" error: %d\n", sockRet);
|
||||
if (sockRet >= 0)
|
||||
@ -345,18 +368,22 @@ void ConnectToSocket(int fd)
|
||||
void PipeBufferInThread(LPVOID lpParam)
|
||||
{
|
||||
bridge_thread *bt = (bridge_thread *)lpParam;
|
||||
print("In thread started using fd %d and pipe %#x\n",
|
||||
bt->fd, bt->hPipe);
|
||||
print("In thread started using fd %d and pipe %#x\n", bt->fd, bt->hPipe);
|
||||
int EOFCount = 0;
|
||||
char *l_buffer;
|
||||
if (IsLinux)
|
||||
l_buffer = sys_mmap(0x25000, 0x1000, PROT_READ | PROT_WRITE, MAP_PRIVATE | MAP_ANON | MAP_FIXED, -1, 0);
|
||||
else
|
||||
l_buffer = malloc(BUFFER_LENGTH);
|
||||
print("Buffer in thread allocated at %#lx\n", l_buffer);
|
||||
while (TRUE)
|
||||
{
|
||||
char buffer[BUFFER_LENGTH];
|
||||
int read = sys_read(bt->fd, buffer, sizeof(buffer));
|
||||
int read = sys_read(bt->fd, l_buffer, BUFFER_LENGTH);
|
||||
|
||||
if (unlikely(read < 0))
|
||||
{
|
||||
print("Failed to read from unix pipe: %d\n",
|
||||
GetErrorMessage());
|
||||
print("Failed to read from unix pipe: %d\n", read);
|
||||
Sleep(1000);
|
||||
continue;
|
||||
}
|
||||
@ -378,14 +405,16 @@ void PipeBufferInThread(LPVOID lpParam)
|
||||
}
|
||||
EOFCount = 0;
|
||||
|
||||
memcpy(buffer, l_buffer, read);
|
||||
|
||||
print("Reading %d bytes from unix pipe: \"", read);
|
||||
for (int i = 0; i < read; i++)
|
||||
print("%c", buffer[i]);
|
||||
print("\"\n");
|
||||
|
||||
DWORD dwWritten;
|
||||
if (unlikely(!WriteFile(bt->hPipe, buffer, read,
|
||||
&dwWritten, NULL)))
|
||||
WINBOOL bResult = WriteFile(bt->hPipe, buffer, read, &dwWritten, NULL);
|
||||
if (unlikely(bResult == FALSE))
|
||||
{
|
||||
if (GetLastError() == ERROR_BROKEN_PIPE)
|
||||
{
|
||||
@ -394,16 +423,14 @@ void PipeBufferInThread(LPVOID lpParam)
|
||||
break;
|
||||
}
|
||||
|
||||
print("Failed to read from pipe: %d\n",
|
||||
GetErrorMessage());
|
||||
print("Failed to read from pipe: %s\n", GetErrorMessage());
|
||||
Sleep(1000);
|
||||
continue;
|
||||
}
|
||||
|
||||
if (unlikely(dwWritten < 0))
|
||||
{
|
||||
print("Failed to write to pipe: %d\n",
|
||||
GetErrorMessage());
|
||||
print("Failed to write to pipe: %s\n", GetErrorMessage());
|
||||
Sleep(1000);
|
||||
continue;
|
||||
}
|
||||
@ -411,8 +438,8 @@ void PipeBufferInThread(LPVOID lpParam)
|
||||
while (dwWritten < read)
|
||||
{
|
||||
int last_written = dwWritten;
|
||||
if (unlikely(!WriteFile(bt->hPipe, buffer + dwWritten,
|
||||
read - dwWritten, &dwWritten, NULL)))
|
||||
WINBOOL bResult = WriteFile(bt->hPipe, buffer + dwWritten, read - dwWritten, &dwWritten, NULL);
|
||||
if (unlikely(bResult == FALSE))
|
||||
{
|
||||
if (GetLastError() == ERROR_BROKEN_PIPE)
|
||||
{
|
||||
@ -421,16 +448,14 @@ void PipeBufferInThread(LPVOID lpParam)
|
||||
break;
|
||||
}
|
||||
|
||||
print("Failed to read from pipe: %d\n",
|
||||
GetErrorMessage());
|
||||
print("Failed to read from pipe: %s\n", GetErrorMessage());
|
||||
Sleep(1000);
|
||||
continue;
|
||||
}
|
||||
|
||||
if (unlikely(last_written == dwWritten))
|
||||
{
|
||||
print("Failed to write to pipe: %d\n",
|
||||
GetErrorMessage());
|
||||
print("Failed to write to pipe: %s\n", GetErrorMessage());
|
||||
Sleep(1000);
|
||||
continue;
|
||||
}
|
||||
@ -441,15 +466,19 @@ void PipeBufferInThread(LPVOID lpParam)
|
||||
void PipeBufferOutThread(LPVOID lpParam)
|
||||
{
|
||||
bridge_thread *bt = (bridge_thread *)lpParam;
|
||||
print("Out thread started using fd %d and pipe %#x\n",
|
||||
bt->fd, bt->hPipe);
|
||||
print("Out thread started using fd %d and pipe %#x\n", bt->fd, bt->hPipe);
|
||||
char *l_buffer;
|
||||
if (IsLinux)
|
||||
l_buffer = sys_mmap(0x26000, 0x1000, PROT_READ | PROT_WRITE, MAP_PRIVATE | MAP_ANON | MAP_FIXED, -1, 0);
|
||||
else
|
||||
l_buffer = malloc(BUFFER_LENGTH);
|
||||
print("Buffer out thread allocated at %#lx\n", l_buffer);
|
||||
while (TRUE)
|
||||
{
|
||||
char buffer[BUFFER_LENGTH];
|
||||
DWORD dwRead;
|
||||
|
||||
if (unlikely(!ReadFile(bt->hPipe, buffer, sizeof(buffer),
|
||||
&dwRead, NULL)))
|
||||
WINBOOL bResult = ReadFile(bt->hPipe, buffer, BUFFER_LENGTH, &dwRead, NULL);
|
||||
if (unlikely(bResult == FALSE))
|
||||
{
|
||||
if (GetLastError() == ERROR_BROKEN_PIPE)
|
||||
{
|
||||
@ -458,8 +487,7 @@ void PipeBufferOutThread(LPVOID lpParam)
|
||||
break;
|
||||
}
|
||||
|
||||
print("Failed to read from pipe: %d\n",
|
||||
GetErrorMessage());
|
||||
print("Failed to read from pipe: %s\n", GetErrorMessage());
|
||||
Sleep(1000);
|
||||
continue;
|
||||
}
|
||||
@ -469,11 +497,11 @@ void PipeBufferOutThread(LPVOID lpParam)
|
||||
print("%c", buffer[i]);
|
||||
print("\"\n");
|
||||
|
||||
int written = sys_write(bt->fd, buffer, dwRead);
|
||||
memcpy(l_buffer, buffer, dwRead);
|
||||
int written = sys_write(bt->fd, l_buffer, dwRead);
|
||||
if (unlikely(written < 0))
|
||||
{
|
||||
print("Failed to write to socket: %d\n",
|
||||
written);
|
||||
print("Failed to write to socket: %d\n", written);
|
||||
continue;
|
||||
}
|
||||
|
||||
@ -483,8 +511,7 @@ void PipeBufferOutThread(LPVOID lpParam)
|
||||
written += sys_write(bt->fd, buffer + written, dwRead - written);
|
||||
if (unlikely(last_written == written))
|
||||
{
|
||||
print("Failed to write to socket: %d\n",
|
||||
GetErrorMessage());
|
||||
print("Failed to write to socket: %s\n", GetErrorMessage());
|
||||
Sleep(1000);
|
||||
continue;
|
||||
}
|
||||
@ -547,16 +574,31 @@ NewConnection:
|
||||
int fd;
|
||||
if (IsLinux)
|
||||
{
|
||||
unsigned long socketArgs[] = {
|
||||
(unsigned long)AF_UNIX,
|
||||
(unsigned long)SOCK_STREAM,
|
||||
0};
|
||||
// unsigned long socketArgs[] = {
|
||||
// (unsigned long)AF_UNIX,
|
||||
// (unsigned long)SOCK_STREAM,
|
||||
// 0};
|
||||
unsigned long *socketArgs = sys_mmap(0x21000, 0x1000, PROT_READ | PROT_WRITE, MAP_PRIVATE | MAP_ANON | MAP_FIXED, -1, 0);
|
||||
socketArgs[0] = (unsigned long)AF_UNIX;
|
||||
socketArgs[1] = (unsigned long)SOCK_STREAM;
|
||||
socketArgs[2] = 0;
|
||||
fd = sys_socketcall(SYS_SOCKET, socketArgs);
|
||||
|
||||
/* FIXME: WSAEAFNOSUPPORT: https://gitlab.winehq.org/wine/wine/-/merge_requests/2786 */
|
||||
// WSADATA wsaData;
|
||||
// int iResult = WSAStartup(MAKEWORD(2, 2), &wsaData);
|
||||
// if (iResult != 0)
|
||||
// printf("WSAStartup failed: %d\n", iResult);
|
||||
// fd = socket(AF_UNIX, SOCK_STREAM, 0);
|
||||
}
|
||||
else
|
||||
fd = sys_socket(AF_UNIX, SOCK_STREAM, 0);
|
||||
|
||||
print("Socket %d created\n", fd);
|
||||
if (fd == INVALID_SOCKET)
|
||||
{
|
||||
print("invalid socket: %d %d\n", fd, WSAGetLastError());
|
||||
ExitProcess(1);
|
||||
}
|
||||
|
||||
if (fd < 0)
|
||||
{
|
||||
@ -567,6 +609,8 @@ NewConnection:
|
||||
ExitProcess(1);
|
||||
}
|
||||
|
||||
print("Socket %d created\n", fd);
|
||||
|
||||
ConnectToSocket(fd);
|
||||
print("Connected to Discord\n");
|
||||
|
||||
|
@ -19,7 +19,7 @@ BEGIN
|
||||
VALUE "FileDescription", "Simple bridge that allows you to use Discord Rich Presence with Wine games/software."
|
||||
VALUE "FileVersion", VER_VERSION_STR
|
||||
VALUE "InternalName", "bridge"
|
||||
VALUE "LegalCopyright", "Copyright (c) 2024 EnderIce2"
|
||||
VALUE "LegalCopyright", "Copyright (c) 2025 EnderIce2"
|
||||
VALUE "OriginalFilename", "bridge.exe"
|
||||
VALUE "ProductName", "rpc-bridge"
|
||||
VALUE "ProductVersion", VER_VERSION_STR
|
||||
|
@ -9,7 +9,7 @@ Simple bridge that allows you to use Discord Rich Presence with Wine games/softw
|
||||
|
||||
[Download latest release](https://github.com/EnderIce2/rpc-bridge/releases/latest/download/bridge.zip "Recommended"){ .md-button .md-button--primary }
|
||||
[Download latest pre-release](https://github.com/EnderIce2/rpc-bridge/releases "Unstable builds with experimental features"){ .md-button }
|
||||
<!-- [Download latest build](https://github.com/EnderIce2/rpc-bridge/actions "Builds from the latest commits, here be dragons!"){ .md-button } -->
|
||||
[Download latest build](https://github.com/EnderIce2/rpc-bridge/actions/workflows/build.yml "Builds from the latest commits, here be dragons!"){ .md-button }
|
||||
|
||||
Works by running a small program in the background that creates a [named pipe](https://learn.microsoft.com/en-us/windows/win32/ipc/named-pipes) `\\.\pipe\discord-ipc-0` inside the prefix and forwards all data to the pipe `/run/user/1000/discord-ipc-0`.
|
||||
|
||||
|
@ -84,21 +84,17 @@ In Lutris, you can achieve this by adding the path to `bridge.exe` in the `Execu
|
||||
|
||||
=== "Without bridge"
|
||||
|
||||
```
|
||||
Executable
|
||||
/mnt/games/lutris/league-of-legends/drive_c/Riot Games/League of Legends/LeagueClient.exe
|
||||
Arguments
|
||||
--locale=en_US --launch-product=league_of_legends --launch-patchline=live
|
||||
```
|
||||
- Executable
|
||||
- `/mnt/games/lutris/league-of-legends/drive_c/Riot Games/League of Legends/LeagueClient.exe`
|
||||
- Arguments
|
||||
- `--locale=en_US --launch-product=league_of_legends --launch-patchline=live`
|
||||
|
||||
=== "With bridge"
|
||||
|
||||
```
|
||||
Executable
|
||||
/mnt/games/lutris/league-of-legends/drive_c/bridge.exe
|
||||
Arguments
|
||||
"C:\Riot Games\League of Legends\LeagueClient.exe" --locale=en_US --launch-product=league_of_legends --launch-patchline=live
|
||||
```
|
||||
- Executable
|
||||
- `/mnt/games/lutris/league-of-legends/drive_c/bridge.exe`
|
||||
- Arguments
|
||||
- `"C:\Riot Games\League of Legends\LeagueClient.exe" --locale=en_US --launch-product=league_of_legends --launch-patchline=live`
|
||||
|
||||
In Wine, all you need to do is run `bridge.exe` and select `Start`.
|
||||
|
||||
|
2
main.c
2
main.c
@ -59,7 +59,7 @@ void DetectWine()
|
||||
if (!GetProcAddress(hNTdll, "wine_get_version"))
|
||||
{
|
||||
MessageBox(NULL, "This program is only intended to run under Wine.",
|
||||
GetErrorMessage(), MB_OK | MB_ICONINFORMATION);
|
||||
"Error", MB_OK | MB_ICONINFORMATION);
|
||||
ExitProcess(1);
|
||||
}
|
||||
|
||||
|
@ -5,5 +5,5 @@
|
||||
#define IDM_HELP_ABOUT 40003
|
||||
#define IDM_VIEW_LOG 40004
|
||||
|
||||
#define VER_VERSION 1, 3, 0, 0
|
||||
#define VER_VERSION_STR "1.3\0"
|
||||
#define VER_VERSION 1, 4, 0, 0
|
||||
#define VER_VERSION_STR "1.4.0.0\0"
|
||||
|
Reference in New Issue
Block a user