aboutsummaryrefslogtreecommitdiff
diff options
context:
space:
mode:
Diffstat (limited to 'games-engines/fs2_open/files/fs2_open-23.0.0-disable-discord.patch')
-rw-r--r--games-engines/fs2_open/files/fs2_open-23.0.0-disable-discord.patch107
1 files changed, 107 insertions, 0 deletions
diff --git a/games-engines/fs2_open/files/fs2_open-23.0.0-disable-discord.patch b/games-engines/fs2_open/files/fs2_open-23.0.0-disable-discord.patch
new file mode 100644
index 000000000..6dc01d4a4
--- /dev/null
+++ b/games-engines/fs2_open/files/fs2_open-23.0.0-disable-discord.patch
@@ -0,0 +1,107 @@
+--- fs2_open/freespace2/freespace.cpp 2023-02-11 13:13:50.000000000 +0100
++++ fs2_open/freespace2/freespace.cpp 2023-02-11 13:32:41.501644997 +0100
+@@ -84,7 +84,6 @@
+ #include "io/timer.h"
+ #include "jumpnode/jumpnode.h"
+ #include "lab/labv2.h"
+-#include "libs/discord/discord.h"
+ #include "libs/ffmpeg/FFmpeg.h"
+ #include "lighting/lighting.h"
+ #include "lighting/lighting_profiles.h"
+@@ -1987,9 +1986,6 @@
+ #ifdef WITH_FFMPEG
+ libs::ffmpeg::initialize();
+ #endif
+- if (Discord_presence) {
+- libs::discord::init();
+- }
+ }
+
+ mod_table_post_process();
+--- fs2_open/code/source_groups.cmake 2023-02-11 13:13:50.000000000 +0100
++++ fs2_open/code/source_groups.cmake 2023-02-11 13:53:03.901702823 +0100
+@@ -706,11 +706,6 @@
+ libs/antlr/ErrorListener.h
+ )
+
+-add_file_folder("Libs\\\\Discord"
+- libs/discord/discord.cpp
+- libs/discord/discord.h
+-)
+-
+ if (FSO_BUILD_WITH_FFMPEG)
+ add_file_folder("Libs\\\\FFmpeg"
+ libs/ffmpeg/FFmpeg.cpp
+--- fs2_open/code/mod_table/mod_table.h 2023-02-11 13:13:50.000000000 +0100
++++ fs2_open/code/mod_table/mod_table.h 2023-02-11 13:57:44.162716081 +0100
+@@ -124,7 +124,6 @@
+ } Shadow_disable_overrides;
+ extern float Thruster_easing;
+ extern bool Always_use_distant_firepoints;
+-extern bool Discord_presence;
+ extern bool Hotkey_always_hide_hidden_ships;
+ extern bool Use_weapon_class_sounds_for_hits_to_player;
+ extern bool SCPUI_loads_hi_res_animations;
+--- fs2_open/code/mod_table/mod_table.cpp 2023-02-11 13:13:50.000000000 +0100
++++ fs2_open/code/mod_table/mod_table.cpp 2023-02-11 13:57:15.745714737 +0100
+@@ -12,7 +12,6 @@
+ #include "globalincs/version.h"
+ #include "graphics/shadows.h"
+ #include "localization/localize.h"
+-#include "libs/discord/discord.h"
+ #include "mission/missioncampaign.h"
+ #include "mission/missionload.h"
+ #include "mission/missionmessage.h"
+@@ -128,34 +127,10 @@
+ shadow_disable_overrides Shadow_disable_overrides {false, false, false, false};
+ float Thruster_easing;
+ bool Always_use_distant_firepoints;
+-bool Discord_presence;
+ bool Hotkey_always_hide_hidden_ships;
+ bool Use_weapon_class_sounds_for_hits_to_player;
+ bool SCPUI_loads_hi_res_animations;
+
+-static auto DiscordOption = options::OptionBuilder<bool>("Other.Discord", "Discord Presence", "Toggle Discord Rich Presence")
+- .category("Other")
+- .default_val(Discord_presence)
+- .level(options::ExpertLevel::Advanced)
+- .importance(55)
+- .change_listener([](bool val, bool) {
+- if(Discord_presence){
+- if (!val) {
+- Discord_presence = false;
+- libs::discord::shutdown();
+- return true;
+- }
+- } else {
+- if (val) {
+- Discord_presence = true;
+- libs::discord::init();
+- return true;
+- }
+- }
+- return false;
+- })
+- .finish();
+-
+ void mod_table_set_version_flags();
+
+ SCP_vector<std::pair<SCP_string, gr_capability>> req_render_ext_pairs = {
+@@ -1128,9 +1103,6 @@
+ if (optional_string("$Use distant firepoint for all turrets:")){
+ stuff_boolean(&Always_use_distant_firepoints);
+ }
+- if (optional_string("$Enable Discord rich presence:")) {
+- stuff_boolean(&Discord_presence);
+- }
+
+ if (optional_string("$Always hide hidden ships in hotkey list:")) {
+ stuff_boolean(&Hotkey_always_hide_hidden_ships);
+@@ -1285,7 +1257,6 @@
+ Lead_indicator_behavior = leadIndicatorBehavior::DEFAULT;
+ Thruster_easing = 0;
+ Always_use_distant_firepoints = false;
+- Discord_presence = true;
+ Hotkey_always_hide_hidden_ships = false;
+ Use_weapon_class_sounds_for_hits_to_player = false;
+ SCPUI_loads_hi_res_animations = true;