From 3797a1e9efa9423c5512004c18860c283a54301b Mon Sep 17 00:00:00 2001 From: oldmud0 Date: Mon, 8 Jan 2018 00:40:50 -0600 Subject: Add Discord rich presence This would work, were it not for some freak stack corruption caused by GCC not liking the Discord RPC library... --- Attorney_Online_remake.pro | 14 +++++++++++--- 1 file changed, 11 insertions(+), 3 deletions(-) (limited to 'Attorney_Online_remake.pro') diff --git a/Attorney_Online_remake.pro b/Attorney_Online_remake.pro index 1f4df763..40355c5c 100644 --- a/Attorney_Online_remake.pro +++ b/Attorney_Online_remake.pro @@ -47,7 +47,8 @@ SOURCES += main.cpp\ aotextarea.cpp \ aolineedit.cpp \ aotextedit.cpp \ - aoevidencedisplay.cpp + aoevidencedisplay.cpp \ + discord_rich_presence.cpp HEADERS += lobby.h \ aoimage.h \ @@ -76,9 +77,16 @@ HEADERS += lobby.h \ aotextarea.h \ aolineedit.h \ aotextedit.h \ - aoevidencedisplay.h + aoevidencedisplay.h \ + discord_rich_presence.h -unix:LIBS += -L$$PWD -lbass +# 1. You need to get BASS and put the x86 bass DLL/headers in the project root folder +# AND the compilation output folder. If you want a static link, you'll probably +# need the .lib file too. MinGW-GCC is really finicky finding BASS, it seems. +# 2. You need to compile the Discord Rich Presence SDK separately and add the lib/headers +# in the same way as BASS. Discord RPC uses CMake, which does not play nicely with +# QMake, so this step must be manual. +unix:LIBS += -L$$PWD -lbass -ldiscord-rpc win32:LIBS += "$$PWD/bass.dll" android:LIBS += -L$$PWD\android\libs\armeabi-v7a\ -lbass -- cgit From dee8de29da7b72b5a1b2566311402933bacf007f Mon Sep 17 00:00:00 2001 From: oldmud0 Date: Mon, 8 Jan 2018 01:13:56 -0600 Subject: Just switch to DLLs. --- Attorney_Online_remake.pro | 5 +++-- 1 file changed, 3 insertions(+), 2 deletions(-) (limited to 'Attorney_Online_remake.pro') diff --git a/Attorney_Online_remake.pro b/Attorney_Online_remake.pro index 40355c5c..1c5ba4ed 100644 --- a/Attorney_Online_remake.pro +++ b/Attorney_Online_remake.pro @@ -78,7 +78,8 @@ HEADERS += lobby.h \ aolineedit.h \ aotextedit.h \ aoevidencedisplay.h \ - discord_rich_presence.h + discord_rich_presence.h \ + discord-rpc.h # 1. You need to get BASS and put the x86 bass DLL/headers in the project root folder # AND the compilation output folder. If you want a static link, you'll probably @@ -87,7 +88,7 @@ HEADERS += lobby.h \ # in the same way as BASS. Discord RPC uses CMake, which does not play nicely with # QMake, so this step must be manual. unix:LIBS += -L$$PWD -lbass -ldiscord-rpc -win32:LIBS += "$$PWD/bass.dll" +win32:LIBS += -L$$PWD "$$PWD/bass.dll" -ldiscord-rpc #"$$PWD/discord-rpc.dll" android:LIBS += -L$$PWD\android\libs\armeabi-v7a\ -lbass CONFIG += c++11 -- cgit